This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Failure to eraseall via NVMC access from segger JLink

I am working on some production scripting and as I want this to be able to run under both windows and linux I have been trying to erase all the NRF52840 using NVMC accesses rather than nrfjprog;.

Till now I have always used nrfjprog to do this eraseall and it works fine.

I write the NVMC config with erase enable followed by erase to the eraseall register; but on reset of go the device just comes up like nothing has been erased.
What Am I doing wrong?

J-Link>halt
PC = 0003E5BE, CycleCnt = C91BFE9B
R0 = 00000000, R1 = 20002D88, R2 = 00000273, R3 = 00000000
R4 = 20001380, R5 = 00001000, R6 = 10001000, R7 = 000FE000
R8 = 00000000, R9 = 00000000, R10= 00000000, R11= 00000000
R12= 20003A50
SP(R13)= 2003FE50, MSP= 2003FE50, PSP= 00000000, R14(LR) = 00027169
XPSR = 61000000: APSR = nZCvq, EPSR = 01000000, IPSR = E7805800000000 (d±Å)
CFBP = 04000000, CONTROL = 04, FAULTMASK = 00, BASEPRI = 00, PRIMASK = 00

FPS0 = 41C80000, FPS1 = 00000000, FPS2 = 00000000, FPS3 = 00000000
FPS4 = 00000000, FPS5 = 00000000, FPS6 = 00000000, FPS7 = 00000000
FPS8 = 00000000, FPS9 = 00000000, FPS10= 00000000, FPS11= 00000000
FPS12= 00000000, FPS13= 41C80000, FPS14= 00000000, FPS15= 00000000
FPS16= 00000000, FPS17= 00000000, FPS18= 00000000, FPS19= 00000000
FPS20= 00000000, FPS21= 00000000, FPS22= 00000000, FPS23= 00000000
FPS24= 00000000, FPS25= 00000000, FPS26= 00000000, FPS27= 00000000
FPS28= 00000000, FPS29= 00000000, FPS30= 00000000, FPS31= 00000000
FPSCR= 00000000
J-Link>w4 4001e504 2
Writing 00000002 -> 4001E504
J-Link>w4 4001e50c 1
Writing 00000001 -> 4001E50C
J-Link>go
J-Link>

Parents Reply Children
Related