How to get USB OTG port to work in Device mode?

ok I might have an idea, The whole windows not being able to recognize the device or see it as a EEM (ethernet emulation) device combined with no proper Drivers for it results in Chaos,
if we make it into a RNDIS device it should not have a problem in windows,

will try this tomorrow and see if it works, I have spent way too much time on this than expected,
Thanks @birty your help is what got me to this point, I want to thank @g4b42 his work should also considered, thank you :slightly_smiling_face:

Evidently 14 year old kids have done that, maybe we need to find one. :rofl:

2 Likes

14 year olds are more than overkill for that kind of task,
checking at DEFCON for any kiddos :laughing: :

but seriously you should not trust a small kid with cybersecurity, I lost my phone to my younger brother who downloaded games from the internet on it, and I lost my sanity to my other cousin who said he could do hacking, I asked how and he just cancels all the ads from a youtube video :sweat_smile:

1 Like

i got this on the internet, from Toradex

check it for more details, i am interested in the RNDIS version as that’s what I think will work :slight_smile:

@hyphop I’d like to ask your help again for implementing the USB-OTG and RNDIS in the mainline kernel, I’m still a bit of a novice in this part and I can only understand it so ever so slowly,

what I have come to understand till now:

I am testing it on my VIM3

USB peripheral mode is enabled by default in the Mainline Ubuntu/Debian kernel for the dwc2 or USB-C, and it is configured with USB-PHY already when built in fenix

when connecting to the PC however, it doesn’t appear as a RNDIS device, as seen on Krescue for example

I’d like to know what other step need to be done to do this, and if possible please elaborately note them for me

Thank you :slightly_smiling_face:

yes need additional configuration - u can check how its doing in krescue !!

well I couldn’t really understand how it works in Krescue, how can I approach it ? I am unaware of which software component is responsible for it.

thank you

just start krescue goto shell

usb otg rndis network setup script there →

cat /opt/usb_otg_rndis

of course u must rewrite it for yourself

good luck

Ok, I’ll try it out today,
Thank you :slightly_smiling_face:

@hyphop I tried the USB-OTG on Krescue, but I unfortunately ran into this error:
image

this is after inserting the USB 1/3 in, waiting for the LED to blink, then inserting the data pins…
any idea ?

i have tested it for linux! windows every time have some surprises ; -)

yes, it does :smile:

@hyphop by any chance, will changing the VID and PID of the USB configuration present it as a more compatible device ?

we need it to appear as ā€œremote NDIS compatible deviceā€

Hi, what is the current situation today ; has fenix included all the fixes and patches in between and can build firmwares having the expected behavior ?

@ravelo most of this conversation was geared towards using it on the VIM3, I believe you want to try this for the VIM1 ?

I believe these patches weren’t applied yet for BSP kernel, but you could check it out and see what is the status

If I try, i ll do it on vim1, I will try from Linux x86; I understood that krescue has embedded that function for vim1-2-3

Yes, it has
I still haven’t got time to tinker with it and bring NDIS mode to be configured, so that it would work with both Windows and linux without a problem, but am slightly preoccupied with my other work.

Hopefully I can get it configured to work soon and share some instructions :slight_smile:

by any chance, will changing the VID and PID of the USB configuration present it as a more compatible device ?

can u get right parameters for windows

before old windows version works - but not for latest windows

I will check around to see if I can get some appropriate VID and PID configs,
It will mostly be copied from some other device, because we don’t have our own specific ones…

@hyphop I got some VID and PID extracted from an android phone, and got this from the device manager:

Device USB\VID_0B05&PID_7774&MI_00\6&3288955f&0&0000 was migrated.

Last Device Instance Id: USB\VID_0B05&PID_7774&MI_00\6&3288955f&0&0000
Class Guid: {4d36e972-e325-11ce-bfc1-08002be10318}
Location Path: 
Migration Rank: 0x0
Present: false

from this, I guess you can take:

VID: 0B05
PID: 7774
MI: 00

VID: 0B05
PID: 7774
MI: 00

  • BIG TNX !! now rndis work again for windows !!!

Krescue will be update soon!!!

1 Like