cgutman / usbipserverforandroid Goto Github PK
View Code? Open in Web Editor NEWUSB/IP server for Android
License: GNU General Public License v3.0
USB/IP server for Android
License: GNU General Public License v3.0
Hi Cameron @cgutman,
Love your work on Sunshine & Moonlight!
I stumbled across this repository while searching for a FOSS alternative to VirtualHere after running into licensing problems. Any chance this could be updated for Android 11 and either released on the Play Store or made available as an .apk? I see the original version you've released on the Play Store was last updated in 2016 and isn't compatible with the NVIDIA SHIELD.
(Or could you please point me in the direction of a USB/IP Server for Android that is FOSS and compatible with recent versions of Android?)
Thank you and have a great day ๐
I'm unable to access the USB device connected to Android.
According to dmesg the USB device is attached as "1-1.4", but the app is unable to parse it.
And if binding to "1-1" a strange error occurs I don't understand.
Client: Windows 10 Pro x64 with usbip v0.3.5
First attempt
C:\usbip-win>usbip --debug attach -r 192.168.35.10 -b 1-1
usbip: debug: usbip.c:151:[run_command] running command: attach
usbip: debug: usbip_network.c:175:[usbip_net_recv_op_common] request failed: status: ST_NA
usbip: debug: usbip_attach.c:142:[query_import_device] failed to recv common header: ERR_STATUS
usbip: debug: usbip_attach.c:144:[query_import_device] op code error: ST_NA
usbip: error: failed to attach
Second attempt
C:\usbip-win>usbip --debug attach -r 192.168.35.10 -b 1-1.4
usbip: debug: usbip.c:151:[run_command] running command: attach
usbip: debug: usbip_network.c:151:[usbip_net_recv_op_common] usbip_net_recv failed: -1
usbip: debug: usbip_attach.c:142:[query_import_device] failed to recv common header: ERR_NETWORK
usbip: error: failed to attach
On Debian Linux 9 client it looks similarly (tested with 1-1 and 1-1.4):
sudo usbip --debug attach -r 192.168.35.10 -b 1-1
usbip: debug: usbip.c:141:[run_command] running command: `attach'
usbip: debug: usbip_network.c:183:[usbip_net_recv_op_common] usbip_net_recv failed: -1
usbip: error: recv op_common
usbip: error: query
Server: Android 9 (aarch64)
[Tue Nov 23 14:38:43 2021] usb 1-1.4: new full-speed USB device number 6 using xhci-hcd
[Tue Nov 23 14:38:43 2021] usb 1-1.4: Unsupported device
First attempt
2021-11-23 14:40:55.396 9863-9900/org.cgutman.usbipserverforandroid I/System.out: Server listening on 3240
2021-11-23 14:41:14.139 9863-9904/org.cgutman.usbipserverforandroid I/System.out: In code: 0x8003
2021-11-23 14:41:14.141 9863-9904/org.cgutman.usbipserverforandroid I/System.out: Out code: 0x3
2021-11-23 14:41:14.148 9863-9904/org.cgutman.usbipserverforandroid I/System.out: Client disconnected
Second attempt
2021-11-23 14:46:52.304 10169-10169/? I/Zygote: seccomp disabled by setenforce 0
2021-11-23 14:46:52.370 10169-10187/org.cgutman.usbipserverforandroid I/System.out: Server listening on 3240
2021-11-23 14:47:13.439 10169-10199/org.cgutman.usbipserverforandroid I/System.out: In code: 0x8003
2021-11-23 14:47:13.440 10169-10199/org.cgutman.usbipserverforandroid E/AndroidRuntime: FATAL EXCEPTION: Thread-3
Process: org.cgutman.usbipserverforandroid, PID: 10169
java.lang.NumberFormatException: For input string: "1.4"
at java.lang.Integer.parseInt(Integer.java:615)
at java.lang.Integer.parseInt(Integer.java:650)
at org.cgutman.usbip.service.UsbIpService.busIdToDevNum(UsbIpService.java:271)
at org.cgutman.usbip.service.UsbIpService.busIdToDeviceId(UsbIpService.java:275)
at org.cgutman.usbip.service.UsbIpService.getDevice(UsbIpService.java:626)
at org.cgutman.usbip.service.UsbIpService.attachToDevice(UsbIpService.java:647)
at org.cgutman.usbip.server.UsbIpServer.handleRequest(UsbIpServer.java:50)
at org.cgutman.usbip.server.UsbIpServer.access$000(UsbIpServer.java:18)
at org.cgutman.usbip.server.UsbIpServer$1.run(UsbIpServer.java:114)
Any ideas? Thank you.
Hi good job.
do it have a Client for android too ?
Thanks
Well this might be due to the fact that I'm using Android 11 ;) Is there any chance we can update this amazing software for android 11/12? It would be amazing <3
Hi where is the windows Client?
what version of windows client can connect to this project?
thanks
Hi,
I am doing work on forwarding a smartcard and yubikey based on your project.
I have taken a snapshot of the repo and converted it to gradle/android studio.
Until now I have found and hopefully fixed one bug which prevented attaching of yubikey.
For now limited communication with a key works, but it looks like there are more bugs which are exposed by yubikey.
I wonder what are your plans in respect to the project?
Are you interested in accepting PRs?
Cheers
--pawel
I'm testing this app with Android 9 (aarch64).
After starting the app and clicking [START SERVICE] I see the following messages in logcat:
2021-11-23 14:29:01.615 9487-9487/? I/Zygote: seccomp disabled by setenforce 0
2021-11-23 14:29:01.776 9487-9487/org.cgutman.usbipserverforandroid D/OpenGLRenderer: Skia GL Pipeline
2021-11-23 14:29:01.886 9487-9507/org.cgutman.usbipserverforandroid I/ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasWideColorDisplay retrieved: 0
2021-11-23 14:29:01.887 9487-9507/org.cgutman.usbipserverforandroid I/ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay retrieved: 0
2021-11-23 14:29:01.888 9487-9507/org.cgutman.usbipserverforandroid I/OpenGLRenderer: Initialized EGL, version 1.4
2021-11-23 14:29:01.888 9487-9507/org.cgutman.usbipserverforandroid D/OpenGLRenderer: Swap behavior 2
2021-11-23 14:29:01.903 9487-9507/org.cgutman.usbipserverforandroid D/mali_winsys: EGLint new_window_surface(egl_winsys_display *, void *, EGLSurface, EGLConfig, egl_winsys_surface **, EGLBoolean) returns 0x3000
2021-11-23 14:29:01.915 9487-9507/org.cgutman.usbipserverforandroid E/gralloc: ioctl c0044901 failed with code -1: Invalid argument
2021-11-23 14:29:01.915 9487-9507/org.cgutman.usbipserverforandroid I/gralloc: ddebug, pair (share_fd=53, user_hnd=1, ion_client=55)
2021-11-23 14:29:01.983 9487-9507/org.cgutman.usbipserverforandroid I/gralloc: ddebug, pair (share_fd=57, user_hnd=2, ion_client=55)
2021-11-23 14:29:04.561 9487-9507/org.cgutman.usbipserverforandroid I/gralloc: ddebug, pair (share_fd=59, user_hnd=3, ion_client=55)
2021-11-23 14:29:08.524 9487-9523/org.cgutman.usbipserverforandroid I/System.out: Server listening on 3240
... but it is not listening on this port as portscan shows:
Initiating SYN Stealth Scan at 14:29
Scanning 192.168.35.10 [1000 ports]
Discovered open port 2222/tcp on 192.168.35.10
Discovered open port 5555/tcp on 192.168.35.10
Completed SYN Stealth Scan at 14:29, 1.87s elapsed (1000 total ports)
I was wrong, it is listening, sorry, please delete this.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.