SMS Controlled Car Alarm Security System

SMS Controlled Car Alarm Security System

     It’s been awhile that I have last posted my projects here since I have helped my friends build their Senior Year Design Project. Now, it is finally done and I will be so happy to share it here. The project is all about a cellphone that will inform the user through Short Message Service (SMS) when an intruder triggered the alarm. Using the AT Commands the serial communication with the phone and the microcontroller was made possible.

     The project comes into a case but temporarily removed for the presentation to the panel of judges since the case wont fit on the prototype.

     There are two ways of sending and receiving SMS messages: by text mode and by PDU (protocol description unit) mode. The text mode (unavailable on this phone) is just an encoding of the bit stream represented by the PDU mode. The phone used was Sony Ericsson T68i and the only mode supported is PDU mode. It was a headache at first since I can only see hexadecimal figures but as time goes by I got used to it.

Phone used:

Sony Ericsson T68i

AT Commands used:

AT – check if the phone is connected
ATE(0 or 1) – 0=echo off 1=echo on
AT+CMGF=0 – pdu mode
AT+CMGS – *enter write pdu code *ctrl Z
AT+CMGR=(index or position of the message on the inbox) – read the message indicated on the index
AT+CPBS=”me” – select phonebook storage
AT+CPMS=”me”,”me”,”me” – select read/delete storage, write/send storage, received storage; (me means phone while sm means sim)
AT+CMGD=(index),0 – delete message on index number specified
AT+GMM – cellphone model
AT+GMI – cellphone manufacturer

*when the phone is switched off all the settings are set back to its default settings so they should always be set up on the program to avoid problems on the microcontroller and phone communication.

How does the system function:

     Ports are set at first, Universal Asynchronous Receiver/Transmitter (UART) is initialized and a first check is done if the phone is turned ON or if it is connected. The Yellow LED then will light if a phone is detected. The microcontroller then will send a command to the phone to send to the user that the System is available and to wait for few seconds because everything is still being set up. After that the Red LED will light signifying that the phone is being set to settings that will help the microcontroller recognize the messages sent to the phone. When all is set the Red LED will stop blinking and the Orange LED will then light up implying that the Alarm is OFF by default. The phone then will send to the user that everything is ready and the alarm can now be turned on. The phone can be turned on by sending text message following the right format indicated on the second text message sent by the microcontroller. When the Alarm is turned on then the Blue LED will light and the Orange LED will turn off. When a disturbance occured, the microcontroller then will turn the siren on and it will send to the user that an intruder has been detected. The siren can only be turned off by sending the proper message format or if the system is turned off by switch. An additional feature was added here which is the sending of invalid password notification.

LED Indicators

LED Indicators

     The microcontroller used here was PIC16F877A. The shock sensor is connected to the RB0/INT pin. The SIREN is connected to the RD6 pin.

Schematic Diagram

Schematic Diagram

Check out the DEMO video here:


11 responses to “SMS Controlled Car Alarm Security System

  1. hey there im doing the same project and im from singapore….can i have your source code just for testing purposes pls….can u email me your c code to…thanks alot man i really appreciate it alot.

      • hey lloydi, can i have you full information on your project….including c code, schematics, for reference purposes….i would be really great full,i hope u dont mind dude…

      • hi lifiq, sorry I think that wont be possible. If you want, you can buy the whole project information since it is a thesis project. It took a lot of money, time and effort to accomplish this project. This project is the only project available on the web that uses T68i phone and can send/receive sms. Unlike other projects using this kind of phone, they can only send messages (like from this link The hardest part is reading the text message. I am selling the project to people including the prototype only for people near on our places. I can also build them new ones if they want me to. If you are interested, I can sell you the codes, schematics and instructions since I think sending the prototype will be not so easy. All left for you to do is just to buy the necessary materials for you to do the project there on your place and follow my step by step guidelines that I will provide. BTW, I am from Philippines. If you don’t want to buy, you can do it and I’ll just guide you but please start it first by yourself. I don’t really tolerate spoon-feeding.

  2. hi lloydi..nice work..ganito din na project ang ginagawa namin ngayon kaso lang ginagamit kong phone ay sony ericson t29i..pwd po ba makuha ang c code ng project mo?may nagawa na akong code kaso lang nagnacocontrol lang ito ng relay gamit ang sms..sige na po sir kahit ang code lang ng project po..xa ng pala kung bibilhin ko project mo,magkano?ito po email ko

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s