Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

rp2: Can't wake from lightsleep with Pin IRQ #7035

Open
@peterhinch

Description

@peterhinch

On a pin change this code sample toggles the LED but never outputs "got here".

frommachineimportPin,lightsleepp25=Pin(25,Pin.OUT)p0=Pin(0,Pin.IN,Pin.PULL_UP)deffoo(_):p25(notp25())# Toggle the LEDp0.irq(foo,trigger=Pin.IRQ_FALLING)whileTrue:lightsleep()print('Got here')

Thedocs indicate that to fix this, the IRQ should be instantiated withwake=machine.SLEEP. Unfortunately this constant does not exist.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp