Vault 7: Projects
This publication series is about specific projects related to the Vault 7 main publication.
2009-2013 Microchip Technology Inc. DS70000582E-page 43
UART
15.1 Protocol and Frame Details
The Smart Card communication scheme is based on an Elementary Time Unit (ETU) that is also
the bit clock. The Smart Card will provide the ETU value in the ATR and the terminal is configured
accordingly. A character frame consists of 10 bits; a Start bit, 8 data bits and a parity bit. Depending
on the mode, guard and wait times are used to separate bytes and message transitions.
The ISO 7816 specification defines 2 communication logic conventions: direct and inverse.
Direct convention is defined as LSB first and a high state as logic one. Inverse mode is defined
as MSB first and a low on the line is interpreted as a logic low. The logic convention is set using
the CONV bit (UxSCCON<3>).
15.1.1 GUARD TIME
Guard time is defined as the minimum delay between two consecutive character frames. The
ISO 7816 specification defines both a Character Guard Time (CGT) and a Block Guard Time
(BGT). In both T = 0 and T = 1 modes, CGT is defined as the minimum delay between the leading
edges of the two consecutive characters in the same direction of transmission. Block Guard Time
(BGT) for T = 1 mode only is defined as the minimum delay between the leading edges of the two
consecutive characters in the opposite directions. The BGT has a standard fixed value of 22 ETU.
15.1.2 WAIT TIME
Wait time is the maximum delay allowed between two consecutive characters transmitted by the
card or an interfacing device. The Character Wait Time (CWT) is the maximum delay between
the leading edges of the two consecutive characters in the block, as shown in Figure 15-2. The
minimum delay is CGT. The Block Wait Time (BWT) is the maximum delay between the leading
edge of the last character of the block received by the card and the leading edge of the first
character of the next block transmitted by the card, as shown in Figure 15-3. BWT helps the
interfacing device in detecting the unresponsive Smart Cards. The minimum delay is BGT.
Figure 15-2: Character Guard and Wait Time
Figure 15-3: Block Guard and Wait Time
Note: The guard time count is started after the parity bit is shifted out. The value of the Guard
Time Counter register will have to be calculated to exclude the character frame time.
Note: The LAST bit (UxTXREG<15>) set by user software is used to automatically start
the guard or wait timers, depending on the state of the module.
CGT ≤ t ≤ CWT
Character of a Block Next Character of the Same Block
BGT ≤ t ≤ BWT
Last Character of a Block
First Character of the Next Block
Sent by the Interface Device
Sent by the Card
Protego_Release_01_05-Related-OEM-Documentation-PIC24FJ32MC10X-Reference_Manual-PIC24FJ32MC102-UART.pdf