wokwi / rp2040js

A Raspberry Pi Pico Emulator in JavaScript
MIT License
389 stars 40 forks source link

PIO doesn't support Atomic Register Access #74

Closed urish closed 3 years ago

urish commented 3 years ago

Some SDK functions rely on atomic writes (section 2.1.2 in the datasheet). One example is pio_interrupt_clear(), which currently has no effect and thus does not clear the IRQ flag, causing the corresponding interrupt to be fired repeatedly. The fix in 5bc9699491021a4c1985c8a10089b446658515b4 surfaced this bug.