Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #13452
    Amir Nathoo
    Participant

    Hi All,

    I am using the tutorial here https://www.rocketscream.com/blog/docs-item/using-mini-ultra-pro-with-the-things-network-ttn/#tab-id-1
    as a reference for testing low power (standby) mode on the SAMD21.

    Using that example with only some minor customization (i.e LoRaWAN session info and sensor payload) I only get to about 6.8mA in standby mode, when the device is powered with a 3.7v RCR123a battery. When the device is transmitting current goes to around 90mA. So it is performing standby using rtc as expected, but not to the level I was expecting.

    I noticed in the example, there is no explicit shutdown of the RFM95. I tried using LMIC_Shutdown() and then restore LMIC session, but it didn’t change the result.

    I have 2 sensors connected to IC2 interface. I am assuming these should automatically go into sleep when the MCU is in standby. So I am not totally sure what else I may be missing.

    #13458
    LIM PHANG MOH
    Keymaster

    The LMIC automatically sleeps the RFM95W when not in use. You don’t have to add anything extra.

    I have 2 sensors connected to IC2 interface. I am assuming these should automatically go into sleep when the MCU is in standby. So I am not totally sure what else I may be missing.

    Never ever assume that. What devices are these? Not all devices are low power.

    #13462
    Amir Nathoo
    Participant

    Not all devices are low power.

    This made be go back and review my code a little more carefully 😉

    Currently I have a BME280 and a BH1750. The BME280 is set to go sleep after each measurement. But I found out the BH1750 was set to continuous mode high resolution rather than one shot which kept IC2 interface active during sleep cycle. I corrected the code and I am now seeing 340uA. It’s much better, but still about 10x more than what I would expect.
    I also found there was a Serial print done after the flush, so probably contributed as well.

    I am inserting the multimeter between the battery and the 3v3, so I am not sure this a good place for measuring what the board as whole is consuming.

    Also right now the sleep cycle is 30 seconds for testing as I want to see how fast the battery will die.

    • This reply was modified 5 years, 2 months ago by Amir Nathoo.
    #13479
    LIM PHANG MOH
    Keymaster

    Currently I have a BME280 and a BH1750. The BME280 is set to go sleep after each measurement. But I found out the BH1750 was set to continuous mode high resolution rather than one shot which kept IC2 interface active during sleep cycle. I corrected the code and I am now seeing 340uA. It’s much better, but still about 10x more than what I would expect.

    Please take a careful look at the sensor datasheet. The sleep current of BH1750 only holds if the light lux is zero (total darkness). Else it will go up whenever light is present. As far as from my experience, only TEMT6000 are able to operate in very low current even when light is present.

    Multi-meter should be used between battery + terminal and VBAT pin terminal (either the breakout pin or JST 2.0mm connector). What you are doing will damage the board as you are applying VBAT directly to the 3.3V rail.

    #13487
    Amir Nathoo
    Participant

    Hi Phang Moh,
    You are right, the BH1750 will continue to draw current in sleep mode unless there is no light and it looks like most sensors behave that way. I have a couple of TEMT6000 breakout boards, so I gave them a try. I am actually surprised, in that configuration I get between 20-30uA which is very good.

    
    deviceName:"microsense-device-hub-002"
    fCnt:3171
    fPort:1
    battery:3.68
    humidity:55
    light:14
    pressure:1010
    temperature:25
    

    So in near ideal conditions, after 3171 uplink messages, the battery has 3.68v. At the start of the test it was at 3.79v. So this looks very good. Of course, in real conditions things are going to be different, but this gives me a very good base to work with.
    Thanks again for the great suggestions.
    Amir.

    • This reply was modified 5 years, 2 months ago by Amir Nathoo.
    #13530
    Amir Nathoo
    Participant

    The device finally stopped transmitting after 14431 uplinks (almost 2x my minimum requirement). Voltage had dropped around 1.8v before I plugged the USB power to recharge.

    The LED behavior is still weird. When I plugged in the USB cable, both the green and the red LEDs turned on which I was expecting. However the red LED turned off almost immediately (it was just a quick blink) and it’s not on, although I can see the battery voltage is going up steadily as it is recharging. I was expecting the red LED to stay on until battery is fully charged. So I am not sure what is going on there.
    The device has performed, really well though and I am sure some more optimizations can be done in the code to make battery last a little longer.

    Amir.

    • This reply was modified 5 years, 2 months ago by Amir Nathoo.
    #13537
    LIM PHANG MOH
    Keymaster

    Hi Amir,
    If you look at the BQ24074 datasheet on page 11, if your battery voltage is very low (in your case, 1.8V), it goes into a mode called battery short circuit detection before actually moving into pre-charge mode. In this mode, the red charging LED shouldn’t lit up. You shouldn’t drain a Li-Ion/Li-Pol below 2.7V. It will damage the battery in the long run. Most battery pack has an automatic cut-off switch to prevent this from happening but some doesn’t have.

    #13540
    Amir Nathoo
    Participant

    Hi Phang Moh,

    Looking at the battery technical description, it does appear they don’t have short-circuit protection 🙁 which makes sense based on the datasheet link you posted. I returned these batteries and got some that do have short-circuit protection, however I probably need to update the application on the device to either initiate charging when the battery voltage goes down to a certain level, or just have a way to cut power off after a last uplink message notifying low battery (if charging source isn’t in place).

    Thanks,
    Amir.

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.