Microchip Technology MA330026 Data Sheet
2011-2014 Microchip Technology Inc.
DS70000652F-page 85
dsPIC33FJ16(GP/MC)101/102 AND dsPIC33FJ32(GP/MC)101/102/104
REGISTER 5-2:
NVMKEY: NONVOLATILE MEMORY KEY REGISTER
REGISTER 5-1:
NVMCON: FLASH MEMORY CONTROL REGISTER
R/SO-0
(
)
R/W-0
(
)
R/W-0
(
U-0
U-0
U-0
U-0
U-0
WR
WREN
WRERR
—
—
—
—
—
bit 15
bit 8
U-0
R/W-0
(
)
U-0
U-0
R/W-0
(
R/W-0
(
)
R/W-0
(
)
R/W-0
(
)
—
ERASE
—
—
NVMOP3
(
)
NVMOP2
(
)
NVMOP1
(
)
NVMOP0
)
bit 7
bit 0
Legend:
SO = Settable Only bit
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 15
WR: Write Control bit
(
1
= Initiates a Flash memory program or erase operation; the operation is self-timed and the bit is
cleared by hardware once operation is complete
0
= Program or erase operation is complete and inactive
bit 14
WREN: Write Enable bit
(
1
= Enables Flash program/erase operations
0
= Inhibits Flash program/erase operations
bit 13
WRERR: Write Sequence Error Flag bit
(
)
1
= An improper program or erase sequence attempt or termination has occurred (bit is set automatically
on any set attempt of the WR bit)
0
= The program or erase operation completed normally
bit 12-7
Unimplemented: Read as ‘0’
bit 6
ERASE: Erase/Program Enable bit
1
= Performs the erase operation specified by NVMOP<3:0> on the next WR command
0
= Performs the program operation specified by NVMOP<3:0> on the next WR command
bit 5-4
Unimplemented: Read as ‘0’
bit 3-0
NVMOP<3:0>: NVM Operation Selection bits
)
If ERASE = 1:
1111
1111
= No operation
1101
= Erase General Segment
1100
= No operation
0011
= No operation
0010
= Memory page erase operation
0001
= No operation
0000
= No operation
If ERASE = 0:
1111
1111
= No operation
1101
= No operation
1100
= No operation
0011
= Memory word program operation
0010
= No operation
0001
= No operation
0000
= No operation
Note 1:
These bits can only be reset on a POR.
2:
All other combinations of NVMOP<3:0> are unimplemented.
U-0
U-0
U-0
U-0
U-0
U-0
U-0
U-0
—
—
—
—
—
—
—
—