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.

C code for gsm interfacing with lpc2148

Status
Not open for further replies.

amanpreet001

Newbie level 4
Joined
Mar 19, 2015
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
44
Can anybody help me with the C code for interfacing GSM with LPC2148. I have previously worked on AVR. In need of a full C code as I am just a beginner in this..
 

aameer

Full Member level 4
Joined
May 12, 2010
Messages
216
Helped
33
Reputation
64
Reaction score
32
Trophy points
1,308
Location
Bangalore
Activity points
2,503
dear aman if you are beginner then you directly moving gsm is not good idea. do on serial communication and other things then you move on. Please try something and ask help. here everybody are there to guide you not to provide ready made stuff
 

amanpreet001

Newbie level 4
Joined
Mar 19, 2015
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
44
I have already done small programs like blinking LEDs etc but was having problem specifically in gsm and gps codes.
 

Attachments

  • gsmnew.txt
    3.2 KB · Views: 11

amanpreet001

Newbie level 4
Joined
Mar 19, 2015
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
44
Please correct me where am i wrong in the gsm code
as it is not sending any data..
 

aameer

Full Member level 4
Joined
May 12, 2010
Messages
216
Helped
33
Reputation
64
Reaction score
32
Trophy points
1,308
Location
Bangalore
Activity points
2,503
first u study what to send and recieve from GSM module.Which GSM Module are you using??
PHP:
PRODUCT NAME 	: GSM MODEM 
HARDWARE  	:  SIM 300 MODULE
COMMUNICATION 	: RS232
COMMANDS	: AT
INPUT VOLTAGE	: 12VDC / 1AMP   
*************************************************************************************************************************
ANTENNA  -  PULL THE ANTENNA OUT IF THE SIGNAL IS WEAK

HOW TO TEST!!!!

1. INSERT THE SIMCARD INTO SIM TRAY BACKSIDE 
2. CONNECT THE RS232 CABLE TO THE PC SERIAL PORT -  SERIAL PORT PROPERTIES ( RESTORE DEFAULTS - 9600 BAUD RATE)
3. OPEN HYPERTERMINAL FROM WINDOWS START>PROGRAMS>ACCESARIES>COMMUNICATIONS>HYPERTERMINAL
4. SELECT THE COMPORT WITH BAUD RATE 9600 
5. TYPE "AT " ECHO "OK" IF ECHO IS OK COMMUNICATION IS OK !!!!!!!!!+


6. CHECK THE LED STATUS ( NETWORK SERCHING , NETWORK CONNECTED, IS SHOWN IN LED STATUS GIVEN BELOW)
****************************************************************************************************************************
 Working state of network status indication LED OUTPUT

State SIM300 function

Off SIM300 is not running
64ms On/ 0.8SEC Off SIM300 does not find the network
64ms On/ 3 SEC Off SIM300 find the network
64ms On/ 300ms Off GPRS communication
*****************************************************************************************************************************

TO CHQ GAIN - AT+CSQ=?
TO CHK NETWORK - AT+COPS=?


Examples for send and receive SMS

For sending SMS in text Mode:

AT+CMGF=1 press enter
AT+CMGS=”mobile number” press enter
Once The AT commands is given’ >’ prompt will be displayed on the screen.
Type the message to sent via SMS. After this, press ctrl+Z to send the SMS.
If the SMS sending is successful, “ok” will be displayed along with the message number.


For reading SMS in the text mode:
AT+CMGF=1 Press enter
AT+CMGR= no.
Number (no.) is the message index number stored in the sim card. For new SMS, URC will be received
on the screen as +CMTI: SM ‘no’. Use this number in the AT+CMGR number to read the message.
Voice call
Initiating outgoing call:
ATD+ mobile number; press enter
For disconnecting the active call:
ATH press enter
For receiving incoming call:
ATA press enter



**************************************************USEFUL AT COMMANDS FOR SETTINGS *****************************************************************

TO CHANGE BAUDRATE  - AT+IPR=BAUDRATE(Ex 9600) 0-115200 For maore details refer AT commands Document page 33

TO SAVE THE SETTINGS AT&W

TO RESTORE FACTORY DEFAULTS TYPE AT&F THEN SAVE IT AT&W

***************************************************************************************************************************************
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top