Hi all, i have a Hassos running in a virtual box on a windows 10 machine. i have RS232 serial connected to a usb port on the windows machine. i would like to access that in hassos but cant figureout how. anyone know how to setup usb in virtual box.
Iâve done this. In windows device manager, find out what port it is using. For instance, COM7 or something. Then, in VB go to âSerial Portsâ in the machine setttings (while the machine is turned off).
âEnable Serial Portâ --> Checked
âPort Numberâ here doesnât really matter, thatâs the port that it will be inside the VM.
âPort Modeâ --> âHostâ
"Connect using existing pipe/socket --> Checked
âPath Addressâ --> The windows port (COM7) or whatever.
Click okay and boot it up, it should appear under supervisorâ>systemâ>hardware\
In regard to your comment âwhy not just use USB passthrough?â. Can you help me to do this. I have VirtualBox 6.1 and found a tutorial (of sorts) on how to do it with VB 5, but I stall at the instruction âNow, head to Devices â USB, and click on âUSB device to shareââ. The closest my installation of VB has is Settings - User interface - dropdown for Devices then check boxes, one of which is USB which is already checked. I have my USB device working but I want it to be accessible by Hassio upon a restart of the VB (ie power loss and restore)
Edit: I forgot to say I have VB set up on Windows 10. I just perused the manual (just references to USB - maybe a thousand) since itâs 400 plus pages long. No joy.
Not sure what you were trying to say - it cut off everything with picture. I have found others with the same problem and the solution given in most cases either works or doesnât for them too. I thought I was onto something the other day and tried again to no avail. There was a checkbox at the bottom for âanyâ someone said to check and it seemed to work - it didnât and I canât find the instructions in History. I am on a different computer now so canât look at VB. To reiterate how far I get: the USB is seen by Virtual Box if I restart the VB, but only if I get it to see it once after the Windows machine starts. If for some reason the Windows machine powers down/restarts, VB does NOT see the USB. Itâs in the list of filters. I have VB starting as a service if that has anything to do with it. I know it adds another layer to troubleshooting when I inevitably donât see my Zwave or Zigbee devices in Home Assistant; I have to stop the service and open a new instance of VB and of course donât see the USB. And again, disengaging and reengaging the USB lets VB âseeâ the USB. I think I tried last month without the service and Iâm now pretty sure that I will have to keep my âsolutionâ - just thought there should be an easier way. There probably is but for some reason things that work for other people donât work for me.
Iâm only getting started with HA so certainly no expert⌠although lots of experience with errors
Re the picture, if you go to the running VM and click Devices > USB, you would see a tick if the device is recognised. You can select it manually as well.
I found an article that stated that the USB is not really âsharedâ, if you mount it for the guest OS then the host OS canât see it, that could be why youâre seeing it on and off.
Have you installed the extension pack for USB 2.0 and 3.0 support?
I installed it, changed the VM Manager USB settings to 2.0 and then I could see device details in Home Assistant > Supervisor > System, options under Host to see Hardware. I could see references to the serial device so figured out the â/dev/ttyusb0â reference. Although I see more info in the Host output than your screenshot. Maybe a before and after screenshot will help show when it appears.
I hope some of this helps.
Thanks for the attempt. I went back to make sure, but I tried this way - and many others. Guess Iâm lucky to have found a solution even though itâs WAY more complicated than it should have to be. I took a screen shot that hopefully illustrates my settings; pretty sure they are what you describe. If I stop the machine (VB) and start again, of course the USB shows up. Itâs when I shutdown the host (Windows) PC and the VB starts as a service via VBoxVMService (per instructional video by the Hookup) that the USB drive is not accessed.
After the restart, is anything showing in the Supervisor > System > Hardware? Iâve seen comments about the drive reference changing. If itâs not accessible at all in the guest OS, is it accessible in Windows? This is without trying to change anything, just straight after restart.