Go Down

Topic: mac renaming serial port after every restart (Read 965 times) previous topic - next topic

Hello,
Can someone please help me deal with this issue, I have an arduino installed on a mac mini 10.7 and it is renaming my arduino device serial port after every startup. I am communicating with the arduino via firmata through an external program, where I am setting the serial port name by hand. Everytime my mac renames the serial port, my program can no longer find the arduino.

My question is simple, how do I keep the device name consistent with my arduino? If the name changes, the system simply cannot run. Or, can anyone please help me find a way to manage this issue another way. I need to find a solution to this issue, so any help would be greatly appreciated.

Thank you!
erik

PaulS

Quote
I am communicating with the arduino via firmata through an external program, where I am setting the serial port name by hand. Everytime my mac renames the serial port, my program can no longer find the arduino.

What external application? That program may be able to try to find the Arduino, wherever it is. The Arduino IDE can.

Its a c++ program I wrote using openframeworks. The problem is that it is being installed into a venue where an attendant with presumably no computer knowledge will be starting up the system. At the moment I have a very convenient click-the-icon-and-everything-will-start setup, but this problem is making things much more difficult.

The more difficult method would be to write something that detects serial ports like the arduino IDE and then leave some instructions for the attendant like "when starting the program each day, be sure to choose the serial port that titled 'usbmodemxxxx'" and hope that they get it right. But that just seems like such a recipe for disaster...

Any ideas?

PaulS

Quote
The more difficult method would be to write something that detects serial ports like the arduino IDE and then leave some instructions for the attendant like "when starting the program each day, be sure to choose the serial port that titled 'usbmodemxxxx'" and hope that they get it right. But that just seems like such a recipe for disaster...

Only slightly more complicated than the first part of your statement is to, after you generate the list (which won't be very long), try to open each port. If successful, wait a bit (for the Arduino to reset) and then send a message. If you get the expected response, then that must be the port that the Arduino is connected to, as it is astronomically unlikely that some other device would generate the expected response. If you don't get the expected response, close the port move on to the next one.

No idiot operators were harmed in the making of the correct connection.

Go Up