background image

 

APG8201-B2 

– Reference Manual

 

[email protected] 

Version 1.00 

www.acs.com.hk 

Page 24 of 48

 

www.acs.com

.hk 

 

7.2.3. 

RDR_to_PC_Parameters 

This message is sent by APG8201-B2 in response to the command message: 

PC_to_RDR_GetParameters

PC_to_RDR_ResetParameters

 and 

PC_to_RDR_SetParameters

 

Offset 

Field 

Size 

Value 

Description 

bMessageType 

82h 

dwLength 

Size of 

abProtocolDataStructure

 field of 

this message 

bSlot 

Identifies the slot number for this 
command. Same value as in Bulk-OUT 
message. 

bSeq 

Sequence number for the corresponding 
command. Same value as in Bulk-OUT 
message. 

bStatus 

Slot status register 

bError 

Slot error register 

bProtocolNum 

00h, 

01h 

Specifies what protocol data structure 
follows: 

00h = Structure for protocol T=0 

01h = Structure for protocol T=1 

The following values are RFU. 

80h = Structure for 2-wire protocol 

81h = Structure for 3-wire protocol 

82h = Structure for I2C protocol 

10 

abProtocolDataSt

ructure 

Byte 

array 

Protocol Data Structure 

 

Protocol Data Structure for Protocol T=0 (

bProtocolNum

=0, 

dwLength

=00000005h) 

Offset 

Field 

Size 

Value 

Description 

10 

bmFindexDindex 

B7-4 

– FI – Index into the table 7 in 

ISO/IEC 7816-3:1997 selecting a clock 
rate conversion factor  

B3-0 

– DI – Index into the table 8 in 

ISO/IEC 7816-3:1997 selecting a baud 
rate conversion factor 

11 

bmTCCKST0 

00h,02h 

For T=0 ,B0 

– 0b, B7-2 – 000000b 

B1 

– Convention used (b1=0 for direct, 

b1=1 for inverse) 

12 

bGuardTimeT0 

00-FFh 

Extra guardtime between two characters. 
Add 0 to 254 etu to the normal guardtime 
of 12etu. 

FFh is the same as 00h. 

13 

bWaitingIntegerT0 

00-FFh 

WI for T=0 used to define WWT 

Summary of Contents for APG8201-B2

Page 1: ...Subject to change without prior notice info acs com hk www acs com hk Reference Manual v1 00 APG8201 B2...

Page 2: ...APG8201 B2 Reference Manual info acs com hk Version 1 00 www acs com hk Page 2 of 48 www acs com hk Revision History Release Date Revision Description Version Number 2018 06 25 Initial Release 1 00...

Page 3: ...o_PC_Escape 25 7 2 5 RDR_to_PC_NotifySlotChange 29 7 2 6 RDR_to_PC_HardwareError 29 8 0 PC linked Operation Mode 30 8 1 SCardConnect API 30 8 2 SCardTransmit API 30 8 3 SCardControl API 30 8 4 SECURE...

Page 4: ...hk Appendix A Set bKeyReturnCondition 44 Appendix B Response Error Codes 45 Appendix C bmFormatString Description 46 Appendix D bmPINBlockString Description 47 Appendix E bmPINLength Format 48 List o...

Page 5: ...t card device which supports PC linked and standalone mode to perform various authentication applications It features a built in PIN pad and a graphical LCD that supports multiple languages and alpha...

Page 6: ...t Protection Application Programming Interface o Supports PC SC o Supports SPE o Supports PPS Protocols and Parameters Selection Built in Peripherals o Dot Matrix LCD o LCD Resolution 96 16 pixels o L...

Page 7: ...orm PPS in USB connected mode When the card ATR indicates the specific operation mode TA2 present bit b5 of TA2 must be 0 and when that particular mode is not supported by the APG8201 B2 the reader wi...

Page 8: ...ictions and enhancements to increase the practical functionality of the APG8201 B2 Smart Card Power Supply VCC C1 o The current consumption of the inserted card must not be larger than 54 mA Programmi...

Page 9: ...o activating the inserted card For MCU based cards the reader allows to select the preferred protocol T 0 or T 1 However this selection is only accepted and carried out by the reader through the PPS w...

Page 10: ...USB Interface The APG8201 B2 is connected to a computer through a USB as specified in the USB Specification 2 0 working in full speed mode i e 12 Mbps In order for the APG8201 B2 to function properly...

Page 11: ...his command activates the card slot and returns ATR from the card Offset Field Size Value Description 0 bMessageType 1 62h 1 dwLength 4 00000000h Message specific data length 2 bSlot 1 00 FFh Identifi...

