Re: [Q]Questions about usb driver in bootloader?
From: Tom Gensel \(eMVP\) (nospam_at_nospam.com)
Date: 12/17/04
- Previous message: Tom Gensel \(eMVP\): "Re: About Power Management in WinCE 4.2"
- In reply to: fred: "[Q]Questions about usb driver in bootloader?"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 17 Dec 2004 21:27:41 GMT
Fred,
It is possible to use wceusbsh.sys for this purpose. Make sure ActiveSync
isn't using the port by unchecking the "Allow USB connection" checkbox in
ActiveSync's connection settings. Then open the port using the device name
syntax - CreateFile(\\\\.\\wceusbsh001... Once the target device is
connected and device enumeration is complete you can send data to your
device with calls to WriteFile.
EP0 device requests are initiated by the USB host and may come in different
sequences. Your device must be prepared to respond to each one
appropriately.
The SET CONFIG request is the host's way of telling the device which
configuration (passed in the low byte of the request's wValue parameter) to
configure itself to, corresponding to the bConfigurationValue set in your
configuration descriptor. In this case, it is basically used to enable the
target device and is typically the last EP0 request you'll receive during
the enumeration process.
Once your device's USB address and config are set you can start sending
data. However, there must be a process on the PC host side ready to receive
it. I would recommend that you initiate the data transfer from the PC and
use that as an indication to your device that it send data to the PC.
Tom Gensel (eMVP)
"fred" <fred@discussions.microsoft.com> wrote in message
news:963F7A53-806C-4F05-8389-8F6F559B5397@microsoft.com...
> hi,
> I am developing a bootloader supporting usb. I have two questions.
> 1. Can I use driver wceusbsh.sys(within activesync) to transfer nk.bin
> from pc to my target devic?I impossible, what interfaces I can use?
> 2. What is the sequence of EP0 requests? Which request indicates that
> the usb driver in pc has been initialized,then I can transfer data to pc
> through EP1?
> 3. What is the function of "SET CONFIG" request and "CLASS" request?
>
> Sorry,my english is very poor,so I am not able to describe my questions
> clearly.
> Fred
>
- Previous message: Tom Gensel \(eMVP\): "Re: About Power Management in WinCE 4.2"
- In reply to: fred: "[Q]Questions about usb driver in bootloader?"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|