zaid2000
Newbie level 1
GSM serial port problem
Hi all..
I'm a student in final year project. My prject is about run a home device by sending a sms from mobile, the message will be recieved by GSM modem connected to board via serial prot,I'm using MicroBasic language and PIC16F877A, Here is some parts of the code:
USART_INIT(9600)
USART_WRITE_TEXT("AT+CMGF=1") 'CHANGE MSG FORMAT
USART_WRITE(13)
USART_WRITE(10)
DELAY_MS(300)
USART_WRITE_TEXT("AT+CMGR=1") 'READ LAST MESG
USART_WRITE(13)
USART_WRITE(10)
DELAY_MS(300)
IF (Y[0]= "1") THEN 'if the msg is "1" then protb.0=1
PORTB.0 = 1
END IF
I think i did everthing right but the problem is that when i send the message it does't work!!!!! !, can anyone help me please.
Ps I also gonna attach the code....PLEASE HELP
Hi all..
I'm a student in final year project. My prject is about run a home device by sending a sms from mobile, the message will be recieved by GSM modem connected to board via serial prot,I'm using MicroBasic language and PIC16F877A, Here is some parts of the code:
USART_INIT(9600)
USART_WRITE_TEXT("AT+CMGF=1") 'CHANGE MSG FORMAT
USART_WRITE(13)
USART_WRITE(10)
DELAY_MS(300)
USART_WRITE_TEXT("AT+CMGR=1") 'READ LAST MESG
USART_WRITE(13)
USART_WRITE(10)
DELAY_MS(300)
IF (Y[0]= "1") THEN 'if the msg is "1" then protb.0=1
PORTB.0 = 1
END IF
I think i did everthing right but the problem is that when i send the message it does't work!!!!! !, can anyone help me please.
Ps I also gonna attach the code....PLEASE HELP