English
Language : 

MC705P6ACPE Datasheet, PDF (65/98 Pages) Freescale Semiconductor, Inc – M68HC05 Microcontrollers
MOR Programming
11.3 MOR Programming
The contents of the MOR should be programmed in bootloader mode using the hardware shown in
Figure 10-2. MC68HC705P6A EPROM Programming Flowchart. In order to allow programming, all the
implemented bits in the MOR are essentially read-write bits in bootloader mode as shown in Figure 11-1.
The programming of the MOR is the same as user EPROM.
1. Set the ELAT bit in the EPROG register.
2. Write the desired data to the desired MOR address.
3. Set the EPGM bit in the EPROG.
4. Wait for the programming time (tEPGM).
5. Clear the ELAT and EPGM bits in the EPROG.
6. Remove the programming voltage from the IRQ/VPP pin.
A sample routine to program a byte of EPROM is shown in Table 11-2.
Once the MOR bits have been programmed, the options are not loaded into the MOR registers until the
part is reset.
Table 11-2. MOR Programming Routine
001C
00FF
0023
1EFF
1F00
0000
00E0
00E0
00E2
00E4
00E6
00E9
00EB
00ED
00EF
A6 04
B7 1C
A6 FF
C7 1E FF
12 1C
AD 03
3F 1C
81
EPROG
DATA2
DATA1
MOR2
MOR1
EPGM
EQU $1C
EQU $FF
EQU #23
EQU $1EFF
EQU $1F00
EQU $00
ORG $E0
LDA #$04
STA EPROG
LDA #DATA2
STA MOR2
BSET EPGM,EPROG
BSR DELAY
CLR EPROG
RTS
PROGRAMMING REG
SAMPLE MOR VALUES
MOPR ADDRESSES
EPGM BIT IN EPROG REG
SET ELAT BIT
IN EPGM REG AT $1C
DATA BYTE
WRITE IT TO MOR LOC
TURN ON PGM VOLTAGE
WAIT 4 ms MINIMUM
CLR EPGM REGISTER
MC68HC705P6A Advance Information Data Sheet, Rev. 2.1
Freescale Semiconductor
65