2012 Microchip Technology Inc. Preliminary DS41642A-page 7
PIC12LF1552
4.0 PROGRAM/VERIFY MODE
In Program/Verify mode, the program memory and the
configuration memory can be accessed and
programmed in serial fashion. ICSPDAT and
ICSPCLK are used for the data and the clock,
respectively. All commands and data words are
transmitted LSb first. Data changes on the rising edge
of the ICSPCLK and latched on the falling edge. In
Program/Verify mode, both the ICSPDAT and
ICSPCLK are Schmitt Trigger inputs. The sequence
that enters the device into Program/Verify mode
places all other logic into the Reset state. Upon
entering Program/Verify mode, all I/Os are
automatically configured as high-impedance inputs
and the address is cleared.
4.1 High-Voltage Program/Verify
Mode Entry and Exit
There are two different methods of entering Program/
Verify mode via high voltage:
•VPP – First entry mode
•V
DD – First entry mode
4.1.1 VPP – FIRST ENTRY MODE
To enter Program/Verify mode via the VPP-first method
the following sequence must be followed:
1. Hold ICSPCLK and ICSPDAT low. All other pins
should be unpowered.
2. Raise the voltage on MCLR
from 0V to VIHH.
3. Raise the voltage on V
DD from 0V to the desired
operating voltage.
The VPP-first entry prevents the device from executing
code prior to entering Program/Verify mode. For
example, the device will execute code when
Configuration Word 1 has MCLR
disabled (MCLRE =
0), the Power-up Timer is disabled (PWRTE
= 0), the
internal oscillator is selected (F
OSC = 100), and
ICSPCLK and ICSPDAT pins are driven by the user
application. Since this may prevent entry, VPP-first
entry mode is strongly recommended. See the timing
diagram in Figure 8-2.
4.1.2 VDD – FIRST ENTRY MODE
To enter Program/Verify mode via the VDD-first method
the following sequence must be followed:
1. Hold ICSPCLK and ICSPDAT low.
2. Raise the voltage on V
DD from 0V to the desired
operating voltage.
3. Raise the voltage on MCLR
from VDD or below
to V
IHH.
The V
DD-first method is useful when programming the
device when V
DD is already applied, for it is not
necessary to disconnect V
DD to enter Program/Verify
mode. See the timing diagram in Figure 8-1.
4.1.3 PROGRAM/VERIFY MODE EXIT
To exit Program/Verify mode take MCLR to VDD or
lower (V
IL). See Figures 8-3 and 8-4.
4.2 Low-Voltage Programming (LVP)
Mode
The Low-Voltage Programming mode allows the
device to be programmed using V
DD only, without high
voltage. When the LVP bit of Configuration Word 2
register is set to1’, the low-voltage ICSP programming
entry is enabled. To disable the Low-Voltage ICSP
mode, the LVP bit must be programmed to ‘0’. This can
only be done while in the High-Voltage Entry mode.
Entry into the Low-Voltage ICSP Program/Verify
modes requires the following steps:
1. MCLR
is brought to VIL.
2. A 32-bit key sequence is presented on
ICSPDAT, while clocking ICSPCLK.
The key sequence is a specific 32-bit pattern, '0100
1101 0100 0011 0100 1000 0101 0000' (more
easily remembered as MCHP in ASCII). The device will
enter Program/Verify mode only if the sequence is
valid. The Least Significant bit of the Least Significant
nibble must be shifted in first.
Once the key sequence is complete, MCLR
must be
held at V
IL for as long as Program/Verify mode is to be
maintained.
For low-voltage programming timing, see Figure 8-8
and Figure 8-9.
Exiting Program/Verify mode is done by no longer
driving MCLR
to VIL. See Figure 8-8 and Figure 8-9.
Note: To enter LVP mode, the LSB of the Least
Significant nibble must be shifted in first.
This differs from entering the key
sequence on other parts.
PIC12LF1552
DS41642A-page 8 Preliminary 2012 Microchip Technology Inc.
4.3 Program/Verify Commands
The device implements ten programming commands;
each six bits in length. The commands are summarized
in Table 4-1.
Commands that have data associated with them are
specified to have a minimum delay of T
DLY between the
command and the data. After this delay 16 clocks are
required to either clock in or clock out the 14-bit data
word. The first clock is for the Start bit and the last clock
is for the Stop bit.
4.3.1 LOAD CONFIGURATION
The Load Configuration command is used to access
the configuration memory (user ID locations,
Configuration Words, Calibration Words). The Load
Configuration command sets the address to 8000h and
loads the data latches with one word of data (see
Figure 4-1).
After issuing the Load Configuration command, use the
Increment Address command until the proper address
to be programmed is reached. The address is then
programmed by issuing either the Begin Internally
Timed Programming or Begin Externally Timed
Programming command.
The only way to get back to the program memory
(address 0) is to exit Program/Verify mode or issue the
Reset Address command after the configuration memory
has been accessed by the Load Configuration command.
FIGURE 4-1: LOAD CONFIGURATION
TABLE 4-1: COMMAND MAPPING
Command
Mapping
Data/Note
Binary (MSb … LSb) Hex
Load Configuration x00000 00h 0, data (14), 0
Load Data For Program Memory x00010 02h 0, data (14), 0
Read Data From Program Memory x00100 04h 0, data (14), 0
Increment Address x00110 06h
Reset Address x10110 16h
Begin Internally Timed Programming x01000 08h
Begin Externally Timed Programming x11000 18h
End Externally Timed Programming x010100Ah
Bulk Erase Program Memory x01001 09h Internally Timed
Row Erase Program Memory x10001 11h Internally Timed
Note: Externally timed writes are not supported
for Configuration and Calibration bits. Any
externally timed write to the Configuration
or Calibration Word will have no effect on
the targeted word.
X00
LSb
MSb 0
1
23
4
5
6
1
2
15
16
ICSPCLK
ICSPDAT
0
0
0
0
TDLY
2012 Microchip Technology Inc. Preliminary DS41642A-page 9
PIC12LF1552
4.3.2 LOAD DATA FOR PROGRAM
MEMORY
The Load Data for Program Memory command is used
to load one 14-bit word into the data latches. The word
programs into program memory after the Begin
Internally Timed Programming or Begin Externally
Timed Programming command is issued (see
Figure 4-2).
FIGURE 4-2: LOAD DATA FOR PROGRAM MEMORY
4.3.3 READ DATA FROM PROGRAM
MEMORY
The Read Data from Program Memory command will
transmit data bits out of the program memory map
currently accessed, starting with the second rising edge
of the clock input. The ICSPDAT pin will go into Output
mode on the first falling clock edge, and it will revert to
Input mode (high-impedance) after the 16th falling edge
of the clock. If the program memory is code-protected
(CP
), the data will be read as zeros (see Figure 4-3).
FIGURE 4-3: READ DATA FROM PROGRAM MEMORY
ICSPCLK
ICSPDAT
1
23
45
6
1
2
15
16
X0
0
LSb
MSb
0
010
0
TDLY
1 2 3 4 5 6 1 2 15 16
LSb
MSb
TDLY
ICSPCLK
ICSPDAT
Input
Input
Output
x
(from Programmer)
X
0
001
0
ICSPDAT
(from device)

PIC12LF1552-I/MS

Mfr. #:
Manufacturer:
Microchip Technology
Description:
8-bit Microcontrollers - MCU 3.5KBFlash 256bRAM 6 I/0, 10-Bit ADC
Lifecycle:
New from this manufacturer.
Delivery:
DHL FedEx Ups TNT EMS
Payment:
T/T Paypal Visa MoneyGram Western Union