전자부품 데이터시트 검색엔진
  Korean  ▼
ALLDATASHEET.CO.KR

X  

PIC16F526-I/P 데이터시트(PDF) 24 Page - Microchip Technology

부품명 PIC16F526-I/P
상세설명  14-Pin, 8-Bit Flash Microcontroller
PDF  122 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
제조업체  MICROCHIP [Microchip Technology]
홈페이지  http://www.microchip.com
Logo MICROCHIP - Microchip Technology

PIC16F526-I/P 데이터시트(HTML) 24 Page - Microchip Technology

Back Button PIC16F526-I/P Datasheet HTML 20Page - Microchip Technology PIC16F526-I/P Datasheet HTML 21Page - Microchip Technology PIC16F526-I/P Datasheet HTML 22Page - Microchip Technology PIC16F526-I/P Datasheet HTML 23Page - Microchip Technology PIC16F526-I/P Datasheet HTML 24Page - Microchip Technology PIC16F526-I/P Datasheet HTML 25Page - Microchip Technology PIC16F526-I/P Datasheet HTML 26Page - Microchip Technology PIC16F526-I/P Datasheet HTML 27Page - Microchip Technology PIC16F526-I/P Datasheet HTML 28Page - Microchip Technology Next Button
Zoom Inzoom in Zoom Outzoom out
 24 / 122 page
background image
PIC16F526
DS41326D-page 24
 2010 Microchip Technology Inc.
5.2.2
WRITING TO FLASH DATA
MEMORY
Once a cell is erased, new data can be written.
Program execution is suspended during the write cycle.
The following sequence must be performed for a single
byte write.
1.
Load EEADR with the address.
2.
Load EEDATA with the data to write.
3.
Set the WREN bit to enable write access to the
array.
4.
Set the WR bit to initiate the erase cycle.
If the WR bit is not set in the instruction cycle after the
WREN bit is set, the WREN bit will be cleared in
hardware.
Sample code that follows this procedure is included in
Example 3.
EXAMPLE 3:
WRITING A FLASH DATA
MEMORY ROW
5.3
Write Verify
Depending on the application, good programming
practice may dictate that data written to the Flash data
memory be verified. Example 4 is an example of a write
verify.
EXAMPLE 4:
WRITE VERIFY OF FLASH
DATA MEMORY
REGISTER 5-1:
EEDATA: FLASH DATA REGISTER
REGISTER 5-2:
EEADR: FLASH ADDRESS REGISTER
BANKSEL
EEADR
MOVLW
EE_ADR_WRITE
; LOAD ADDRESS
MOVWF
EEADR
;
MOVLW
EE_DATA_TO_WRITE ; LOAD DATA
MOVWF
EEDATA
; INTO EEDATA REGISTER
BSF
EECON,WREN
; ENABLE WRITES
BSF
EECON,WR
; INITITATE ERASE
Note 1: Only a series of BSF commands will work
to enable the memory write sequence
documented in Example 2. No other
sequence of commands will work, no
exceptions.
2: For reads, erases and writes to the Flash
data memory, there is no need to insert a
NOP into the user code as is done on mid-
range devices. The instruction immediately
following the “BSF EECON,WR/RD” will be
fetched and executed properly.
MOVF
EEDATA, W
;EEDATA has not changed
;from previous write
BSF
EECON, RD
;Read the value written
XORWF
EEDATA, W
;
BTFSS
STATUS, Z
;Is data the same
GOTO
WRITE_ERR
;No, handle error
;Yes, continue
R/W-x
R/W-x
R/W-x
R/W-x
R/W-x
R/W-x
R/W-x
R/W-x
EEDATA7
EEDATA6
EEDATA5
EEDATA4
EEDATA3
EEDATA2
EEDATA1
EEDATA0
bit 7
bit 0
Legend:
R = Readable bit
W = Writable bit
U = Unimplemented bit, read as ‘0’
-n = Value at POR
‘1’ = Bit is set
‘0’ = Bit is cleared
x = Bit is unknown
bit 7-0
EEDATA<7:0>: 8-bits of data to be read from/written to data Flash
U-0
U-0
R/W-x
R/W-x
R/W-x
R/W-x
R/W-x
R/W-x
EEADR5
EEADR4
EEADR3
EEADR2
EEADR1
EEADR0
bit 7
bit 0
Legend:
R = Readable bit
W = Writable bit
U = Unimplemented bit, read as ‘0’
-n = Value at POR
‘1’ = Bit is set
‘0’ = Bit is cleared
x = Bit is unknown
bit 7-6
Unimplemented: Read as ‘0’.
bit 5-0
EEADR<5:0>: 6-bits of data to be read from/written to data Flash



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100  ...More


데이터시트 다운로드

Go To PDF Page


링크 URL



ALLDATASHEET 가 귀하에 도움이 되셨나요?  [ DONATE ] 

Alldatasheet는?   |   광고문의   |   운영자에게 연락하기   |   개인정보취급방침   |   링크 투 데이터시트    |   링크교환   |   제조사별 검색
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com