omi icon indicating copy to clipboard operation
omi copied to clipboard

Added Deep Sleep functionality

Open neooriginal opened this issue 1 year ago • 5 comments

Hey, First off please be patient with me since i have no experience with this and made this just using google and a few hours of searching through stackoverflow.

This code adds a deep sleep functionality using the 4. and 5. gpio pin (for dev kit v2). if there are any problems with the code lmk. you are also free to use this code as a new pr.

hope this helps

neooriginal avatar Aug 14 '24 01:08 neooriginal

We are not using firmware 1.5, all the firmware changes have been made in firmware 1.0.

That said, your deep_sleep code still can be integrated, but you might have to wait for https://github.com/BasedHardware/Omi/pull/576 and add it to it.

francip avatar Aug 14 '24 03:08 francip

Yes, I think with my code you can easily slip in the deep sleep code. My code uses a "fancy" state machine so I think you can slip in the function somewhere without changing too much. If you want I can write a state table so it would be easier to see where you could put it.

kevvz avatar Aug 14 '24 05:08 kevvz

Yes, I think with my code you can easily slip in the deep sleep code. My code uses a "fancy" state machine so I think you can slip in the function somewhere without changing too much. If you want I can write a state table so it would be easier to see where you could put it.

sure thanks :) Do you perhaps have discord for better communication? @neo_original is my tag

neooriginal avatar Aug 14 '24 05:08 neooriginal

Build is successfull. If anyone wants to test it for me, please build it yourself since i cant attach uf2

Cant test it myself yet

neooriginal avatar Aug 18 '24 04:08 neooriginal

Seems like shutting down works. Any idea how to start it?

neooriginal avatar Aug 20 '24 07:08 neooriginal

@Neotastisch We should probably wait for other hardware feature PRs like SD Card, Audio, Buttons, and Accelerometer working first. You can also setup a sleep pin-out in overlay and use in-built battery management elements in the actual libraries to cycle down components fully too. See: https://docs.zephyrproject.org/latest/services/pm/device.html

Not sure how you are handling wake-up without a force restart?

vincentkoc avatar Aug 24 '24 07:08 vincentkoc

@Neotastisch We should probably wait for other hardware feature PRs like SD Card, Audio, Buttons, and Accelerometer working first. You can also setup a sleep pin-out in overlay and use in-built battery management elements in the actual libraries to cycle down components fully too. See: https://docs.zephyrproject.org/latest/services/pm/device.html

Not sure how you are handling wake-up without a force restart?

still working on that. this pr also uses the new button handling so when its done it should work together seamlessly

neooriginal avatar Aug 24 '24 07:08 neooriginal

i killed my friend :( cant afford a new one.

anyone taking over this? Sorry

neooriginal avatar Aug 26 '24 08:08 neooriginal

aw man really sad, wanted to contribute

neooriginal avatar Aug 26 '24 08:08 neooriginal

@Neotastisch I think @ebowwa on discord reached out for sending you a new one, did you already sort that out?

josancamon19 avatar Aug 29 '24 21:08 josancamon19

@Neotastisch I think @ebowwa on discord reached out for sending you a new one, did you already sort that out?

I build mine myself, so probably not right?

neooriginal avatar Aug 31 '24 21:08 neooriginal

@kevvz @ro-kirchev can you guys check if this is going well? thanks

josancamon19 avatar Sep 01 '24 08:09 josancamon19

@Joan its an open-source build, where likely the button was broken off the board.

Replacement is handled.

On Sun, Sep 1, 2024 at 1:53 AM Joan Cabezas @.***> wrote:

@kevvz https://github.com/kevvz @ro-kirchev https://github.com/ro-kirchev can you guys check if this is going well? thanks

— Reply to this email directly, view it on GitHub https://github.com/BasedHardware/Omi/pull/597#issuecomment-2323239351, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATRFMNLHYPEKR6QDTF63JLTZULI2HAVCNFSM6AAAAABMPLN2J2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMRTGIZTSMZVGE . You are receiving this because you were mentioned.Message ID: @.***>

ebowwa avatar Sep 01 '24 09:09 ebowwa

@kevvz @ro-kirchev can you guys check if this is going well? thanks

I would not check it yet, it's not done yet. I pushed an untested update recently but could not test it since it broke

neooriginal avatar Sep 01 '24 09:09 neooriginal

Will redo it later

neooriginal avatar Sep 14 '24 06:09 neooriginal