[100221 SW AL] UART device not going low power

In out project we have a nRF9160 connected through UART to a nRF52840 that's used for low power beaconing.

In order to configure the advertisement data on the nrf52840 we need to power cycle it, so it will listen on the UART for commands before shutting it down to go low power.

The power cycling can't be done reliably without re-configuring as OUTPUT the nRF9160 TX pin that would otherwise back power the nRF52840, which causes the nRF52840 to keep running until a beacon event happens.

The problem we are seeing is that after configuring the UART TX pin on the nRF9160 as OUTPUT the device will no be low power anymore. Setting (again) the UART device to LOW_POWER state doesn't have an effect anymore.

The sequence of events is:

- set UART device to LOW POWER state

- configure TX pin as OUTPUT with PULLDOWN resistor

- drive TX pin LOW

- configure the TX pin as DISCONNECTED

- set again UART device to LOW POWER (doesn't seem to have any effect)

Is there any know issue about configuring the UART pins as GPIOs that wouldn't allow the UART driver to get to the low power state?

Parents
  • Hi 

    Why would leaving the TX pin high power up the nRF52840 again? 

    Since this pin would be the RX pin on the nRF52840 side it would seem more intuitive if a low signal would wake it up, since this is typically a sign of UART activity. 

    I need a bit more time to look into the consequences of overriding the TX pin while the driver is running. There is no good way of reassigning pins dynamically in the nRF Connect SDK unfortunately, and it is quite likely that doing this will have some unintended side effects. 

    I assume I should be able to reproduce this issue using standard development kits, and by following your description?

    Best regards
    Torbjørn

  • Leaving the TX pin high would not power up the nRF52840 again, but it doesn't let it shut down.

    The problem is that since the nRF52840 is configured to be low power and uses just few uA while not beaconing, the current coming from the nRF9160 TX pin is enough for it to not shut down quickly and reliably.

    Only a beaconing event in the nRF52840 requires enough power to drain the energy accumulated in the UART lines,  resulting in the device shutting down (most likely due to a brownout).

    Having the beaconing interval set to 10 seconds we would have to wait more than 10 seconds to be sure that the nRF52840 is completely powered down, and that is not desirable.

    You should be able to reproduce the issue using development kits and following my description, i will give you a bit more context on the setup.

    - nRF9160 and nRF52840 are connected to each other through UART

    - nRF9160 controls the power of the nRF52840 through a GPIO (i will refer to it as nRF5_EN)

    Initial situation is:

    - nRF9160 has the UART to the nRF52840 enabled, while the nRF52840 is in low power mode (UART disabled)

    if in this situation the nRF9160 removes power to nRF52840, driving the nRF5_EN pin LOW. Now is possible to see that the nRF52840 is still running for some time (at least 1/2 seconds in out tests), unless it does something in order to consume the accumulated current (for example beaconing).

    Our only way to be sure that the nRF52840 is powered down quick is the sequence of actions i described in the original post, so to configure the TX line on the nRF9160 side to OUTPUT.

    I hope i made the situation more clear, please let me know if it's not.

  • Hi 

    Which version of the nRF Connect SDK are you using?

    If you have 'low-power-enable' set in the pinctrl configuration then the pins should be configured to input mode once you set the driver in low power mode. 

    If you then enable the pull down resistor on the pin then this should pull it low, similar to setting it as an output in the low configuration (just with less drive strength). 

    Would you be able to try this out, and see if it solves the issue?

    You would need to disable the pull down before taking the UART driver out of the low power state. 

    Best regards
    Torbjørn

  • We are currently using the sdk v1.6.1, so no pinctrl is used.

    I tried to configure the pin with the pull down resistor instead of configuring it as output, the reset of the nRF52840 works but the power consumption problem remains.

    I see the same power consumption as before putting the UART to low power, ~500uA

Reply Children
  • Hi 

    Thanks for the update. 

    So to summarize then, the problem is about putting the UART in a low power state on the nRF9160 side, when the TX pin is reconfigured either as an output or with pull down enabled. 

    If this is the case it seems like the UARTE interface is not properly disabled when the UART driver goes into a low power state. Are you able to check the state of the ENABLE register in the UARTE peripheral after you have set it to low power? 

    Could you try to manually set the ENABLE register to 0, and see if it fixes the current consumption issue? 
    For this fix to work properly, you would have to restore the original value before enabling the driver again. 

    I will do some testing on my own side, and also have a closer look at the driver implementation, to see what actually happens when the driver enters the low power state. 

    Best regards
    Torbjørn

Related