On Sat, 24 Jul 2004, Duncan Sands wrote:

> I have a "freebox", an ADSL modem.  When reading various string
> descriptors, the bLength and bDescriptorType fields are both zero,
> yet appropriate data follows, see the examples below:
> 
> # Format is: bLength bDescriptorType - DATA
> # where DATA is a sequence of printable characters.
> # Wierdo characters are replaced by ? (none here),
> # and null by !.  So 0 0 - F!r!e!e!B!o!X!!!!... means
> # bLength=0, bDescriptorType=0, then
> # F(null)r(null)e(null)e(null)B(null)o(null)X(null)(null)(null)...)
> 
> Product:
> 
> 0 0 - F!r!e!e!B!o!X!!!!...
> 
> Manufacturer:
> 
> 0 0 - F!r!e!e!b!o!x! !S!A!!!...
> 
> Serial number?:
> 
> 0 0 - 1!.!0!0!!!...
> 
> Any idea how to handle these strange strings?  Could these
> guys be using an unofficial convention for sending null terminated
> strings?
> 
> Thanks,
> 
> Duncan.
> 
> PS: The modem happily returns 255 bytes (the amount asked for).
> All the trailing bytes are zero.

It's possible that this is more than just a private convention.  In 
principle we could try to support it: If the descriptor type and length 
are both 0 then request 255 bytes and assume it's a null-terminated 
string.

I'm concerned because this is so contrary to the specification and subject
to errors.  (If the descriptor type is 0, how can you be sure you're
looking at the right sort of descriptor?)

If there's any evidence that more than one device or vendor uses this 
convention, then we ought to adopt it.  Otherwise I say to forget about 
it.

Alan Stern



-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to