I have a question regarding building a composite device.
My composite device would contain : a HID (e.g. keyboard) device and a Mass Storage (e.g. disk) device.
Current understanding:
==============
The composite device could have a single configuration with two interfaces :
Interface 0 - Keyboard
Interface 1 - Mass Storage
Two separate endpoints could be defined for the HID and the Mass Storage device.
Endpoint 0 - Keyboard
IN Endpoint
bmAttributes = Interrupt
wMaxPacketSize = 8
bInterval = 1
Endpoint 1 - Mass Storage
IN Endpoint (just an assumption)
bmAttributes = Bulk
wMaxPacketSize = 50 (just a dummy value : not decided yet)
bInterval = 8 (just a dummy value : not decided yet)
Hence the keyboard is intended to be used as a low-speed,interrupt-based HID class device
And the disk storage is intended to be used as a full-speed, bulk-based Mass-Storage class device.
When the composite device is connected to the host,
By observing which line is pulled high (D+ or D-) , the host can identify if the connected device is a low-speed device OR a full-speed device.
The host also obtains the endpoints descriptors from the composite device and determines the bandwidth requirement for the HID and the mass storage devices. The host is able to receive low-speed data and full-speed data over the same USB 2.0 bus from the composite device.
In theory, it appears that by using separate endpoints, data from the low-speed end-point(keyboard) and data from the full-speed end-point (disk) can be sent/received over the physical USB link.
Question :
=======
The composite device is expected to identify itself as a low-speed OR a full-speed device to the host, by pulling lines D+ or D-. In this case where the composite device is supporting both a low-speed(keyboard) and a full-speed (disk), how should the D+/D- be configured.
Is it possible to construct a composite device with endpoints having two separate speeds (low and full) ?
Any information would be greatly helpful.