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

Debugging a APP_ERROR_CHECK

I am working on a project using a BLE Nano and Nordic sdk 8.1. I included the ble_flash.c, ble_error_log.c, and ble_debug_assert_handler.c files in my include path and c source files. I also added -DDEBUG to the flags. I then check if the app is failing using the APP_ERROR_CHECK(err_code); When I do this my program just stops running though and I don't get an error log or anything in the serial monitor and I don't see any stack trace saved on the device when I open it up. Are there any other steps I have to do or am I missing something? BTW I am compiling from terminal using a makefile.

Parents
  • I tried using timer2 but I got the following error: "In file included from ../../../../../../components/libraries/pwm/app_pwm.h:38:0, from ../../../main.c:40: ../../../../../../components/drivers_nrf/timer/nrf_drv_timer.h:48:31: error: 'TIMER2_INSTANCE_INDEX' undeclared here (not in a function) .instance_id = TIMER##id##INSTANCE_INDEX,
    ^ ../../../../../../components/libraries/pwm/app_pwm.h:50:50: note: in expansion of macro 'NRF_DRV_TIMER_INSTANCE' const nrf_drv_timer_t m_pwm
    ##name##_timer = NRF_DRV_TIMER_INSTANCE(num);
    ^ ../../../main.c:44:1: note: in expansion of macro 'APP_PWM_INSTANCE' APP_PWM_INSTANCE(PWM1,2); // Create the instance "PWM1" using TIMER2. ^ "

    Is there anything I have to do to initialize timer2?

Reply
  • I tried using timer2 but I got the following error: "In file included from ../../../../../../components/libraries/pwm/app_pwm.h:38:0, from ../../../main.c:40: ../../../../../../components/drivers_nrf/timer/nrf_drv_timer.h:48:31: error: 'TIMER2_INSTANCE_INDEX' undeclared here (not in a function) .instance_id = TIMER##id##INSTANCE_INDEX,
    ^ ../../../../../../components/libraries/pwm/app_pwm.h:50:50: note: in expansion of macro 'NRF_DRV_TIMER_INSTANCE' const nrf_drv_timer_t m_pwm
    ##name##_timer = NRF_DRV_TIMER_INSTANCE(num);
    ^ ../../../main.c:44:1: note: in expansion of macro 'APP_PWM_INSTANCE' APP_PWM_INSTANCE(PWM1,2); // Create the instance "PWM1" using TIMER2. ^ "

    Is there anything I have to do to initialize timer2?

Children
No Data
Related