Hi guys please let me know if I can post a question regarding GSM modem over here My modem is working fine just when I try to receive msg through at+cmgr=1 1st character I get is not '+' Its not related to h/w but programming and response of GSM modem for at commands so is it ok if I post my query over here?
i be thinking ::::::: you must be wait for the great wise anserw of sir erac
i be thinking he sleeping to very late and you must waiting long time
sir erac are you being there yet ???????????
Ya for at i get OK But for initialization i've sent
at ate0 atv0 at+cgmf=1 at+cpms="SM"
so for OK it gives response as 0 and I am sure that this initialization is getting dne correctly as i've deleted msg after returning from ChkMsg function and other thing is when I connect my modem to computer after this initialization I can see echo off verbose mode off msg set to text mode etc.
yes it is a difucult question you be thinking.
who you send one "at" and get ansewr?????
i be thinking you must see ok:::: do you see ok ?????? if you not be seeing ok you must work to the code.
if you having the ansewr but i don not now.
you must have a wait for the big sir erac to give his wise post i be thinking.
you be thinking to laugh while you read his post:::: but be good, he is always right!!!!!!!!
Thanks kalib then here is the question: What is the 1st character that I receive after at+cmgr=1 I considered it as '+' as in +CMGR:.... etc. However my check for '+' fails Here is the part of code:
sbit p0 = P2^0; sbit p1 = P2^1; sbit p3 = P2^3; sbit p4 = P2^4; sbit p5 = P2^5; sbit p6 = P2^6; unsigned char CheckMsg(void) { unsigned char at_cmgr[] = "at+cmgr=1"; char Received_Char; Command(at_cmgr); CR(); Received_Char = Receive_Char(); if(Received_Char != '+') { p3 = 1; return 0; } Received_Char = Receive_Char(); if(Received_Char != 'C') { p1 = 1; return 0; } Received_Char = Receive_Char(); if(Received_Char != 'M') { p4 = 1; return 0; } Received_Char = Receive_Char(); if(Received_Char != 'G') { p4 = 1; return 0; } else return 1; } void Command(unsigned char *at_command) { unsigned char i; i = 0; do { Xmit_Char(at_command+i); i++; } while(at_command[i] != '\0'); return; } void CR(void) { Xmit_Static_Char(0x0D); return; }
the function ChkMsg returns 0 even if msg is been received Xmit_Char and Xmit_Static_Char just transmit characters serially they are working correctly on port2 I've connected LEDs so that I can judge the output Thanks in advance
gsm is not the kiel product you be knowing?????
but:::::: i is be working with gsm and i will help with you.
if you hate the ansewr i giving you you can ask sir erac :::::: he is old and wise and kind and very fun and knows everything you be knowing. and you is be laughing lots for his posing.
View all questions in Keil forum