This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nRF9160 AT+CFUN=0 draws excessive current

Hi,

This is a situation after registration. See the following link for detailed information of the setup:

https://devzone.nordicsemi.com/f/nordic-q-a/45544/nrf9160-dk-psm-current-too-high-after-opening-and-closing-a-tcp-socket

I have registered the device for testing the PSM mode. After registration I wanted to shutdown the modem entirely by issuing the AT+CFUN=0 command.

I expected the current to drop to about 6uA or lower.

This did not happen. The current consumption after AT+CFUN=0 became about 9.33mA.

When using the AT command AT+CFUN=44, the current did get low as expected.

Anyway I assumed that AT+CFUN=0 would turn the modem off completely.

Is this correct?

Best regards,

Houwer de Geus

Parents
  • Hi Houwer,

    I understand the reasoning by your assumption because of the naming of the different modes:

    AT+CFUN=<n>

    0 – Power off
    1 – Normal mode
    4 – Offline mode
    44 – Offline mode without shutting down UICC
     

    The correct way to "shutdown" the modem is to set it in Offline mode.

    If  you set the modem in "Power off" mode, you need to power cycle the device to be able to turn it ON again.

    As far as I know you would only use "Power Off" mode to store information in the modem flash permanently or for graceful "detachment" of the network . 

    As stated in the documentation: "When commanding the device to power off, a power cycle is needed and no further AT commands should be sent before that is completed."


    I would like to know how long you get this excessive current consumption after setting the modem to "Power Off" mode?

    As far as I know "Commanding the device to Power off might take some time if signaling with the network is needed." so it would be understandable if it draws some extra in that period.

    Best Regards,

    Martin L.

  • Hi Martin,

    When using AT+CFUN=0, the current is about 9.33mA, almost constantly. I would expect more network activity related to network signalling. While typing this, it's already a few minutes (about 5) in this state.

    Now I understand that I should use one of the Offline modes if I want to turn off the modem without power cycle.

    Best regards,

    Houwer

Reply Children
  • Hi Houwer,

    I would like to know a bit more about your environment:

    • Could you state which application you are running?
    • How is the current consumption measured?
    • Which modem firmware version are you using?

    Best Regards,

    Martin L.

  • Hi Martin,

    We are using an internal development tool in combination with the libraries as provided by Nordic Semiconductor.

    We are using bsd lib: v0.2.1.

    The modem firmware version is: mfw-m1_nrf9160_0.6.8-30.alpha

    The application is simple and performs the following actions:

    • AT+CPSMS=1,,,"00111000","00011110"
    • AT+CFUN=1
    • Wait for registration using the iBasis SIM. It indicates roaming
    • Open TCP socket: socket_fd = nrf_socket(NRF_AF_INETNRF_SOCK_STREAMNRF_IPPROTO_TCP);
    • use nrf_getaddrinfo() to retrieve the IP adress.
    • Perform TCP connect: nrf_connect(socket_fd, &ipv4Address, sizeof(nrf_sockaddr_in_t))
      
    • Close the Socket: ret = nrf_close(pContext->socket_fd);
    • AT+CFUN=0

    I just tested by manual entering AT commands in a test application. You can reproduce this by only doing the next things:

    • AT+CFUN=1
    • Wait for registration (OK response, just waited a number of seconds)
    • AT+CFUN=0
    • Ok received

    The measured current consumption is about 9.7 mA after AT+CFUN=0.

    When using AT+CFUN=4 instead of AT+CFUN=0, the current is about 10mA.

    When using AT+CFUN=44 instead of AT+CFUN=0, the current is about 0.65mA which is the same current after reset. This is caused by active peripherals probably. This test application is not optimized for low power.

    The current is measured on the development board via P24 according to the description as provided in the documentation of Nordic Semiconductor.

    Bets regards,

    Houwer de Geus

  • Hi Houwer,

    Thank you so much for the additional information.

    The modem firmware version you are using is from December 2018.

    I highly recomend to download and flash the new modem firmware version: https://www.nordicsemi.com/Products/Low-power-cellular-IoT/nRF9160/Download#infotabs

    This may actually affect the consumption you are seeing.


    Please note that the NCS (nRF Connect SDK) just had it's v0.4.0 release .

    If you want the latest and greatest NCS, please use the v0.4.0 tag.

    cd ncs/nrf
    git checkout master
    git pull
    git checkout v0.4.0
    west update

    Best Regards,

    Martin L.

  • Hi Martin,

    The mfw_nrf9160_0.7.0-29.alpha version solves the problem. Thanks a lot!

    I did try to get the v0.4.0 NCS release. I could perform all commands you mentioned, except for the last one. The west update could not be performed. I suppose I missed earlier steps to install this. Maybe you could point me in the right direction. Otherwise I will study the documentation myself.

    Anyhow I thank you for the quick responses on this issue.

    Best regards,

    Houwer de Geus

  • Hi Houwer,

    Great to hear that the new modem firmware fixed the issue.

    You probably have not installed the "west" tool. (you can follow this guide or the following:)

    For all the steps for installing the toolchain is listed in the updated "Getting Started Assistant" application in the nRF Connect for Desktop. 

    Best Regards,

    Martin L.

Related