Continue to Site

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.

GSM Mobile Phone(t630) interfacing to AVR using Proteus

Status
Not open for further replies.

umairmukati

Junior Member level 1
Joined
Feb 1, 2012
Messages
18
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,283
Activity points
1,411
Hi,
I need to use GSM in one of my project, to send sms to a target mobile.
I am using Sony Ericsson T630, and I am able to successfully send SMS through HyperTerminal utilizing AT Commands.:sad::???: Untitled.png
As expected, I am not able to send SMS to mobile through Proteus, the same error. I am not getting any reply (e.g. "OK" or "ERROR") from my mobile attached to the serial port through USB to Serial Converter.
To make sure that it is not the issue of programming, I also tried to connect my mobile like that in the picture; but no response at all.
Can any one tell me what is the problem?
Regards,
Umair Mukati.
 

Here is my code:
/*
* GSM_t630.c
*
* Created: 2/9/2012 5:12:55 PM
* Author: UmairMukati
*/
#define F_CPU 7372800UL
#define UART_BAUD_RATE 9600
#include <avr/io.h>
#include <avr/interrupt.h>
#include <util/delay.h>
#include "uart.h"

void gsm_init(void)
{
uart_init(UART_BAUD_SELECT(UART_BAUD_RATE,F_CPU));
sei();
uart_puts("AT");
uart_putc(0x0D); //Carriage Return
uart_putc(0x0A); //Line Feed
_delay_ms(1000);
uart_puts("AT+CMGF=1;");
uart_putc(0x0D); //Carriage Return
uart_putc(0x0A); //Line Feed
_delay_ms(1000);
}
void send_msg(char *num,char *msg)
{
uart_puts("AT+CMGS=\"");
uart_puts(num);
uart_puts("\"");
uart_putc(0x0D); //Carriage Return
uart_putc(0x0A); //Line Feed
_delay_ms(1000);
uart_puts(msg);
uart_putc(0x1A); //Control Z
}

int main(void)
{
gsm_init();
send_msg("+923422017005","Hi, If you receive my msg please inform me");
while(1);
return 0;
}
I have used peter fluery library for UART Transmission.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top