[Pcsclite-muscle] bNumDataRatesSupported = 0 and get_data_rates
Ludovic Rousseau
ludovic.rousseau at gmail.com
Tue May 22 14:22:19 UTC 2012
Hello,
You should use the MUSCLE list instead
http://musclecard.com/list.html
2012/5/22 Bruno Jesus <00cpxxx at gmail.com>:
> Hi, I have a reader that does not return any data rates and sends a
> bNumDataRatesSupported = 0 in it's descriptor. But the reader is being
> rejected by pcsclite and I guess it's because when it asks for the
> data rates it gets bad values. As far as I can tell the reader does
> not answer the 0x03 control message.
>
> My suggestion is to change ccid_usb.c in libccid, around line 558 from:
>
> usbDevice[reader_index].ccid.arrayOfSupportedDataRates =
> get_data_rates(reader_index, config_desc, num);
>
> to:
>
> if(usbDevice[reader_index].ccid.bNumDataRatesSupported)
> usbDevice[reader_index].ccid.arrayOfSupportedDataRates =
> get_data_rates(reader_index, config_desc, num);
>
> This is the part of the log that shows this problem:
> 00000172 ccid_usb.c:508:OpenUSBByName() Using USB bus/device: 2/5
> 02021292 ccid_usb.c:1026:ControlUSB() control failed (2/5): -7 Success
> 00000042 ccid_usb.c:964:get_data_rates() Wrong GET DATA RATES size: 251
This should not prevent the driver from working correctly.
Your reader DO return data rates. But I guess that is just 251 bytes
of random data.
Your log trace do not show any sign of rejection by the driver.
Bye
--
Dr. Ludovic Rousseau
More information about the Pcsclite-muscle
mailing list