The C Source, Patches and (shudder!) Bugs
Post Reply
Guest
Posts: 6
Joined: 07 Jan 2013, 13:46

Reset of usb modem after switching

Post by Guest » 07 Jan 2013, 13:58

Hi all,

I found that after triggering usb_modeswitch command the usb is disconnected and then reconnected again with product ID changed. I tried to search in the code (in function switchSendMessage()) where reset of the usb is done but I couldn't find any.

My question : Is the usb is disconnect and reconnect again from itself after sending the message (MessageContent) for doing the switch part ?, I mean don't we need to reset the usb using a function like resetUSB() ?

Josh
Site Admin
Posts: 6593
Joined: 03 Nov 2007, 00:30

Re: Reset of usb modem after switching

Post by Josh » 07 Jan 2013, 14:08

Guest wrote:My question : Is the usb is disconnect and reconnect again from itself after sending the message (MessageContent) for doing the switch part ?, I mean don't we need to reset the usb using a function like resetUSB() ?
The disconnect/reconnect is purely a matter of the device firmware. It's the reaction to the switching "message" which is a special UFI mass storage command in most cases.

usb_modeswitch has no influence on that process. It actually resembles unplugging and replugging.
A device reset is not needed and doesn't do anything for most devices.

Guest
Posts: 6
Joined: 07 Jan 2013, 13:46

Re: Reset of usb modem after switching

Post by Guest » 07 Jan 2013, 15:12

Thanks for the quick response :)

Post Reply