Basics: Project 105d SIM900A GSM GPRS mini board – GSM security system

Basics: Project 105d

Project name: SIM900A GSM GPRS mini board GSM security system

Tags: SIM900A GSM GPRS module, Simcom, SIM900A GSM GPRS mini module, SIM900A GSM mini module, SIM900A mini module, Arduino Nano, Arduino IDE, Arduino, SIM900A GSM GPRS mini board, SIM900A mini v 3.8.2, SIM900A datasheet, SIM900A pinout, sim900a arduino code, sim900a gsm module pin diagram, gsm sim900a pin diagram, gsm sim900a interfacing with arduino, how to check sim900a gsm module, sim900a gsm module interfacing with arduino nano, sim900a gsm module interfacing with arduino uno, what is sim900a, does sim900a support 4G, doesn sim900a support 3G, what is GSM module, what is a sim900a GSM module, GSM SIM 900A module, sim900a gsm module, sim 900a gsm gprs module, SIM900A mini DEV board v 3.9.2, Arduino, Arduino Uno, GSM based Home Automation, GSM Alarm System, Security system, PIR sensor

Attachments: SIM900Asecuritysystemsketch

In this project, you needed these parts (Dear visitors. You can support our project buy clicking on the links of parts and buying them or donate us to keep this website alive. Thank you):

1. SIM900A GSM GPRS mini module 1 pc

SIM900A GSM GPRS mini board

2. Breadboard 1 pc

medium breadboard

3. Jumper cables F-M, M-M

jumper cables

4. PIR sensor HC – SR 501 or HC – SR 505 or Mini PIR Motion Sensor Module SC0322 1 pc

pir sensor
pir sensor

5. Standard SIM card 1pc

sim card sizes

6. SIM card size adapter (optional) 1 pc

sim card adapter

7. Arduino Uno R3 (you can also use the other version of Arduino) 1pc

arduino uno

8. Arduino IDE (you can download it here)

General

We will learn how to make a GSM security system (GSM alarm system) using Arduino Uno, PIR sensor and SIM900A GSM GPRS mini board. Whenever an unauthorized person is detected by PIR sensor a SMS message will be sent on the desired number.

Project steps:

  • The PIR sensor will detect movement (intruder) and the signal will be sent to Arduino Uno board digital pin.
  • Arduino Uno board through serial communication will communicate with the SIM900A GSM GPRS mini board.
  • The smartphone will receive the SMS message from the SIM900A GSM GPRS mini board about the movement.
  • Optional. It can be a relay module connected to the Arduino Uno which can be used to turn on a light or alarm sound as an indication that intruder is detected.
Project 105d

Understanding the PIR sensor

You can read more about it here.

Understanding the SIM900A GSM GPRS module

You can read more about it here.

Signals and connections of the PIR sensor

mini pir sensor
hc-sr501 pir sensor
mini pir sensor

We are going to use Mini PIR Motion Sensor Module SC0322 in this project.

Signals and connections of the SIM900A GSM GPRS module

sim900a GSM GPRS mini board

RS232 RXD – RS232 receive pin

RS232 TXD – RS232 transmit pin

5VT – 5V TXD transmit pin

5VR – 5V RXD receive pin

3VT – 3V3 TXD (SIMT) transmit pin

3VR – 3V3 RXD (SIMR) receive pin

GND – ground pin

VCC – power supply 5V pin

SIM900A pinout

sim900a pinout
  • VBAT – 3 VBAT pins are dedicated to connect the supply voltage. The power supply of SIM900A has to be a single voltage source of VBAT= 3.4V…4.5V. It must be able to provide sufficient current in a transmit burst which is typically rises to 2A
  • VRTC – Current input for RTC when the battery is not supplied for the system. Current output for backup battery when the main battery is present and the backup battery is in low voltage state. If the RTC function is enabled, a battery or capacitor should be connected with the VRTC pin. Otherwise the VRTC pin can be keep open.
  • VDD_EXT – 2.8V output power supply. If unused, keep open.
  • GND – Ground
  • PWRKEY – Voltage input for PWRKEY. PWRKEY should be pulled low to power on or power off the system. The user should keep pressing the key for a short time when power on or power off the system because the system need margin time in order to assert the software. It is already pulled up.
  • PWRKEY_OUT – Connecting PWRKEY and PWRKEY_OUT for a short time then release also can power on or power off the module.
  • MIC_P MIC_N – Positive and negative voice band input. If unused keep open
  • SPK_P SPK_N – Positive and negative voice band output
  • LINEIN_R LINEIN_L – Line input
  • DISP_DATA DISP _CLK DISP _CS DISP _D/C – Display interface. If unused keep open
  • STATUS – Indicate working status. If unused keep open
  • NETLIGHT – Indicate net status. If unused keep open
  • SCL – I2C bus clock. If unused keep open
  • SDA – I2C bus data. If unused keep open
  • KBR0~KBR4 – Keypad interface. If unused keep these pins open
  • KBC0~KBC4 – Keypad interface. Pull up to VDD_EXT, if unused keep pins open
  • RXD – Receive data. DTR Pin has been pulled up to VDD_EXT. If unused keep pin open
  • TXD – Transmit data
  • RTS – Request to send
  • CTS – Clear to send
  • RI – Ring indicator
  • DSR – Data Set Ready
  • DCD – Data carry detect
  • DTR – Data terminal Ready
  • DBG_TXD – Serial interface for debugging and firmware upgrade. If unused keep pins open
  • DBG_RXD – Serial interface for debugging and firmware upgrade. If unused keep pins open
  • SIM_VDD – Voltage supply for SIM card. The voltage can be select by software automatically either 1.8V or 3V
  • SIM_DATA – SIM data output. All signals of SIM interface are protected against ESD with a TVS diode array. Maximum cable length 200mm from the module pad to SIM card holder.
  • SIM_CLK – SIM clock
  • SIM_RST – SIM reset
  • SIM_PRESENCE – SIM detect. If unused keep open
  • ADC – General purpose analog to digital converter. If unused keep open. Input voltage range: 0V ~ 3V
  • NRESET – External reset input (Active low). If unused keep open.
  • PWM1 – PWM Output. If unused keep open.
  • PWM2 – PWM Output. If unused keep open.

