Host Protocols CCID Protocol (PCSC)
April 13, 2023 at 2:39 AMSpringCore CCID implementation
The implementation is a subset of the USB CCID 1.10 specification.
It operates with
- A PC to RDR (host to device) endpoint for commands (BulkOut),
- A RDR to PC (device to host) endpoint for responses (BulkIn),
- A second RDR to PC (device to host) endpoint for notifications (InterruptIn).
CCID_PC_To_RDR Commands
Code | Command | Description | Equivalent PC/SC function |
---|---|---|---|
62 |
PC_To_RDR_IccPowerOn | Power up the card in the slot, and return its ATR | SCardConnect |
63 |
PC_To_RDR_IccPowerOff | Power down the card in the slot | SCardDisconnect |
65 |
PC_To_RDR_GetSlotStatus | Retrieve the slot’s current status and protocol data | SCardStatus |
6B |
PC_To_RDR_Escape | Send a direct command to the device | SCardControl |
6F |
PC_To_RDR_XfrBlock | Send a C-APDU to the card (and return its R-APDU) | SCardTransmit |
CCID_RDR_To_PC Responses
Code | Command | Description | In response to |
---|---|---|---|
80 |
RDR_To_PC_DataBlock | R-APDU returned by the card ATR of the card |
PC_To_RDR_XfrBlock (success) PC_To_RDR_IccPowerOn (success) |
81 |
RDR_To_PC_SlotStatus | Status of the slot | PC_To_RDR_GetSlotStatus PC_To_RDR_IccPowerOff PC_To_RDR_XfrBlock (failure) PC_To_RDR_IccPowerOn (failure) |
83 |
RDR_To_PC_Escape | Send a direct command to the device | PC_To_RDR_Escape |
Non-USB implementations
SpringCore devices also support a variant of the USB CCID protocol on Serial and Network (TCP) interfaces.
On such interfaces, the Control endpoint, that is implicit for USB devices, has no equivalent. A specific Non-USB Control implementation emulates this missing feature.
Also, to ease the host-side implementation of the protocol, the format of the notification messages (going though InterruptIn message) has been adapted to have the very same header as response messages. This is documented in the Non-USB Notifications paragraph.