pico-sdk icon indicating copy to clipboard operation
pico-sdk copied to clipboard

Bug 1668 v2 - Provide method to prevent init of SYS_CLK, when left on during 'lightsleep'

Open mungewell opened this issue 1 year ago • 5 comments

During 'lightsleep' user may want to keep some clocks running (for example PIOs), but at present microPython calls 'clock-init()' causing the SYS_CLK to be reinitialized.

This patch allows microPython to provide the previously used 'sleep_en0 & sleep_en1' signifying which clocks stayed on. As most are dependant of SYS_CLK it can be inferred that this does NOT need to (/should NOT) be re-initialized.

mungewell avatar Mar 18 '24 00:03 mungewell

Yes, should be a logical "&&".

I'll update PR and add some documentation. Thanks.

mungewell avatar Mar 19 '24 19:03 mungewell

I removed the tabs.

Do you want the whole series resubmitted (_v3?) as a single patch/pull request?

mungewell avatar Mar 23 '24 18:03 mungewell

That's not my decision to make, so leave it as-is for now unless asked otherwise :slightly_smiling_face:

lurch avatar Mar 23 '24 18:03 lurch