Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Remote Control by cellphone...

Status
Not open for further replies.

KaJuan

New Member
Hello!


I am a 5th Yr. Computer Engineering student. As a 5th Yr. Computer Engineering student we are required to have a senior project in order for us to graduate. My senior project is entitled "Remote control using cellphone".

The object of my project is to send remote control commands using a cellphone (SMS). The usser sends command using the a cell phone. The device to be controlled is to be connected to another cellphone via an interfacing box. The cellphone connected to the device that is to be controlled will extract the SMS recieved by the cell phone and determine if this is a valid command. If it is a valid command it will output a cooresponding control signal to the device being controlled.

I have learned that the cellphone communicates with external devices via its port serially, using the RS232 format at 9600 baud rate. The problem is the voltage level of the pin. I dont know what voltage level will be considred high logic and what voltage level will be considered low logic. Another problem is the microcontroller to be used in this project. The only microcontroller I am familiar with are the Microchip PIC series microcontroller, specifically the PIC16F84A. Can I use the PIC16F84A for this purpose? If yes, how am I to program that pic? Do you have any source codes?

Hope somebody could help me (anything as long as it is related to my project)....


Thank you... and Merry Christmas to ALL!!!!!!!!!
 
KaJuan said:
Hello!


I am a 5th Yr. Computer Engineering student. As a 5th Yr. Computer Engineering student we are required to have a senior project in order for us to graduate. My senior project is entitled "Remote control using cellphone".

The object of my project is to send remote control commands using a cellphone (SMS). The usser sends command using the a cell phone. The device to be controlled is to be connected to another cellphone via an interfacing box. The cellphone connected to the device that is to be controlled will extract the SMS recieved by the cell phone and determine if this is a valid command. If it is a valid command it will output a cooresponding control signal to the device being controlled.

I have learned that the cellphone communicates with external devices via its port serially, using the RS232 format at 9600 baud rate. The problem is the voltage level of the pin. I dont know what voltage level will be considred high logic and what voltage level will be considered low logic. Another problem is the microcontroller to be used in this project. The only microcontroller I am familiar with are the Microchip PIC series microcontroller, specifically the PIC16F84A. Can I use the PIC16F84A for this purpose? If yes, how am I to program that pic? Do you have any source codes?

Hope somebody could help me (anything as long as it is related to my project)....

First thing is to find out what the output from the phone actually is - you can do that with an oscilloscope. If it's TTL level you can feed straight in a PIC pin, if it's RS232 you can use a MAX232 (or even a crude resistor interface).

The PIC16F84A should be fine for what you want, depending what you need to do even the smaller 8 pin PIC's could well be enough.

Probably your first thing to do (after finding out the phone output levels) is to connect it to a PC and monitor what comes out - you can then find exactly what you need the PIC to do.
 
A quick search using google gives the ff. links:

http://www.gnokii.org/faq.shtml



**broken link removed**

http://www.mwiacek.com/

You might connect one cellphone to the PC using commercially available download cables. Reverse engineer these cables to give you some idea on how to interface them to the PIC.

BTW, the PIC16F84a does not have a asynchronous serial port and so you may have to synthesize one using software. The newer and cheaper PIC16F627 has the USART built-in, saving you one software headache.
 
motion said:
BTW, the PIC16F84a does not have a asynchronous serial port and so you may have to synthesize one using software. The newer and cheaper PIC16F627 has the USART built-in, saving you one software headache.

This can be an advantage, it's extremely simple to do RS232 in software (hardly any more complicted than using the hardware USART) - and it give the possibility of running in either polarity. The inbuilt USART's are designed to connect to a MAX232 (which inverts the polarity), and usually require a hardware inverter if not using a MAX232.
 
Thank You

Thank you all for helping me in my project by giving me those cool sites, indeed they are useful in the development of my project.


I keep you posted for every developement of my project...


Thanks onece again... Happy Hew Year to ALL !!!!!!!!!
 
about Mr. Nigel Goodwin's PIC Board that has pic16f628

Sir, I have visited your site about pic spicifically the RS232 communications. The tutorial needs the MAIN BOARD that has the PIC16F628. I have notice that board does not include a system clock. Why is this so? Can a microcontroller work even though it does not have a system clock?
 
Re: about Mr. Nigel Goodwin's PIC Board that has pic16f628

KaJuan said:
Sir, I have visited your site about pic spicifically the RS232 communications. The tutorial needs the MAIN BOARD that has the PIC16F628. I have notice that board does not include a system clock. Why is this so? Can a microcontroller work even though it does not have a system clock?

As explained in the text on the main page, I used the 16F628 because it has an internal 4MHz oscillator - by selecting that in the fuse settings, along with no MCLR pin, it leaves 16 I/O pins free on an 18 pin chip.
 
about the PIC main board

Thank you verys much sir...

I wasn't able to read that text... I will now... Thank you very much...
 
microcontroller to be use

