Can you please tell me how to interface GSM modem (sim 300) to microcontroller (AT89C51)to send sms?
I need assembly program for the same..
I have prepared my own but it is not working:
here it is:
connections:
GSM modem has following on-board connections:
MAX232----->> RS232 (Female connector)
pin 7 ---> Pin 2
pin 8 ---> Pin 3
So i have done following connections after this:
RS232 (Female connector) --->> RE232(PCB male connector ) ( This o did because it was difficult to take connections from on-board Female connetor)
I took out following pins from RS232 male connector and connected to microcontroller:
RS232(PCB male connector ) ---> AT89C51
Pin 2 --> Pin 11
Pin 3--> Pin 10
Pin 5 Grounded.
Rest AT89C51 connetions:
Crystal oscillator 12 Mhz.
EN (Pin 31) -VCC
Pin 40-- VCC
Pin 20-- Gnd
Are these connetions are correct??
why my program is not working ??
can any one tell me assembly program to interface the same?
I need assembly program for the same..
I have prepared my own but it is not working:
here it is:
Rich (BB code):
ORG 0000H
MOV TMOD,#20H //TIMER 1, MODE 2
MOV TH1,#-3 //9600 BAUD RATE
MOV SCON,#50H //8 BIT, 1 STOP, EN ENABLED
SETB TR1
MOV DPTR,#MSG1
ACALL H1
ACALL DELAY
MOV DPTR,#MSG2
ACALL H1
ACALL DELAY
MOV DPTR,#MSG3
ACALL H1
ACALL DELAY
MOV DPTR,#MSG4
ACALL H1
ACALL DELAY
MOV DPTR,#MSG5
ACALL H1
ACALL DELAY
STAY: SJAMP STAY
H1: CLR A
MOVC A,@A+DPTR
JZ B1
ACALL SEND
INC DPTR
SJMP H1
B1:
RET
SEND: MOV SBUF,A
H2: JNB TI,H2
CLR TI
RET
DELAY: MOV R3,#50H
HERE2: MOV R4,#50H
HERE: DJNZ R4,HERE
DJNZ R3,HERE2
RET
ORG 300H
MSG1: DB "AT",0DH
DB 0H
MSG2: DB "AT+CMGF=1",0DH
DB 0H
MSG3: DB "ATE=0",0DH
DB 0H
MSG4: DB "AT+CMGS=",'"8149111111"',0DH
DB 0H
MSG5: DB "TEXT",0X1A
DB 0H
END
GSM modem has following on-board connections:
MAX232----->> RS232 (Female connector)
pin 7 ---> Pin 2
pin 8 ---> Pin 3
So i have done following connections after this:
RS232 (Female connector) --->> RE232(PCB male connector ) ( This o did because it was difficult to take connections from on-board Female connetor)
I took out following pins from RS232 male connector and connected to microcontroller:
RS232(PCB male connector ) ---> AT89C51
Pin 2 --> Pin 11
Pin 3--> Pin 10
Pin 5 Grounded.
Rest AT89C51 connetions:
Crystal oscillator 12 Mhz.
EN (Pin 31) -VCC
Pin 40-- VCC
Pin 20-- Gnd
Are these connetions are correct??
why my program is not working ??
can any one tell me assembly program to interface the same?