AT32UC3L064-D3HES ATMEL [ATMEL Corporation], AT32UC3L064-D3HES Datasheet - Page 477

no-image

AT32UC3L064-D3HES

Manufacturer Part Number
AT32UC3L064-D3HES
Description
Manufacturer
ATMEL [ATMEL Corporation]
Datasheet
22.8.2.1
22.8.2.2
32099D–06/2010
Clock Generation
Setting up and Performing a Transfer
The Clock Waveform Generator Register (CWGR) is used to control the waveform of the
TWCK clock. CWGR must be programmed so that the desired TWI bus timings are generated.
CWGR describes bus timings as a function of cycles of a prescaled clock. The clock prescal-
ing can be selected through the EXP field in CWGR.
CWGR has the following fields:
LOW: Prescaled clock cycles in clock low count. Used to time T
HIGH: Prescaled clock cycles in clock high count. Used to time T
STASTO: Prescaled clock cycles in clock high count. Used to time T
DATA: Prescaled clock cycles for data setup and hold count. Used to time T
EXP: Specifies the clock prescaler setting.
Note that the total clock low time generated is the sum of T
Any slave or other bus master taking part in the transfer may extend the TWCK low period at
any time.
The TWIM hardware monitors the state of the TWCK line as required by the I²C specification.
The clock generation counters are started when a high/low level is detected on the TWCK line,
not when the TWIM hardware releases/drives the TWCK line. This means that the CWGR set-
tings alone do not determine the TWCK frequency. The CWGR settings determine the clock
low time and the clock high time, but the TWCK rise and fall times are determined by the exter-
nal circuitry (capacitive load, etc.).
Figure 22-5. Bus Timing Diagram
Operation of TWIM is mainly controlled by the Control Register (CR) and the Command Reg-
ister (CMDR). The following list presents the main steps in a typical communication:
f
prescaled
S
=
t
t LOW
HD:STA
-------------------------
2
(
EXP
f
clkpb
+ )
1
t
SU:DAT
)
t HIGH
t
HD:DAT
t LOW
t
t
SU:DAT
SU:STA
AT32UC3L016/32/64
HD_DAT
Sr
LOW
HIGH
+ T
. and T
HD_STA
.
SU_DAT
BUF
, T
t
HD_DAT
+ T
SU:STO
SU_STA
.
LOW
, T
.
, T
SU_DAT
P
SU_STO
477
.
.

Related parts for AT32UC3L064-D3HES