Framing Error Detection; Nack Detection; Figure 25-9 Parity Bit Diagram; Figure 25-10 Framing Error Diagram - Motorola DragonBall MC9328MX1 Reference Manual

Integrated portable system processor
Table of Contents

Advertisement

SmartCard Interface Module (SIM)
LSB
Start
When a parity error is detected on a given byte, the RCV_PF bit for that byte is set in the receive FIFO. A
parity error cannot cause an interrupt, however it can signal the SIM transmitter to create a NACK pulse to
the SmartCard asking for a retransmission of the corrupted data. NACK generation upon a parity error is
enabled by setting the automatic NACK enable (ANACK) bit in the SIM CNTL register.

25.3.3.5 Framing Error Detection

The receive state machine is responsible for detecting framing errors in the received data. A SIM data
transaction is defined as 11 or 12 bits long consisting of the start bit, 8 data bits, 1 parity bit and 1 or 2 stop
bits. A framing error occurs when the stop bit is not detected during the 11th bit time of a data transaction.
The stop bit is generally defined as two bit times (ETUs) of a high pulse following the parity bit. When the
GUARD_CNTL register is programed to 0xFF, the stop bit is defined as one bit time. A framing error can
only occur when the parity bit of the current byte is low, and the STOP bit arrives late. Figure 25-10 shows
a typical SIM data transaction with the stop bits identified. Also shown is a SIM data transaction with a late
arriving STOP bit indicating a framing error.
LSB
Start
Without Framing Error
LSB
Start
Framing Error with Low Parity
When a framing error is detected on a given byte, the RCV_FE bit for that byte is set in the receive FIFO.
A framing error cannot cause an interrupt, nor can it create a NACK pulse to the SmartCard asking for a
retransmission of the corrupted data.

25.3.3.6 NACK Detection

The existence of the NACK pulse is sampled by the receive state machine at 11 ETUs after the falling edge
of the start bit. An ETU is equivalent in time to one transmit clock period. Once the receiver detects a
NACK, it signals the transmitter that an error occurred. The transmitter waits for at least another two ETUs
before initiating retransmission, as required by the ISO 7816 specification.
25-12
Parity Bit
MSB
Byte
P
i
Figure 25-9. Parity Bit Diagram
MSB
Byte
P
i
Frame Error
MSB
Byte
P
i
Figure 25-10. Framing Error Diagram
MC9328MX1 Reference Manual
Stop Bits Start
Byte
Stop Bits
Stop Bits Start
Byte
Stop Bits
Stop Bits Start
Byte
i+1
i+1
i+1
MOTOROLA

Advertisement

Table of Contents
loading

Table of Contents