I have some devices that, when I plug in, will display a unique name, usually a serial number, as opposed to "COM #" is there any way I can have my Arduino Uno (or Mega) give itself a different name in my program's set up structure?

Edit: My purpose here is that I'm writing a program on the computer side that needs to find the Arduino among multiple possible COM ports. I'm deploying this program over multiple computers that I don't have admin access to so changing the registry is likely a non-starter.

Right now, I'm going through each port and sending a *idn?\n (which my program responds to with a specific string). For another device I have, I can search the possible connections for a port named [device serial number] and test that one first.

  • When I plug in my Arduino, I'd like it to identify to the computer as an arbitrary string specified in the setup phase of the code as opposed to "COM #" as it does by default
    – ATE-ENGE
    Commented May 16, 2017 at 13:09
  • 2
    So you don't want the default name of that specific serial port that is COM# Am I correct ? Please correct me if I have mistaken. Commented May 16, 2017 at 13:16
  • 3
    What platform are you using to connect to your Arduino, Windows or Linux? (Suspect Windows) Commented May 16, 2017 at 13:27
  • 4
    "will display a unique name" .... where do they display this "unique name"?
    – Majenko
    Commented May 16, 2017 at 13:28
  • I am using windows, That is a correct understanding. In terms of display location: when given the option on my computer to connect to various devices, I can select COM port 1 -> COM port N or a string that represents the serial number of a device like "Tektronix 25145134514"
    – ATE-ENGE
    Commented May 16, 2017 at 13:43

2 Answers 2

  1. If you read this So it says:

    You'll have to change the software on the Arduino USB chip itself, and you may need to modify the drivers for the Arduino USB interface on the computer side. It's not trivial, and probably not worth it.

Then according to this you need to toggle and tinker with the Driver software

  1. Wait that means it is not the correct answer. So according to your plan you need to maybe toggle with IDE that is instead of manually changing the ports you want the software to identify on its own. So for that purpose you have to tweak with Arduino board bootloader, and say it send a message to the Arduino IDE on startup . After that you have to tweak with Arduino ide source codes and then tweak it to Search for that message and then it reads down the address that is its COM
  • Thanks! That's too bad that there isn't an easier solution. (As a side note I think you mean to say "tinker with," in US English at least "tinkle," is slang for urinate XD )
    – ATE-ENGE
    Commented May 16, 2017 at 14:11
  • tinkle and tinker are different things, just don't tinker with you winkle when tinkling :) Commented May 16, 2017 at 15:15

On Windows you can change the "Friendly names" assigned to devices and COM ports are devices. The process is basically open the device manager, open the device properties, find the 'Device Key' and then locate that in the registry and change the 'Friendly Name' value.

See this page for more details: https://www.eightforums.com/customization/15321-tutorial-how-change-device-names-device-manager.html

  • Ok, is there a way to do this on my Arduino so that it would be constant from computer to computer?
    – ATE-ENGE
    Commented May 16, 2017 at 13:47
  • 1
    No. The name is generated by the device driver on the PC. The Arduino has nothing to do with it. Commented May 16, 2017 at 15:14
  • Often those names can be used to ensure that every time you plug into a specific USB port on the PC you get the same COM number.
    – SDsolar
    Commented May 17, 2017 at 8:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.