Site Logo
Dating online > 18 years > C# get com port friendly name

C# get com port friendly name

Site Logo

Posted by dariosantarelli on October 18, When using the SerialPort. GetPortNames method, you are querying the current computer for a list of valid serial port names. The port names are obtained from the system registry if the registry contains stale or otherwise incorrect data then this method will return incorrect data. The limit of this approach is that you get just an array of port names e.

SEE VIDEO BY TOPIC: 11: Get User Input In C# - Preparing You For Project - C# Tutorial For Beginners - C Sharp Tutorial

Content:

Subscribe to RSS

Site Logo

Sign In Register. Quick Links Categories Recent Discussions. Categories I also have another microcontroller on this board that is sitting and watching usb traffic and interfacing with the propeller and other components. My chief concern is how to find the ftdi part from a windows C environment. I can open a serial port and start walking thru each com port until something answers on the board, but I would like a real solid way to id the ftdi part, and then know exactly what COM port it is setup on.

For example, think about Parallax's IDE for the propeller. How does this tool ID the eval board? Very cool, but there doesnt seem to be an interface to get the COM port out of this.

Anybody out there know a good approach, or maybe someone from parallax can tell me how they do it in the prop IDE. Thanks, Krillis. The PropTool simply scans each serial port asking if a Propeller is there and looks for a response. Can someone from Parallax tell me what they do with more detail, so I can try to set things up to do the same? I was hoping they were taking advantage of the ftdi capabilities in the driver to read the ChipID or some kind of description field, and then using that info to discover the exact com port.

Can you help? Jeff Martin Posts: Hi Krillis, Hippy is correct, the Propeller Tool determines what serial ports are present on the system, then it opens each of them, one at a time, and executes the Propeller Chip connection protocol basically a toggle of the DTR control line and transmission of a stream of data that the Propeller Chip recognizes and responds to to determine which port has a Propeller on it.

I "highly" recommend you use these API calls from your C application, because reading the appropriate parts of the registry directly only works if the user that is logged in at the time has sufficient security permissions to access hardware information in the registry We ignore the parallel port entries.

By the way, when I had to figure out how to do this stuff, I couldn't find ANYONE with this knowledge willing to talk; so the above is the result of perhaps hours of my research and experimentation and I don't know how many millimeters of lost hair line.

I hope I've saved you a lot of unnecessary loss of time and hair. Good luck! Thanks for the detailed reply, Jeff. I will be going down this path for my application, so if I find alternatives that may work better in c , I will post the news here.

Thanks again, Krillis. Sign In or Register to comment.

DISABLE ADBLOCK

Sometimes we require to communicate with an external device like a printer, microcontroller board or any serial device using the serial port of a windows machine. We can use any one of them for serial communication but sometimes we require to create our own custom serial application for communication. In windows, it is easy to create the custom serial application using the win32 API. In this blog post, we will learn serial port programming using the Win32 API.

Want to reply to this thread or ask your own question? You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

The modem creates 2 serial ports. The second port is used to get vital information from the modem, such as signal quality; to send and receive text messages; and a whole host of other functions. I am writing an application that will wrap up some of the features provided by the second port. What I need is a sure fire method of identifying which COM port is the spare one.

How to get friendly names for COM ports in C#

Recently I was developing a little application that needed to enumerate existing COM ports on a machine and then display them in a menu. Generally, this task is quite simple to accomplish:. However, the tricky part was that I wanted to display human-friendly names that identify the device similar to they way they are displayed in the Device Manager. Well, this turned out to be a little more complicated than I thought. There are a couple of WMI objects that one could enumerate to get a list of ports. However, none seem to produce a complete set. Unfortunately, this method does not actually return all COM port devices.

C# - Getting the FriendlyName from USB Serial Port?

A Developer. An Eweek. Does anybody have a code snippet? You should start by doing a bit of general research on WMI, which is implement in.

Pages: [1].

As an embedded developer who writes desktop software mostly for configuration of, and data download from, peripheral devices, I use serial data streams a lot. C and the. NET Framework provide a rapid application development that is ideal for early development that needs to track changing requirements as hardware designs evolve.

FTDI COM Port ID using C# on windows

By using our site, you acknowledge that you have read and understand our Cookie Policy , Privacy Policy , and our Terms of Service. Code Review Stack Exchange is a question and answer site for peer programmer code reviews. It only takes a minute to sign up.

By using our site, you acknowledge that you have read and understand our Cookie Policy , Privacy Policy , and our Terms of Service. Stack Overflow for Teams is a private, secure spot for you and your coworkers to find and share information. I could get COM26 and etc. How could I do that? That isn't the name of the serial port; it is COM The name listed in the device manager is probably the name of the device providing the emulation.

SerialPort.GetPortNames with Friendly Names

Select all Open in new window. IT issues often require a personalized solution. Get Free Limited Access. Why EE? Get Access. Log In.

Apr 27, - reg file, modify the “FriendlyName” and “PortName” in the file for each port which needs to re-assigned. Figure 6 - Modifying the lereposduguerrier.com

Sign In Register. Quick Links Categories Recent Discussions. Categories

How do I get device information from specific port names?

.

Get the name of the com port and the devices connected to it

.

.

.

.

.

Comments: 5
  1. JoJojas

    I apologise, but, in my opinion, you are mistaken. I suggest it to discuss. Write to me in PM, we will talk.

  2. Gumuro

    Certainly is not present.

  3. Nem

    Rather valuable message

  4. Mir

    In my opinion you are mistaken. Let's discuss.

  5. Dotaxe

    I recommend to you to come for a site on which there are many articles on this question.

Thanks! Your comment will appear after verification.
Add a comment

© 2020 Online - Advisor on specific issues.