Download my code into FLASH about the macro DEVELOPMENT_DEBUG

6 posts / 0 new
Last post
fn654
Offline
Last seen:1年9个月go
加入:2016-06-14 13:27
Download my code into FLASH about the macro DEVELOPMENT_DEBUG


If i download my code into FLASH, should I have to change the macro DEVELOPMENT_DEBUG to 0,like
#define DEVELOPMENT_DEBUG 0 //0: code at OTP, 1: code via JTAG
If I dont change it ,will it have the bad effect on my device?
Thanks

Device:
Gongyu_Dialog
Offline
Last seen:20 hours 38 min ago
加入:2016-04-27 07:07
you don't need to change the

you don't need to change the micro definition to 0.
It is used to add some debug info and ensure no duplicate gpio usages.

fn654
Offline
Last seen:1年9个月go
加入:2016-06-14 13:27
Thanks for you reply,

Thanks for you reply,
But if i define the micro definition DEVELOPMENT_DEBUG to 1,some devices will go to NMI_HandlerC after some time later and never go out of it .As a result ,my device never broadcast again. To the contrary,if i define the micro definition DEVELOPMENT_DEBUG to 0,all my device never stop broadcasting for a long time.
The problem has confused me for a long time.
thanks.

Gongyu_Dialog
Offline
Last seen:20 hours 38 min ago
加入:2016-04-27 07:07
If you disable the sleep

If you disable the sleep settings, and run in keil debug mode, does the issue happen again?

fn654
Offline
Last seen:1年9个月go
加入:2016-06-14 13:27
it never happen in keil debug

it never happen in keil debug mode.and the device work in extended sleep mode with 0.5s adv interval

Gongyu_Dialog
Offline
Last seen:20 hours 38 min ago
加入:2016-04-27 07:07
1. check the 32k clock

1. check the 32k clock
2. use jlink, attach to the device when issue happens, check the assembly code, get which function causes the issue.
*(volatile unsigned long *)(STATUS_BASE + 0x14) = hardfault_args[5]; // LR
*(volatile unsigned long *)(STATUS_BASE + 0x18) = hardfault_args[6]; // PC

besides, not sure you've enable watch dog or not.