Page 12: ...o the CCID Data is sent as is to the ICC TPDU exchange level The response to this message is the RDR_to_PC_DataBlock message 7 1 4 PC_to_RDR_GetParameters This command gets the slot parameters Offset...

Page 13: ...e following values are reserved for future use 80h Structure for 2 wire protocol 81h Structure for 3 wire protocol 82h Structure for I2C protocol 8 abRFU 2 Reserved for future use 10 abProtocolDataStr...

Page 14: ...e 8 in ISO IEC 7816 3 1997 selecting a baud rate conversion factor 11 bmTCCKST1 1 10h 11h 12h 13h B7 2 000100b B0 Checksum type b0 0 for LRC b0 1 for CRC B1 Convention used b1 0 for direct b1 1 for in...

Page 15: ...ay Data block sent to the CCID 7 1 7 1 Get Firmware Version Offset Field Size Value Description 10 bcmdCode 1 04h 11 wcmdLength 2 0000h 13 abRFU 2 Reserved for future use Example bSendBuffer 0 04h bSe...

Page 16: ...timeout 1 00h 16 PinLength 2 XXYYh XXh PIN Max length YYh PIN Min length 18 KeyReturnCondition 1 The value is a bit wise OR operation 01 Max size reached 02 Key Enter pressed 04 Timeout occurred 08 Ke...

Page 17: ...dBuffer 3 00h bSendBuffer 4 00h bSendBuffer 5 0Ah bSendBuffer 6 00h bSendBuffer abData 31 32 33 20 20 20 20 20 20h dwSendBufferLen 25h SCARDStatus SCardControl hSAM SCARD_CTL_CODE 3500 bSendBuffer dwS...

Page 18: ...000 indicates upper line of LCD 0001 indicates lower line Bit3 0 indicates the display position 20 EchoLCDMode 1 00 display in ASCII code 01 display char Example bSendBuffer 0 06h bSendBuffer 1 00h bS...

Page 19: ...essage 5 bSlot 1 00 FFh Identifies the slot number for this command 6 bSeq 1 00 FFh Sequence number for command 7 bBWI 1 00 FFh Used to extend the CCIDs Block Waiting Timeout for this current transfer...

Page 20: ...display for the PIN Verification management 00h no string 01h Message which index is indicated in bMsgIndex FFh default CCID message 19 wLangId 2 Language used to display the messages 21 bMsgIndex 1 M...

Page 21: ...current PIN entry requested In this case the bInsertinoOffsetOld value mustn t be taken into account If 1 Current PIN entry requested b2 b7 RFU 20 bEntryValidationCo ndition 1 The value is a bit wise...

Page 22: ...its new PIN if bConfirm 01h Only present if bNumberMessage is not null 26 bMsgIndex3 1 Message index in the Reader message table should be 02h The message is the prompt for the user to re enter its n...

Page 23: ...us 1 Slot status register 8 bError 1 Slot error register 9 bChainParameter 1 00h RFU TPDU exchange level 10 abData Byte array This field contains the data returned by the CCID 7 2 2 RDR_to_PC_SlotStat...

Page 24: ...ta structure follows 00h Structure for protocol T 0 01h Structure for protocol T 1 The following values are RFU 80h Structure for 2 wire protocol 81h Structure for 3 wire protocol 82h Structure for I2...

Page 25: ...b0 0 for LRC b0 1 for CRC B1 Convention used b1 0 for direct b1 1 for inverse 12 bGuardTimeT1 1 00 FFh Extra guardtime 0 to 254 etu between two characters If value is FFh then guardtime is reduced by...

Page 26: ...ription 10 bRespType 1 80h 11 wcmdLength 1 04h 12 abData 4 0x00h 7 2 4 2 Get Firmware Version Offset Field Size Value Description 10 bRespType 1 84h 11 wcmdLength 2 0004h 13 abRFU 2 0000h Reserved for...

Page 27: ...ue Description 10 bRespType 1 8Ah 11 wResLength 2 13 abRFU 2 0000h 15 abData Byte array Data receive from Reader 7 2 4 8 LCD Production Test Function Offset Field Size Value Description 10 bRespType 1...

Page 28: ...sion 1 00 www acs com hk Page 28 of 48 www acs com hk 7 2 4 11 Authentication Offset Field Size Value Description 10 bRespType 1 8Dh 11 wResLength 2 0008h 13 abStatus 2 0000h SUCCESS 0001h BAD_PARAMET...

Page 29: ...0b no change 1b change If no slot exists for a given location the field returns 00b in those 2 bits Example A 3 slot CCID reports a single byte with the following format Bit 0 Slot 0 current state Bit...

