vshymanskyy / TinyGSM

A small Arduino library for GSM modules, that just works
GNU Lesser General Public License v3.0
1.91k stars 709 forks source link

How to set power mode by tinyGSM #688

Open asadi2021 opened 1 year ago

asadi2021 commented 1 year ago

Hi, I am using TinyGSM library for Sim800 connected to esp32 , I want to use deep sleep mode for power saving. but when I use modem.poweroff(); with digitalWrite(SIM800_RST_PIN,LOW); my modem is restart after seconds . Has TinyGSM any function for setting power mode or sim800 power off completely? Thank you

tronar commented 4 months ago

Something like this happens with Sim7000. powerOff "toggles" PWR_PIN instead of bringing it low, and it happens to work every other time (like powerOn/powerOff cycles brings the module down once every two cycles). I changed powerOff to actually pull down PWR_PIN after sending a poweroff command. That seems to hold...