Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

I need help please GSM Alarm projects and read sms

Status
Not open for further replies.

turkbey

Newbie level 4
Joined
Sep 2, 2007
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,327
Hi every budy, My GSM alarm project, I want to send the event of an alarm message to 3 people, but it took 3 people to read and micro phone number via SMS, then save it somewhere and need to send messages to the alarm during this 3 mikrobasic, or C, how can I do it? My GSM module M95
thanks
 

but it took 3 people to read and micro phone number via SMS, then save it somewhere and need to send messages to the alarm during this 3 mikrobasic, or C, how can I do it?


Can you explain this....
 

Thanks for yours interested.
Now my project like this
When get a new message
1-Read message may be like this "+901234567890"
then write "01234567890" to eeprom(in SMS message phone number)
get 2. phone numberlike this
and get 3. phone number like this
Than wait a response from alarm sensors
if get a response then send a messages 1,2, and 3 phone numbers "ALARM ALARMé type
 

you want the number to be send in sms or taken from the sending mobile?
 

No dear rajudp;
first useing the system and becase first time useing the micro isn't know when the get alarm response which number send a message
so I want send to first time and first messages like this for "user1=+90XXXXXXXX" then sen a second messages"user2=+90YYYYYY"
when the GSM is received messages write user1 phone number is to EEPROM and than setup is OK
when the alarm response then +CMGS= user1 "ALARM ALARM" like this
 

you can use any micro controller with serial port, use serial interrupt and store the receive message in a buffer , from the program check the buffer count for a valid message length and chech message
 

No dear rajudp;
first useing the system and becase first time useing the micro isn't know when the get alarm response which number send a message
so I want send to first time and first messages like this for "user1=+90XXXXXXXX" then sen a second messages"user2=+90YYYYYY"
when the GSM is received messages write user1 phone number is to EEPROM and than setup is OK
when the alarm response then +CMGS= user1 "ALARM ALARM" like this

rajudp is correct, use a syntax(your own) for the first messages when you receive the numbers. That will help you to get the numbers from the message in your program. I think you can receive all the three numbers in a single message. The advantage of using syntax is that you can change the numbers later by another(or same) message, also no need to count the buffer.;-)
 

Yes anzillhan I think Like this "user10XXXXXXXuser2YYYYYYYY" then usart_read_textuser1 ....
but How can I get nubers after user1 text? and which command to to count ?
 

I don't know your device and IDE.

any way read the usart and store it to a character array.
Now since you know the syntax, you know the position of your no.
Write it to your eeprom.
 

you can send all numbers in one sms, normally the numbers will be in 10 digits you can sms like 123456xxxx123456yyyy123456zzzz for numbers or you give a message start indicator before the numbers ( any special characters not comes with a default sms , don't use '+' there will be more '+' sine in a single sms if using '+' sine you have to check for the next character also
 

From the serial port (TX pin of the GSM module) you found
<CR><LF>
+CMGR: "REC UNREAD","+880123456789",,"12/07/26,00:07:36+24"<CR><LF>
(SMS body)<CR><LF>
<CR><LF>
OK<CR><LF>

21th offset From the first + sign is the number start.
I think Anzilkhan is correct. You can send the number in one sms. So that you can found the number in the sms body. read the sms body and save the number into the EEPROM. That's not very complex.
 

From the serial port (TX pin of the GSM module) you found
<CR><LF>
+CMGR: "REC UNREAD","+880123456789",,"12/07/26,00:07:36+24"<CR><LF>
(SMS body)<CR><LF>
<CR><LF>
OK<CR><LF>

21th offset From the first + sign is the number start.
I think Anzilkhan is correct. You can send the number in one sms. So that you can found the number in the sms body. read the sms body and save the number into the EEPROM. That's not very complex.

i normally do start the sms with a symbol other than '+' and wait for that symbol and store the remaining to buffer as message
 

i normally do start the sms with a symbol other than '+' and wait for that symbol and store the remaining to buffer as message

rajudp, yes you are right if you want to read the sms body. But If you want to read the sender number of the sms then you have to consider from the + sign. But for this project, I think your idea is right. it should make a sintex in the sms to read all three numbers.
 

Ok sir so,How can I send SMS from phonebook enteryAny AT command have M95 modulelike ths AT+CMGS=phonebookindex may be I use AT command
Thanks for all
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top