Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 4057
  • Last Modified:

connecting virtual machine serial port to named pipe

I have a device that I need to program through a serial port.  The problem is my laptop doesn't a serial port.  I do however have a serial-to-USB cable that I can plug in.  I can then set it to use COM1.

So to program the device in question I have to boot to a floppy drive and run the programming application in a DOS environment.  In order for the serial-to-USB cable driver to work I have to have Windows running.  To work around this problem I thought I could use a virtual machine in Hyper-V or VirtualBox that could map a serial port to a named pipe.  Here's where I'm getting confused.

It would seem like what I need to do is somehow serve my COM1 port to a named pipe on my laptop.  I could then point the virtual machine to that named pipe.  I see how to point the virtual machine to a named pipe.  I just don't see how to "serve" that named pipe from my laptop.  I've read around about creating named pipes and such, but I still don't see how to map my COM1 port to the named pipe so I can then in turn connect to it with a virtual machine.

Is this possible to do?  Is my thought process flawed?
0
Zouleous
Asked:
Zouleous
2 Solutions
 
ZouleousAuthor Commented:
Interesting information in those links.  Thanks for that.  I'll continue studying them more, but the information is geared for VMware.  I'm using either Hyper-V (prefered) or Sun VirtualBox if I have to.  If you have anything geared more toward Hyper-V that would be great.  I think I understand how to set up the Hyper-V side to connect to the named pipe.  I think what I have to do is figure out how to get the COM port linked to the named pipe so I can then connect the Hyper-V machine to it.  Would you know how to do that part specifically?

There's a lot of information in the links you provided so I'll keep looking.
0
 
ZouleousAuthor Commented:
Just to be clear I'm trying to connect to the COM1 port on my laptop from a Hyper-V machine running on a server.
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
Michael SCommented:
COM Ports on Hyper-V do not work with the named pipes.  You would need to use a 3rd party solution like this:

http://www.fabulatech.com/network-serial-port-kit.html
0
 
ZouleousAuthor Commented:
I had looked at that software.  Not worth spending that much money for a something that's a convenience thing.  Interesting you say Hyper-V doesn't work with named pipes though.  This is straight from the Hyper-V Planning and Deployment guide:

"Each virtual machine is configured with 2 virtual serial (COM) ports that can be attached to a named pipe to communicate with a local or remote physical computer. "
0
 
Michael SCommented:
Actually the only way they work is for debugging, it's almost as if Microsoft never intended them to work. The Hyper-V Deployment guide also says this:

“Note:  No access to a physical COM port is available from a virtual machine"

Ben Armstrong, one of the guys from the MSDN blogs, actually quoted this:

"This is not possible with Hyper-V - we do not support the use of physical COM ports."

0
 
ZouleousAuthor Commented:
Not really the solution I was looking for, but it does address what's officially supported (or unsupported in this case).  Would have been nice to find a free 3rd part solution to accomplish this.
0
 
Michael SCommented:
Sorry to burst your bubble - I went through the same thing a long time ago and ran into the same problem - that's why I know about it not working.  Hope it works out for you.
0
 
Janett FiesCommented:
If you need need to access your serial device in virtual machine, you should use additional software, due to no virtual environment will see the serial port attached. Here are some great steps to access COM port in different virtual machines http://www.eltima.com/com-port-in-virtual-machine/
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now