我看到 有人回复 调用这个函数 可以 跳转到BOOT
void EnterCodeUpgrade (void)
{
FLASH_ROM_LOCK(0);
FLASH_ROM_ERASE( 0, 4096 );
R8_SAFE_ACCESS_SIG = SAFE_ACCESS_SIG1;
R8_SAFE_ACCESS_SIG = SAFE_ACCESS_SIG2;
R16_INT32K_TUNE = 0xFFFF;
R8_RST_WDOG_CTRL |= RB_SOFTWARE_RESET;
R8_SAFE_ACCESS_SIG = 0;
while(1);
}
但是,编译 没法连接 FLASH_ROM_LOCK
e:/risc5ide_cb6/risc-v embedded gcc/bin/../lib/gcc/riscv-none-embed/8.2.0/../../../../riscv-none-embed/bin/ld.exe: E:\CH573\APP\Main.o: in function `DebugInit':
E:\CH573\APP/Main.c:383: undefined reference to `FLASH_ROM_LOCK'
collect2.exe: error: ld returned 1 exit status