stephansbest
Newbie level 4
- Joined
- Jan 28, 2014
- Messages
- 7
- Helped
- 0
- Reputation
- 0
- Reaction score
- 0
- Trophy points
- 1
- Activity points
- 53
Hi guys i am working on a project which requires that i send an sms to a phone using sim300 gsm module.I am using pic basic pro, but the test is not been sent
ild be glad if you can help....
i am using pic 16f876a and sainsmart sim300 gsm/gprs module,below is my code
INCLUDE "modedefs.BAS"
Thank you!
ild be glad if you can help....
i am using pic 16f876a and sainsmart sim300 gsm/gprs module,below is my code
INCLUDE "modedefs.BAS"
Code:
TRISC=%10000000
G1 VAR PORTC.6
G2 VAR PORTC.7
rec var WORD
LED VAR PORTC.0
PAUSE 1000
SEROUT PORTC.6,9600,["AT"] 'check to see if gsm is working
PAUSE 2000
SEROUT PORTC.6,9600,["AT+CMGF = 1",13] 'set the sms mode to text
PAUSE 2000
SEROUT PORTC.6,9600,["AT+CSMP = 17,167,0,0",13] 'set text mode parameters
PAUSE 2000
HIGH G1
serout PORTC.6,9600,["AT+CMGS =",34,"+233501371821",34,13] 'send text to this number
pause 200
serout PORTC.6,9600,["GAS LEAKAGE DETECTED AT HOME PLEASE ATTEND TO IT",26]
Thank you!
Last edited by a moderator: