Microcontroller › 8051 › Help about GSM interfacing with 8051 › Refering to the command 4.2.5
Refering to the command 4.2.5:AT+CMGS from SIM900 AT command set I hope:
In the else loop,after transmitting the mobile number it is sufficient to send 0X0D.Not necessary to send 0X0A.
And also try without using ’’ before and after the number.
I have used the following code pattern for entering the mobile number:
AT+CMGS=”1234567890”
After sending this line just send ‘r’ i.e..,0X0D.But 0X0A is not necessary.
A delay of 300ms worked for me to transmit the text after transmitting number.
And also try without using ’’ before and after the number.
The below code pattern worked for may work for you:
char mobno[]="AT+CMGS="8308941641"";
tx_data(0x0D);
delay(50000); //uncomment this delay to about 300ms. it is necessary while interfacing with uC
tx_string(message,43);
tx_data(0x1A);
The rest of the code is same.