PyGate with LoPY4 - High Power Consumption on Deep Sleep



  • Hi guys!

    I have the following setup:

    1. PyGate board powered only by a LiPO battery (3.6 Volt). USB-C port is not connected at all.

    2. LoPY4 running firmware 1.20.2.rc10.

    3. A LoRA antenna connected to PyGate.

    4. The example script from the documentation:
      https://docs.pycom.io/tutorials/expansionboards/pygate/#pygate

    I did the following measurements:

    1. When PyGate is running the power consumption varies from 100 to 400 mA (at 3.6 V external power). That is a normal power consumption for a GW that is connected to the Wi-Fi and receives-forwards LoRA messages to the TTN

    2. However, what is really strange is that the whole system (LoPY+PyGate) continues to consume 10mA once I put it in deep sleep - This is how I do it: I run the command pybytes.deepsleep(20000) this command according to the following documentation should put in deep sleep the system for 20 seconds. Certainly the power consumption is going down from ~300mA to 10mA but even this current (i.e. 10 mA) is very high for a low-power system. Especially for our case, it is prohibitive to proceed as our project requires a LoRA Gateway that operats only for 5 minutes during the day and the rest of the day the Gateway should just sleep.

    https://docs.pycom.io/pybytes/api/deepsleep/#app

    Any ideas are welcome!

    Re: PyGate - Temperature and power consumption



  • I've tested the SparkFun Nano Power Timer board some months ago, it was working ok, but it wasn't powering Expansion Board.

    What about :

    • using LiPo/LiIon battery to avoid any USB cable to power Expansion Board ?
    • powering LoPy4 directly, from Vin (3.0-5.5V) ?

    Why 15 s ? Is there any code in LoPy4 enabling the DONE pin of the Nano Power Timer ?



  • @rcolistete thank you for indicating this! I've just purchased 2 items of the Nano Power Timer.
    I've followed all the instructions given here but it does not work. To be more specific:

    1. I have connected the power (5V) to the Vin pins and the Vout pins are powering the Extension Board v3.0 (with a LoPy4) via the USB connector of the Ext. Board.

    2. Also, I connected the output pin P19 to the DONE pin of the Nano Power.

    3. Delay via Dip Switch: 1 min

    The issue: Once I plug-in the external input (5V) to the Nano Power, the Extension Board never turns on. If I put the push button of the Nano Power for 1 second then the Extension Board turns on for around 15 seconds and then turns off again.

    Any ideas?



  • @Gijs Thank you for saving me a lot of time! I think it would be a good idea to clarify that in the PyGate datasheet.


  • Global Moderator

    Sorry, read too quickly.

    For your solution, I believe the external watchdog timer would be preferable. We have no sort of deepsleep built into the Pygate, like the Pysense 2 and Pytrack 2 have, where the power to the development module is cut off, having only the USB controller pic running to keep track of time, as the general use-case of the Pygate is to be on all the time. You could still try to desolder the LEDs and cut some power there. Other than that, I dont think it is possible without hardware / firmware modifications.



  • @Gijs Thank you for your recommendation. I don't use the PoE module, only Lopy4 connected to the PyGate. I use (and measure) the current of external power (i.e. Li battery) port of the PyGate.


  • Global Moderator

    Did you remove the jumper on the header on the PyEthernet module? You can find this next to the large magnetics IC. This jumper allows for a basic current draw for some PoE modules, or they will switch off completely. I believe the current is indeed close to 10mA, but Im not exactly sure. Removing the small jumper removes the default load from the circuit.
    Best,
    Gijs



  • It is really hard to find any low power LoRawan gateway, as gateways are designed to work 24/7.



  • @rcolistete Thank you for elaborating on this! I had assumed that Pycom products don't need any kind of h/w modification in order to support low-power...The fact that I'm still to measuring 10-12mA in deep sleep mode (even trying the available methods, i.e. pybytes.deepsleep, machine.deepsleep) is really strange for a product series claiming to have been designed for low-power IoT applications.



  • Another option is to modify "robert-hh / ATTiny-Watchdog-for-MicroPython" repository to use the ATTiny (85, etc) to turn on/off PyGate with LoPY4 using a MOSFET.

    ATTiny 85 power usage :

    • active mode, approx. 0.7-3.6 mA @ 3.0V 1-8 MHz;
    • in deepsleep mode : 0.1-0.2 uA @ 3.0V without interrupts, 5 uA with interrupts.

    http://www.technoblogy.com/show?KX0
    https://www.re-innovation.co.uk/docs/sleep-modes-on-attiny85/
    https://arduino.stackexchange.com/questions/13983/attiny85-power-consumption-vs-clock-speed



  • @robert-hh Thanks, it was a typo error.



  • @rcolistete 40µA or 40nA? The data sheet tells of 40nA, and the board has barely more than just that chip and a transistor. So what consumes 40µA?



  • See this board, SparkFun Nano Power Timer - TPL5110.
    "Selectable Time intervals: 100ms to 7200s (2 hours)"
    But you can place your own resistor to define a longer time.

    I've tested this board and the current is about 40 nA when the output is off.

    PS : fixed the text, it is 40 nA, not 40 uA.


Log in to reply
 

Pycom on Twitter