March 25, 2016

0 Comments

Using the SIM800 Dev Board with Gizduino V – Part 1

The SIM800 GSM/GPRS Dev module is a full featured GSM/GPRS module packed with more features as compared to the SIM900. This module have inbuilt Bluetooth stack compliant with 3.0+EDR, MMS, FTP, TCP/IP, email and Micro SD support in addition to the standard features of the SIM900. The good thing about this module is that AT commands from the older dev board based on the SIM900 is compatible with this new module. Upgrading is easy, just plug and play. This particular Dev Module from E-Gizmo Mechatronix Central has on board reliable LDO regulator that allows a wide range of power supply voltage without tripping the SIM800 module, on board buffered LED status indicators, onboard micro SD card socket, SMA RF connector and unpopulated header pads for easy access to all pin functions of the SIM800.

SIM800 GSM/GPRS Dev Module

SIM800 GSM/GPRS Dev Module

First we will be using the SIM800 to send a message when a button is pressed and turn on/off a LED using SMS. In this setup we will be using the Gizduino V (ATMega 328 Based Arduino Compatible Module), LED’S and push button switches and Arduino 1.6.8 IDE. We will not be using any other external libraries aside from the SoftwareSerial library. The Hardware serial of the Gizduino V is used for debugging and programming. The figure below shows the test setup wiring.

Setup

Wiring Diagram of the Setup (Click to Enlarge)

First, we initialize some variables for for storing messages, storing receivers number where our SMS will be sent, also we include the SoftwareSerial library. In addition a macro is added to enable or disable debug messages to the Hardware Serial. Most of the functions are based on the SIM900 routines from Cooking Hacks.

SMS_1

Next we setup all the necessary GPIO pins where LED’s and switches are connected, initialize the hardware serial, software serial used to communicate with the modem, and call the initialization routine for the SIM800.

SMS_2

Before we go through the other functions, we take a look on how we send the AT Command to the modem using this code:

SMS_1

Since we communicate with the modem using AT Command, we make use of the above code to send the command, and wait for its response. It is important to know the response so that we could track the errors.

To initialize the SIM800, we first connect to the network, then delete all message and we set the modem to text mode. As compared to the SIM900, we need to power on the SIM900 on its PWON pin before we start the communication, the firmware of this SIM800 has auto power on as soon as the input power is connected.

SMS_4

To send an SMS, we issue the AT+CMGS command to the modem

SMS_5

For us to use SMS to turn on or off devices, we need a routine to receive SMS, as compared to sending SMS, when a message is received, we use several routines to handle the message so that we could extract the information that we want. The modem will issue a +CMTI when a new message is received in the following format +CMTI: “SM”,11 where 11 is the location of the message in the memory. We are interested with the location of the message in the memory,  because we will need the location when we issue the AT+CMGR command to read the new message.

SMS_7

When we get the location of the message, we issue the AT+CMGR command to the modem

SMS_8

To handle the new message from the previous command, we use the following code

SMS_9

Additionally, we need the functions below so that we always process a complete message from the modemSMS_10

And a function to wait for new messages, we use the function below inside the loop to continuously check for new messages.

SMS_11

Finally, we process the data inside the loop, to turn on or off devices, we compare the contents of the message buffer to a pre-defined keyword.

SMS_12_a

To send a message when a button is pressed, we check the state of the button and use the SendSMS function to send a message to a predefined number.

SMS_12_b

That’s it! Happy Coding! See you on the next part.

 

Continue reading...

February 10, 2016

0 Comments

What’s New with PhilRobotics Version 2.0?

Like a Phoenix being reborn, PhilRobotics is celebrating Chinese New Year 2016 (year of the Fire Monkey) by adding more interesting contents in our website. That means more featured projects from our elite members, more events to cover and we are also going to do some fearless reviews on some electronic gadgets and products (so […]

Continue reading...

January 17, 2015

2 Comments

Sending SMS with IOT-644 Board, ThingSpeak and Chikka API

This article will show you how to add SMS capabilities to your IOT based projects. This article is based on gizDuino IOT-644 arduino compatible board based on ATmega644 and Wiznet W5500 Ethernet chip, ThingSpeak and chikka API.   Arduino do not have native support for HTTPS protocol so we will use Thingspeak to trigger the […]

Continue reading...

October 12, 2014

2 Comments

Reading RFID tags with C# and RDM630

  The RDM630 Proximity Reader Module is a low cost 125 kHz RFID  Proximity reader. It uses uEM 4100 or compatible card with  64 bit Manchester encoding and outputs the data to its serial port at 9600 baud. With this, RFID tags can be easily read by C# using the serialport module and can be integrated […]

Continue reading...

September 23, 2014

0 Comments

PBOT Graphical Programming with miniBloq

  The PBOT is an entry level robotics platform that features 3 IR Collision Sensors, 3 Line Sensors and a 2 channel Motor driver. It is Compatible with all Gizduino Boards (An arduino derivative board) and all arduino form factor boards. It is a good starting point for beginners in the field of robotics. Line Follower, Sumo […]

Continue reading...

September 19, 2014

0 Comments

Hacking a cheapo PIR for projects

This cheap PIR sensor with LED light is an eye catcher for hacks at only 150 Philippine peso. A generic PIR based on the LP0001 PIR controller chip and can readily be used for projects. The circuit reveals a basic circuit based on the datasheet of the controller chip, the signal from the output pin can […]

Continue reading...

September 18, 2014

0 Comments

Getting Started with the E-Gizmo IOT644

Today, we live in the Internet era where everything can be seen or controlled online. Internet of Things are becoming more and more popular. For us makers, the E-Gizmo IOT-644 board is a great starter board to build IOT projects. It is based on Atmel Atmega 644, double the memory and RAM of the Uno and […]

Continue reading...

August 12, 2013

0 Comments

Philrobotics interviewed by Vigattin radio program

(Photo grabbed from http://vigattintourism.com/tourism/articles/Vigattin-Radio-with-Project-NOAH-and-PhilRobotics) Philrobotics has been interviewed last Saturday, August 10, 2013,  by Vigattin radio program (DZIQ 990kHz) along with Project Noah and International Rice Research Institute’s (IRRI) Bigas Hackathon organizer Ms. Bianca Ferrer. It was great looking back at how we’ve won the 1st Bigas Hackathon with lack of planning and the only […]

Continue reading...
.