I have a Processing program that reads data sent to the serial port by an Arduino. When I go to device manager it shows that the Arduino is plugged into COM 4, however in order to get Processing to read the data the number I need for the COM in the following line is 2:
String portName = Serial.list()[2]
Why do the numbers not match?
Thanks!
Serial.list()[2]
can easily refer to COM4 as well.