From 0ad99f5c6ead2844aa3e85a9c2317922f33c4d96 Mon Sep 17 00:00:00 2001 From: BlackMark Date: Thu, 26 May 2022 16:03:50 +0200 Subject: [PATCH] Refactor interface to be fully static --- eink/eink | 2 +- eink/main.cpp | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/eink/eink b/eink/eink index 1c01b17..2cb38b9 160000 --- a/eink/eink +++ b/eink/eink @@ -1 +1 @@ -Subproject commit 1c01b17f4d0100127c54aeef16c09c99a3f277b1 +Subproject commit 2cb38b9fdcc4bec48d3b17b2b704a21ada23794a diff --git a/eink/main.cpp b/eink/main.cpp index d46ef5c..ff7e71a 100644 --- a/eink/main.cpp +++ b/eink/main.cpp @@ -23,19 +23,19 @@ int main() serial << F("e-Paper demo") << F("\r\n"); - Epd eink; - eink.Init(); + auto einkDisplay = eink::Eink<200, 200, spi_t, io::P::C1, io::P::C0, io::P::C2>{}; + einkDisplay.init(); serial << F("e-Paper init") << F("\r\n"); serial << F("e-Paper clear") << F("\r\n"); - eink.DisplayClear(); + einkDisplay.clear(); serial << F("e-Paper draw") << F("\r\n"); - eink.DisplayFrame(IMAGE_BLACK, IMAGE_RED); + einkDisplay.draw(IMAGE_BLACK, IMAGE_RED); serial << F("e-Paper sleep") << F("\r\n"); - eink.Sleep(); + einkDisplay.sleep(); while (true) { serial << F("e-Paper running") << F("\r\n");