Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Low power / wakeup #19

Open
Tracked by #18
Wolfestin123 opened this issue Feb 22, 2024 · 5 comments
Open
Tracked by #18

Low power / wakeup #19

Wolfestin123 opened this issue Feb 22, 2024 · 5 comments

Comments

@Wolfestin123
Copy link

No description provided.

@jdede
Copy link
Member

jdede commented Feb 22, 2024

Please add some content: Is the low power working or failing?

@Wolfestin123
Copy link
Author

The power consumption measurement of MoleNet V6 is attached in the pdf below.
MoleNet - V6_power_consumption.pdf
The code used :
`
from machine import deepsleep
from machine import lightsleep
from time import sleep

print('Im awake. Going to sleep in 10 seconds')
sleep(10)
print('Going to 10 sec light sleep now')
lightsleep(10000)
sleep(10)
print('Going to 10 sec deep sleep now')
deepsleep(10000)

`

@jdede
Copy link
Member

jdede commented Feb 29, 2024

2 mA with LoRa and SD powered up is too high. Please set the LoRa-module into deep sleep mode and check the current drawn by the pull-up resistors.

@jdede jdede reopened this Feb 29, 2024
@Wolfestin123
Copy link
Author

Wolfestin123 commented Apr 3, 2024

I have configured the LoRa module to sleep and measured the current consumption. The results indicate a reduction in current consumption of the LoRa chip (RA-01H) by 2mA during sleep. Please find the attached code and results for reference.
MoleNet - V6_power_consumption_with_LORA_sleep.pdf

`import LoRaSender
import LoRaReceiver

from config import *
from machine import Pin, SPI, SoftSPI
from sx127x import SX127x
from machine import lightsleep
from time import sleep
from machine import deepsleep

device_spi = SoftSPI(
baudrate = 200000,
polarity = 0, phase = 0, bits = 8, firstbit = SPI.MSB,
sck = Pin(device_config['sck'], Pin.OUT, Pin.PULL_DOWN),
mosi = Pin(device_config['mosi'], Pin.OUT, Pin.PULL_UP),
miso = Pin(device_config['miso'], Pin.IN, Pin.PULL_UP))

Pin(device_config['reset'], Pin.OUT, value=1)
lora = SX127x(device_spi, pins=device_config, parameters=lora_parameters)

print("going to light sleep")

lightsleep(10000) # 10 seconds light sleep
print("lora on")
sleep(20)

lora.sleep() # Lora is on sleep mode
print("lora off")

lightsleep(10000) # 10 seconds light sleep

deepsleep(20000) # 20 seconds deep sleep

`

@jdede
Copy link
Member

jdede commented Apr 3, 2024

2mA during sleep for the LoRa transceiver???

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants