Minor potential inconsistency in the documentation
Posted: Sun Jul 25, 2021 6:48 am
This refers to the following section: https://docs.micropython.org/en/latest/ ... interrupts
The section stars with
The example the continues with the following sample code for configuring the interrupts:
The minor issue here is that the above code will not create hard interrupts but soft interrupts according to the documentation found here: https://docs.micropython.org/en/latest/ ... ne.Pin.irq The test at this link clearly states that interrupts are created as soft interrupts by default.
Can someone either explain to my why my logic is wrong, or point me to a place where I can create a pull request or similar for an update to the tutorial?
The section stars with
(My emphasis)All pins except number 16 can be configured to trigger a hard interrupt if their input changes. You can set code (a callback function) to be executed on the trigger.
The example the continues with the following sample code for configuring the interrupts:
Code: Select all
>>> p0.irq(trigger=Pin.IRQ_FALLING, handler=callback)
>>> p2.irq(trigger=Pin.IRQ_RISING | Pin.IRQ_FALLING, handler=callback)
Can someone either explain to my why my logic is wrong, or point me to a place where I can create a pull request or similar for an update to the tutorial?