Sir, I already have studied a bit of your tutorial about RS232 communications using the PIC16F628 microcontroller. Would this microcontroller fit my application? or will I have to move to a higher version? PIC16F876? I am still studying the software emulation of the USART using the PIC16F628. I haven't touch the USART capability of the PIC16F628 yet... Any advice?


Thank you in advance.... More power...
 
Re: microcontroller to be use

KaJuan said:
Sir, I already have studied a bit of your tutorial about RS232 communications using the PIC16F628 microcontroller. Would this microcontroller fit my application? or will I have to move to a higher version? PIC16F876? I am still studying the software emulation of the USART using the PIC16F628. I haven't touch the USART capability of the PIC16F628 yet... Any advice?

I should think it would be fine, you don't need loads more I/O pins, and you don't need any of the extra hardware facilities offered by the 16F876. Although the 16F628 'only' has 2K of program memory, that's an awful lot of assembler! - I doubt you will use anywhere near that amount.
 
Thank you sir!!!!

I don't know if I still have questions about my project, but if I do I'll just post it here again.... thank you onc again for replying....
 
capacitors used in your RS232 board

Sir I seen in the MAX232 dat sheets that the capacitors used are all 1uF. How com in your RS232board the capacitor you used were not all 1uF?
 
Re: capacitors used in your RS232 board

KaJuan said:
Sir I seen in the MAX232 dat sheets that the capacitors used are all 1uF. How com in your RS232board the capacitor you used were not all 1uF?

The values aren't 'cast in stone', those I used came off a datasheet as well, they are only used as charge pumps to genertte the +10V and -10V for the RS232, so (to some extent) larger is better.
 
Transmit and Receive Subroutine for Fullduplex RS232 Comm.

Sir will the transmit and receive subroutine for the Half Duplex 8N1 RS232 communication work for Full Duplex 8N1 R2232? They also differ in baud rate but I have already figured out how to reconfigure the routine so it would work for faster baud rate.
 
Re: Transmit and Receive Subroutine for Fullduplex RS232 Com

KaJuan said:
Sir will the transmit and receive subroutine for the Half Duplex 8N1 RS232 communication work for Full Duplex 8N1 R2232? They also differ in baud rate but I have already figured out how to reconfigure the routine so it would work for faster baud rate.

The existing routines are half duplex only, for full duplex you really need a hardware USART and interrupt routines. There are various full duplex routines in MicroChip application notes. Personally I've never felt the need for full duplex.
 
this project is a lot easier than you might think..

all you need to do is master the usrt on the pic ie get it to send and receive exact commands to the pc. then all you have to do is a direct connection from pic's rx and tx pins to mbile and share gnds and guess what you are done.

Now the hardest part here is testing what the uart receives because it will receive a different no. of bytes for different commands and thats a total *****. Im using a circular buffer and maybe malloc to create dynamic array that grows according to <cr> position.

Any more q's just ask but note i havnt used pics in a while but 8051's z8 and avr so be patient
 
I have a similar problem.

I have already finished the interfacing between the cellphone and the PIC
My problem now is how will i program my controller according to what i want. I have very little knowledge in programming stuffs.
My project is a free-call unlocker. the door would only open for certain numbers calling on the cell phone. Then it will automatically be locked again 20 seconds after the call ended. a keypad is connected in order to add and delete contacts numbers that could open the door. but before you could add or remove a number you will be ask to enter a password. if the password entered is incorrect for three consecutive tries. an alarm will be triggered. thats pratically what my project do. i hope you could help me program PIC16F84.

thanks a lot.
 
Re: I have a similar problem.

hollywood_aka_ace said:
I have already finished the interfacing between the cellphone and the PIC
My problem now is how will i program my controller according to what i want. I have very little knowledge in programming stuffs.
My project is a free-call unlocker. the door would only open for certain numbers calling on the cell phone. Then it will automatically be locked again 20 seconds after the call ended. a keypad is connected in order to add and delete contacts numbers that could open the door. but before you could add or remove a number you will be ask to enter a password. if the password entered is incorrect for three consecutive tries. an alarm will be triggered. thats pratically what my project do. i hope you could help me program PIC16F84.

thanks a lot.


You need to go to etsi.com and download some pdf's on gsm standards for at command sets. These are big and there are many, also hard to understand so get cracking...
 
I have a 370 page manual for GSM cellular modem commands. Took forever to print out and punch holes in it.
 
sneding and receiving data in Full Duplex RS232

Sir I have a question with regards to how the PIC sends and receives in full duplex mode. In a full duplex RS232, will the sending and receving of data happen at the same time? If so how will the PIC handle this since it is only capable of doing once task either by receving or trasmitting. I also have a problem with how the PIC will receive the data replied by the cell phone after you sent the cellphone a certain command. The no. of bytes the PIC will receive is dependent ont ehkind of command the or data teh cellphoen will sned back to the PIC. How will you solve this, my first concept is through the use of arrays. How will you do it? Could you send me a code snipet or code example of it?
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top