Can't run off battery - micro USB connector

Hi all,

I have 2 DWM3001CDKs that have been programmed with the latest DW3_QM33_SDK_1.0.2 binary for the CLI, but it doesn’t work when connected to battery.

When performing TWR between initiator and responder, everything works fine when both are hooked up to USB, but when one is running off battery, it says SUCCESS but then has RX_TIMEOUT for a second, and then it seems to reboot and then says SUCCESS with a reading again.

@carlos.silva seemed to have fixed it back here: DWM30001CDK standalone operation without connection to USB UART - #14 by carlos.silva, but this still seems to be an issue with this latest release.

I made a video showcasing this issue here: https://youtu.be/zMKBI1GoJoY

In the video the initiator is on the left and the responder is on the right.

To setup the initiator I do SETAPP INITF -CHAN=5 -ADDR=0 -PADDR=1 and then ‘SAVE’ and then I reboot the device, and to setup the responder I do SETAPP RESPF -CHAN=5 -ADDR=1 -PADDR=0 and then ‘SAVE’ and then reboot the device. When both are hooked up via USB it works great. Once I take the responder off USB and hook up an external 5V supply via the micro USB connector (J9)

I am not sure how to modify this new SDK to make it work… I also tried the HEX file provided by @akash found here: QM33 SDK CLI skipping ranging sessions when connected to USB power only - #3 by akash, but this also didn’t work as the USB never enumerated (waited a couple of minutes and never showed up, so I could never set it up via the CLI).

Hi @NicolasMontoya !

This problem is under investigation, there’s an issue when USB is started with the HFCLK already enabled, the USB will take around 14 seconds to be enumerated, to workaround it was included:

#if !defined(USB_ENABLE)
    /* Workaround for nRF SDK issue. We cannot turn on HFCLK for all the time when we use USB.
     * When USB_ENABLE flag is on, then LFCLK request is being handled in the HAL_usb.c */
    nrf_drv_clock_hfclk_request(NULL);
    while (!nrf_drv_clock_hfclk_is_running())
        ;
#endif

in Src\Boards\Src\DWM3001CDK\FreeRTOS\DWM3001CDK.c in peripherals_init().

At the same time, this stops UWB when USB is not enumerated and the HFCLK is released. For you using the DWM3001CDK powered by battery or external source, the fix will be to remove the "#if !defined(USB_ENABLE)" and let only the HFLCK request:

    nrf_drv_clock_hfclk_request(NULL);
    while (!nrf_drv_clock_hfclk_is_running())
        ;

This way, the HFCLK will keep running when the UWB is not enumerated, but when you plug your DWM3001CDK into a PC, it may take ~14s to get enumerated.

Please let me know if it works for you.
Kind regards!

Thank you for the quick response carlos! I will try this once I am back in the office again and let you know if this works! Thanks.

Hello, did you fixed the problem with that method?
I’m still stucked with the same issue, even if applying that solution.

My bad, I connected my power source(battery) to the J9 Port and it works well.
Thanks for your response @carlos.silva

1 Like