Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Debug COM port read/write using software/virtual COM port and console/terminal on the other end

I have a Delphi application that reads/writes to a COM port connected to a large hardware device, so I don't usually have the hardware available during development. That said, the communication protocol is fairly simple, so I can generally do the development and have someone onsite test it, and it usually works. Occasionally I run into a harder problem, though. To solve this, I'd like to setup a virtual COM port where one side of the COM port is my application and the other side is a very simple COM port debug console (similar to the old modem terminal programs), where ASCII commands my app sends are logged onscreen and I can type in some ASCII command to send back to my application to simulate the hardware device. I've been unable to find any tools that provide a virtual/software COM port and a console/terminal to debug with. Does anyone have software suggestions and steps to set something like this up?

The software/virtual COM port and terminal need to support Windows 7 64-bit (or Vista 32 if necessary).

like image 837
Anagoge Avatar asked Oct 06 '10 05:10

Anagoge


People also ask

What are virtual COM ports used for?

A USB Virtual COM Port allows you to use a USB Interface to talk to serial devices. This essentially gives users a simple pathway to communicating to peripherals using software development tools that support serial communications, a relatively common standard is most programming languages.

How do I find my COM port on console?

Locate the correct COM portRight click on the Windows Start Icon and select "Device Manager." Open the "Ports (COM & LPT)" Section. Locate the "PI USB to Serial" and note which COM port it is using.

How do I check COM port connections?

1) Click Start. 2) Click Control Panel in the Start menu. 3) Click Device Manager in the Control Panel. 4) Click + next to Port in the Device Manager to display the port list.

How do I open a virtual COM port?

In the device “Properties”, open the “Advanced” tab and check whether the “Load VCP” option is enabled. Then, click OK. Unplug your USB device and connect it to your PC again. Now your operating system should be able to recognize the device, and Virtual COM Port Driver should be loaded.


1 Answers

I'm doing something similar with paired virtual COM ports created by http://com0com.sourceforge.net/

like image 72
Stijn Sanders Avatar answered Sep 30 '22 14:09

Stijn Sanders