Wiring

Project 105d SIM900A GSM GPRS mini board

Step by step procedure

1.Download, install and open Arduino IDE.

2. Insert standard Sim Card to Sim Card holder of SIM900A GSM GPRS mini board and lock it. Sim card must be unlocked and with credit.

SIM900A GSM GPRS mini board

3.Attach GSM/GPRS antenna to SMA connector of SIM900A GSM GPRS mini board.

4. Power up with 5V DC not more than 2A external power supply or attach to Arduino Uno. The ‘status LED’ (D5) will be on.

5.Do wiring. Plug in Arduino Uno board to your PC USB port.

6. Wait for some time (approx. 1 minute) and see the blinking rate of ‘network LED’ (D6). GSM module will use some time to establish connection with mobile network.

7. Once the connection is established successfully, the status/network LED will blink continuously every 3 seconds. You may try making a call to the mobile number of the sim card inside SIM900A GSM GPRS mini board. If you hear a ring back, the SIM900A GSM GPRS mini board has successfully established network connection.

8.Select the correct board and com port in Arduino IDE.

9.Open, modify, verify and upload the SIM900Asecuritysystemsketch to your Adruino Uno board. Make sure to change the phone number in the code to your own phone number.

Project 105d SIM900A GSM GPRS mini board

10. Open Serial Monitor at 115200 bps. When the PIR sensor detects movement (intruder) the SMS message will be send on your smartphone – “Intruder detected”.

11. That’s it! Happy coding!

Code

First, we need to add the software serial library so we won’t have to remove the TX or RX pins while uploading the code. Any message we are going to send will be stored in the outgoingData string. Then we define the pin where PIR sensor is attached.

In setup() we set the communication rate at 115200 bps and baudrate for SIM900A GSM GPRS mini board – 19200 bps.

When motion detected by PIR sensor (signal is HIGH) the SMS message is sent. Make sure to change the number in the code to your own phone number.

Summary

We have learnt how to make a GSM security system (GSM alarm system) using Arduino Uno, PIR sensor and SIM900A GSM GPRS mini board.

Libraries

SoftwareSerial library included in Arduino IDE.  The library has the following known limitations:If using multiple software serial ports, only one can receive data at a time.Not all pins on the Mega and Mega 2560 support change interrupts, so only the following can be used for RX: 10, 11, 12, 13, 14, 15, 50, 51, 52, 53, A8 (62), A9 (63), A10 (64), A11 (65), A12 (66), A13 (67), A14 (68), A15 (69).Not all pins on the Leonardo and Micro support change interrupts, so only the following can be used for RX: 8, 9, 10, 11, 14 (MISO), 15 (SCK), 16 (MOSI).On Arduino or Genuino 101 the current maximum RX speed is 57600bpsOn Arduino or Genuino 101 RX doesn’t work on Pin 13 The library has the following known limitations: If using multiple software serial ports, only one can receive data at a time;Not all pins on the Mega and Mega 2560 support change interrupts, so only the following can be used for RX: 10, 11, 12, 13, 14, 15, 50, 51, 52, 53, A8 (62), A9 (63), A10 (64), A11 (65), A12 (66), A13 (67), A14 (68), A15 (69);Not all pins on the Leonardo and Micro support change interrupts, so only the following can be used for RX: 8, 9, 10, 11, 14 (MISO), 15 (SCK), 16 (MOSI);On Arduino or Genuino 101 the current maximum RX speed is 57600bps; On Arduino or Genuino 101 RX doesn’t work on Pin 13. You can read about it here.

Sketch

  • See attachment on the begining of this project description.

AcoptexCom

Leave a Reply

Your email address will not be published.