{"id":13027,"date":"2021-11-19T20:45:07","date_gmt":"2021-11-19T20:45:07","guid":{"rendered":"https:\/\/wolles-elektronikkiste.de\/sim800l-module"},"modified":"2025-10-10T19:30:15","modified_gmt":"2025-10-10T19:30:15","slug":"sim800l-module","status":"publish","type":"post","link":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module","title":{"rendered":"SIM800L module"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">About this Post<\/h2>\n\n<p>The SIM800L module allows you to build a mobile phone that you can control with your microcontroller. The range of functions is huge. Most of you are certainly primarily interested in SMS and telephony, for example for data transmission in areas without WiFi access. But the SIM800L offers many more functions, such as FTP, TCP\/IP and HTTP applications, e-mail, or MMS. One could write a whole book about the SIM800L module.<\/p>\n<p>In order not to make this post too long, I will focus on the following topics:<\/p>\n<ul>\n<li><a href=\"#technische_Eigenschaften\">Technical features of the SIM800L<\/a><\/li>\n<li><a href=\"#schaltung\">Wiring of the SIM800L module<\/a><\/li>\n<li><a href=\"#at_befehle\">Communication via AT commands<\/a><\/li>\n<li><a href=\"#sms_senden\">How to send SMS<\/a><\/li>\n<li><a href=\"#sms_empfangen\">How to receive SMS<\/a><\/li>\n<li><a href=\"#per_sms_steuern\">Controlling microcontrollers via SMS<\/a><\/li>\n<li><a href=\"#per_anruf_steuern\">Controlling microcontrollers via calls<\/a><\/li>\n<li><a href=\"#whitelist\">Restrict the access &#8211; whitelist<\/a><\/li>\n<li><a href=\"#zeit\">Query and synchronize the time<\/a><\/li>\n<li><a href=\"#bibliothek\">Programming the SIM800L module with a library<\/a><\/li>\n<li><a href=\"#location\">Appendix: GSM location &#8211; an attempt<\/a><a id=\"technische_Eigenschaften\"><\/a><\/li>\n<\/ul>\n\n<h2 class=\"wp-block-heading\">Technical characteristics<\/h2>\n\n<p>The SIM800L is a quad-band <a href=\"https:\/\/de.wikipedia.org\/wiki\/Global_System_for_Mobile_Communications\" target=\"_blank\" rel=\"noopener\">GSM<\/a> \/ <a href=\"https:\/\/de.wikipedia.org\/wiki\/General_Packet_Radio_Service\" target=\"_blank\" rel=\"noopener\">GRPS<\/a> module. It covers the GSM850, EGSM900, DCS1800 and PCS1900 frequency bands. To use the SIM800L, you need a 2G micro-SIM card. Your microcontroller communicates with the SIM800L serially via RX\/TX and AT commands.<\/p>\n<p>The voltage range for the power supply is an unusual 3.4 to 4.4 volts. For this reason and because of current peaks of up to 2 amps, power supply via the microcontroller is not possible. Lithium-ion batteries are suitable, or you can use <a href=\"https:\/\/wolles-elektronikkiste.de\/en\/voltage-regulation-linear-and-switching-regulators\" target=\"_blank\" rel=\"noopener\">switching regulators<\/a> such as the LM2596. For switching regulators, however, you still need a suitable power supply.<\/p>\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/SIM800L_pinout-1024x589.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"589\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/SIM800L_pinout-1024x589.png\" alt=\"SIM800L pinout\" class=\"wp-image-12947\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/SIM800L_pinout-1024x589.png 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/SIM800L_pinout-300x173.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/SIM800L_pinout-768x442.png 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/SIM800L_pinout-1536x883.png 1536w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/SIM800L_pinout-1320x759.png 1320w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/SIM800L_pinout.png 1977w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\"> SIM800L pinout <\/figcaption><\/figure>\n\n<p>The SIM800L module has the following pins:<\/p>\n<ul>\n<li><strong>Antenna connector<\/strong> (IPX U.FL, top left \/ unlabeled).<\/li>\n<li><strong>NET<\/strong>: Antenna connector for spiral antennas.<\/li>\n<li><strong>VCC<\/strong>: Power supply (3.4 &#8211; 4.4 Volt).<\/li>\n<li><strong>RESET<\/strong>: active-low, you can leave it unconnected.<\/li>\n<li><strong>RX\/TX<\/strong>: serial ports, baud rate: 1200 &#8211; 115200 bps.<\/li>\n<li><strong>GND<\/strong>: connect to GND of the power supply and GND of the microcontroller.<\/li>\n<li><strong>RING<\/strong>: HIGH by default, briefly goes LOW when a call or SMS is received; useful for interrupt programming.<\/li>\n<li><strong>DTR<\/strong>: controls sleep modes.<\/li>\n<li><strong>MIC+\/MIC-<\/strong>: Microphone connectors.<\/li>\n<li><strong>Speaker+\/-<\/strong>: here you can connect 8-ohm speakers directly and get a &#8220;full&#8221; 1.08 watts.<\/li>\n<\/ul>\n\n<h3 class=\"wp-block-heading\">RX \/ TX voltage level<\/h3>\n\n<p>There are contradictory statements about the permissible voltage level of the serial interfaces of the SIM800L. Some say it can handle 5 volts, others see the limit at 3.3 volts. According to the <a href=\"https:\/\/www.rlocman.de\/datasheet\/data.html?di=600593&amp;\/SIM800L\" target=\"_blank\" rel=\"noopener\">data sheet<\/a>, however, the maximum is 2.8 volts. You can also find there how to <em>optimally<\/em> connect 3.3 volt and 5 volt microcontrollers (from page 31). I only used a voltage divider in the RX line of the module and did well with it.<\/p>\n\n<h3 class=\"wp-block-heading\">Antennas for the SIM800L module<\/h3>\n<div class=\"wp-block-image is-resized\">\n<figure class=\"aligncenter size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Antennen-1024x417.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"417\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Antennen-1024x417.jpg\" alt=\"Antennas and antenna adapters for the SIM800L module\" class=\"wp-image-12790\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Antennen-1024x417.jpg 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Antennen-300x122.jpg 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Antennen-768x313.jpg 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Antennen-1536x626.jpg 1536w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Antennen-1320x538.jpg 1320w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Antennen.jpg 2000w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">Antennas and antenna adapters for the SIM800L module<\/figcaption><\/figure>\n<\/div><div class=\"wp-block-image is-resized\">\n<figure class=\"alignright size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_with_helical_antenna-703x1024.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"703\" height=\"1024\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_with_helical_antenna-703x1024.jpg\" alt=\"SIM800L module with spiral antenna\" class=\"wp-image-12792\" style=\"width:231px;height:auto\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_with_helical_antenna-703x1024.jpg 703w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_with_helical_antenna-206x300.jpg 206w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_with_helical_antenna-768x1118.jpg 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_with_helical_antenna.jpg 824w\" sizes=\"auto, (max-width: 703px) 100vw, 703px\" \/><\/a><\/figure>\n<\/div>\n<p>The SIM800L module is normally offered with one or more antennas. In many cases, you can get by with a simple spiral antenna. In areas with poor reception, interfering signals or shielded buildings, you may need a better antenna.<\/p>\n<p>One could also come up with the idea of using two antennas. However, this can be counterproductive, as they might interfere with each other.<\/p>\n<p>If you buy an antenna with an SMA connection (that&#8217;s the one with the screw thread), then you still need an IPX UF. L to SMA adapter.<\/p>\n\n<h3 class=\"wp-block-heading\">Power consumption<\/h3>\n\n<p>Typical power consumption is:<\/p>\n<ul>\n<li>Power Down Mode: 60 \u03bcA<\/li>\n<li>Sleep Mode: 0.7 &#8211; 1.0 mA<\/li>\n<li>Normal Mode: (Waiting for SMS or Call): approx. 15 mA<\/li>\n<\/ul>\n<p>How much power the SIM800L module consumes during a phone call or when transferring data via GRPS is not so easy to answer because the consumption is not constant. I have found quite concrete information <a href=\"https:\/\/lastminuteengineers.com\/sim800l-gsm-module-arduino-tutorial\/\" target=\"_blank\" rel=\"noopener\">here<\/a> (131 &#8211; 216 mA, depending on the frequency band). In my measurements I found values around 70 mA, but with peaks.<\/p>\n<p>At the beginning of a connection, peak values of up to 2 amps can occur, as mentioned above.<\/p>\n\n<h3 class=\"wp-block-heading\">Notes on the SIM card<\/h3>\n<div class=\"wp-block-image is-resized\">\n<figure class=\"alignright size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_Sim_Karte-741x1024.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"741\" height=\"1024\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_Sim_Karte-741x1024.jpg\" alt=\"How to insert the SIM card into the SIM800L\" class=\"wp-image-12809\" style=\"width:208px;height:auto\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_Sim_Karte-741x1024.jpg 741w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_Sim_Karte-217x300.jpg 217w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_Sim_Karte-768x1062.jpg 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_Sim_Karte-1111x1536.jpg 1111w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_Sim_Karte.jpg 1118w\" sizes=\"auto, (max-width: 741px) 100vw, 741px\" \/><\/a><\/figure>\n<\/div>\n<p>The SIM card is inserted into the cardholder as shown on the right.<\/p>\n<p>I can&#8217;t tell you which is the ideal SIM card for you. This depends too much on your application, i.e. mainly on the expected frequency of SMS or calls.<\/p>\n<p>But I want to share an experience with you. I had bought an &#8220;IoT and M2M Prepaid&#8221; card because it sounded so beautiful. Unfortunately, the card had a &#8220;+882&#8221; country code, which stands for &#8220;International Networks&#8221;. This number is blocked by many mobile phone providers because it is also used for fraud calls. In addition, a connection with this area code can generate high costs. So calls were not easily possible, and I could only send SMS from, but not to the module. I then got another SIM card from the good old Telekom. So choose your SIM card wisely.<\/p>\n<p>And be careful when creating programmes to send text messages so that you don&#8217;t accidentally send bulk SMS. In the best case, you have a prepaid card, which is then empty.<a id=\"schaltung\"><\/a><\/p>\n\n<h2 class=\"wp-block-heading\">Wiring of the SIM800L module<\/h2>\n\n<p>This is the wiring I used:<\/p>\n\n<figure class=\"wp-block-image size-large is-resized\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/sim800l_nano_wiring-1024x568.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"568\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/sim800l_nano_wiring-1024x568.png\" alt=\"\" class=\"wp-image-25025\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/sim800l_nano_wiring-1024x568.png 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/sim800l_nano_wiring-300x167.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/sim800l_nano_wiring-768x426.png 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/sim800l_nano_wiring-1320x733.png 1320w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/sim800l_nano_wiring.png 1490w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\"> SIM800L connected to an Arduino Nano <\/figcaption><\/figure>\n\n<p>Note that RX of the module is connected to TX of the microcontroller and TX of the module to RX of the microcontroller.<\/p>\n<p>For the above circuit, the voltage at RX of the module is:<a id=\"at_befehle\"><\/a><\/p>\n<\/p>\n<p class=\"ql-center-displayed-equation\" style=\"line-height: 41px;\"><span class=\"ql-right-eqno\"> &nbsp; <\/span><span class=\"ql-left-eqno\"> &nbsp; <\/span><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/ql-cache\/quicklatex.com-8e3ccd46ef6b21614fd32d94f155af1b_l3.png\" height=\"41\" width=\"284\" class=\"ql-img-displayed-equation quicklatex-auto-format\" alt=\"&#92;&#091; &#86;&#95;&#123;&#82;&#88;&#125;&#61;&#92;&#102;&#114;&#97;&#99;&#123;&#53;&#46;&#54;&#125;&#123;&#53;&#46;&#54;&#43;&#52;&#46;&#55;&#125;&#92;&#99;&#100;&#111;&#116;&#32;&#53;&#46;&#48;&#92;&#59;&#61;&#92;&#59;&#92;&#115;&#105;&#109;&#32;&#50;&#46;&#55;&#50;&#92;&#59;&#091;&#92;&#116;&#101;&#120;&#116;&#123;&#86;&#125;&#093; &#92;&#093;\" title=\"Rendered by QuickLaTeX.com\"\/><\/p>\n<p>\n\n<h2 class=\"wp-block-heading\">Communication via AT commands<\/h2>\n\n<p>One or the other of you may already know AT commands from the <a href=\"https:\/\/wolles-elektronikkiste.de\/en\/hc-05-and-hc-06-bluetooth-modules\" target=\"_blank\" rel=\"noopener\">HC05 \/ HC06 Bluetooth modules<\/a> or other serially controlled components. Most AT commands have this structure (exceptions prove the rule!):<\/p>\n<ul>\n<li>AT+xxxx: Call of a function or query without parameters<\/li>\n<li>AT+xxxx=yyyy: Assignment of the value yyyy to the property \/ function xxxx<\/li>\n<li>AT+xxxx?: Query the value of xxxx<\/li>\n<li>AT+xxxx=? Query the options<\/li>\n<\/ul>\n<p>A list of AT commands for the SIM800L module can be found <a href=\"https:\/\/github.com\/anothermist\/LIBRARIES\/blob\/master\/TinyGSM\/extras\/AT%20Command%20Manuals\/SIM800%20Series%20AT%20Command%20Manual%20V1.10.pdf\" target=\"_blank\" rel=\"noopener\">here<\/a>. There are over 300 of them in this document alone.<\/p>\n<p>The easiest way is to send the AT commands via the serial monitor of the Arduino IDE to &#8220;play around&#8221; with them. Alternatively, you can use terminal programs such as <a href=\"https:\/\/www.putty.org\/\" target=\"_blank\" rel=\"noopener\">PuTTY<\/a> or <a href=\"https:\/\/www.der-hammer.info\/pages\/terminal.html\" target=\"_blank\" rel=\"noopener\">HTerm<\/a>, but then you need a USB-to-TTL adapter.<\/p>\n\n<h3 class=\"wp-block-heading\">SoftwareSerial Sketch<\/h3>\n\n<p>Upload the following SoftwareSerial sketch to your Arduino board to communicate via the serial monitor:<\/p>\n<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"SoftwareSerial.ino\" data-enlighter-title=\"SoftwareSerial.ino\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\n\nvoid setup() {\n  Serial.begin(9600);\n  Serial.println(\"Software Serial Sketch\");\n  mySerial.begin(9600);\n}\n\nvoid loop() { \/\/ run over and over\n  while(mySerial.available()) {\n    Serial.write(mySerial.read());\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<p>\n\n<p>In my experience, you can work reliably with a baud rate of 9600 bps. At 115200 bps, I lost parts of SMS. In the serial monitor, you need to set the same baud rate and select &#8220;Carriage Return (CR)&#8221;.<\/p>\n\n<h3 class=\"wp-block-heading\">Getting Started<\/h3>\n\n<p>Once you have wired everything, inserted the SIM card and supplied the SIM800L module with power, you can now start. The LED on the SIM800L module should initially light up with a frequency of about 0.8 seconds after the supply voltage is applied.<\/p>\n\n<p>As a first test, you simply enter <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT<\/code> and confirm with Enter or click on &#8220;Send&#8221;. The module should respond with a friendly <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">OK<\/code>. If it does not, then check the wiring and the settings of the serial monitor again.<\/p>\n<p>If everything is OK, you can now query information about the module:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ATI<\/code>&nbsp;\u2192 &nbsp; answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">SIM800 R14.18<\/code><\/p>\n<p>Your SIM card may be protected by a PIN. Enter the following:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CPIN?<\/code> \u2192 &nbsp; for answer: &nbsp; <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CPIN: READY<\/code> no PIN is necessary; for answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CPIN: SIM PIN<\/code> you have to enter the PIN including the quotation marks:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CPIN=\"xxxx\"<\/code> \u2192 answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">OK<\/code> ; if the PIN is incorrect or if the PIN has already been entered: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ERROR<\/code>.<\/p>\n<p>At the latest after entering the correct pin, the module should connect to the network and the LED should flash every 3 seconds.<\/p>\n<p>A very useful feature is to query the battery status:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CBC<\/code>&nbsp;\u2192 answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CBC: 0,75,4005<\/code><\/p>\n<p>This means: &#8220;<strong>0<\/strong>&#8221; &#8211; battery does not charge (&#8220;1&#8221; would mean the battery charges). &#8220;<strong>75<\/strong>&#8221; means that the battery still has 75% capacity. &#8220;<strong>4005<\/strong>&#8221; stands for 4005 mV voltage.<\/p>\n<p>You can find out the signal strength of your network as follows:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CSQ<\/code> \u2192 answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CSQ: 20,0<\/code><\/p>\n<p>The first number means:&nbsp;<\/p>\n<ul>\n<li>&#8220;<strong>0<\/strong>&#8220;: &nbsp; -115 dBm or less<\/li>\n<li>&#8220;<strong>1<\/strong>&#8220;: &nbsp; -111 dBm<\/li>\n<li>&#8220;<strong>2<\/strong> &#8230; 30&#8243;: -110 &#8230; -54 dBm<\/li>\n<li>&#8220;<strong>31<\/strong>&#8220;: &nbsp; -52 dBm or greater<\/li>\n<li>&#8220;<strong>99<\/strong>&#8220;: &nbsp; unknown or not measurable<\/li>\n<\/ul>\n<p>You can find out which network you are in as follows:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+COPS?<\/code>&nbsp;\u2192 answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+COPS: 0,0,\"D1\"<\/code><\/p>\n<p>The essential information is behind the second comma. So here it is the D1 network. The other numbers encode mode and format. Check out the <a href=\"https:\/\/github.com\/anothermist\/LIBRARIES\/blob\/master\/TinyGSM\/extras\/AT%20Command%20Manuals\/SIM800%20Series%20AT%20Command%20Manual%20V1.10.pdf\" target=\"_blank\" rel=\"noopener\">AT command list<\/a>for more information.&nbsp;<\/p>\n<p>This query is also useful:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CREG?<\/code> \u2192 answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CREG: 0,1<\/code><\/p>\n<p>The second number means: &#8220;1&#8221; registered, home network; &#8220;5&#8221; registered, roaming. If you get a 2, 3 or 4, you are not registered.<\/p>\n<p>You can find out your service provider (according to SIM card) by:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CSPN?<\/code>&nbsp;\u2192 answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CSPN: \"Telekom.de\",0<\/code><\/p>\n\n<h4 class=\"wp-block-heading\">Sleep and Power Down Modes<\/h4>\n\n<p>You activate the power-down mode with:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CPOWD=1<\/code> \u2192 answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">NORMAL POWER DOWN<\/code><\/p>\n<p>With parameter 0, the SIM800L module is switched off immediately and without feedback. Unfortunately, the power-down mode does not seem to be stable. Again and again my module switched itself on after some time. So far, I have not been able to find out the reason.<\/p>\n<p>The sleep mode (slow clock) works better. And this is how the sleep mode is started:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CSCLK=x<\/code>&nbsp;\u2192 answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CSCLK: x<\/code> &nbsp; with x = 0, 1, 2:<\/p>\n<ul>\n<li><strong>0<\/strong>: normal (awake) mode.<\/li>\n<li><strong>1<\/strong>: Slow Clock Mode 1; To temporarily exit this slow clock mode, set DTR to GND. This is very convenient. When DTR is set to HIGH again, the module goes back into sleep mode. In the normal state, DTR is pulled to HIGH by an internal pull-up resistor.<\/li>\n<li><strong>2<\/strong>: Slow Clock Mode 2; to wake up you send <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CSCLK=0<\/code> twice in quick succession.<\/li>\n<\/ul>\n<p>In sleep mode, the SIM800L module is available for SMS and calls.<a id=\"sms_senden\"><\/a><\/p>\n\n<h2 class=\"wp-block-heading\">How to send SMS<\/h2>\n\n<p>To send an SMS, you may have to enter your PIN and set the module  to SMS text mode using <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CMGF=1<\/code>. You may have to add a delay to give the module time to connect.<\/p>\n<p>You initiate the actual sending of the SMS by entering the recipient&#8217;s telephone number:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CMGS=\"+491738xxxxxx\"<\/code><\/p>\n<p>Then a prompt should appear ( &gt; ). You enter the SMS text and complete the input with Ctrl+Z (ASCII code No. 26) and then press Enter. That&#8217;s the theory. Practically, I did not manage to send Ctrl+Z via the serial monitor, as it only processes visible characters. But through a sketch (see below) this is no problem. You create a Ctrl+Z with <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">Serial.write(26)<\/code> . <\/p>\n<p>All other commands are transmitted by <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">Serial.println()<\/code>. Quotation marks must be preceded by a backslash so that they are not interpreted as the end of the println() statement.<\/p>\n<p>I have outsourced the SoftwareSerial query as a separate function (updateSerial). Since the response to an AT command can take a little time,  I have added a waiting time (wt_ms = 100 ms). You may have to adjust the value.<\/p>\n<p>The main loop allows you to enter further commands via the serial monitor. Here you do not need to wait, as you query constantly.<\/p>\n<p>Here&#8217;s what the full sketch looks like:<\/p>\n<\/p>\n<div class=\"scroll-paragraph-long\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"send_sms_from_sim800l.ino\" data-enlighter-title=\"send_sms_from_sim800l.ino\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\nconst unsigned int wt_ms = 100; \/\/ wait ms\n\nvoid setup() {\n  Serial.begin(9600);\n  Serial.println(\"Send SMS Sketch\");\n  mySerial.begin(9600);\n  delay(1000);\n  updateSerial(wt_ms);\n  mySerial.println(\"AT\"); \/\/ to check if the module is connected\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CPIN=\\\"xxxx\\\"\"); \/\/ if Pin is needed\n  updateSerial(wt_ms);\n\/\/  delay(8000); \/\/ maybe needed to setup connection to the network\n\/\/  mySerial.println(\"AT+CCID\"); \/\/ optional check\n\/\/  updateSerial(wt_ms);\n\/\/  mySerial.println(\"AT+CBC\"); \/\/ optional check\n\/\/  updateSerial(wt_ms);\n\/\/  mySerial.println(\"AT+COPS?\"); \/\/ optional check\n\/\/  updateSerial(wt_ms);\n\/\/  mySerial.println(\"AT+CSQ\"); \/\/ optional check\n\/\/  updateSerial(wt_ms);\n\/\/  mySerial.println(\"AT+CREG?\"); \/\/ optional check\n\/\/  updateSerial(wt_ms);\n  mySerial.println(\"AT+CMGF=1\"); \/\/ SMS text mode\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CMGS=\\\"+491738xxxxxx\\\"\");\n  updateSerial(wt_ms);\n  mySerial.print(\"Hi Wolle, this is a message from your SIM800L Module.\"); \n  updateSerial(wt_ms);\n  mySerial.write(26);\n  mySerial.println(\"\");\n  updateSerial(wt_ms);\n}\n\nvoid loop() { \n  updateSerial(0);\n}\n  \nvoid updateSerial(unsigned int wait_ms){\n  String dataString = \"\";\n  delay(wait_ms);\n  if(mySerial.available()) {\n    dataString = mySerial.readString();\n    Serial.println(dataString);\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<\/div>\n<p>\n\n<p>You may have noticed that the answers of the SIM800L module are read in this sketch with <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">mySerial.readString()<\/code> and stored in a variable. This has the advantage that you can edit or evaluate the module&#8217;s response.<\/p>\n\n<h3 class=\"wp-block-heading\">Output to serial monitor and smartphone<\/h3>\n\n<p>Here&#8217;s what the output looked like:<\/p>\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/sms__to__smartphone.png\"><img loading=\"lazy\" decoding=\"async\" width=\"819\" height=\"349\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/sms__to__smartphone.png\" alt=\"Output of send_sms_from_sim800l.ino\" class=\"wp-image-12777\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/sms__to__smartphone.png 819w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/sms__to__smartphone-300x128.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/sms__to__smartphone-768x327.png 768w\" sizes=\"auto, (max-width: 819px) 100vw, 819px\" \/><\/a><figcaption class=\"wp-element-caption\">Output of send_sms_from_sim800l.ino<\/figcaption><\/figure>\n\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"197\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SMS_received_on_smartphone-1024x197.png\" alt=\"SMS on smartphone\" class=\"wp-image-12755\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SMS_received_on_smartphone-1024x197.png 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SMS_received_on_smartphone-300x58.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SMS_received_on_smartphone-768x147.png 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SMS_received_on_smartphone-1320x253.png 1320w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SMS_received_on_smartphone.png 1500w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><figcaption class=\"wp-element-caption\">SMS on smartphone<\/figcaption><\/figure>\n\n<h3 class=\"wp-block-heading\">Evaluating Strings<\/h3>\n\n<p>There are three very useful functions for evaluating and editing strings:<\/p>\n<ul>\n<li><code>indexOf()<\/code> \/ <code>lastIndexOf()<\/code>: returns the next or last position of the search string within the string. If the string is not found, the functions return -1.<\/li>\n<li><code>parseInt()<\/code>: searches for the next sequence of numbers in a string and returns it as an integer value.<\/li>\n<li><code>substring(x,y)<\/code>: intersects a sequence from a string (position x to y-1).<\/li>\n<\/ul>\n<p>As a small example of the <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">substring()<\/code> function, I show how you specifically cut out the name of the network from the module response to a &#8220;COPS&#8221; query. In my case, the &#8220;D1&#8243; from +COPS: 0.0,&#8221;D1&#8221;.<\/p>\n<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"evaluate_module_answer.ino\" data-enlighter-title=\"evaluate_module_answer.ino\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\nconst int wt_ms = 100; \/\/ wait ms\nString moduleAnswer = \"\";\n\nvoid setup() {\n  String irg = \"AT+COPS\";\n  Serial.begin(9600);\n  Serial.println(\"Evaluate Answer\");\n  mySerial.begin(9600);\n  delay(1000);\n  \n  mySerial.println(\"AT+COPS?\");\n  updateSerial(wt_ms);\n  \n  moduleAnswer = moduleAnswer.substring(1);   \/\/ does not work without, don't know why!\n  int pos1 = moduleAnswer.indexOf(\"\\\"\");      \/\/ first position of \" \n  int pos2 = moduleAnswer.lastIndexOf(\"\\\"\");  \/\/ last position of \"\n  moduleAnswer = moduleAnswer.substring(pos1+1,pos2);\n  Serial.print(\"The module is connected to \");\n  Serial.println(moduleAnswer);\n}\n\nvoid loop(){\n}\n  \nvoid updateSerial(unsigned int wait_ms){\n  delay(wait_ms);\n  if(mySerial.available()) {\n    moduleAnswer = mySerial.readString();\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<p>\n\n<p>Why I needed the line:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">moduleAnswer = moduleAnswer.substring(1);<\/code><\/p>\n<p>I don&#8217;t know. Without that, it didn&#8217;t work.<a id=\"sms_empfangen\"><\/a><\/p>\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/output_modify_module_answer.png\"><img loading=\"lazy\" decoding=\"async\" width=\"819\" height=\"349\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/output_modify_module_answer.png\" alt=\"Output of evaluate_module_answer.ino\" class=\"wp-image-12751\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/output_modify_module_answer.png 819w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/output_modify_module_answer-300x128.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/output_modify_module_answer-768x327.png 768w\" sizes=\"auto, (max-width: 819px) 100vw, 819px\" \/><\/a><figcaption class=\"wp-element-caption\">Output of evaluate_module_answer.ino<\/figcaption><\/figure>\n\n<h2 class=\"wp-block-heading\">How to receive SMS<\/h2>\n\n<p>To receive SMS, you must first be connected to the network again and activate the SMS text mode. In addition, you define how incoming SMS are to be handled:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CNMI=1,2<\/code>.<\/p>\n<p>The parameters used here ensure that the SMS text appears directly on the serial monitor.<\/p>\n<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"receive_sms_with_sim800l.ino\" data-enlighter-title=\"receive_sms_with_sim800l.ino\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\nconst int wt_ms = 100; \/\/ wait ms\n\nvoid setup() {\n  Serial.begin(9600);\n  Serial.println(\"Receive SMS Sketch\");\n  mySerial.begin(9600);\n  delay(1000);\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CPIN=\\\"xxxx\\\"\"); \/\/ in your SIM card has a PIN\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CREG?\"); \/\/ optional check\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CMGF=1\"); \n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CNMI=1,2\"); \/\/ defines how incoming SMS are handled\n  updateSerial(wt_ms);\n}\n\nvoid loop() { \n  updateSerial(0);\n}\n  \nvoid updateSerial(unsigned int wait_ms){\n  String bufString = \"\";\n  delay(wait_ms);\n  if(mySerial.available()) {\n    bufString = mySerial.readString();\n  }\n  if(bufString != \"\"){\n    Serial.println(bufString);\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<p>\n\n<p>And this is what it looks like on the serial monitor when an SMS is received:<\/p>\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Received__SMS.png\"><img loading=\"lazy\" decoding=\"async\" width=\"819\" height=\"349\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Received__SMS.png\" alt=\"Received SMS\" class=\"wp-image-12829\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Received__SMS.png 819w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Received__SMS-300x128.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/Received__SMS-768x327.png 768w\" sizes=\"auto, (max-width: 819px) 100vw, 819px\" \/><\/a><figcaption class=\"wp-element-caption\">Received SMS<\/figcaption><\/figure>\n\n<p>An alternative mode for processing SMS is: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CNMI=2,1<\/code> (instead of &#8220;1.2&#8221;). This will ensure that the SMS are saved. You will only get a message on the serial monitor, such as:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CMTI: \"ME\",21<\/code><\/p>\n<p>This means that SMS No. 21 has been saved in the phone memory (&#8220;ME&#8221; = Mobile Equipment). You can list the saved SMS with <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CMGL=\"ALL\"<\/code>:<\/p>\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"819\" height=\"108\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/List_SMS.png\" alt=\"\" class=\"wp-image-12775\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/List_SMS.png 819w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/List_SMS-300x40.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/List_SMS-768x101.png 768w\" sizes=\"auto, (max-width: 819px) 100vw, 819px\" \/><\/figure>\n\n<p>Instead of &#8220;ALL&#8221; you can also use &#8220;REC UNREAD&#8221; (received unread) or &#8220;REC READ&#8221; (received read) as parameters.<\/p>\n<p>With <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CMGD=21<\/code> you will delete the SMS No. 21. You can also delete all SMS at once. To do this, use the statement <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CMGDA=\"DEL ALL\"<\/code>.<a id=\"per_sms_steuern\"><\/a><\/p>\n\n<h2 class=\"wp-block-heading\">Controlling the microcontroller via SMS<\/h2>\n\n<p>You can control your microcontroller via SMS. I would like to demonstrate this using the example of two LEDs that I have connected to pins 9 and 10.<\/p>\n\n<h3 class=\"wp-block-heading\">Variant 1: with indexOf()<\/h3>\n\n<p>I called the two LEDs led1 and led2. When an SMS is received, the sketch uses the indexOf function to find out whether led1 or led2 is included in the text. Then it searches for the keyword &#8220;on&#8221;. If this is the case, led1 or led2 is switched on. If no &#8220;on&#8221; is included, the led1 or led2 is switched off. Examples:<\/p>\n<ul>\n<li>led1on: led1 is switched on<\/li>\n<li>blablaled2blablaonblablabla: led2 is switched on<\/li>\n<li>led1: led1 is turned off.<\/li>\n<\/ul>\n<\/p>\n<div class=\"scroll-paragraph-long\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"control_by_SMS_indexof.ino\" data-enlighter-title=\"control_by_SMS_indexof.ino\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\nconst int led1_pin = 9;\nconst int led2_pin = 10;\nconst int wt_ms = 100; \/\/ wait ms\n\nvoid setup() {\n  String moduleAnswer = \"\";\n  Serial.begin(9600);\n  Serial.println(\"Control LED Sketch\");\n  mySerial.begin(9600);\n  pinMode(led1_pin, OUTPUT);\n  pinMode(led2_pin, OUTPUT);\n  \n  delay(1000);\n  updateSerial(wt_ms, moduleAnswer);\n  mySerial.println(\"AT+CPIN=\\\"xxxx\\\"\");\n  updateSerial(wt_ms, moduleAnswer);\n  mySerial.println(\"AT+CREG?\"); \n  updateSerial(wt_ms, moduleAnswer);\n  mySerial.println(\"AT+CMGF=1\"); \n  updateSerial(wt_ms, moduleAnswer);\n  mySerial.println(\"AT+CNMI=1,2\");\n  updateSerial(wt_ms, moduleAnswer);\n}\n\nvoid loop() { \n  String smsText = \"\";\n  updateSerial(0, smsText);\n    \n  if(smsText != \"\"){\n    smsText = smsText.substring(1);\n    Serial.print(\"Text: \");\n    Serial.println(smsText);\n    if(smsText.indexOf(\"led1\")&gt;0){\n      \n      if(smsText.indexOf(\"on\")&gt;0){\n        digitalWrite(led1_pin, HIGH);\n      }\n      else{\n        digitalWrite(led1_pin, LOW);\n      }\n    }\n    \n    if(smsText.indexOf(\"led2\")&gt;0){\n      if(smsText.indexOf(\"on\")&gt;0){\n        digitalWrite(led2_pin, HIGH);\n      }\n      else{\n        digitalWrite(led2_pin, LOW);\n      }  \n    }  \n  }\n}\n  \nvoid updateSerial(unsigned int wait_ms, String &amp;bufString){\n  bufString = \"\";\n  delay(wait_ms);\n  if(mySerial.available()) {\n    bufString = mySerial.readString();\n  }\n  if(bufString != \"\"){\n    Serial.println(bufString);\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<\/div>\n<p>\n\n<p>Since strings are quite memory-intensive, I pass &#8220;moduleAnswer&#8221; and &#8220;smsText&#8221; as a reference (&amp;bufString). This means that the function works with the original. Accordingly, there is no return value.<\/p>\n\n<h3 class=\"wp-block-heading\">Variant 2: with parseInt()<\/h3>\n\n<p>In this variant, the pin and the desired pin state (0 or 1) are directly sent in the SMS text. Examples:<\/p>\n<ul>\n<li>*10*1*: Pin 10 goes HIGH<\/li>\n<li>*9*0*: Pin 9 goes LOW<\/li>\n<\/ul>\n<\/p>\n<div class=\"scroll-paragraph-long\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"control_by_SMS_parseint.ino\" data-enlighter-title=\"control_by_SMS_parseint.ino\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\nconst int led1_pin = 9;\nconst int led2_pin = 10;\nconst int wt_ms = 100; \/\/ wait ms\n\nvoid setup() {\n  Serial.begin(9600);\n  Serial.println(\"Control LED Sketch\");\n  mySerial.begin(9600);\n  pinMode(led1_pin, OUTPUT);\n  pinMode(led2_pin, OUTPUT);\n  \n  delay(1000);\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CPIN=\\\"xxxx\\\"\");\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CREG?\"); \n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CMGF=1\"); \n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CNMI=1,2\");\n  updateSerial(wt_ms);\n}\n\nvoid loop() { \n  waitForSMS();\n}\n  \nvoid waitForSMS(){\n  int led = 0;\n  bool state = false;\n  if(mySerial.available()){\n    while(((char)mySerial.read())!= '\\n'){}\n    led = mySerial.parseInt();\n    state = mySerial.parseInt();\n    digitalWrite(led, state);\n  }\n}\n\n\nvoid updateSerial(unsigned int wait_ms){\n  String bufString = \"\";\n  delay(wait_ms);\n  if(mySerial.available()) {\n    bufString = mySerial.readString();\n  }\n  if(bufString != \"\"){\n    Serial.println(bufString);\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<\/div>\n<p>\n\n<h2 class=\"wp-block-heading\">Making calls<\/h2>\n\n<p>Making calls with the SIM800L is even easier than sending SMS. Actually, you just have to make sure that your SIM800L module is connected to the net and to set up Serial\/SoftwareSerial as with the other sketches:<\/p>\n<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"call.ino\" data-enlighter-title=\"call.ino\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\nconst int wt_ms = 100; \/\/ wait ms \n\nvoid setup() {\n  Serial.begin(9600);\n  mySerial.begin(9600);\n  Serial.println(\"Call or wait for a call\");\n  delay(1000);\n  mySerial.println(\"AT\");  \/\/ optional check\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CPIN=\\\"++++\\\"\");\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CREG?\"); \/\/ optional check\n  updateSerial(wt_ms);\n}\nvoid loop() { \n  updateSerial(0);\n}\n  \nvoid updateSerial(unsigned int wait_ms){\n  String dataString = \"\";\n  delay(wait_ms);\n  if(mySerial.available()) {\n    dataString = mySerial.readString();\n    if(dataString != \"\"){\n      Serial.println(dataString);\n    }\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<p>\n\n<h3 class=\"wp-block-heading\">Outgoing call<\/h3>\n\n<p>You start a call with the following AT command:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ATD+ +xxxxxxxxxxxx;<\/code><\/p>\n<p>Replace xxxxxxxxxxxx with the number to dial, starting with the country code. With <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ATH<\/code> you end the call. Don&#8217;t forget the semicolon at the end (it&#8217;s no spelling mistake!). <\/p>\n\n<h3 class=\"wp-block-heading\">Incoming call<\/h3>\n\n<p>Use the same sketch if you want to call your SIM800L module. The call is indicated acoustically, by &#8220;RING&#8221; in the serial monitor and by a short LOW signal at the RING pin. You could use the latter signal to wake up your microcontroller from <a href=\"https:\/\/wolles-elektronikkiste.de\/en\/sleep-modes-and-power-management\" target=\"_blank\" rel=\"noopener\">sleep mode<\/a>. In this way, energy-saving projects can be implemented.<\/p>\n<p>With <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ATA<\/code> you take the call, with <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ATH<\/code> you reject it.<\/p>\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/incoming_call.png\"><img loading=\"lazy\" decoding=\"async\" width=\"819\" height=\"349\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/incoming_call.png\" alt=\"Incoming call on the serial monitor\" class=\"wp-image-12762\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/incoming_call.png 819w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/incoming_call-300x128.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/incoming_call-768x327.png 768w\" sizes=\"auto, (max-width: 819px) 100vw, 819px\" \/><\/a><figcaption class=\"wp-element-caption\">Incoming call on the serial monitor<\/figcaption><\/figure>\n\n<h3 class=\"wp-block-heading\">Telephony settings <\/h3>\n\n<p>Here are some useful functions and settings. You can query the call volume as follows:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CLVL?<\/code>&nbsp;\u2192 answer: <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CLVL: 33<\/code><\/p>\n<p>And this is how you set the volume:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CLVL=x<\/code>&nbsp;with x = 0 &#8211; 100<\/p>\n<p>The ringtone volume is independent of this (also 0-100):<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CRSL?<\/code> (Query) \/ <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CRSL=x<\/code> &nbsp; (Setting)<\/p>\n<p>There are 20 ringing sounds that you set as follows:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CALS=x<\/code>&nbsp;with x = 0 &#8211; 19<a id=\"per_anruf_steuern\"><\/a><\/p>\n\n<h2 class=\"wp-block-heading\">Controlling the microcontroller by call<\/h2>\n\n<p>I thought about how to control the microcontroller by calls. Switching on an LED is easy via &#8220;RING&#8221;. It is just as easy to turn off the LED with another call. However, it is also easy to get confused. Have I switched it on or off last time? Therefore, it would be nice to get feedback on whether the LED is on or off.<\/p>\n<p>I managed to do that with the following sketch. When a call is received, the sketch checks the status of the LED. If it is switched on, the call will be rejected immediately. If, on the other hand, it is off, nothing happens at first. In both cases, the number of &#8220;RINGS&#8221; are counted for the next 10 seconds. If the LED was switched off, the call is rejected now. As a result, the sketch counts a different number of &#8220;RINGS&#8221; depending on the LED state. Accordingly, the LED is switched on or off. And the caller knows that if the call is rejected immediately, the LED was off and is now on.<\/p>\n<\/p>\n<div class=\"scroll-paragraph-long\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"control_by_call.ino\" data-enlighter-title=\"control_by_call.ino\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\nconst int ledPin = 9;\nconst int wt_ms = 100; \/\/ wait ms\n\nvoid setup() {\n  String moduleAnswer = \"\";\n  Serial.begin(9600);\n  Serial.println(\"Control LED by Call\");\n  mySerial.begin(9600);\n  pinMode(ledPin, OUTPUT);\n  delay(1000);\n  updateSerial(wt_ms, moduleAnswer); \n  mySerial.println(\"AT+CPIN=\\\"xxxx\\\"\"); \/\/ in case a PIN is required\n  updateSerial(wt_ms, moduleAnswer); \n  mySerial.println(\"AT+CREG?\"); \/\/ optional check\n  updateSerial(wt_ms, moduleAnswer);\n}\n\nvoid loop() { \n  String ring = \"\";\n  int noOfRings = 0;\n  unsigned long callTime = 0;\n  const unsigned long threshold = 10000; \n  \n  updateSerial(0, ring); \n  \n  if(ring != \"\"){\n    if(ring.indexOf(\"RING\")&gt;0){\n      noOfRings++;\n      callTime = millis();\n      ring = \"\";\n      if(digitalRead(ledPin)){\n        mySerial.println(\"ATH\");\n      }\n      \n      while((millis()-callTime)&lt;threshold){\n        updateSerial(0, ring); \n        if(ring != \"\"){\n          if(ring.indexOf(\"RING\")&gt;0){\n            noOfRings++;\n            ring = \"\";\n          }\n        }\n      }\n      if(noOfRings == 1){\n        digitalWrite(ledPin, LOW);\n      }\n      else{\n        digitalWrite(ledPin, HIGH);\n        mySerial.println(\"ATH\");\n      }\n    }\n  }\n}\n  \nvoid updateSerial(unsigned int wait_ms, String &amp;bufString){\n  bufString = \"\";\n  delay(wait_ms);\n  if(mySerial.available()) {\n    bufString = mySerial.readString();\n  }\n  if(bufString != \"\"){\n    Serial.println(bufString);\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<\/div>\n<p>\n<p><strong>Attention:<\/strong> A rejected call is not necessarily free of charge! You might, among other things, turn off the setting that the SMS notification service is offered when &#8220;busy&#8221;. Check this before your phone bill explodes!<a id=\"whitelist\"><\/a><\/p>\n\n<h2 class=\"wp-block-heading\">Restrict the access &#8211; Whitelist<\/h2>\n\n<p>With the SMS and call methods, there is always a risk that someone may unintentionally or maliciously check your SIM800L without authorization. To prevent this, you can set up a whitelist. This allows you to set the phone numbers for which your SIM800L shall be reachable. The SIM800L rejects calls from devices with other phone numbers. The caller receives a busy signal.<\/p>\n<p>Here&#8217;s how it works:<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CWHITELIST=mode,index,phone_number<\/code><\/p>\n<p>The mode determines whether the whitelist is effective for calls, SMS, or both:<\/p>\n<ul>\n<li><strong>0<\/strong>: Whitelist disabled<\/li>\n<li><strong>1<\/strong>: Call Whitelist<\/li>\n<li><strong>2<\/strong>: SMS Whitelist<\/li>\n<li><strong>3<\/strong>: Call and SMS Whitelist<\/li>\n<\/ul>\n<p>The mode always applies to the entire whitelist. This means that different settings for different numbers are not possible.<\/p>\n<p>Index is the number of the entry (1-30). &#8220;phone_number&#8221; is the phone number including the country code, but without &#8220;+&#8221; &#8211; as I found out after several hours of experimenting and researching.<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CWHITELIST?<\/code> queries the whitelist and <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CWHITELIST=0<\/code> &nbsp; disables the entire list.<\/p>\n<p>Here is an example:<a id=\"zeit\"><\/a><\/p>\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_whitelist-1024x468.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"468\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_whitelist-1024x468.png\" alt=\"Use of the whitelist for the SIM800L module\" class=\"wp-image-12847\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_whitelist-1024x468.png 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_whitelist-300x137.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_whitelist-768x351.png 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/SIM800L_whitelist.png 1046w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">Use of the whitelist<\/figcaption><\/figure>\n\n<h2 class=\"wp-block-heading\">Query the time<\/h2>\n\n<p>You can use the SIM800L module as an RTC (Real Time Clock). With <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CCLK?<\/code>&nbsp;you query the time.<\/p>\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CCLK: \"04\/01\/01,00:01:31+00\"\n<\/code><\/p>\n<p>The format is: &nbsp; <em>&#8220;YY\/MM\/DD,hh:mm:ss\u00b1tz&#8221;<\/em>, i.e.<em>&#8220;Year\/Month\/Day,Hours:Minutes:Seconds+tz&#8221;<\/em>, where tz is the deviation from GMT in quarters of an hour. After disconnection from the power supply, the module starts again and again at 00:00 on 01\/01\/2004. So, you have to set the time. There are three ways to do this:<\/p>\n<ol>\n<li>Manual setting<\/li>\n<li>Via the computer&#8217;s system time<\/li>\n<li>Query an NTP server<\/li>\n<\/ol>\n\n<h3 class=\"wp-block-heading\">Manually setting the time<\/h3>\n\n<p>I think the following inputs and outputs on the serial monitor are self-explanatory:<\/p>\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_manually.png\"><img loading=\"lazy\" decoding=\"async\" width=\"860\" height=\"349\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_manually.png\" alt=\"Time setting with CCLK\" class=\"wp-image-12882\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_manually.png 860w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_manually-300x122.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_manually-768x312.png 768w\" sizes=\"auto, (max-width: 860px) 100vw, 860px\" \/><\/a><figcaption class=\"wp-element-caption\">Time setting with CCLK<\/figcaption><\/figure>\n\n<h3 class=\"wp-block-heading\">Synchronizing with the computer&#8217;s system time<\/h3>\n\n<p>This method uses the computer&#8217;s system time to set the time. To do this, you first have to &#8220;teach&#8221; the microcontroller to handle date and time. The soft-RTC version of the <a href=\"https:\/\/github.com\/adafruit\/RTClib\/tree\/master\/examples\" target=\"_blank\" rel=\"noopener\">RTCLib<\/a> is well suited for this. The microcontroller then synchronises with the SIM800L module. I don&#8217;t want to go into too much detail. How you work with DateTime and RTC_Millis objects, I have explained in my blog post about the RTC module <a href=\"https:\/\/wolles-elektronikkiste.de\/en\/ds3231-real-time-clock\" target=\"_blank\" rel=\"noopener\">DS3231<\/a>.<\/p>\n<p>I just mention this method for completeness. Better is the third method, with which you can set the time whenever and how often you want.<\/p>\n<\/p>\n<div class=\"scroll-paragraph-long\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"set_time_by_system_time.ino\" data-enlighter-title=\"set_time_by_system_time.ino\">#include \"RTClib.h\"\n#include &lt;SoftwareSerial.h&gt;\nRTC_Millis rtc;\nSoftwareSerial mySerial(7,8);\nconst int wt_ms = 100; \/\/ wait ms \n\nvoid setup () {\n  Serial.begin(9600); \n  mySerial.begin(9600);\n  Serial.println(\"Set time and date by system time\");\n  delay(1000);\n  Serial.println(\"Time before setting: \");\n  mySerial.println(\"AT+CCLK?\");\n  updateSerial(wt_ms);\n  Serial.println(\"Time after setting: \");\n  rtc.begin(DateTime(F(__DATE__), F(__TIME__))); \/\/ sets soft-RTC time by system time\n  setTimeBySystemTime();\n}\n\nvoid loop () {\n  mySerial.println(\"AT+CCLK?\");\n  updateSerial(wt_ms);\n  delay(3000);\n}\n\nvoid setTimeBySystemTime(){\n  DateTime now = rtc.now();\n  String dateTimeString = String(now.year()-2000);\n  dateTimeString += \"\/\";\n  dateTimeString += byteToStringAndFormat(now.month());\n  dateTimeString += \"\/\";\n  dateTimeString += byteToStringAndFormat(now.day());\n  dateTimeString += \",\";\n  dateTimeString += byteToStringAndFormat(now.hour());\n  dateTimeString += \":\";\n  dateTimeString += byteToStringAndFormat(now.minute());\n  dateTimeString += \":\";\n  dateTimeString += byteToStringAndFormat(now.second());\n  dateTimeString += \"+08\"; \/\/ change according to your time zone \n  mySerial.print(\"AT+CCLK=\\\"\");\n  mySerial.print(dateTimeString);\n  mySerial.println(\"\\\"\");\n  updateSerial(wt_ms);\n}\n\nString byteToStringAndFormat(byte b){\n  String str = \"\";\n  str = String(b);\n  if(b&lt;10){\n    str = \"0\" + str;\n  }\n  return str;    \n}\n\nvoid updateSerial(unsigned int wait_ms){\n  String dataString = \"\";\n  delay(wait_ms);\n  if(mySerial.available()) {\n    dataString = mySerial.readString();\n    if(dataString != \"\"){\n      Serial.println(dataString);\n    }\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}\n<\/pre>\n<\/div>\n<p>\n\n<p>Here&#8217;s what the output looks like:<\/p>\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_by_system_time.png\"><img loading=\"lazy\" decoding=\"async\" width=\"860\" height=\"349\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_by_system_time.png\" alt=\"Synchronizing the SIM800L with the computer system time\" class=\"wp-image-12884\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_by_system_time.png 860w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_by_system_time-300x122.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/10\/set_time_by_system_time-768x312.png 768w\" sizes=\"auto, (max-width: 860px) 100vw, 860px\" \/><\/a><figcaption class=\"wp-element-caption\">Synchronizing the SIM800L with the computer system time<\/figcaption><\/figure>\n\n<h3 class=\"wp-block-heading\">Setting the time via NTP server<\/h3>\n\n<p>You can also synchronize the time of the SIM800L with an NTP (Network Time Protocoll) server. This is a GPRS application for which you have to execute a series of &#8220;SAPBR&#8221; commands. In the sketch I added some comments. Otherwise, please have a look at the AT command list. The &#8220;CNTP&#8221; commands for the NTP server can be found in a separate document, the <a href=\"https:\/\/cdn-shop.adafruit.com\/product-files\/2637\/SIM800+Series_NTP_Application+Note_V1.01.pdf\" target=\"_blank\" rel=\"noopener\">NTP Application Note<\/a>.<\/p>\n<\/p>\n<div class=\"scroll-paragraph-long\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\nconst int wt_ms = 100; \/\/ wait ms\n\nvoid setup() {\n  Serial.begin(9600);\n  mySerial.begin(9600);\n  Serial.println(\"Get Time\");\n  delay(1000);\n  mySerial.println(\"AT\");  \/\/ optional check\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CPIN=\\\"xxxx\\\"\"); \/\/ if PIN is required\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CREG?\"); \/\/ optional check\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=3,1,\\\"CONTYPE\\\",\\\"GPRS\\\"\"); \/\/ set GPRS connection\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=3,1,\\\"APN\\\",\\\"internet\\\"\"); \/\/ set APN name\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=3,1,\\\"USER\\\",\\\"\\\"\"); \/\/ username empty\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=3,1,\\\"PWD\\\",\\\"\\\"\");  \/\/ password empty\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=1,1\"); \/\/ set rate\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=2,1\");  \/\/ connect\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CNTPCID=1\"); \/\/ set GPRS Bearer Profile\u2019s ID\n  updateSerial(wt_ms);\n  int timeZone = 2; \/\/ local time = UTC + timeZone\n  int timeVal = timeZone*4;\n  mySerial.print(\"AT+CNTP=\\\"0.de.pool.ntp.org\\\",\"); \/\/ replace by your country ntp server\n  mySerial.println(timeVal);\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CNTP\"); \/\/ synchronize time\n  updateSerial(wt_ms);\n\n  mySerial.println(\"AT+CCLK?\"); \/\/ query local (module) time\n  updateSerial(wt_ms);\n  \n  \/\/ close connection:\n  mySerial.println(\"AT+SAPBR=0,1\");\n} \n  \nvoid loop() { \n  updateSerial(0);\n}\n  \nvoid updateSerial(unsigned int wait_ms){\n  String dataString = \"\";\n  delay(wait_ms);\n  if(mySerial.available()) {\n    dataString = mySerial.readString();\n    if(dataString != \"\"){\n      Serial.println(dataString);\n    }\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<\/div>\n<p>\n\n<p>One more comment about the timeZone: Some time zones do not have full-hour shifts vs GMT. Therefore, the timeshift is passed to the server in quarters of an hour. <a id=\"bibliothek\"><\/a><\/p>\n\n<h2 class=\"wp-block-heading\">Programming the SIM800L module with a library<\/h2>\n\n<p>I had a look at different libraries. GSMSim by Erdem Arslan seemed to be the best. You can install it via the Library Manager or download it directly from GitHub <a href=\"https:\/\/github.com\/erdemarslan\/GSMSim\" target=\"_blank\" rel=\"noopener\">here<\/a>. However, the example sketches do not work &#8220;out of the box&#8221; on an Arduino UNO. Below you will find the modified example sketch for sending SMS.<\/p>\n<\/p>\n<div class=\"scroll-paragraph-long\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"GSMSim_SMS_mod.ino\" data-enlighter-title=\"GSMSim_SMS_mod.ino\">#include &lt;GSMSimSMS.h&gt;\n#include &lt;SoftwareSerial.h&gt;\n#define RESET_PIN 10 \/\/ you can use any pin.\n\nSoftwareSerial Serial1(6,7);\nGSMSimSMS sms(Serial1, RESET_PIN); \/\/ GSMSimSMS inherit from GSMSim. You can use GSMSim methods with it.\n\nvoid setup() {\n  Serial1.begin(9600); \/\/ If you don't change module baudrate, it comes with auto baudrate.\n  Serial.begin(9600); \/\/ Serial for debug...\n\n  \/\/ Init module...\n  sms.init(); \/\/ use for init module. Use it if you don't have any valid reason.\n\n  Serial.print(\"Set Phone Function... \");\n  Serial.println(sms.setPhoneFunc(1));\n  delay(1000);\n\n  \/\/Serial.println(\"Enter Pin Code:...\");\n  \/\/Serial.println(sms.enterPinCode(\"xxxx\"));\n  \/\/delay(3000);\n\n  Serial.print(\"is Module Registered to Network?... \");\n  Serial.println(sms.isRegistered());\n  delay(1000);\n\n  Serial.print(\"Signal Quality... \");\n  Serial.println(sms.signalQuality());\n  delay(1000);\n\n  Serial.print(\"Operator Name... \");\n  Serial.println(sms.operatorNameFromSim());\n  delay(1000);\n\n  Serial.print(\"Init SMS... \");\n  Serial.println(sms.initSMS()); \/\/ Its optional but highly recommended. Some function work with this function.\n  delay(1000);\n\n  Serial.print(\"List Unread SMS... \");\n  Serial.println(sms.list(true)); \/\/ Its optional but highly recommended. Some function work with this function.\n  delay(1000);\n\n  Serial.print(\"SMS to any number... \");\n  Serial.println(sms.send(\"+49173xxxxxxx\", \"SMS test message\")); \/\/ only use ascii chars please\n  delay(1000);\n}\n\nvoid loop() { \n}<\/pre>\n<\/div>\n<p>\u00a0<\/p>\n<p>\n\n<p>All in all, however, I would advise working without a library. You are simply more flexible.<a id=\"location\"><\/a><\/p>\n\n<h2 class=\"wp-block-heading\">Annex: GSM Location &#8211; an attempt<\/h2>\n\n<p>Theoretically, the location of the SIM800L can be determined. To anticipate it, I finally get a &#8220;Location Error&#8221;. It could be that this is related to my location, and that it works elsewhere. Usually, I don&#8217;t publish <em>anything that <em>might<\/em> work.<\/em> However, since I have invested many hours in this problem and could solve some partial aspects that others had problems with, I would like to share my experience.<\/p>\n\n<h3 class=\"wp-block-heading\">CIPGSMLOC has stopped working<\/h3>\n\n<p>With the AT command <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CIPGSMLOC=1,1<\/code> and some preparatory settings, it was possible until some time ago to determine the location in longitude and latitude. However, the method is based on a service that has unfortunately been switched off. This path is therefore blocked.<\/p>\n<p>Alternatively, there are the &#8220;CLBS&#8221; AT commands described in the <a href=\"https:\/\/www.avnet.com\/wps\/wcm\/connect\/onesite\/5ddc2831-b698-44ac-92f5-50d79a14cb3f\/Heracles-SIMCOM_GSM+Location_Application+Note_V1.02.pdf?MOD=AJPERES&amp;CVID=m31n15G&amp;CVID=m31n15G&amp;CVID=m31jwAj&amp;CVID=m31jwAj\" target=\"_blank\" rel=\"noopener\">Location_Application_Note<\/a>. However, this requires an update of the firmware of the SIM800L.<\/p>\n\n<h3 class=\"wp-block-heading\">Firmware update to version 1418B05SIM800L24<\/h3>\n\n<h4 class=\"wp-block-heading\">Preparations<\/h4>\n\n<p>On the hardware side, you need a USB-to-TTL adapter, which you can get for a few Euros at Amazon and Co. Then you need the firmware version 1418B05SIM800L24. You can find it <a href=\"https:\/\/github.com\/geekmatic\/SIM800_firmware_updates\/blob\/master\/1418B05SIM800L24.zip\" target=\"_blank\" rel=\"noopener\">here<\/a> on GitHub, for example. Download the ZIP file and unzip it somewhere. Furthermore, you need the program SIM800_Series_download_Tools_Customer_v1.19 to upload the firmware. This is available <a href=\"https:\/\/simcom.ee\/documents\/SIM800x\/SIM800_Series_download_Tools_Customer_v1.19.rar\" target=\"_blank\" rel=\"noopener\">here<\/a>. Download and unzip the rar file. It doesn&#8217;t matter which folder you use. In the unzipped folder you will find the program Flash_tool.exe.<\/p>\n<p>Wire your hardware as follows:<\/p>\n<div class=\"wp-block-image is-resized\">\n<figure class=\"aligncenter size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/wiring_for_firmware_upload-1024x502.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"502\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/wiring_for_firmware_upload-1024x502.png\" alt=\"Circuit for uploading new firmware for the SIM800L module\" class=\"wp-image-12894\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/wiring_for_firmware_upload-1024x502.png 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/wiring_for_firmware_upload-300x147.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/wiring_for_firmware_upload-768x377.png 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/wiring_for_firmware_upload.png 1256w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">Circuit to upload new firmware <\/figcaption><\/figure>\n<\/div><p>The voltage divider (5.6 k\u03a9 \/ 4.7 k\u03a9) is for a 5V adapter. As mentioned above, there are voices that say the SIM800L pins are 5V tolerant. You have to decide for yourself how careful you want to be.<\/p>\n\n<h3 class=\"wp-block-heading\">Uploading the firmware<\/h3>\n\n<p>Now launch Flash_tool.exe. Click on &#8220;Image Folder&#8221; and select the previously downloaded and unzipped firmware file. Set SIM800L, UART and baud rate 115200.&nbsp; As &#8220;Com&#8221; you select the port of your adapter. &#8220;Erase Type&#8221; is &#8220;Erase Source Code And User Data&#8221;:<\/p>\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Firmware_Upload.png\"><img loading=\"lazy\" decoding=\"async\" width=\"484\" height=\"656\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Firmware_Upload.png\" alt=\"Firmware upload to the SIM800L module with Flash_tool.exe\" class=\"wp-image-12898\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Firmware_Upload.png 484w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Firmware_Upload-221x300.png 221w\" sizes=\"auto, (max-width: 484px) 100vw, 484px\" \/><\/a><figcaption class=\"wp-element-caption\">Firmware upload to the SIM800L module with Flash_tool.exe<\/figcaption><\/figure>\n<\/div>\n<p>Click on &#8220;Start Download&#8221;. Then you take the SIM800L briefly from the power and reconnect it. The upload (called download here) should start in about 10 seconds.<\/p>\n<p>After a few minutes, the firmware is on the module. Disconnect the module from power again and restart it.<\/p>\n\n<h3 class=\"wp-block-heading\">Attempt to determine the location<\/h3>\n<div class=\"wp-block-image\">\n<figure class=\"alignright size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"144\" height=\"152\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/errors.png\" alt=\"\" class=\"wp-image-12900\"\/><\/figure>\n<\/div>\n<p>With the following sketch, everything seems to work, up to the actual location request <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">AT+CLBS=1,1<\/code>. The answer is <code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">+CLBS: 1<\/code>. According to the error list, this is &#8220;Location Failed&#8221;. Maybe something needs to be set differently, or maybe it has to do with the net coverage where I live. Or has the service been discontinued? I parked the whole thing in my X-Files folder.<\/p>\n<\/p>\n<div class=\"scroll-paragraph-long\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"get_location.ino\" data-enlighter-title=\"get_location.ino\">#include &lt;SoftwareSerial.h&gt;\nSoftwareSerial mySerial(7,8);\nconst int wt_ms = 100; \/\/ wait ms\n\nvoid setup() {\n  Serial.begin(9600);\n  mySerial.begin(9600);\n  Serial.println(\"Get Location\");\n  delay(1000);\n  mySerial.println(\"AT\");  \/\/ optional check\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CPIN=\\\"xxxx\\\"\"); \/\/ if PIN is required\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CREG?\"); \/\/ optional check\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=3,1,\\\"CONTYPE\\\",\\\"GPRS\\\"\"); \/\/ set GPRS connection\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=3,1,\\\"APN\\\",\\\"internet\\\"\"); \/\/ set APN name\n\/\/  updateSerial(wt_ms);\n\/\/  mySerial.println(\"AT+SAPBR=3,1,\\\"USER\\\",\\\"\\\"\"); \/\/ username empty\n\/\/  updateSerial(wt_ms);\n\/\/  mySerial.println(\"AT+SAPBR=3,1,\\\"PWD\\\",\\\"\\\"\");  \/\/ password empty\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=1,1\"); \/\/ set rate\n  updateSerial(wt_ms);\n  mySerial.println(\"AT+SAPBR=2,1\");  \/\/ connect\n  updateSerial(500);\n  mySerial.println(\"AT+CLBSCFG=0,1\"); \n  updateSerial(500);\n  mySerial.println(\"AT+CLBSCFG=0,2\"); \n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CLBSCFG=0,3\"); \n  updateSerial(wt_ms);\n  mySerial.println(\"AT+CLBSCFG=1,3,\\\"lbs-simcom.com:3002\\\"\");\n  updateSerial(500);\n  mySerial.println(\"AT+CLBS=1,1\");\n  updateSerial(500);\n  delay(10000);\n  \n  \/\/close connection:\n  mySerial.println(\"AT+SAPBR=0,1\");\n} \n  \nvoid loop() { \n  updateSerial(0);\n}\n  \nvoid updateSerial(unsigned int wait_ms){\n  String dataString = \"\";\n  delay(wait_ms);\n  if(mySerial.available()) {\n    dataString = mySerial.readString();\n    if(dataString != \"\"){\n      Serial.println(dataString);\n    }\n  }\n  while(Serial.available()) {\n    mySerial.write(Serial.read());\n  }\n}<\/pre>\n<\/div>\n<p>\u00a0<\/p>\n<p>\n\n<h2 class=\"wp-block-heading\">Acknowledgement<\/h2>\n<p>Again, I used some images from <a href=\"https:\/\/pixabay.com\/de\/\" target=\"_blank\" rel=\"noopener\">Pixabay<\/a> for my post image. Many thanks to the creators:<\/p>\n<ul>\n<li>Smartphone: <a href=\"https:\/\/pixabay.com\/de\/users\/leo_romero-10193055\/?utm_source=link-attribution&amp;utm_medium=referral&amp;utm_campaign=image&amp;utm_content=4948812\" target=\"_blank\" rel=\"noopener\">Leo Romero<\/a><\/li>\n<li>Call icon: <a href=\"https:\/\/pixabay.com\/de\/users\/memed_nurrohmad-3307648\/?utm_source=link-attribution&amp;utm_medium=referral&amp;utm_campaign=image&amp;utm_content=1831936\" target=\"_blank\" rel=\"noopener\">Memed_Nurrohmad<\/a><\/li>\n<li>SMS symbol: <a href=\"https:\/\/pixabay.com\/de\/users\/openclipart-vectors-30363\/?utm_source=link-attribution&amp;utm_medium=referral&amp;utm_campaign=image&amp;utm_content=150505\" target=\"_blank\" rel=\"noopener\">OpenClipart-Vectors<\/a><\/li>\n<li>Arduino: <a href=\"https:\/\/pixabay.com\/de\/users\/seven_au-4857820\/?utm_source=link-attribution&amp;utm_medium=referral&amp;utm_campaign=image&amp;utm_content=2168193\" target=\"_blank\" rel=\"noopener\">Seven_au<\/a><\/li>\n<li>Arrows:<a href=\"https:\/\/pixabay.com\/de\/users\/clker-free-vector-images-3736\/?utm_source=link-attribution&amp;utm_medium=referral&amp;utm_campaign=image&amp;utm_content=297787\" target=\"_blank\" rel=\"noopener\"> Clker Free Vector Images<\/a><\/li>\n<\/ul>\n<p>I got the SIM800L from <a href=\"https:\/\/github.com\/Warlib1975\/Fritzing-parts\/blob\/master\/SIM800L.fzpz\" target=\"_blank\" rel=\"noopener\">Andrey Fedorov<\/a> on GitHub.<\/p>\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>With the SIM800L, you can add mobile phone functions to your projects, e.g. make calls or send measured values via SMS and much more. <\/p>\n","protected":false},"author":1,"featured_media":12890,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[565,1320],"tags":[1598,556,602,1590,1597,1596,1592,1546,1594,1599,1595,1591,1588,1589,1600,1593],"class_list":["post-13027","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-other-parts","category-wireless-en-2","tag-1418b05sim800l24-en","tag-arduino-en-2","tag-at-instructions","tag-call","tag-cipgsmloc-en","tag-cntp-en","tag-control","tag-firmware-en","tag-localization","tag-location-failed-en","tag-ntp-en","tag-sim-en","tag-sim800l-en","tag-sms-en","tag-synchronize","tag-whitelist-en"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>SIM800L module &#8226; Wolles Elektronikkiste<\/title>\n<meta name=\"description\" content=\"With the SIM800L, you can add mobile phone functions to your projects, e.g. make calls or send measured values via SMS and much more.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"SIM800L module &#8226; Wolles Elektronikkiste\" \/>\n<meta property=\"og:description\" content=\"With the SIM800L, you can add mobile phone functions to your projects, e.g. make calls or send measured values via SMS and much more.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module\" \/>\n<meta property=\"og:site_name\" content=\"Wolles Elektronikkiste\" \/>\n<meta property=\"article:published_time\" content=\"2021-11-19T20:45:07+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-10-10T19:30:15+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Beitragsbild_sim800l.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1340\" \/>\n\t<meta property=\"og:image:height\" content=\"1339\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Wolfgang Ewald\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Wolfgang Ewald\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"28 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module\"},\"author\":{\"name\":\"Wolfgang Ewald\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#\\\/schema\\\/person\\\/b774e4d64b4766889a2f7c6e5ec85b46\"},\"headline\":\"SIM800L module\",\"datePublished\":\"2021-11-19T20:45:07+00:00\",\"dateModified\":\"2025-10-10T19:30:15+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module\"},\"wordCount\":3822,\"commentCount\":16,\"publisher\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#\\\/schema\\\/person\\\/b774e4d64b4766889a2f7c6e5ec85b46\"},\"image\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2021\\\/11\\\/Beitragsbild_sim800l.png\",\"keywords\":[\"1418B05SIM800L24\",\"Arduino\",\"AT instructions\",\"call\",\"CIPGSMLOC\",\"CNTP\",\"control\",\"firmware\",\"localization\",\"location failed\",\"NTP\",\"SIM\",\"SIM800L\",\"SMS\",\"synchronize\",\"whitelist\"],\"articleSection\":[\"Other parts\",\"wireless\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module\",\"url\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module\",\"name\":\"SIM800L module &#8226; Wolles Elektronikkiste\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2021\\\/11\\\/Beitragsbild_sim800l.png\",\"datePublished\":\"2021-11-19T20:45:07+00:00\",\"dateModified\":\"2025-10-10T19:30:15+00:00\",\"description\":\"With the SIM800L, you can add mobile phone functions to your projects, e.g. make calls or send measured values via SMS and much more.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module#primaryimage\",\"url\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2021\\\/11\\\/Beitragsbild_sim800l.png\",\"contentUrl\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2021\\\/11\\\/Beitragsbild_sim800l.png\",\"width\":1340,\"height\":1339},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/sim800l-module#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Startseite\",\"item\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"SIM800L module\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#website\",\"url\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\",\"name\":\"Wolles Elektronikkiste\",\"description\":\"Die wunderbare Welt der Elektronik\",\"publisher\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#\\\/schema\\\/person\\\/b774e4d64b4766889a2f7c6e5ec85b46\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#\\\/schema\\\/person\\\/b774e4d64b4766889a2f7c6e5ec85b46\",\"name\":\"Wolfgang Ewald\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2019\\\/03\\\/cropped-Logo-1.png\",\"url\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2019\\\/03\\\/cropped-Logo-1.png\",\"contentUrl\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2019\\\/03\\\/cropped-Logo-1.png\",\"width\":512,\"height\":512,\"caption\":\"Wolfgang Ewald\"},\"logo\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2019\\\/03\\\/cropped-Logo-1.png\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"SIM800L module &#8226; Wolles Elektronikkiste","description":"With the SIM800L, you can add mobile phone functions to your projects, e.g. make calls or send measured values via SMS and much more.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module","og_locale":"en_US","og_type":"article","og_title":"SIM800L module &#8226; Wolles Elektronikkiste","og_description":"With the SIM800L, you can add mobile phone functions to your projects, e.g. make calls or send measured values via SMS and much more.","og_url":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module","og_site_name":"Wolles Elektronikkiste","article_published_time":"2021-11-19T20:45:07+00:00","article_modified_time":"2025-10-10T19:30:15+00:00","og_image":[{"width":1340,"height":1339,"url":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Beitragsbild_sim800l.png","type":"image\/png"}],"author":"Wolfgang Ewald","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Wolfgang Ewald","Est. reading time":"28 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module#article","isPartOf":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module"},"author":{"name":"Wolfgang Ewald","@id":"https:\/\/wolles-elektronikkiste.de\/en#\/schema\/person\/b774e4d64b4766889a2f7c6e5ec85b46"},"headline":"SIM800L module","datePublished":"2021-11-19T20:45:07+00:00","dateModified":"2025-10-10T19:30:15+00:00","mainEntityOfPage":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module"},"wordCount":3822,"commentCount":16,"publisher":{"@id":"https:\/\/wolles-elektronikkiste.de\/en#\/schema\/person\/b774e4d64b4766889a2f7c6e5ec85b46"},"image":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module#primaryimage"},"thumbnailUrl":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Beitragsbild_sim800l.png","keywords":["1418B05SIM800L24","Arduino","AT instructions","call","CIPGSMLOC","CNTP","control","firmware","localization","location failed","NTP","SIM","SIM800L","SMS","synchronize","whitelist"],"articleSection":["Other parts","wireless"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module#respond"]}]},{"@type":"WebPage","@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module","url":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module","name":"SIM800L module &#8226; Wolles Elektronikkiste","isPartOf":{"@id":"https:\/\/wolles-elektronikkiste.de\/en#website"},"primaryImageOfPage":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module#primaryimage"},"image":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module#primaryimage"},"thumbnailUrl":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Beitragsbild_sim800l.png","datePublished":"2021-11-19T20:45:07+00:00","dateModified":"2025-10-10T19:30:15+00:00","description":"With the SIM800L, you can add mobile phone functions to your projects, e.g. make calls or send measured values via SMS and much more.","breadcrumb":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module#primaryimage","url":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Beitragsbild_sim800l.png","contentUrl":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2021\/11\/Beitragsbild_sim800l.png","width":1340,"height":1339},{"@type":"BreadcrumbList","@id":"https:\/\/wolles-elektronikkiste.de\/en\/sim800l-module#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Startseite","item":"https:\/\/wolles-elektronikkiste.de\/en"},{"@type":"ListItem","position":2,"name":"SIM800L module"}]},{"@type":"WebSite","@id":"https:\/\/wolles-elektronikkiste.de\/en#website","url":"https:\/\/wolles-elektronikkiste.de\/en","name":"Wolles Elektronikkiste","description":"Die wunderbare Welt der Elektronik","publisher":{"@id":"https:\/\/wolles-elektronikkiste.de\/en#\/schema\/person\/b774e4d64b4766889a2f7c6e5ec85b46"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/wolles-elektronikkiste.de\/en?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/wolles-elektronikkiste.de\/en#\/schema\/person\/b774e4d64b4766889a2f7c6e5ec85b46","name":"Wolfgang Ewald","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2019\/03\/cropped-Logo-1.png","url":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2019\/03\/cropped-Logo-1.png","contentUrl":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2019\/03\/cropped-Logo-1.png","width":512,"height":512,"caption":"Wolfgang Ewald"},"logo":{"@id":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2019\/03\/cropped-Logo-1.png"}}]}},"_links":{"self":[{"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/posts\/13027","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/comments?post=13027"}],"version-history":[{"count":2,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/posts\/13027\/revisions"}],"predecessor-version":[{"id":25030,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/posts\/13027\/revisions\/25030"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/media\/12890"}],"wp:attachment":[{"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/media?parent=13027"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/categories?post=13027"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/tags?post=13027"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}