Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 5054

Troubleshooting • Re: Bios does not recognize raspberry Pi in g_multi mode

$
0
0
I've not played around with this since the end of April.

To get things working on Win11 I did a couple of things differently to what you're doing:
  • Used the VID and PID that g_ether uses. 0x525 and 0xa4a2 respectively.
  • Used functions/rndis.usb0 rather than functions/ecm.usb0. Forces it to present as an RNDIS network adaptor.
  • I've written an arbitary string to configs/c.1/strings/0x409/configuration
Windows doesn't appear to like CDC or ECM ethernet devices. RNDIS originated with windows. There may be third party drivers/.inf files about but the problem is finding a signed one that Windows will accept.
Thanks again for the response..
I´ve tried to modifiy the script file to:

Code:

#!/bin/bashcd /sys/kernel/config/usb_gadget/mkdir -p mcgreedy_usbcd sina_access_usbecho 0x525 > idVendor # Linux Foundationecho 0xa4a2 > idProduct # Multifunction Composite Gadgetecho 0x0100 > bcdDevice # v1.0.0echo 0x0200 > bcdUSB # USB2mkdir -p strings/0x409echo "fedcba9876543210" > strings/0x409/serialnumberecho "Greedy" > strings/0x409/manufacturerecho "McGreedy USB Device" > strings/0x409/productmkdir -p configs/c.1/strings/0x409echo "1865hbqduhg8719284eg" > configs/c.1/strings/0x409/configuration #just an arbitary stringecho 250 > configs/c.1/MaxPower# Add functions here#Ethernet Adapter:mkdir -p functions/rndis.usb0HOST="48:6f:73:74:50:43" # "HostPC"SELF="42:61:64:55:53:42" # "BadUSB"echo $HOST > functions/rndis.usb0/host_addrecho $SELF > functions/rndis.usb0/dev_addrln -s functions/rndis.usb0 configs/c.1/#Mass Storage:FILE=/mnt/disk1.imgmkdir -p ${FILE/img/d}mount -o loop,ro, -t ntfs-3g $FILE ${FILE/img/d}mkdir -p functions/mass_storage.usb0echo 1 > functions/mass_storage.usb0/stallecho 0 > functions/mass_storage.usb0/lun.0/cdromecho 0 > functions/mass_storage.usb0/lun.0/roecho 0 > functions/mass_storage.usb0/lun.0/nofuaecho $FILE > functions/mass_storage.usb0/lun.0/fileln -s functions/mass_storage.usb0 configs/c.1/# End functionsls /sys/class/udc > UDC#Ethernet Adapter startupifconfig usb0 10.0.0.1 netmask 255.255.255.252 uproute add -net default gw 10.0.0.2
Now the Raspi gets recognized as RNDIS Adapter like wished but the mass_storage doesnt work anymore :(

Statistics: Posted by SgtMcGreedy — Wed Jul 31, 2024 2:22 pm



Viewing all articles
Browse latest Browse all 5054

Trending Articles