Connect virtual serial port to physical serial port
Re: Connect virtual serial port to physical serial port
Yes, that's it. I can wait for Don as well.
But if there is another way to install Windows, using virtualisation or not, I'm in!
But if there is another way to install Windows, using virtualisation or not, I'm in!
-
mpack
- Site Moderator
- Posts: 39134
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Mostly XP
Re: Connect virtual serial port to physical serial port
Configuring a serial port in the guest should be quite straightforward. You enable it in the VM settings, the main thing you need to provide is the name of the host port (e.g. "/dev/tty0" or whatever your Linux distro calls it).
Beyond that, I'm unsure of what your question is. I assume you have some kind of USB-RS232 adapter and want to use it to talk to the device. Unfortunately RS232 is 1960s tech and very far from plug and play. You kind of need to know how to use it. What year does the device come from? How about a photo of the connector it has on it, and do you still have the user manual for the device?
Beyond that, I'm unsure of what your question is. I assume you have some kind of USB-RS232 adapter and want to use it to talk to the device. Unfortunately RS232 is 1960s tech and very far from plug and play. You kind of need to know how to use it. What year does the device come from? How about a photo of the connector it has on it, and do you still have the user manual for the device?
Re: Connect virtual serial port to physical serial port
The thing is that I don't have a clue about how to know the name of the host port, and what "port mode" I have to choose.
Here is a photo of the port (https://framadrive.org/index.php/s/X8uuvCgrqt9V2qS) I want to connect to the computer (via the proper cable). I think the device dates back to the 1990s. I do have the user manual but they are in French so I don't think it could help you helping me. It only says that I have to use COM1 and PORT A.
Documentation:
User manual: https://framadrive.org/index.php/s/UJPuzV1joZfXnQW
Serial Port: https://framadrive.org/index.php/s/TKufkBaYGxkkXOQ
Here is a photo of the port (https://framadrive.org/index.php/s/X8uuvCgrqt9V2qS) I want to connect to the computer (via the proper cable). I think the device dates back to the 1990s. I do have the user manual but they are in French so I don't think it could help you helping me. It only says that I have to use COM1 and PORT A.
Documentation:
User manual: https://framadrive.org/index.php/s/UJPuzV1joZfXnQW
Serial Port: https://framadrive.org/index.php/s/TKufkBaYGxkkXOQ
-
mpack
- Site Moderator
- Posts: 39134
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Mostly XP
Re: Connect virtual serial port to physical serial port
I can't tell you how to find out what ports are available on your host - I don't use Linux hosts. Frankly, tuition on how to operate your host OS is beyond my remit. I can show you how I do it on my XP host, which is that I open the device manager, find the "Ports" branch, and note the name of any available serial ports.stagnette wrote:The thing is that I don't have a clue about how to know the name of the host port, and what "port mode" I have to choose.
Looking at your photograph, I see two 9 pin male D connectors. That's a bad sign, as normally the PC (DTE) end has a male connector, the other (DCE) end has a female connector, and you would use a "straight through" cable to connect the two ends (pin 1 to pin 1, pin 2 to pin 2 etc). Looking at the port description from the user manual it looks like the device is wired as a DCE but only has the wrong gender connector. Hence you'll need a straight though 9 pin cable and a "gender bender" for the device end of the cable.
In the VM settings the "Port Mode" should be "Host Device", and the "Path/Address" should be set to the name of whatever host serial port you want the VM to use, e.g. "/dev/ttyS0". Tick the enable checkbox then leave all the other settings alone. The port will be seen as "COM1" inside a Windows guest OS.
DTE = Data Terminal Equipment. In the 1960s this was a terminal or teletype, but these days its the PC.
DCE = Data Communications Equipment - a modem or other device that the terminal communicates through or with.
Re: Connect virtual serial port to physical serial port
The path seems to be /dev/ttyS0 but Virtualbox reacts as if I didn't have the permissions needed... (https://framadrive.org/index.php/s/iK2AADnrwZvnQq9)
Concerning the cable, I already have the right one!
Concerning the cable, I already have the right one!
-
Perryg
- Site Moderator
- Posts: 34369
- Joined: 6. Sep 2008, 22:55
- Primary OS: Linux other
- VBox Version: OSE self-compiled
- Guest OSses: *NIX
Re: Connect virtual serial port to physical serial port
As the warning shows you must have the group added to your user to be able to use it. IIRC that would be the dialout group.
But look it up to be sure.
Code: Select all
usermod -aG dialout <USER_NAME>Re: Connect virtual serial port to physical serial port
It returns "Permission denied"...
-
Perryg
- Site Moderator
- Posts: 34369
- Joined: 6. Sep 2008, 22:55
- Primary OS: Linux other
- VBox Version: OSE self-compiled
- Guest OSses: *NIX
Re: Connect virtual serial port to physical serial port
Permissions do not change until you log out or reboot.
Re: Connect virtual serial port to physical serial port
I know, and I already did it (after writing "sudo usermod -a -G vboxusers manivelles"). But maybe there is something else to do? (I'm quite a novice)
-
Perryg
- Site Moderator
- Posts: 34369
- Joined: 6. Sep 2008, 22:55
- Primary OS: Linux other
- VBox Version: OSE self-compiled
- Guest OSses: *NIX
Re: Connect virtual serial port to physical serial port
Well this error is host based and you should travel to the forum of the host OS to get this part sorted out. Like I said I don't have/use serial ports these days and the dialout group may not be the only one you need. Perhaps the tty group as well but not sure. Once you resolve the permissions it should work as far as I remember. But don't just add groups willy-nilly. It can cause security issues and it would be better to do it right the first time.