SolderedElectronics / Inkplate-Arduino-library

Inkplate family Arduino library. The easiest way to add e-paper to your project.
https://inkplate.readthedocs.io/en/latest/arduino.html
GNU Lesser General Public License v3.0
250 stars 78 forks source link

Inkplate6 wake up on touchpad continually firing #231

Closed amcox closed 8 months ago

amcox commented 11 months ago

On an Inkplate6, e-radonica version, the wake on touchpad example in the Inkplate library does not work. The board continually wakes up immediately from sleep, displaying "Wakeup caused by external signal using RTC_IO".

I see the note in the example code that some boards need a pull-up resistor, and the behavior appears similar, but the link there points only to a discussion related to the Inkplate6 Color, which appears to have a different board layout.

rsoric commented 11 months ago

Hi @amcox,

ran tests on this today and I couldn't figure it out, turn out that in that example, in the setup function, the #ifdef line is written wrong:

// Different I/O expander has been used on Soldered Inkplate V2 board and original Soldered Inkplate.

#ifdef ARDUINO_INKPLATE6PLUS
    display.setIntOutput(1, false, false, HIGH, IO_INT_ADDR);
    display.setIntPin(PAD1, RISING, IO_INT_ADDR);
    display.setIntPin(PAD2, RISING, IO_INT_ADDR);
    display.setIntPin(PAD3, RISING, IO_INT_ADDR);
#elif ARDUINO_INKPLATE6V2
    display.setIntPin(PAD1, IO_INT_ADDR);
    display.setIntPin(PAD2, IO_INT_ADDR);
    display.setIntPin(PAD3, IO_INT_ADDR);
#endif

should really be

// Different I/O expander has been used on Soldered Inkplate V2 board and original Soldered Inkplate.
#ifdef ARDUINO_ESP32_DEV
    display.setIntOutput(1, false, false, HIGH, IO_INT_ADDR);
    display.setIntPin(PAD1, RISING, IO_INT_ADDR);
    display.setIntPin(PAD2, RISING, IO_INT_ADDR);
    display.setIntPin(PAD3, RISING, IO_INT_ADDR);
#elif ARDUINO_INKPLATE6V2
    display.setIntPin(PAD1, IO_INT_ADDR);
    display.setIntPin(PAD2, IO_INT_ADDR);
    display.setIntPin(PAD3, IO_INT_ADDR);
#endif

please give that a try, it worked as expected on my device.

-Rob

p.s. Thanks @BornaBiro!

amcox commented 11 months ago

Perfect, that solves the issue. Thank you very much for your help!

rsoric commented 11 months ago

Great to hear! We're going to correct this in a new version of the library very soon so I'll leave the issue open until then.

Hope you enjoy making stuff with Inkplate, if you have any other questions or issues you run into, let us know here or via our contact form.

rsoric commented 8 months ago

Closing this issue as there's no more activity.