Electronic Components Datasheet Search
  New Zealand  ▼
ALLDATASHEET.CO.NZ

X  

PIC18F23K22 Datasheet(PDF) 17 Page - Microchip Technology

Part # PIC18F23K22
Description  Flash Memory Programming Specification
PDF  42 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  MICROCHIP [Microchip Technology]
Direct Link  http://www.microchip.com
Logo MICROCHIP - Microchip Technology

PIC18F23K22 Datasheet(HTML) 17 Page - Microchip Technology

Back Button PIC18F23K22 Datasheet HTML 13Page - Microchip Technology PIC18F23K22 Datasheet HTML 14Page - Microchip Technology PIC18F23K22 Datasheet HTML 15Page - Microchip Technology PIC18F23K22 Datasheet HTML 16Page - Microchip Technology PIC18F23K22 Datasheet HTML 17Page - Microchip Technology PIC18F23K22 Datasheet HTML 18Page - Microchip Technology PIC18F23K22 Datasheet HTML 19Page - Microchip Technology PIC18F23K22 Datasheet HTML 20Page - Microchip Technology PIC18F23K22 Datasheet HTML 21Page - Microchip Technology Next Button
Zoom Inzoom in Zoom Outzoom out
 17 / 42 page
background image
 2010 Microchip Technology Inc.
Advance Information
DS41398B-page 17
PIC18(L)F2XK22/4XK22
3.2
Code Memory Programming
Programming code memory is accomplished by first
loading data into the write buffer and then initiating a
programming sequence. The write and erase buffer
sizes shown in Table 3-4 can be mapped to any
location of the same size beginning at 000000h. The
actual memory write sequence takes the contents of
this buffer and programs the proper amount of code
memory that contains the Table Pointer.
The programming duration is externally timed and is
controlled by PGC. After a Start Programming
command is issued (4-bit command, ‘1111’), a NOP is
issued, where the 4th PGC is held high for the duration
of the programming time, P9.
After PGC is brought low, the programming sequence
is terminated. PGC must be held low for the time
specified by parameter P10 to allow high-voltage
discharge of the memory array.
The code sequence to program a device is shown in
Table 3-5. The flowchart shown in Figure 3-4 depicts
the logic necessary to completely write the device. The
timing diagram that details the Start Programming
command and parameters P9 and P10 is shown in
Figure 3-5.
TABLE 3-4:
WRITE AND ERASE BUFFER SIZES
TABLE 3-5:
WRITE CODE MEMORY CODE SEQUENCE
Note:
The TBLPTR register must point to the
same
region
when
initiating
the
programming sequence as it did when the
write buffers were loaded.
Devices
Write Buffer Size
(bytes)
Erase Size
(bytes)
PIC18F23K22
PIC18F24K22
PIC18F25K22
PIC18F26K22
PIC18F43K22
PIC18F44K22
PIC18F45K22
PIC18F46K22
PIC18LF23K22
PIC18LF24K22
PIC18LF25K22
PIC18LF26K22
PIC18LF43K22
PIC18LF44K22
PIC18LF45K22
PIC18LF46K22
64
64
4-bit
Command
Data Payload
Core Instruction
Step 1: Direct access to code memory.
0000
0000
0000
8E A6
9C A6
84 A6
BSF
EECON1, EEPGD
BCF
EECON1, CFGS
BSF
EECON1, WREN
Step 2: Point to row to write.
0000
0000
0000
0000
0000
0000
0E <Addr[21:16]>
6E F8
0E <Addr[15:8]>
6E F7
0E <Addr[7:0]>
6E F6
MOVLW <Addr[21:16]>
MOVWF TBLPTRU
MOVLW <Addr[15:8]>
MOVWF TBLPTRH
MOVLW <Addr[7:0]>
MOVWF TBLPTRL
Step 3: Load write buffer. Repeat for all but the last two bytes.
1101
<MSB><LSB>
Write 2 bytes and post-increment address by 2.
Step 4: Load write buffer for last two bytes and start programming.
1111
0000
<MSB><LSB>
00 00
Write 2 bytes and start programming.
NOP - hold PGC high for time P9 and low for time P10.
To continue writing data, repeat steps 2 through 4, where the Address Pointer is incremented by 2 at each iteration of
the loop.



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


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
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