Open c1570 opened 1 year ago
Writing to the UART never blocks at the moment: https://github.com/wokwi/rp2040js/blob/61e1d2cc9953eb049f7c45f8f0d3acc39c4c55e1/src/peripherals/uart.ts#L76 This also means that printf() using pico_stdio_uart is way faster in emulation than in reality quite often (basically whenever the silicon 8 byte TX buffer is exhausted).
Additionally, using the UART doesn't actually change the GPIO pins but only triggers the onByte() callback: https://github.com/wokwi/rp2040js/blob/61e1d2cc9953eb049f7c45f8f0d3acc39c4c55e1/src/peripherals/uart.ts#L119
Probably not a big deal but worth documenting anyways.
Oh - good thing you mentioned this, one of the first things I was about to do was depend on those GPIO pins being written, hahaha
Writing to the UART never blocks at the moment: https://github.com/wokwi/rp2040js/blob/61e1d2cc9953eb049f7c45f8f0d3acc39c4c55e1/src/peripherals/uart.ts#L76 This also means that printf() using pico_stdio_uart is way faster in emulation than in reality quite often (basically whenever the silicon 8 byte TX buffer is exhausted).
Additionally, using the UART doesn't actually change the GPIO pins but only triggers the onByte() callback: https://github.com/wokwi/rp2040js/blob/61e1d2cc9953eb049f7c45f8f0d3acc39c4c55e1/src/peripherals/uart.ts#L119
Probably not a big deal but worth documenting anyways.