The VirtualHere USB Client Console Edition can now run as a console only daemon in most Linux editions (including Android). It is a 100% static binary therefore it requires no runtime libraries, other than usbip drivers compiled into your Linux setup. usbip drivers are included in the Linux mainline so they are easy to compile with the Linux/Android kernel make command.
The client will interact with the usbip drivers in the Kernel to provide remote USB capabilities.
Running the Linux Client in the console is usually a two step process.
Step 1. Start the Client as a daemon so that it runs in the background using the -n
flag. You can move it into an init.d script so it runs on startup as a daemon
Step 2. Run the client again and this time use the -t
argument to control the daemon
Note: when running the client as a daemon (step 1) the VirtualHere Server it connects to must be purchased
Notes for Android
- You need root to run the VirtualHere Client because it needs access to the kernel sysfs file system
- You will need to modprobe vhci-hcd somehow, either by directly compiling the usbip driver into the kernel statically or loading the driver on boot using modprobe.d scripts because the VirtualHere client cannot modprobe this automatically due to SELinux restrictions
- There is no "app" to control the Android client. Its easy to write a java app that can open the IPC path to the client. In Android the IPC Path is
/data/data/vhclient_ipc
to issue commands and/data/data/vhclient_ipc_response
to receive responses from the client. In an app, you can also just call JavaRuntime.exec()
and pass-t
argument to run the client and send and receive commands/status