ST72T331N2T6 STMicroelectronics, ST72T331N2T6 Datasheet - Page 61

no-image

ST72T331N2T6

Manufacturer Part Number
ST72T331N2T6
Description
8-bit Microcontrollers - MCU OTP EPROM 8K SPI/SCI
Manufacturer
STMicroelectronics
Datasheet

Specifications of ST72T331N2T6

Product Category
8-bit Microcontrollers - MCU
Rohs
yes
Core
ST7
Data Bus Width
8 bit
Maximum Clock Frequency
16 MHz
Program Memory Size
8 KB
Data Ram Size
384 B
On-chip Adc
Yes
Package / Case
TQFP-64
Mounting Style
SMD/SMT
A/d Bit Size
8 bit
A/d Channels Available
8
Interface Type
SCI, SPI
Maximum Operating Temperature
+ 85 C
Minimum Operating Temperature
- 40 C
Number Of Programmable I/os
44
Number Of Timers
2
On-chip Dac
No
Program Memory Type
EPROM
Factory Pack Quantity
90
Supply Voltage - Max
5.5 V
Supply Voltage - Min
3.5 V
SERIAL COMMUNICATIONS INTERFACE (Cont’d)
5.5.4.2 Transmitter
The transmitter can send data words of either 8 or
9 bits depending on the M bit status. When the M
bit is set, word length is 9 bits and the 9th bit (the
MSB) has to be stored in the T8 bit in the CR1 reg-
ister.
Character Transmission
During an SCI transmission, data shifts out least
significant bit first on the TDO pin. In this mode,
the DR register consists of a buffer (TDR) between
the internal bus and the transmit shift register (see
Figure 1.).
Procedure
– Select the M bit to define the word length.
– Select the desired baud rate using the BRR and
– Set the TE bit to assign the TDO pin to the alter-
– Access the SR register and write the data to
Clearing the TDRE bit is always performed by the
following software sequence:
1. An access to the SR register
2. A write to the DR register
The TDRE bit is set by hardware and it indicates:
– The TDR register is empty.
– The data transfer is beginning.
– The next data can be written in the DR register
This flag generates an interrupt if the TIE bit is set
and the I bit is cleared in the CCR register.
When a transmission is taking place, a write in-
struction to the DR register stores the data in the
TDR register and which is copied in the shift regis-
ter at the end of the current transmission.
When no transmission is taking place, a write in-
struction to the DR register places the data directly
in the shift register, the data transmission starts,
and the TDRE bit is immediately set.
the ETPR registers.
nate function and to send a idle frame as first
transmission.
send in the DR register (this sequence clears the
TDRE bit). Repeat this sequence for each data to
be transmitted.
without overwriting the previous data.
When a frame transmission is complete (after the
stop bit or after the break frame) the TC bit is set
and an interrupt is generated if the TCIE is set and
the I bit is cleared in the CCR register.
Clearing the TC bit is performed by the following
software sequence:
1. An access to the SR register
2. A write to the DR register
Note: The TDRE and TC bits are cleared by the
same software sequence.
Break Characters
Setting the SBK bit loads the shift register with a
break character. The break frame length depends
on the M bit (see Figure 2.).
As long as the SBK bit is set, the SCI send break
frames to the TDO pin. After clearing this bit by
software the SCI insert a logic 1 bit at the end of
the last break frame to guarantee the recognition
of the start bit of the next frame.
Idle Characters
Setting the TE bit drives the SCI to send an idle
frame before the first data frame.
Clearing and then setting the TE bit during a trans-
mission sends an idle frame after the current word.
Note: Resetting and setting the TE bit causes the
data in the TDR register to be lost. Therefore the
best time to toggle the TE bit is when the TDRE bit
is set i.e. before writing the next byte in the DR.
ST72E331 ST72T331
61/107
61

Related parts for ST72T331N2T6