Repository navigation
Conversation
tannewt
left a comment
There was a problem hiding this comment.
What feedback would you like from me? It looks like you intend on changing things to be closer to what I want already. (By entering deep sleep at exit for example.)
|
FYI, I'll make changes to the Python side of this in the next few days. |
|
@tannewt I was considering the following to be the final form of the api. import alarm
import alarm_io
import alarm_time
import alarm_touch
alarm_io.enable(board.IO6, level=1, pull=True)
alarm_time.enable(2.5)
alarm_touch.enable(board.IO8)
alarm.disable //Disable all alarms
alarm_io.disable //Disable all io alarms, similar for time & touch alarm.
//Go to light/deep sleep on code.py exit based on usb connection check.
|
|
I'd prefer each alarm type to be it's own object rather than just I likely won't have time until next week to help with this. #2796 is really what I'd like to see. |
|
|
I would like to point anyone looking for updates regarding deep sleep api to issue #2796, where the api is being actively discussed |
|
@microdev1 I will close this in favor of the PR I will be submitting, if that's OK with you. |
|
@dhalbert As discussed earlier on discord, there is still some work left to be done on the alarm modules... I have already got changes on my local branch. I am waiting for the api changes before pushing them. |
|
@microdev1 It went out of my head that you were still working on these. I am working in https://github.com/dhalbert/circuitpython/tree/sleep, but it does not even compile yet and has rough edges. I push regularly for backup purposes and just merged from upstream. The API implied in the #2796 is still a moving target, and my branch is the latest, though the API hasn't been re-reviewed completely by @tannewt yet. I am very focused at first on the narrow path of getting |
This PR implements deep sleep support in CircuitPython!
Port(s) supported: (as of this PR)
To-do:
code.pyfinishes