I would suggest a dedicated thread that pulls requests from a ConcurrentQueue
and operates on the UART.
All other threads should Enqueue
requests and continue on with their work, so there's no waiting involved. Does that fit your needs?
Here's the documentation for ConcurrentQueue