Virtualhere not working on Octopi/Raspbian

I just bought Virtualhere, and it does not seems to work in my environment.

I am using a Raspbery PI3, running Octopi (based on Raspbian Linux) as my Virtualhere USB server. I want to be able to access my 3D printer from both the Raspberry and my desktop PC (one at a time!!) The printer normally shows as a serial device on the Raspberry. Because I have no graphical interface on my Raspberry and I want to control the USB port by script, I have to use the console version of Virtualhere on my Raspberry, so after testing it was working from a client running on my PC, I bought the licence.

Here is what happens:

ON MY RASPBERRY

After clean boot :
My 3D printer is accessible at /dev/ttyACM0

After running : sudo ./vhusbdarm -b
My printer is still accessible at /dev/ttyACM0

After running : sudo ./vhclientarmhf -n
My printer is still accessible at /dev/ttyACM0

After running : sudo ./vhclientarmhf -t list
I get a list of USB devices, including my 3D printer (octopi.113)

After running : sudo ./vhclientarmhf -t use,octopi.113
It says OK
/dev/ttyACM0 and /dev/serial disappear, and no new device appears in /dev/
The print server on my Raspberry can't connect to the 3D printer

After running : sudo ./vhclientarmhf -t "stop using,octopi.113"
/dev/ttyACM0 not /dev/serial does not reapears, and no new devices appears in /dev/
The print server on my Raspberry still can't connect to the 3D printer

ON MY PC

I can connect/disconnect to the USB port using the Virtualhere client, and everything runs fine.

Could you help me diagnose the problem ? Obviously, knowing it wouldn't work, I would not have bought the software ...

Tanks,

André

#2

I've rebooted the the Raspberry, and the devices are back. After starting the server (sudo ./vhusbdarm -b), I did not start the client on the Raspberry. Instead, I've connected to the 3D Printer from my desktop PC (running Windows) and it works, but the same devices disappears on the Raspberry. Releasing the device on the windows machine does not make them reappears on the Raspberry, and I still can't connect to the 3D printer from the Raspberry itself using the Virtualhere client.

Note that I also have a camera plugged in the Raspberry, and if I connect to it, it has the behaviour (except that the devices disappearing are /dev/media0, /dev/v41 and /dev/video1.

Hope that clarifies my problem a bit ;-)

André

#3

I think what you are trying to do is use the printer connected to the pi on the virtualhere client pc.

Then you are stopping using the printer on the pc and you want the printer to be enabled again locally on the pi.

Yes this is possible you need to use this setting in the server config.ini:

1. Stop and exit the server on the pi
2. Edit the server config.ini and add the line

AutoAttachToKernel=1

3. Save the config.ini file then reboot the pi
4. Start the server and then use the printer on the pc via virtualhere then stop using the printer and it should reattach itself to the pi again.

#4

Thank you very much. Worked on the first attempt.

Regards,
André