forked from Arduino/metronom
The tube library calls delay(100) after every display write and the BME280 library calls delay(100) when re-initializing after a failed transfer. Inside the TC3 timer ISR the SysTick interrupt is blocked, so micros() stops advancing past ~1ms and delay() can spin forever when its start sample lands exactly at the bottom of the micros() sawtooth. All clocks derive from the same 48MHz source, so the ISR phase is locked and one specific code path (display update on a falling temperature reading) hits the fatal window reproducibly. ISRs now only raise flags; sensor reads, display updates and timer rescheduling run from loop(), where delay() works normally. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
1.1 KiB
1.1 KiB