Use of RTC1 in nRF52805

I am using NRF5 SDK 17.1

SES

S112 for the nRf52805

I followed the guide for the 805

 Developing for the nRF52805 with nRF5 SDK 

i then used the NUS Peripheral and was trying to setup the rtc so the device sleeps until the RTC match then wakes and advertises. after a disconnection it would reset the RTC and wake on a match and advertise again.

I have enableed RTC1 in the SDK-CONFIG.h file and disabled the app_timer

I also do not create a APP_TIME_DEF() in the program.

when i try and build i get 

C:\Nordic_Semi\SDK\nRF5_SDK_17.1.0_ddde560\modules\nrfx\drivers\src/nrfx_rtc.c:336: multiple definition of `RTC1_IRQHandler'; Output/ble_app_uart_pca10040e_s112 Release/Obj/drv_rtc.o:C:\Nordic_Semi\SDK\nRF5_SDK_17.1.0_ddde560\components\libraries\timer/drv_rtc.c:354: first defined here
Build failed

I have tried several things to get this to compile.  I have done something similar using a nrf52840 and RTC2, but i cannot get this to work on the 805?

Is there still something using the APP_TIMER so RTC1 is not available?

if So, i have also tried using APP_TIMER for the same reason and get a similar error

thanks

Parents
  • Hello,

    It's not clear to me what you are trying to achieve here. The app_timer module use RTC1 and is intende to be used to execute a callback at given interval or execute a single shot callback some time in the future. It ensure low power operation and can for instance be used to wakeup the chip after a period of time, the library documentation and looking at some of the ble examples should be good starting point, e.g.:
    https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_timer.html

    It's not clear to me why you are in parallell trying to use the RTC1 directly, it seems like you want to re-invent something that the app_timer already do excellent. It would be very problematic to have many software modules relying on app_timer, and then you try to go bare metal (without any obvious pros since the current is the same) using the same RTC1.

    Kenneth

Reply
  • Hello,

    It's not clear to me what you are trying to achieve here. The app_timer module use RTC1 and is intende to be used to execute a callback at given interval or execute a single shot callback some time in the future. It ensure low power operation and can for instance be used to wakeup the chip after a period of time, the library documentation and looking at some of the ble examples should be good starting point, e.g.:
    https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_timer.html

    It's not clear to me why you are in parallell trying to use the RTC1 directly, it seems like you want to re-invent something that the app_timer already do excellent. It would be very problematic to have many software modules relying on app_timer, and then you try to go bare metal (without any obvious pros since the current is the same) using the same RTC1.

    Kenneth

Children
Related