On Dec 18, 2007 10:22 PM, Sebastien Chassot <[EMAIL PROTECTED]> wrote:
> On Tue, 2007-12-18 at 21:45 +0100, Ludovic Rousseau wrote:
> > And with which reader?
> >
> It's a SCR335 (SCM Microsystems Inc. SCR33x USB Smart Card Reader, rev
> 2.00/5.18, addr 2)
>
> I choose this model to avoid any difficulties ;)
I don't remember having a time out problem with this reader.
> APDU: 00 47 80 00 02 B6 00 00
> ifdhandler.c:948:IFDHTransmitToICC() lun: 0
> openct/proto-t1.c:487:t1_transceive() CT sent S-block with wtx=1
> openct/proto-t1.c:487:t1_transceive() CT sent S-block with wtx=1
>
> (...)
>
> openct/proto-t1.c:487:t1_transceive() CT sent S-block with wtx=1
> openct/proto-t1.c:487:t1_transceive() CT sent S-block with wtx=1
> openct/proto-t1.c:487:t1_transceive() CT sent S-block with wtx=1
> commands.c:1206:CCID_Receive Card absent or mute
> openct/proto-t1.c:221:t1_transceive() fatal: transmit/receive failed
The driver is correctly managing wtx requests (time extension) from
the card. And then the reader decides to report a dead card after some
time.
Maybe the card is too long to respond.
Maybe the reader is too quick to declare the card dead.
If you can you may try with a reader from another manufacturer.
It MAY be possible to solve the problem by changing the BWI (block
waiting interval) configured by the driver.
Edit the file ccid/src/ifdhandler.c like this:
Index: ccid/src/ifdhandler.c
===================================================================
--- ccid/src/ifdhandler.c (revision 2714)
+++ ccid/src/ifdhandler.c (working copy)
@@ -681,7 +681,8 @@ EXTERNAL RESPONSECODE IFDHSetProtocolPar
{
DEBUG_COMM3("BWI/CWI (TB%d) present: 0x%02X",
i+1,
atr.ib[i][ATR_INTERFACE_BYTE_TB].value);
- param[3] =
atr.ib[i][ATR_INTERFACE_BYTE_TB].value;
+// param[3] =
atr.ib[i][ATR_INTERFACE_BYTE_TB].value;
+ param[3] = 0x9F;
/* only the first TBi (i>2) must be used */
break;
This will change the value of BWI from 4 to 9 (maximal value) and the
CWI value from 5 to F.
bye
--
Dr. Ludovic Rousseau
_______________________________________________
Muscle mailing list
[email protected]
http://lists.drizzle.com/mailman/listinfo/muscle