NRF9160dk Power Saver

Good day

I intend to use a power saving mode to turn on a device for a set amount of time.  During this, the device would still need to receive commands over mqtt.  Is this possible?

Thank you in advance.

Kind regards,

Hassan.

  • Hi,

     

    I intend to use a power saving mode to turn on a device for a set amount of time.  During this, the device would still need to receive commands over mqtt.  Is this possible?

    This depends on several of your applications requirements.

    Ideally, to maintain a TCP connection (mqtt is TCP based), you need to keep it alive. This keep-alive can differ from cellular network-to-network, due to routing within the specific telecom provider. For some networks, this is several minutes, for others it can be up to 30 minutes.

     

    If you have a RX driven application, meaning an application that is supposed to act on a command from the internet, you need to poll the server in your wanted interval. This interval depends on what your application requires in terms of latency.

    For a RX driven application, you usually run eDRX, as it can have lower sleep intervals (down to seconds area).

     

    Kind regards

    Håkon

  • Good day 

    Thank you so much for the assistance.  I'm having a little trouble. Once I enable PSM using 

    lte_lc_psm_req(true), I get this response from the AT%XMONITOR command - 
    MONITOR: 1,"","","65501","5209",9,8,"0E187117",361,3623,27,37,"","00101111","10110100","01001001"  
    The active time was set as follows:
    const char *rat = "00101111"; (15 minutes)
    I am expecting the current to drop significantly once I enable it but i'm not seeing any drop in current on my multimeter.
    Do you have any ideas what the issue may be?
    Thank you!
    kind regards,
    Hassan
  • Hi Hassan,

     

    An active time of 15 minutes means that you will not enter PSM before 15 minutes after your previous on-air transaction.

    If you send something, then wait 15 minutes, the nRF shall enter PSM.

     

    Is this what you want? Normally, the active time is in the range of seconds to single-digit minutes.

     

    Kind regards,

    Håkon

  • Good day

    I've changed the active time to 

    "00000001" now and am still not seeing the current drop.  Im currently trying to do this with a variation of of the mqtt sample. 
    The result is as follows:
    MONITOR: 1,"","","65501","5209",9,8,"0E187117",361,3623,26,36,"","00000001","10110100","01001001"
    280,548]
    <inf> mqtt_simple: Publishing: {*REDACTED*}
    Do you have any other ideas?
    Thank you very much.
    Kind regards,
    Hassan
  • Hi,

     

    Each time you send data from your firmware, it will break the power saving mode. If you send data frequently, you will effectively never enter PSM.

    Can you try adjusting the config CONFIG_MQTT_KEEPALIVE to a higher value? for instance 300 seconds.

     

    Kind regards,

    Håkon

Related