Skip to content

calling sleep_ms inside an interrupt handler causes lockup #108

Closed
@Lard4

Description

@Lard4

Summary: when you call sleep_ms inside of an interrupt handler, some sort of infinite loop occurs inside of the hardware timer. Specifically, picoprobe/gdb is pointing to the code hanging somewhere in this function:

uint32_t hi_target = target >> 32u;

To reproduce: build/flash https://github.com/Lard4/pico-irq-test then when GP22 goes high (gets the interrupt), it turns off the LED then hangs.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions