diff --git a/eink.hpp b/eink.hpp index ce545fc..0704cdb 100644 --- a/eink.hpp +++ b/eink.hpp @@ -164,9 +164,6 @@ class Eink { template static void draw(const RleImage &rleImage) { - setRamXPos(); - setRamYPos(); - constexpr auto sendImageChannel = [](const auto command, const auto &image) { using image_t = std::remove_cvref_t; @@ -189,9 +186,6 @@ class Eink { static void clear(const Color color = Color::WHITE) { - setRamXPos(); - setRamYPos(); - constexpr auto getFillData = [](const auto &color) -> std::pair { switch (color) { case Color::BLACK: @@ -284,6 +278,10 @@ class Eink { sendChannel(Cmd::WRITE_RAM_BLACK); sendChannel(Cmd::WRITE_RAM_RED); + + setRamRange(); + setRamXPos(); + setRamYPos(); } template