Skip to content

What happens, when an interrupt is called? #16918

Answered by bixb922
bcux asked this question in ESP32
Discussion options

You must be logged in to vote

Does the while-loop stop and the active core runs the interrupt (edge1 or edge4) or does the second core the job with the interrupt?

Micropython only uses core 1 on the ESP32 family of processors. Core 2 is reserved for the operating system and the underlying runtime, but that is transparent.

Micropython will complete the current instruction in the while loop, call edge1 or edge4, and then return to the next instruction. Interrupts are only served between instructions, so you need not worry about half-completed instructions.

What happens, when egde1 is running and edge4 is called?

Edge1 will complete, then edge4 is called, and then control will return to the next instruction in the wh…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@bcux
Comment options

Answer selected by peterhinch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
ESP32
Labels
None yet
2 participants