Page 30: ...In_ SCARDCONTEXT hContext _In_ LPCTSTR szReader _In_ DWORD dwShareMode _In_ DWORD dwPreferredProtocols _Out_ LPSCARDHANDLE phCard _Out_ LPDWORD pdwActiveProtocol 8 2 SCardTransmit API LONG WINAPI SCar...

Page 31: ...1 09 04 01 00 00 00 00 24 01 01 08 24 FF FF FF FF FF FF FFh LCD display NEW PIN key User enter 4 digits long new PIN e g 1 2 3 4 and then press OK LCD display CONFIRM PIN key User enter 4 digits long...

Page 32: ...00 00 00 00h 8 9 Read Key Escape command code 06 00 06 00 00 00 08 04 01 00 00h is used to read key entered with keypad by user Read Key Host Reader 06 00 06 00 00 00 08 04 01 00 00h Read Key Reader...

Page 33: ...with Get Feature Request control code and this API will return a list of supported features from the reader In APG8201 B2 only Verify PIN Direct Modify PIN Direct and IFD PIN Properties are supported...

Page 34: ...ATURE_REQUEST returns a list of supported features from the reader hCard Reference value returned from SCardConnect dwControlCode CM_IOCTL_GET_FEATURE_REQUEST lpInBuffer NULL nInBufferSize Must be the...

Page 35: ...Not supported Number of seconds after first key stroke 2 bmFormatString 1 Several parameters for the PIN format options For more information please refer to bmFormatString Description 3 bmPINBlockStri...

Page 36: ...PG8201 B2 will not return this status because it checks the PIN length during input 6B80h Invalid parameter in passed structure SW1SW2 Result from the card nOutBufferSize 2 IpBytesReturned Pointer to...

Page 37: ...confirmation is requested before acceptance of a new PIN meaning that the user has to enter this new PIN twice before it is accepted Indicates if the current PIN must be entered and set in the same AP...

Page 38: ...not return this status because it checks the PIN length during input 6B80h Invalid parameter in passed structure SW1SW2 Result from the card nOutBufferSize 2 lpBytesReturned Pointer to a DWORD that re...

Page 39: ...the received buffer and shift it by 8 bits Set the result to an OR operation together with the fourth element of the received buffer Example Firmware_Version Common RecvBuff 2 8 Common RecvBuff 3 9 3...

Page 40: ...D_DISPLAY_LCD_MESSAGE The IOCTL_SMARTCARD_DISPLAY_LCD_MESSAGE enables display LCD message command hCard Reference value returned from SCardConnect dwControlCode IOCTL_SMARTCARD_DISPLAY_LCD_MESSAGE lpI...

Page 41: ...pointed to by lpOutBuffer Offset Field Size Value Description 0 abStatus 2 0000h 0001h SUCCESS BAD_PARAMETER 2 bKeyReturnCondition 1 31h 32h 33h 34h Maximum size reached Key E pressed Timeout occurred...

Page 42: ...key pressed 3 bTimeOut2 1 00h 0 IFD does not distinguish bTimeOut from bTimeOut2 1 IFD distinguishes bTimeOut from bTimeOut2 nOutBufferSize 4 lpBytesReturned Pointer to a DWORD that receives the size...

Page 43: ...axExtraDigit 2 YYXXh XX Minimum PIN size in digit YY Maximum PIN size in digit Valid XX value 0h 20h Valid YY value 0h 20h 18 bKeyReturnCondition 1 05h The value is a bit wise OR operation 01h Max siz...

Page 44: ...turnCondition OR Operand If Maximum PIN size is reached 01h If APG8201 B2 device KEY_E is pressed 02h If APG8201 B2 session TIMEOUT has reached 04h If APG8201 B2 device KEY_C is pressed 08h If APG8201...

Page 45: ...ror Codes The following table summarizes the possible error code returned by the APG8201 B2 CCID Error Code Status 0001h BAD_PARAMETER 0083h SLOTERROR_LCDCOMMANDERROR 0084h SLOTERROR_WRONGCONFIRMPIN 0...

Page 46: ...f 1h the system units are bytes This bit quantifies the next parameter unit moving Bit 6 3 Define the PIN position after format in the APDU command relative to the first data after Lc The position is...

Page 47: ...dix D bmPINBlockString Description Bit Number Description Bit 7 4 Size in bits of the PIN length inserted in the APDU command If value is equal to 0h then the effective PIN length is not inserted in t...

Page 48: ...system units are bits If 1h the system units are bytes Bit 3 0 Indicate the PIN length position in the APDU command according to the previous parameters maximum 1111 for 15 system units EMV is a regis...

Reviews: