Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork8.2k
Open
Description
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
Labels
No labels