參數(shù)資料
型號: PIC16F627T-20E/SO
廠商: Microchip Technology
文件頁數(shù): 162/170頁
文件大?。?/td> 0K
描述: IC MCU FLASH 1KX14 18-SOIC
標(biāo)準(zhǔn)包裝: 1,100
系列: PIC® 16F
核心處理器: PIC
芯體尺寸: 8-位
速度: 20MHz
連通性: UART/USART
外圍設(shè)備: 欠壓檢測/復(fù)位,POR,PWM,WDT
輸入/輸出數(shù): 16
程序存儲器容量: 1.75KB(1K x 14)
程序存儲器類型: 閃存
EEPROM 大小: 128 x 8
RAM 容量: 224 x 8
電壓 - 電源 (Vcc/Vdd): 3 V ~ 5.5 V
振蕩器型: 內(nèi)部
工作溫度: -40°C ~ 125°C
封裝/外殼: 18-SOIC(0.295",7.50mm 寬)
包裝: 帶卷 (TR)
2003 Microchip Technology Inc.
Preliminary
DS40300C-page 89
PIC16F62X
13.3
READING THE EEPROM DATA
MEMORY
To read a data memory location, the user must write the
address to the EEADR register and then set control bit
RD (EECON1<0>). The data is available, in the very
next cycle, in the EEDATA register; therefore it can be
read in the next instruction. EEDATA will hold this value
until another read or until it is written to by the user
(during a write operation).
EXAMPLE 13-1:
DATA EEPROM READ
BSF
STATUS, RP0
; Bank 1
MOVLW
CONFIG_ADDR
;
MOVWF
EEADR
; Address to read
BSF
EECON1, RD
; EE Read
MOVF
EEDATA, W
; W = EEDATA
BCF
STATUS, RP0
; Bank 0
13.4
WRITING TO THE EEPROM DATA
MEMORY
To write an EEPROM data location, the user must first
write the address to the EEADR register and the data
to the EEDATA register. Then the user must follow a
specific sequence to initiate the write for each byte.
EXAMPLE 13-2:
DATA EEPROM WRITE
BSF
STATUS, RP0
; Bank 1
BSF
EECON1, WREN
; Enable write
BCF
INTCON, GIE
; Disable INTs.
MOVLW
55h
;
MOVWF
EECON2
; Write 55h
MOVLW
AAh
;
MOVWF
EECON2
; Write AAh
BSF
EECON1,WR
; Set WR bit
; begin write
BSF
INTCON, GIE
; Enable INTs
.
The write will not initiate if the above sequence is not
exactly followed (write 55h to EECON2, write AAh to
EECON2, then set WR bit) for each byte. We strongly
recommend that interrupts be disabled during this
code segment. A cycle count is executed during the
required sequence. Any number that is not equal to the
required cycles to execute the required sequence will
cause the data not to be written into the EEPROM.
Additionally, the WREN bit in EECON1 must be set to
enable write. This mechanism prevents accidental
writes to data EEPROM due to errant (unexpected)
code execution (i.e., lost programs). The user should
keep the WREN bit clear at all times, except when
updating EEPROM. The WREN bit is not cleared
by hardware.
After a write sequence has been initiated, clearing the
WREN bit will not affect this write cycle. The WR bit will
be inhibited from being set unless the WREN bit is set.
At the completion of the write cycle, the WR bit is
cleared in hardware and the EE Write Complete
Interrupt Flag bit (EEIF) is set. The user can either
enable this interrupt or poll this bit. The EEIF bit in the
PIR1 registers must be cleared by software.
13.5
WRITE VERIFY
Depending on the application, good programming
practice may dictate that the value written to the Data
EEPROM should be verified (Example 13-3) to the
desired value to be written. This should be used in
applications where an EEPROM bit will be stressed
near the specification limit.
EXAMPLE 13-3:
WRITE VERIFY
BSF
STATUS, RP0
; Bank 1
MOVF
EEDATA, W
BSF
EECON1, RD
; Read the
; value written
;
; Is the value written (in W reg) and
; read (in EEDATA) the same?
;
SUBWF EEDATA, W
;
BCF
STATUS, RP0
; Bank0
BTFSS STATUS, Z
; Is difference 0?
GOTO
WRITE_ERR
; NO, Write error
:
; YES, Good write
:
; Continue program
13.6
PROTECTION AGAINST
SPURIOUS WRITE
There are conditions when the device may not want to
write to the data EEPROM memory. To protect against
spurious EEPROM writes, various mechanisms have
been built in. On power-up, WREN is cleared. Also, the
Power-up
Timer
(72
ms
duration)
prevents
EEPROM write.
The write initiate sequence, and the WREN bit together
help prevent an accidental write during brown-out,
power glitch, or software malfunction.
13.7
DATA EEPROM OPERATION
DURING CODE PROTECT
When the device is code protected, the CPU is able to
read and write unscrambled data to the Data
EEPROM.
Required
Se
q
uence
相關(guān)PDF資料
PDF描述
PIC16F628T-20E/SO IC MCU FLASH 2KX14 18-SOIC
PIC16F628T-04E/SO IC MCU FLASH 2KX14 18-SOIC
PIC18F448T-I/L IC MCU FLASH 8KX16 W/CAN 44-PLCC
PIC18LF448T-I/L IC MCU FLASH 8KX16 LV CAN 44PLCC
PIC18LF458T-I/L IC MCU FLSH 16KX16 LV CAN 44PLCC
相關(guān)代理商/技術(shù)參數(shù)
參數(shù)描述
PIC16F627T-20I/SO 功能描述:8位微控制器 -MCU 1.75KB 224 RAM 16I/O 20MHz IndTemp SOIC18 RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時鐘頻率:50 MHz 程序存儲器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16F627T-20I/SS 功能描述:8位微控制器 -MCU 1.75KB 224 RAM 16I/O 20MHz IndTemp SSOP20 RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時鐘頻率:50 MHz 程序存儲器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16F628-04/P 功能描述:8位微控制器 -MCU 3.5KB 224 RAM 16 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時鐘頻率:50 MHz 程序存儲器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16F628-04/P 制造商:Microchip Technology Inc 功能描述:IC 8BIT FLASH MCU 16F628 DIP18
PIC16F628-04/SO 功能描述:8位微控制器 -MCU 3.5KB 224 RAM 16 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時鐘頻率:50 MHz 程序存儲器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT