Click here to Skip to main content
15,909,835 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
please i would like to know how to execute AT command using c++.I am working on a c++ application that needs to send an SMS message.
i would like to know if there are any functions that can do that.
i am uisng a GSM/GPRS modem

thanks in advance
Posted

 
Share this answer
 
Comments
Albert Holguin 13-Jun-11 15:46pm    
only 12.4M? :P
CPallini 13-Jun-11 15:50pm    
12.4 MILLIONs?
There's too much confusion,
I can't get no relief.
Not in C++, your modem should probably have some sort of device dependent API or control mechanism for interfacing programmatically, but C++ doesn't. There may also be libraries available to help you achieve this faster, but you'll have to look for these specifically.

Essentially what you need to learn is how to establish serial communications then pass/receive commands and responses from your modem.

Here's an example (but it's in C#):
http://65.39.148.41/KB/IP/Send_and_Read_SMS.aspx?display=Normal&fid=1544794&df=90&mpp=25&noise=3&sort=Position&view=Quick&select=3772649&fr=206&prof=False[^]
 
Share this answer
 
v2
AT+CMGS is what you need. Start with this[^] and this[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900