This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

When is hardware reset ignored on the 51822?

I ran into this last night and curiously, James appears to have posted about it yesterday (devzone.nordicsemi.com/.../trouble-with-system-halted,but-cannot-reset-nrf51822-chip)

Here is my code: it generates a square wave of increasing period on GPIO 0.11 that you can watch on a scope. Presumably, when you short pin 23 (SWDIO/nRESET) to ground, the chip should reboot and this will be evident by the period collapsing back to 10us and increasing again.

int main(void)
{
uint16_t x = 1;

	nrf_gpio_cfg_output(11);

	while(1)
	{
                for(int i=0; i<x; i++)
		    nrf_delay_us(10);
                x++;
		nrf_gpio_pin_toggle(11);
	}
}

However, here is what I see: after I use SWD to download the program via the Segger, I can short SWDIO/nRESET for seconds without resetting the chip. If I power cycle the CPU, everything works as expected.

This is with a G0 step of a 51822-QFAA and I have tried it both ways with respect to PAN 7 (12K pull-down on SWDCLK installed and omitted). I've also isolated the chip from the SWD interface without change.

How can the the J-Flash util leave the core in a state that even a hardware reset doesn't work? I am downloading the code through Keil 4.73, J-Flash 4.72A at 100kHz.

Thanks, Dan

Parents
  • Håkon, Thank you for getting back to me. Unfortunately that command resulted in ERROR: An error occurred while connecting to the device even though I can open the JLink.exe command line utility and communicate with the core. I tried all of the different types of resets that JLink.exe would offer as well and still, the nReset pin won't operate. Do you have any other ideas?

    Thank you, Dan

Reply
  • Håkon, Thank you for getting back to me. Unfortunately that command resulted in ERROR: An error occurred while connecting to the device even though I can open the JLink.exe command line utility and communicate with the core. I tried all of the different types of resets that JLink.exe would offer as well and still, the nReset pin won't operate. Do you have any other ideas?

    Thank you, Dan

Children
No Data
Related