DatasheetQ Logo
Electronic component search and free download site. Transistors,MosFET ,Diode,Integrated circuits

ATMEGA329 データシートの表示(PDF) - Atmel Corporation

部品番号
コンポーネント説明
メーカー
ATMEGA329 Datasheet PDF : 392 Pages
First Prev 21 22 23 24 25 26 27 28 29 30 Next Last
ATmega329/3290/649/6490
8.5.4
8.5.5
8.5.6
Assembly Code Example
EEPROM_read:
; Wait for completion of previous write
sbic EECR,EEWE
rjmp EEPROM_read
; Set up address (r18:r17) in address register
out EEARH, r18
out EEARL, r17
; Start eeprom read by writing EERE
sbi EECR,EERE
; Read data from Data Register
in r16,EEDR
ret
C Code Example
unsigned char EEPROM_read(unsigned int uiAddress)
{
/* Wait for completion of previous write */
while(EECR & (1<<EEWE))
;
/* Set up address register */
EEAR = uiAddress;
/* Start eeprom read by writing EERE */
EECR |= (1<<EERE);
/* Return data from Data Register */
return EEDR;
}
GPIOR2 – General Purpose I/O Register 2
Bit
7
6
5
4
3
2
1
0x2B (0x4B)
MSB
Read/Write
R/W
R/W
R/W
R/W
R/W
R/W
R/W
Initial Value
0
0
0
0
0
0
0
GPIOR1 – General Purpose I/O Register 1
Bit
7
6
5
4
3
2
1
0x2A (0x4A)
MSB
Read/Write
R/W
R/W
R/W
R/W
R/W
R/W
R/W
Initial Value
0
0
0
0
0
0
0
GPIOR0 – General Purpose I/O Register 0
Bit
7
6
5
4
3
2
1
0x1E (0x3E)
MSB
Read/Write
R/W
R/W
R/W
R/W
R/W
R/W
R/W
Initial Value
0
0
0
0
0
0
0
0
LSB
R/W
0
GPIOR2
0
LSB
R/W
0
GPIOR1
0
LSB
R/W
0
GPIOR0
25
2552J–AVR–08/07

Share Link: 

datasheetq.com  [ Privacy Policy ]Request Datasheet ] [ Contact Us ]