T1_DATA

The T1_DATA structure is used by the Smart Card Driver Library for processing T1 I/O. It should not be directly modified by a driver.

typedef struct _T1_DATA {

    //
    // Current information field size that can be transmitted
    //
    UCHAR    InfSize;

    //
    // Number of bytes already received from smart card
    // 
    ULONG    BytesReceived;

    //
    // Number of bytes already sent to the card;
    //
    ULONG    BytesSent;

    //
    // Total number of bytes still to send
    // 
    ULONG    BytesToSend;

    //
    // T1 error code of last received block
    //
    UCHAR    LastError;

    //
    // This is the node address byte to be sent to the card
    //
    UCHAR     NAD;

    //
    // State before error occurred
    //
    ULONG    PrevState;

    //
    // Resend counter
    //
    UCHAR    Resend;

    //
    // Resync counter
    //
    UCHAR    Resynch;

    //
    // The Send Sequence Number is either 0 or 1 as defined in ISO 7816-3
    //
    UCHAR    SSN;

    //
    // Current state of protocol
    //
    ULONG    State;

    //
    // Waiting time extension requested by the smart card
    // This value should be used by the driver to extend block waiting time.
    //
    UCHAR    Wtx;

} T1_DATA, *PT1_DATA;
 

Members

The following member is important for the driver:

Wtx
Contains the waiting time extension for a T=1 transmission. If nonzero, this is a multiplier for the block waiting time. Usually, the driver should time out if the block waiting time expires. Several smart card operations need longer time, so the smart card answers with a waiting time extension, and therefore the block waiting time must be multiplied with the Wtx value. Note that this value only applies as a waiting extension if the value is nonzero.