hi,
i am working on timer example in peripheral folder. i am including this example in ble_uart example in ble_peripheral folder. i am getting error " 'NRFX_TIMER0_INST_IDX' undeclared here (not in a function); did you mean 'NRFX_TIMER_INSTANCE'? "
hi,
i am working on timer example in peripheral folder. i am including this example in ble_uart example in ble_peripheral folder. i am getting error " 'NRFX_TIMER0_INST_IDX' undeclared here (not in a function); did you mean 'NRFX_TIMER_INSTANCE'? "
Hi,
Don't forget to enable timer in sdk_config.h file:
#define NRFX_TIMER0_ENABLED 1
Since your app is using SoftDevice, it uses TIMER0, so you should use another available TIMER instance.
Best regards
Emir
hi,
i already enabled NRFX_TIMER0_ENABLED in sdk_config.h. i have also enabled "TIMER periperal driver - legacy layer".now error is " undefined reference to `nrfx_timer_init"
As I sad, SoftDevice is using the TIMER0, you should use another available TIMER, e.g. TIMER1.
Could you try to use TIMER1 for your example, please?
yes i am using TIMER1 same error is there. i am including time example in ble_uart_example in ble_peripheral folder.
yes i am using TIMER1 same error is there. i am including time example in ble_uart_example in ble_peripheral folder.
Could you share the main file, so I can take a closer look into this, please?
Otherwise, make sure you have done the following things:
- Include paths to the nrfx_timer library in the project settings
- Add nrfx_timer.c to your project files
- #include nrfx_timer.h in the main file
- Declare TIMER instance: const nrf_drv_timer_t TIMER_INST_EXAMPLE = NRF_DRV_TIMER_INSTANCE(0);