Skip to content

add_repeating_timer_us only works with some values of delay_usΒ #737

@thaumatichthys

Description

@thaumatichthys

add_repeating_timer_us(-50, isr, NULL, &timer); is fine, but add_repeating_timer_us(-51, isr, NULL, &timer); will hang the pico.

A workaround is to call add_repeating_timer with a working delay value, and write the wanted value to the timer struct. timer.delay_us = -51

I'm not sure if this is mentioned in the C++ SDK documentation, but I could not find any mention of this.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions