參數(shù)資料
型號: IT80C52EXXX-30SHXXX:R
廠商: TEMIC SEMICONDUCTORS
元件分類: 微控制器/微處理器
英文描述: 8-BIT, MROM, 30 MHz, MICROCONTROLLER, PQFP44
文件頁數(shù): 15/60頁
文件大?。?/td> 5137K
22
8266D-MCU Wireless-06/12
ATmega128RFA1
call EEPROM_write
C Code Example (Single Byte Programming)
void EEPROM_write(unsigned int uiAddress, unsigned char ucData)
{
/* Wait for completion of previous erase/write */
while(EECR & (1<<EEPE))
;
/* Set up address */
EEAR = uiAddress;
EEDR = 255;
/* Write logical one to EEMPE and enable erase only*/
EECR = (1<<EEMPE) + (1<<EEPM0);
/* Start eeprom erase by setting EEPE */
EECR |= (1<<EEPE);
/* Wait for completion of erase */
while(EECR & (1<<EEPE))
;
/* Set up Data Registers */
EEDR = ucData;
/* Write logical one to EEMPE and enable write only */
EECR = (1<<EEMPE) + (2<<EEPM0);
/* Start eeprom write by setting EEPE */
EECR |= (1<<EEPE);
}
Although the code for separate erase/write operations is more complex it is
recommended over the atomic operation. The erase operation can be omitted if the
target EEPROM byte already contains the value 255 (e.g. after a chip erase without the
EESAVE fuse set).
Assembly Code Example (Atomic Operation)
EEPROM_atomic_write:
; Wait for completion of previous write
sbic EECR,EEPE
rjmp EEPROM_atomic_write
; Set up address (r18:r17) in address register
out EEARH, r18
out EEARL, r17
; Write data (r16) to Data Register
out EEDR,r16
; Write logical one to EEMPE
sbi EECR,EEMPE
; Start eeprom write by setting EEPE
sbi EECR,EEPE
ret
相關(guān)PDF資料
PDF描述
MC80C52CXXX-20/883D 8-BIT, MROM, 20 MHz, MICROCONTROLLER, CDIP40
MR80C52CXXX-25SB 8-BIT, MROM, 25 MHz, MICROCONTROLLER, CQCC44
MR80C52UXXX-25 8-BIT, MROM, 25 MHz, MICROCONTROLLER, CQCC44
IS80C32U-S 8-BIT, 20 MHz, MICROCONTROLLER, PQCC44
IV80C52UXXX-S 8-BIT, MROM, 20 MHz, MICROCONTROLLER, PQFP44
相關(guān)代理商/技術(shù)參數(shù)
參數(shù)描述
IT80F 制造商:未知廠家 制造商全稱:未知廠家 功能描述:TRIAC|50V V(DRM)|8A I(T)RMS|TO-220
IT80G 制造商:未知廠家 制造商全稱:未知廠家 功能描述:TRIAC|50V V(DRM)|8A I(T)RMS|TO-220
IT810B 制造商:未知廠家 制造商全稱:未知廠家 功能描述:Analog IC
IT8152FG 制造商:未知廠家 制造商全稱:未知廠家 功能描述:Specification|Errata_v0.1 for it8152fg_v0.3.4
IT8172G 制造商:未知廠家 制造商全稱:未知廠家 功能描述:RISC Companion Chip|Errata v0.2 for it8172g_v0.6