AT89LP51ED2-20AU Atmel, AT89LP51ED2-20AU Datasheet - Page 146

no-image

AT89LP51ED2-20AU

Manufacturer Part Number
AT89LP51ED2-20AU
Description
8-bit Microcontrollers - MCU 64KB 20MHz 2.4V-5.5V
Manufacturer
Atmel
Datasheet

Specifications of AT89LP51ED2-20AU

Rohs
yes
Core
8051
Processor Series
AT89x
Data Bus Width
8 bit
Maximum Clock Frequency
20 MHz
Program Memory Size
64 KB
Data Ram Size
256 B
On-chip Adc
Yes
Operating Supply Voltage
2.4 V to 5.5 V
Operating Temperature Range
- 40 C to + 85 C
Package / Case
TQFP-44
Mounting Style
SMD/SMT
Data Rom Size
4 KB
Interface Type
2-Wire, SPI, UART
Number Of Programmable I/os
36
Number Of Timers
3
Program Memory Type
Flash
Factory Pack Quantity
160

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
AT89LP51ED2-20AU
Manufacturer:
Atmel
Quantity:
10 000
19.6
146
Transmission Modes
AT89LP51RD2/ED2/ID2 Preliminary
Even though this example is simple, it shows the principles involved in all TWI transmissions.
These can be summarized as follows:
The TWI can operate in one of four major modes. These are named Master Transmitter (MT),
Master Receiver (MR), Slave Transmitter (ST) and Slave Receiver (SR). Several of these
modes can be used in the same application. As an example, the TWI can use MT mode to write
data into a TWI EEPROM, MR mode to read the data back from the EEPROM. If other masters
are present in the system, some of these might transmit data to the TWI, and then SR mode
would be used. It is the application software that decides which modes are legal.
The following sections describe each of these modes. Possible status codes are described
along with figures detailing data transmission in each of the modes. These figures contain the
following abbreviations:
4. When the address packet has been transmitted, the SI flag in SSCON is set, and SSCS
5. The application software should now examine the value of SSCS, to make sure that the
6. When the data packet has been transmitted, the SI flag in SSCON is set, and SSCS is
7. The application software should now examine the value of SSCS, to make sure that the
• When the TWI has finished an operation and expects application response, the SI flag is set.
• When the SI flag is set, the user must update all TWI registers with the value relevant for the
• After all TWI Register updates and other pending application software tasks have been
The SCL line is pulled low until SI is cleared.
next TWI bus cycle. As an example, SSDAT must be loaded with the value to be transmitted
in the next bus cycle.
completed, SSCON is written. When writing SSCON, the SI bit should be cleared. The TWI
will then commence executing whatever operation was specified by the SSCON setting.
is updated with a status code indicating that the address packet has successfully been
sent. The status code will also reflect whether a slave acknowledged the packet or not.
address packet was successfully transmitted, and that the value of the ACK bit was as
expected. If SSCS indicates otherwise, the application software might take some spe-
cial action, like calling an error routine. Assuming that the status code is as expected,
the application must load a data packet into SSDAT. Subsequently, a specific value
must be written to SSCON, instructing the TWI hardware to transmit the data packet
present in SSDAT. Which value to write is described later on. However, it is important
that the SI bit is cleared in the value written. The TWI will not start any operation as long
as the SI bit in SSCON is set. Immediately after the application has cleared SI, the TWI
will initiate transmission of the data packet.
updated with a status code indicating that the data packet has successfully been sent.
The status code will also reflect whether a slave acknowledged the packet or not.
data packet was successfully transmitted, and that the value of the ACK bit was as
expected. If SSCS indicates otherwise, the application software might take some spe-
cial action, like calling an error routine. Assuming that the status code is as expected,
the application must write a specific value to SSCON, instructing the TWI hardware to
transmit a STOP condition. Which value to write is described later on. However, it is
important that the SI bit is cleared in the value written. The TWI will not start any opera-
tion as long as the SI bit in SSCON is set. Immediately after the application has cleared
SI, the TWI will initiate transmission of the STOP condition. Note that SI is NOT set
after a STOP condition has been sent.
3714A–MICRO–7/11

Related parts for AT89LP51ED2-20AU