virtual com port ?

i understand this has little to do with arduinos, but

i have an application that gets input from a com port. it there a way to create a virtual com port on a Window PC such that to separate applications running on that PC can communicate thru it?

i'm familiar with unix pipes and such. but the application is using a com port

I think the search term would be "com port emulator", not "virtual com port". No experience with them.

https://www.google.com/search?&q=com+port+emulator+windows+10

each time you plugin a device which has a CP2102 or CH340 or some other chips a "virtual COM-Port" gets installed on the Computer. You can buy such devices at lots of places for a few bucks

https://www.banggood.com/search/usb-serial-adapter.html

best regards Stefan

a virtual port has no hardware

gcjr:
a virtual port has no hardware

So how would you call this thing you can plug-into an usb-port of a computer and in the device-manager apears an entry like "USB-Serial CH340 (COM18)" ?
best regards Stefan

gcjr:
a virtual port has no hardware

That's going to make it very difficult to connect anything to it

gcjr:
it there a way to create a virtual com port on a Window PC such that 2 separate applications running on that PC can communicate thru it?

i'm familiar with unix pipes and such. but the application is using a com port

The virtual com port that @gcjr is referring to is a com port emulator or terminal emulator (and hence no hardware); if not mistaken, in linux it's a pty (pseudo terminal).

It’s definitely a hacky kludge, but you could plug 2 USB<–>Serial converters into the PC and then connect the TTL Serial sides TX–>RX.

trying to avoid that for such a simple project.

recently used a mega connected to a com port to emulate some hardware an application communicated with via rs-422. would be overkill in this case.

was hoping for a quick and easy answer for this, as well as future challenges.

See reply #1; did you try?

that was a google search. wasn't expecting to have to install some application. may look back later

in the mean time, the project i needed it for is complete

I am still completely at sea as to what is required

No hardware implies that whatever is needed is software but the OP wasn't expecting to install any

No wonder I am confused

Windows does not come with tools that Linux users are used to :wink:

@UKHeliBob
It's my understanding that @gcjr wants a com port internal to Windows so two Windows applications can communicate over it.

for those interested

ethernet address 127.0.0.1 is reserved for use as the machine the application is running on. it allows different applications to connect to one another (different port #s) without needing to know the IP address of the machine they run on

i had thought something similar might be available on Windows for a com port, something 2 different applications could connect to for testing.

the application i was working on received information thru the com port from an arduino. i don't have the arduino hardware and thought a simple way to test would be to use a terminal emulator, a program that runs on a PC that allows you to tx/rx to a serial interface. if there was a virtual com port(s) (e.g. com99 and com100) both applications could be run and tested together using those ports.

since i run cygwin which provides a linux like environment, having a /dev/, i see a pty0 and a pty1. using those device names, i was able to open 2 terminal emulators on my PC and when i entered keypress on the one emulator, they appears on the other.

Term ls /dev/
clipboard  console  kmsg    ptmx  pty2    sda1  sda4  sdb1  ttyS3    zero
conin      dsp      mqueue  pty0  random  sda2  sda5  shm   urandom
conout     full     null    pty1  sda     sda3  sdb   tty   windows

when i plug a USB device into my laptop, i see a something like /dev/ttyS3 appear.

so i believe Window can do this. not sure how; presumably which 2 com ports

i had thought something similar might be available on Windows for a com port, something 2 different applications could connect to for testing.

Of course there are, and you would have found them if you had even tried the search that sterretje suggested in reply #1.

One of them is com0com

The Null-modem emulator allows you to create an unlimited number of virtual COM port pairs and use any pair to connect one COM port based application to another. Each COM port pair provides two COM ports. The output to one port is the input from other port and vice versa.

a null modem is a pair of rs-232 cables that have the tx and rx leads cross wired, avoiding the need for a modem to connect to different machines.

i have a couple rs-485 adapters. i could have cross wired two of them. or i could have used the mega instead.

i really do mean virtual, no hardware. the Windows equivalent of the /dev/pty0 and /dev/pty1 i already described.

So, you STILL have not bothered to look. I give up.

i did quickly, but i see emulators and hardware.

i demonstrated that my laptop has the capability using linux techniques.

i said i would look thru the links later when i have time. in the mean time the project is complete

@gcjr expressed a lack of interest in installing any software, which I can appreciate.

These days however especially when the water is rising and there are unaddressed alligators I’ll try anything, which may explain the complete and totally undocumented mess my laboratory computer has become…

a7