MCU Processing while outputting in Serial

Tags: #<Tag:0x00007f038f3c20c8> #<Tag:0x00007f038f3c1ec0>


When outputting serial data on the RX TX pins, can The microcontroller still read inputs, my first assumption is yes, and that it sets a serial bit HIGH then runs normal processes and then comes back a short time later to set the next bit HIGH or LOW and so on. I guess I’m asking if Serial output halts the processor until the task is finished.

The context is that I am trying to read data from an encoder which can send many thousands of pulses in a very short time. At 1024 steps per revolution, the Photon/Argon can handle this task very easily, but I was wondering it would be able to see these steps while outputting serial data. The steps per revolution can go up to 65,536, but I plan to stay on the lowest setting for this application.

Thanks a lot,


The UART is hardware driven.
The software only placed data into a buffer and the hardware takes that data out in the background via DMA or interrupt driven (in case of ParticleSoftSerial).

What is a very short time?
If you are intending to get 65536 pulses per second you are looking at 15µs per pulse which is definetly demanding even when using interrupts.