Opened 17 years ago
Closed 14 years ago
#1273 closed defect (fixed)
serial ports problem
Reported by: | Iakov Kaabak | Owned by: | |
---|---|---|---|
Component: | uart | Version: | VirtualBox 1.5.6 |
Keywords: | Cc: | ||
Guest type: | other | Host type: | other |
Description
I am using VirtualBox 1.5.6 (VirtualBox_1.5.6-1_Win_x86.msi) on Windows XP. Guest system is Windows Server 2003 from en_windows_server_2003_with_sp1_enterprise.iso (MSDN). I configured virtual machine to have com port on Host Pipe, but it doesn't seem to work. When I look at guest's Device Manager, it shows no ports at all; when I look at its Resources view, it doesn't show serial port resources as used (standard COM1). I added COM2 to use physical port, and result is the same. On the other hand, when I run Process Explorer on host, it shows both handles as open by VirtualBox process.
So, the question is: how to have serial ports work? I really need only pipe (to connect WinDbg).
Change History (11)
comment:1 by , 17 years ago
comment:2 by , 17 years ago
I have the same problem with a Vista Business guest under a Windows XP host. No serial ports under the guest OS device manager, ports in use on host OS when virtualbox is running.
The serial port virtualization does work correctly on the same host with a Ubuntu 8.04 guest OS.
I need virtual serial port access to let the guest OS access an external modem connected to the host computer's COM1 port.
comment:3 by , 17 years ago
I had this problem with a Linux host, XP as guest and a USB serial port bridge. I solved it by going to "Add Hardware" in the Control Panel and adding the COM port manually. It was not detected, I had to go to the bottom of the list of "Installed Hardware" and select "Add a new hardware device". After that the COM port was listed and I could add it and work with it.
comment:4 by , 17 years ago
I have done more testing with VBox 1.6.0 on Win XP using a Vista guest. I have not been able to get COM1 to work in the Vista guest, but COM2 does seem to be recognized and does work. I have two serial ports configured for the VM. The first is set disconnected, and the second is set to redirect the host port COM1. The second port is recognized and used by Vista. I can access the external mode connected to the host computer's COM1 port using COM2 in the Vista guest.
comment:5 by , 16 years ago
Component: | other → uart |
---|
comment:6 by , 16 years ago
I used the workaround described by lesliev; it was not easy, requiring a dummy COM3 before COM1 could be created. Here is a excerpt from the log in case it helps someone.
Control Panel, Add Hardware
...
Yes, I have already connected the hardware: selected
Add a new hardware device (last on list)
Install the hardware that I manually select from a list: selected (skips useless search by Windows)
List all Hardware
Standard port types: Communications Port
Device Manager showed this created COM3, with a problem (address and IRQ not known).
Control Panel, Add Hardware
...
Yes, I have already connected the hardware: selected
Add a new hardware device (last on list)
Search for and install the hardware automatically: selected
Windows found a Communications Port
...
This created COM1. COM3 uninstalled.
comment:7 by , 16 years ago
On my system just enougth to do last step:
Yes, I have already connected the hardware: selected
Add a new hardware device (last on list)
Search for and install the hardware automatically: selected
Windows found a Communications Port
please include those info in manual!!!
comment:8 by , 16 years ago
I have exactly the same problem with Vista Business SP2 host and Vista Business SP1/SP2 guest.
I'm trying to setup a configuration for kernel debugging with WinDbg, and guest sees no COM ports in both Disconnected and Host Pipe mode (I can't try Host Device as the host has no physical COM ports). Whatever I tried, the guest simply doesn't see any COM ports.
I tried the suggestions by lesliev, catkin and axet with no success - ports added manually don't work (resource conflict), automatic scan finds nothing.
Any suggesstions how this could be overcome? Thank you!
comment:9 by , 15 years ago
i got my usb to serial PL2303 based adaptor working with ubuntu 9.10 host and XP as guest. I wanted it so as to run 8051 based burner software in XP. I have no physical com ports in my laptop. VBox version 3.2.4
In vbox serial port setting; enable serial port,port number COM1, port mode Host Device, create pipe option disappears, portfile path as /dev/ttyUSB0 (or whichever is yours, see by typing 'ls /dev|grep USB' as root) In XP go to control panel, add hardware, next, choose 'Yes i have ...', select 'Add a new hardware device' from bottom, select 'Search for and install ... (Recommended)' (important step), then select 'install communications port'.
try loopback test with 'hypertrm'
another method of enabling the adapter as usb device and installing its driver works but creates problems with devices during serial communication. The hypertrm test also fails there. Now i need not have to switch from ubuntu to vista to reprogram by ic.
comment:10 by , 15 years ago
My USB serial port used to work in a Windows guest when connecting /dev/ttyUSB0 to COM1, but trying to use it in the last month or so has given me endless problems. It seems to work at first but after a little data comes through I notice the host (Ubuntu 9.10) seems to have moved the /dev/ttyUSB0 to /dev/ttyUSB1 and no more data goes through. Then I shut down the VM and change the settings to connect COM1 to /dev/ttyUSB1 and boot up again... only to transfer a few packets before the USB disconnects again. I have no idea whether this is a Virtualbox issue or Ubuntu, but I tried VMWare Player out of desperation and that works very well. VMWare has a simpler interface - you can't redirect COM ports like in VirtualBox, so you install the USB-serial drivers as normal in Windows and everything seems to work very well. VMWare can also connect and disconnect the USB on the fly, so no more rebooting.
But there is one other thing that is very useful with regards to VirtualBox's serial port model: you can connect COM1 in the guest to a *program* on the host. I use this function to emulate hardware talking over COM1 so I can test my windows program off-site. Here are my instructions on how to achieve that: http://lesliev.livejournal.com/80613.html
comment:11 by , 14 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
The serial ports emulation was much improved with VBox 4.0.4. The serial device is still not visible in certain Windows guests but this is covered by another ticket and will be finally fixed in VBox 4.1.
On a related note, I have had trouble getting Vboxmanage to even connect the UART to anything, be it a named pipe or USB to serial adapter. I need this for my speech synthesizer, and it is becoming rather frustrating. I get the following error: Cannot set the host port mode of the serial port 0 because the device path is empty or null. I get a similar error when I try pipes: Cannot set the host pipe mode of the serial port 0 because the pipe path is empty or null. This is proving extremely frustrating, and I hope it could be resolved quickly. Host is Windows XP Home Eddition, though I've tried on Professional and it doesn't seem to make any difference. Any help appreciated. Thanks, Zack.
Replying to IakovK: