Arduino + SIM800 power on/off?

Greeting!

Need a bit of help. I got new (cheap) SIM800L module, now i got few questions. Module: http://www.ebay.com/itm/SIM800L-GPRS-GSM-Module-Board-Quadband-QUAD-BAND-Antenna-for-MCU-Arduino-/281743051042?hash=item419931c922:g:JqEAAOSwT6pVm7MX

  1. What is VDO pin
  2. is there a way that i power it down for almost all day and then wake up at specific hour. (wake up is triggerd by DS3231 RTC alarm function?

That is for now. Thanks for your answers!

The first thing you need is a schematic of your board, though they seem hard to find.

Also you want to download the sim 800l datasheet.

Some Arduino Sim shields use a hardwate port to power the board off, but thats not on your basic board, so you can either build in such a circuit or use the software control to power it off; see page 24

http://www.seeedstudio.com/wiki/images/4/46/SIM800L_Hardware_Design_V1.00.pdf

AT+CFUN=0 is Minimal Power Mode
AT+CFUN=1 is Normal Mode

link to AT Commands

If you were using just the actual module, it can be bone but as it comes already on the board there is no connection to use a pin to control the on and off. Check out the AT commands.

Greetings,

I am building beescale and i want to run on batteries as long as possible.. i got 18650 batteries (3.7V 9.8Ah) and i would like to run it on 3.7 V.

For better image:

i use:

Arduino UNO
GSM SIM800L
LCD 2line 16 char
DS3231
DHT21
HX711 + load cell (120kg)

Now i am testing just on usb cable from pc...
cuz if i could use 3.7 v i can get 4x9,8Ah and that is a lot :slight_smile:
thanks for your answers

The battery life time depends, to a large extent on how long your sensors, display and GSM module are active.
You'd get a basic idea of the total current consumption by putting an ammeter in series with your power supply with all devices active.
For minimal power consumption, you'd have the arduino and peripherals shut down most of the time, waking up only occasionally to collect and send data. The backlight of the LCD would be switched on on demand.
The Uno is not a particularly good choice for minimal power consumption applications because of its regulator and USB controller.

Reading forums, I came across on your topic.

I'm working on almost the same project.

With a friend I have 10 beehives (amateur - hobby) and I want to make one sms scale for "Measuring the weight of a beehive".

I own Arduino Uno, DTH21 (temperature and humidity sensor), and through eBay ordered a Load cell 150kg (max) with HX711, DS3231 and SIM800L. (all components except sim800 I burned previously with bad power supply from ebay)

I ordered ATMEGA328P (pair... just in case , if something blows again) chip so it can eventually reduce the size and battery consumption.

I'm interested in whether you have a project documentation and/or code (if you would be so kind and shared with me)?

For now I just did a piece of code that measures the temp / hum.
Next is calibration and zeroing of weight, then sending data over sms (that is 99% finished, but think about IOT services and GPRS) and at the end "wake up alarm".
My entire code is in segments , while I do not for all components, then it 'll consolidate.

How did you power the board and how long does the battery? I plan to use two 18650.

Thanks in advance and sorry to bother you.

Bici

My project has developed .. now i use just microcontroler and few components.. after this post: https://www.openhomeautomation.net/arduino-battery/

so if i plug all components in

  • LCD 2x16 i2c
  • RTC DS3231 (alarm is triggerd 2 times per day
  • DHT21
  • HX711 and load cell

power on : 20mAh
power down (most power save) 1-2 mAh


when i attach SIM800L (it works fine on 5V) power jumps from 30mAh to 150 mAh

in cycle of 10 seconds .. 30 mAh 80 mAh 120 mAh 150mAh 80 mAh 30mAh ..then 30 mAh for 5 seconds and again.. cycle..

so i would like to somehow put SIM800L module off and wake up just once per day

and still guessing why from that breadboard..sms is not send..from uno is.. at same pins.. i must miss something..

i have wired SIM800L

  • vcc +5v
  • ground to ground
  • rx to pin 4
  • tx to pin 5

RST VDO and second GND pin are empty

Hey...i still have some issues .. biggest problem is doing sim800l module - power consumtion.

I have now 4 18650 3.7v 9,8Ah batteries wired in a way that i got 19.6Ah and 7,4V and regulator to 5 V

if i turn off sim800l module power consumption is 1 mAh but if i connect it back it from 30-150 mAh .. way too much

if i optimize that for max 10mAh it would last around 60 days.. but if not i have problem then

So add me on skype: simonmur and we will figure out something

Replace the +5V regulator with more efficient switching one

-Malhar

MalharD:
Replace the +5V regulator with more efficient switching one

-Malhar

What you mean by that? because arduino ATMEGA328 cannot run on higer voltage then 5v

Do you use a 7805 to lower the voltage to 5v ?
If yes,you are wasting nearly 33%(based on your data) of the battery capacity as heat.

-Malhar

I use LM2596 dc dc converter

smfoto:
I use LM2596 dc dc converter

Okay. Try using standalone atmega328p. There are power parasites on the arduino UNO board.

-Malhar

Hi @smfoto.

Thanks for the quick answer.

I will for sure work with microchip. Now I use the Arduino Uno as a programmer and solderless breadboard for the playground.

I have and the LCD1602 but I think that I will not use it.

Earlier in this forum I found a post for power sim800l, but it requires additional LM2596 that over Arduino pin turns on and off, simple and good solution. I think it would be great for you

I was just being tested to see if it works, but now I have a problem with scale, does not show the exact weight. I think the problem is in the HX711. I ordered a new and already have one hx711 burned (and ATMEGA328P and dht21 all with cheap Breadboard power from ebay).

I need at least four measurements during the day (it could be three), for example, 8-14-20 or 8-12-16-20. So I got the sms in 20 hours with all this data. Two alarms for me are not enough, although I do not know how to bring out with this DS3231 (or other).

At the end of all this I have put together in a single unit and probably a lot of code to customize.
I have chosen the wrong approach to work each component separately, in the end will be a problem. But I found a lot of code here on the forums, so I wanted to use it.

Thanks again.

Bici

First i need to make that SIM800L module work on ATMEGA328, on uno works on microchip not...

I do my coding that way.. each component own scetch and then when each one works.. i combine them one by one into complete code, when i add one i test if ok i add another one, again test.. etc... so i get complete code.. and still have code separate for testing.

Ill think about this.. with lm2596...

you can try to wake it every full hour and then if hour match 8 -12 -16- 20 you mesure if not you put it back to sleep .. ill do that way

I measured the voltage, when for example: pinMode (6, OUTPUT) and digitalWrite (6, LOW); receive a voltage of 4.01V, and the end of the loop when the digitalWrite (6, HIGH); voltage is 0.00V.

For LM2596 ON / OFF voltages are 0.5V and 2.5V, I guess less than 0.5V and higher than 2.5V.

And for SIM800l my work with ordinary script, RX and TX are D7 and D8 (for that I put the ON / OFF pin to D6) and works great.

SMS_Send.ino:

#include <SoftwareSerial.h>
 
//SIM800 TX is connected to Arduino D8 and RX is connected to Arduino D7
#define SIM800_TX_PIN 8
#define SIM800_RX_PIN 7
 
//Create software serial object to communicate with SIM800
SoftwareSerial serialSIM800(SIM800_TX_PIN,SIM800_RX_PIN);
 
void setup() {
  pinMode(6, OUTPUT);       //SIM pin power ON/OFF.
  digitalWrite(6, LOW);     // turn the LM2596 on (LOW is the voltage level)
  delay(1000);              // wait for a second  
  //Begin serial comunication with Arduino and Arduino IDE (Serial Monitor)
  Serial.begin(9600);
  while(!Serial);
   
  //Being serial communication witj Arduino and SIM800
  serialSIM800.begin(9600);
  delay(1000);
   
  Serial.println("Setup Complete!");
  Serial.println("Sending SMS...");
   
  //Set SMS format to ASCII
  serialSIM800.write("AT+CMGF=1\r\n");
  delay(1000);
 
  //Send new SMS command and message number
  serialSIM800.write("AT+CMGS=\"+1234567890\"\r\n"); //my smartphone no.
  delay(1000);
   
  //Send SMS content
  serialSIM800.write("TEST");
  delay(1000);
   
  //Send Ctrl+Z / ESC to denote SMS message is complete
  serialSIM800.write((char)26);
  delay(1000);
     
  Serial.println("SMS Sent!");
  delay(1000); 
  digitalWrite(6, HIGH);    //  turn the LM2596 off (HIGH is the voltage level)
}
 
void loop() {
}

For alarm I have not even tried. First I have to read sheet detail.

Today I worked around hx711. Tried to get a valid reading, but unsuccessfully, waitinng for the new one.

P.S.: Whether there is a chance to look at your code, working part (here or on PM or skype). I am interested in how did you organize your code.

Thanks, that code works (ill my other trys don't :confused: ) so ill rebuild code around that code:)

that is awsome solution.. ill try it next week when i get my LM2596 dc-dc step down :slight_smile:

i'll publish then power consumption (power on / power off / power on/sleep power on/no sleep)...

Hi,
I'm just wondering. Are you connecting battery (18650) directly to SIM800 ?
Or using dc/dc converter ?

Using LM2596 DC-DC converter - on this converter i have pin 5 unpined and connected to arduino, so i can turn on/off and also connected all other components on it (lcd, dht, hx711) so i reduce power consumption to minumum.

but i throw away all china 18650 now i am considering about original batteries (more expensive) or car battery and solar power (which is always good in beehouse).

Don't buy 18650 with capacity over 2.5Ah.. they are fake.

smfoto:
Using LM2596 DC-DC converter - on this converter i have pin 5 unpined and connected to arduino, so i can turn on/off and also connected all other components on it (lcd, dht, hx711) so i reduce power consumption to minumum.

but i throw away all china 18650 now i am considering about original batteries (more expensive) or car battery and solar power (which is always good in beehouse).

Don't buy 18650 with capacity over 2.5Ah.. they are fake.

As far as I can see LM2596 have min input 4.5V it'nt too low ? This bateries are 3,7V.
I'm just wondering if I could connect them directly to SIM800 without converter.