What could the nRF52840 be doing while apparently idle — and what are the risks of interrupting it with a reset?

Hi,

I'm using the nRF52840 with the SoftDevice for BLE. In my system, it's primarily a BLE transceiver controlled via SPI by an external TI MSP430. We're considering implementing a preventive reset strategy: if the nRF appears idle (no BLE connection, no SPI activity) for a long time (e.g., 24 hour), we trigger a reset — either via an SPI interrupt (soft reset) or via a GPIO (hardware reset).

But I realize that “idle” from the outside might not mean truly idle internally.

So my question is:

What operations could the nRF52840 be performing while it appears idle externally?

  • Could it still be handling flash writes (e.g., bonding info, GATT attributes, flash queue, deferred writes)?

  • Could there be any background tasks from the SoftDevice?

And more specifically:

  • What is the worst-case outcome of interrupting such a state with a reset?

  • Are there ways to detect if it’s truly safe to reset, or to coordinate the reset in a safer way?

I'd appreciate any guidance for resetting this MCU safely under such conditions.

Thanks!

Agustín

Update: I'm using nRF5 SDK v17.1.0.

  • Hi!

    A reset is something done typically by fault/error handlers, and the Watchdog when it encounters a error. If you are using the Watchdog, and reset on faults in the FW, then I don't see the need for this kind of "preventive reset".

  • Thanks, I appreciate the perspective.

    That said, my question is less about whether to reset and more about what the nRF52840 might be doing under the hood when it appears idle (no BLE connections, no advertising, no SPI activity).

    I’m trying to understand if things like deferred internal flash writes or SoftDevice tasks could still be happening silently and whether triggering a reset in that moment could corrupt data or cause other issues.

    Is there any guidance on how to tell when it’s truly safe to reset?

    Best,
    Agustín

  • coiti4 said:
    That said, my question is less about whether to reset and more about what the nRF52840 might be doing under the hood when it appears idle (no BLE connections, no advertising, no SPI activity).

    For most applications, if things are working correctly, then the CPU should then simply be sleeping, consuming the minimum amount of power.

    coiti4 said:
    I’m trying to understand if things like deferred internal flash writes or SoftDevice tasks could still be happening silently and whether triggering a reset in that moment could corrupt data or cause other issues.

    That are things that the CPU could be doing, yes, but it should not cause any issues to trigger a reset in these cases. E.g. the FDS filesystem, and other systems are designed to be robust against sudden power failures. e.g. a battery-powered product could suddenly lose power when the battery is empty, and the systems are designed to be robust against that.

Related