Fyi. Writing Pico PIO code. A read from a GPIO takes...3.5 clock cycles. I think. (Plz no sue.) I tested several wildly different clock speeds. You can do INPUT_SYNC_BYPASS with `hw_set_bits(&PIO->input_sync_bypass, 1u << PIN);` and it goes down to like 1.1 cycles, but the docs warn the PIO could summon nasal demons if it reads … Continue reading Raspberry Pico GPIO latency