AT90CAN32 Automotive Atmel Corporation, AT90CAN32 Automotive Datasheet - Page 183

no-image

AT90CAN32 Automotive

Manufacturer Part Number
AT90CAN32 Automotive
Description
Manufacturer
Atmel Corporation

Specifications of AT90CAN32 Automotive

Flash (kbytes)
32 Kbytes
Pin Count
64
Max. Operating Frequency
16 MHz
Cpu
8-bit AVR
# Of Touch Channels
16
Hardware Qtouch Acquisition
No
Max I/o Pins
53
Ext Interrupts
8
Usb Speed
No
Usb Interface
No
Spi
1
Twi (i2c)
1
Uart
2
Can
1
Graphic Lcd
No
Video Decoder
No
Camera Interface
No
Adc Channels
8
Adc Resolution (bits)
10
Adc Speed (ksps)
15
Analog Comparators
1
Resistive Touch Screen
No
Temp. Sensor
No
Crypto Engine
No
Sram (kbytes)
2
Eeprom (bytes)
1024
Self Program Memory
YES
Dram Memory
No
Nand Interface
No
Picopower
No
Temp. Range (deg C)
-40 to 125
I/o Supply Class
2.7 to 5.5
Operating Voltage (vcc)
2.7 to 5.5
Fpu
No
Mpu / Mmu
no / no
Timers
4
Output Compare Channels
8
Input Capture Channels
2
Pwm Channels
7
32khz Rtc
Yes
Calibrated Rc Oscillator
Yes
17.7.1
7682C–AUTO–04/08
Sending Frames with 5 to 8 Data Bit
chronous operation is used, the clock on the XCKn pin will be overridden and used as
transmission clock.
A data transmission is initiated by loading the transmit buffer with the data to be transmitted. The
CPU can load the transmit buffer by writing to the UDRn I/O location. The buffered data in the
transmit buffer will be moved to the Shift Register when the Shift Register is ready to send a new
frame. The Shift Register is loaded with new data if it is in idle state (no ongoing transmission) or
immediately after the last stop bit of the previous frame is transmitted. When the Shift Register is
loaded with new data, it will transfer one complete frame at the rate given by the Baud Register,
U2Xn bit or by XCKn depending on mode of operation.
The following code examples show a simple USART0 transmit function based on polling of the
Data Register Empty (UDRE0) flag. When using frames with less than eight bits, the most signif-
icant bits written to the UDR0 are ignored. The USART0 has to be initialized before the function
can be used. For the assembly code, the data to be sent is assumed to be stored in Register
R16
Note:
The function simply waits for the transmit buffer to be empty by checking the UDRE0 flag, before
loading it with new data to be transmitted. If the Data Register Empty interrupt is utilized, the
interrupt routine writes the data into the buffer.
Assembly Code Example
C Code Example
.
USART0_Transmit:
void USART0_Transmit (unsigned char data)
{
}
; Wait for empty transmit buffer
lds
sbrs
rjmp
; Put data (r16) into buffer, sends the data
sts
ret
/* Wait for empty transmit buffer */
while ( ! ( UCSRA0 & (1<<UDRE0)));
/* Put data into buffer, sends the data */
UDR0 = data;
1. The example code assumes that the part specific header file is included.
r17, UCSR0A
r17, UDRE0
USART0_Transmit
UDR0, r16
(1)
(1)
AT90CAN32/64/128
183

Related parts for AT90CAN32 Automotive