emw
Posts: 52
Joined: Tue Apr 12, 2016 2:53 pm

USBProxy on PI Zero W

Tue Dec 18, 2018 3:27 pm

Has anyone used USBPRoxy on the PI Zero (W). I have been try to use it with a MAX3421E as the host port and the local USB as the device (gadget) port. I have not been having a lot of luck. I has wondering if anyone else had tried this, and if they could give me any tips.

I seem to have the MAX3421E port working, and I am doing the rest as follows:


cd
sudo apt-get install build-essential cmake libpcap-dev libusb-1.0-0-dev
wget https://github.com/dominicgs/USBProxy/a ... master.zip
unzip master.zip
cd USBProxy-master
mkdir src/build
cd src/build
cmake ..
make

sudo make install
sudo ldconfig



* add "dtoverlay=dwc2" to /boot/config.txt
* add " modules-load=dwc2 " after rootwait string in /boot/cmdline.txt.

* to prevent usb printer drivers from grabbing usb port
sudo sh -c 'echo "blacklist usblp" > /etc/modprobe.d/blacklist-usblp.conf

sudo reboot
sudo usb-mitm -l


I get the following results:

Loading plugins from /usr/local/lib/USBProxy/
vendorId=ffffffff
productId=ffffffff
cleaning up /tmp
removing 1
Made directory /tmp/gadget-DzxTIa for gadget
Printing Config data
Strings: 2
DeviceProxy: DeviceProxy_LibUSB
HostProxy: HostProxy_GadgetFS
Vectors: 1
Plugins:
PacketFilter_StreamLog
Pointer: 1
PacketFilter_StreamLog::file: 0xb6c38cb0
Device: 12 01 00 02 00 00 00 40 b8 04 02 02 00 01 01 02 03 01
Manufacturer: EPSON
Product: TM-T88V
Serial: 4D5844469389310000
*Config(1): 09 02 20 00 01 01 00 e0 01
Interface(0):
*Alt(0): 09 04 00 00 02 ff ff 02 00
EP(01): 07 05 01 02 40 00 00
EP(82): 07 05 82 02 40 00 00
old bInterval: 00
calculated new bInterval: 80000000
old bInterval: 00
calculated new bInterval: 80000000
searching in [/tmp/gadget-DzxTIa]
/tmp/gadget-DzxTIa device file not found.
Error, unable to find gadget file.
Fail on open 34 Numerical result out of range
GadgetFS not connected.
done

emw
Posts: 52
Joined: Tue Apr 12, 2016 2:53 pm

Re: USBProxy on PI Zero W

Thu Dec 20, 2018 3:26 pm

looks like the code did not recognize the gadgetfs device on the raspberry pi. I have not done any serious testing yet, but adding "20980000.usb", to *devices[] in src/Plugins/Hosts/GadgetFS_helpers.c find_gadget_filename() seems to solve the problem.

Return to “Advanced users”