Issue regarding the Configuration of GRTC in nRf54L15-DK

I’m working on the nRF54L15-DK using nRF Connect SDK v3.0.2.In my project, I’m trying to enable and use the GRTC peripheral. Here's what I’ve done so far:


.overlay file (boards/nrf54l15dk_nrf54l15_cpuapp.overlay):

&grtc {
    status = "okay";
};
prj.conf:
CONFIG_NRFX_GRTC=y
CONFIG_COUNTER=y
In main.c:
#define GRTC_NODE DT_NODELABEL(grtc)
const struct device *grtc_dev = DEVICE_DT_GET(GRTC_NODE);
if (!device_is_ready(grtc_dev)) {
printk("GRTC device not ready!\n");
return;
}

However, I’m getting a linker error:
undefined reference to '__device_dts_ord_62'

This is because DEVICE_DT_GET(GRTC_NODE) resolves to a pointer using the device’s ordinal number. If the GRTC device is not marked as "okay" in the DeviceTree or its driver is not enabled in Kconfig, the symbol isn’t generated, leading to this linker error.

Have any solution for this?

Parents Reply
  • Hi Håkon,

    Thanks for your response.

    However, my use case specifically requires the system to wake up from system-off (deep sleep) mode using the GRTC peripheral, not just timekeeping or delays in active mode.

    As far as I understand, in system-off mode, the normal Zephyr k_timer or kernel tick-based mechanisms (like k_sleep) are not functional, and GRTC is the only available wake-up source via its compare channels.

    Could you please clarify:

    • How to correctly configure the GRTC for wake-up from system-off on the nRF54L15-DK (SDK v3.0.2)?

    • Are there any required configurations in the DeviceTree, prj.conf, or special APIs (such as nrfx_grtc) to enable this?

    Thanks,
    Mohammed Hashir P

Children
Related