Energy consumption in Fipy

  • If I am continuously sensing temperature and sending it over physical layer after 10 sec, Will using power mode "always on" or "TX only" affect the energy consumption?

  • @jcaron I do not have any problem with current it draws for now. I am just experimenting with the power_modes "Always ON" and "TX_only" but it seems to have no difference at all in power consumption in both the modes but their should be some difference as far I know. I don't know if it should be the case or I have done something wrong.

  • @jcaron Here I have limit of writing only one post per 10 minutes until I have 3 quotes.
    I am using Fipy with Pysense shield, with temperature sensor DS18S20.
    I am not using the battery, I have to connect it to my PC. and Yes it draws 300mA current.
    I am using the code from pycom tutorials, but just adding power_mode parameter. And also not using the receiving code. I am experimenting only with transmission.

  • @muhammad-Umair 148 mAh is a lot higher than expected, at least on the battery power path. For 30 minutes of operation that means nearly 300 mA @ 5V, that's a lot more. I know the USB power path is less optimised, but that seems really high to me even via USB.

    Make sure you shut down/deactivate Wi-Fi, BLE, LTE and anything else you're not using.

    What is the sensor you are using? How much should it draw?

    Are you using a Pytrack, Pysense or other shield? Any other sensors or devices attached?

  • @jcaron Actually I am using default parameters for raw Lora (so no need to define them in code) and just changing the power mode between ALWAYS_ON and TX_ONLY

    For the moment I have to test it through USB tester

    It the part of my work to use default parameters and just add power mode option and to use USB Tester.

    The power consumption is 148mAh for all 3 cases, for running the experiment for 30 mins

  • @muhammad-Umair It's more useful for everybody (especially people facing similar issues in the feature) if you include all the information in this thread. Don't forget to redact any private info (network names and IDs, passwords, keys, etc.) of course.

  • @jcaron I am messaging you in private. I hope it is fine for you.

  • @muhammad-Umair If you want to measure power consumption precisely, you should use a battery and measure between the battery and the device. The USB power path has additional stuff going on which may give incorrect results.

    Did you correctly switch off Wi-Fi, BLE, and LTE on the Wi-Fi? If you didn't the Lora current will probably be drowned by the others.

    Also what settings to you have for LoRa TX power, SF, bandwidth, etc? How much data do you transmit on each interval?

    How much did you measure? With the ESP32 + LoRa only I would expect around 30-40 mAh when measured via USB, maybe a bit more.

    Can you share your test code? The difference between the 3 tests should be small but measurable (at least on the battery power path, not so sure via USB).

  • @jcaron Thank you for your well written response.
    Yes I am using raw LoRa.
    So, basically I have done 3 experiments with Temperature sensor for 3 different cases and measured their power consumption in mAh through USB Tester UT658.
    1st case: I only sense the temperature every 10sec continuously for 30 mins.
    2nd case: I sense the temperature and send it through raw LoRa every 10sec for 30min with the power mode ALWAYS_ON.
    3rd case: I sense the temperature and send it through raw LoRa every 10sec for 30 min with the power mode TX_ONLY.
    Results: I am getting exactly the same power consumption in mAh for all the 3 cases.

    Do you thing I did something wrong in the experiments or it is correct?

  • @muhammad-Umair I suppose you mean you are going to use raw LoRa.

    “always on” mode is the equivalent of class C for LoRaWAN: at any time the device is not transmitting, it will be listening. That uses about 10 mA just for the radio (on top of what the ESP32 and other components may use).

    TX only is closer to LoRaWAN class A: when not transmitting, the radio is idle.

    In any case, continuously sending and sending data every 10 seconds nearly certainly means you won’t be able to use deep sleep much, if at all. This means you will probably have an average current around 50 mA, possibly a bit more, and running off battery is practically impossible, unless you plan to recharge the device every couple of days, so 10 mA more or less won’t make much of a difference.

Log in to reply

Pycom on Twitter