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

I can read "NRF_POWER->RESETREAS" in code, but I can't with nrfjprog

I put my code before ble_stack_init()

reset_reason = NRF_POWER->RESETREAS;
NRF_LOG_PRINTF("reset_reason: 0x%08x.\n",reset_reason );
//NRF_POWER->RESETREAS = 0xffffffff;

and it works

but when I tried nrfjprog, it did not work.

nrfjprog --memrd 0x40000400 --n 4

I mean first method, I get 0x00000002 (=watchdog reset) second method, I get 0x00000000

Why this happend?

Related