Hello and Happy New Year my lovely Armbian friends!
I am aware that this topic is a reoccurring one, having abused the search function beyond its functional capabilities I have found the following threads that deal with somekind of sleep and wake with separate pins for each function:
how to wake up OPi3
gpio to inform of system shutdown
I would like to know if it is possible to have 1 pin act as both sleep and wake depending on its voltage? - if so how could i modify one of those dts in the first link?
I am new to dts so not sure how the pin mappings are assigned.
for example,
I have a DRV5053 hall effect sensor that will act as a magnetic switch, when the magnet is near (sleep here) the output voltage increases to max of 2v, when the magnet is away (wake here) the output voltage drops to near 0v.
I am using pygame to run a GUI for a small oled screen, it is ok if the GUI restarts as it is launched after autologin by .bashrc (which i assume gets reloaded on system wake?) .. however I would like to use sleep and wake to preserve the current state within the GUI, as the boot time from completely disconnecting power & reconnecting (as if a physical switch) is a little long at around a full minute..
Thank you so much for your help