
NUC126
Aug. 08, 2018
Page
218
of 943
Rev 1.03
NUC12
6 S
E
RI
E
S
T
E
CH
NI
CA
L R
E
F
E
RE
NCE
MA
NUA
L
11
APROM without IAP
No
Table 6.4-1 Boot Source Selection Table
6.4.4.3
In-Application-Programming (IAP)
The NUC126 Series provides In-Application-Programming (IAP) mode for user to switch the code
executing between APROM, LDROM and SPROM. User can enable the IAP mode by booting chip
and setting the chip boot selection bits in CBS (CONFIG0[7:6]) as 10 or 00.
When chip boots with IAP mode enabled, any executable code (align to 512 bytes) is allowed to map
to the system memory vector. User can set the remap address by FMC_ISPADDR and then trigger
ISP procedure with the “Vector Page Remap” command (0x2E).
6.4.4.4
In-System-Programming (ISP)
The NUC126 series supports In-System-Programming (ISP) function allowing the embedded flash
memory to be reprogrammed under software control. ISP is performed without addition devices and
just utilize on-chip connectivity interfaces, such as UART, USB, I
2
C and SPI.
The NUC126 ISP provides the following functions for embedded flash memory.
Supports flash page erase function
Supports flash mass erase function
Supports flash data program function
Supports flash data read function
Supports company ID read function
Supports device ID read function
Supports unique ID read function
Supports memory CRC32 checksum calculation function
Supports flash all-one verification function
Supports system memory vector remap function
ISP Commands
Table 6.4-2 shows all supported ISP commands. Including command code, address and data
limitations.
ISP CMD
Code ISPADDR
ISPDAT
MPDAT0~ MPDAT3
FLASH Page Erase
0x22
Valid address of flash memory. It must be page
alignment.
N/A or 0x0055AA03 if erase
SPROM.
FLASH Mass Erase
(Valid only when CFG0[5]=0)
0x26
0x0000_0000
N/A
FLASH 32-bit Program
0x21
Valid address of flash memory. It must be word
alignment.
FMC_ISPDAT:Programming Data
FMC_MPDAT0~FMC_MPDAT3:
N/A
FLASH 64-bit Program
0x61
Valid address of flash memory organization. It must
be 64-bit alignment.
FMC_ISPDAT:N/A
FMC_MPDAT0: LSB
Programming Data
FMC_MPDAT1: MSB
Programming Data
FMC_MPDAT2~FMC_MPDAT3: