Etu counter, Guard time counter – Rainbow Electronics T89C5121 User Manual

Page 31

Advertising
background image

31

A/T8xC5121

4164G–SCR–07/06

the different counters. One of the most important counters is the guard time counter that
gives time slots corresponding to the character frame.

It is enabled only in UART mode.

The transition from the receipt mode to the transmit mode is done automatically. Priority
is given to the transmission.

ETU Counter

The ETU (Elementary Timing Unit) counter controls the working frequency of the barrel
shifter, in fact, it generates the enable signal of the barrel shifter.

It is 11 bits wide and there is a special compensation mode activated with the most sig-
nificant bit that allows non integer ETU value with a working clock equal to the card
clock .

But the decimal value is limited to a half clock cycle. In fact the bit duration is not fixed. It
takes turns in n clock cycles and n-1 clock cycles. The character duration (10 bits) is
also equal to 10*(n+1/2) clock cycles.

This allows to reach the required precision of the character duration specified by the
ISO7816 standard.

example: F = 372 D = 32 = > ETU = 11.625 clock cycles.

ETU = (ETU[10-0] -0.5 * COMP)*f with ETU[10-0] = 12, COMP = 1 (bit 7 of SCETU1)

To achieve this clock rate we activated the compensation mode and we programmed
the ETU duration to 12 clock cycles.

The result will be a full character duration (10 bits) equal to 11.5 clock cycles.

Guard Time Counter

The minimum time between the leading edge of the start bit of a character and the lead-
ing edge of the start bit of the following character transmitted (Guard time) is controlled
by one counter.

It is 9 bits wide and is incremented at the ETU rate.

Figure 15. Guard Time Counter

ETU Counter

SCGT1

SCGT0

GT[8:0]

Guard Time Counter

Timeout

Advertising