Hello,
I just want to know how can you differentiate between 3 Arduino Mega's connected to same PC. Do they have different PID ?
I have this python code which checks the 'com' ports and fetch me any Arduino connected port and I send different serial command.
example : I want to send "a" only to Arduino Mega 1, "b" only to Arduino Mega 2. So how do I find the COM port of mega 1, mega 2 and mega 3. So if they have any different PID I can use if/else statement to get the COM port.
Send to the COM ports a command that returns a device ID via Serial. The built-in signature (see "29.6.10 Reading the Signature Row from Software" only contains the chip type (see "30.3 Signature Bytes") but no individual ID.
What is displayed when you do Tools/Get Board Info in the IDE ?
You could, of course, send a query message to each board and have it reply with its ID from a sketch running on it
I'd handle that between the PC software and the uC software.
I'd give each mega an ID and give all three a getID function.
Then your PC software can query each and record it on launch.