Serial Communication using USB, Python


I'm very new to Arduino.

I have created a program for controlling servo movements based on face detection in python, the angles are sent through USB to Arduino.

but I need to control 5 servos at a time, So how can I control all servos at real-time,
How can I read serial data from USB (while doing another process while executing a for loop ), is it possible to multithread in Arduino UNO?

Have a look at this Python - Arduino demo and at Serial Input Basics, especially the 3rd example.

Why do you think you need multithreading on the Arduino?

Just send the 5 servo values in a single message and have the Arduino write the values to the appropriate servos.


thank you for your replay friend