For my project i have two servos and i need to set them to the right angle every time the program loops. In order do this i use a serial usb connection and send a number to set one of the servos. But for the second servo i need to pass two numbers in one message. I was thinking about a string “X,Y” that i could send and split it between the comma on the arduino, but it seems that i can only send numbers and only 1 number at that over the serial port? How would i go about doing this.
Serial.write("90,90");//does not work...
You can do:
Or: