CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

interfacing GSM to PIC

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
madtoilet



Joined: 02 Apr 2008
Posts: 36

View user's profile Send private message

interfacing GSM to PIC
PostPosted: Thu Apr 10, 2008 5:42 pm     Reply with quote

Hey, i know alot of people have been asking about this and i have read through most of the topics on the forum (using search).

Though alot of the topics were helpful, i'm still unclear on certain aspects. here is my code for it

Code:

#include "D:\Program Files\PICC\Devices\LCD.h"
#include "string.h"
#fuses HS,NOWDT,NOPROTECT, NOLVP
#use delay(clock=4mhz)
#use rs232(baud=4800, bits=8, parity=N, stop=1, xmit=PIN_C6, rcv=PIN_C7, stream=GSM, ERRORS)

#define CZ 0x1A

void gsm_call(void)
{

char c;


output_low(PIN_C4);  //selecting multiplexer
output_high(PIN_C5);
delay_ms(500);

/*
putc('A');
putc('T');
*/

fprintf(GSM, "AT+CMGF=1\r\n");
delay_ms(2050);
fprintf(GSM, "AT+CMGS=4153851526\r\n");
delay_ms(2000);
fprintf(GSM, "check%c\r\n", CZ);

}


this is the function that i call. It isn't quite working. I'm to send a message out from the GSM module.

i'm confused as to how i'm to send carriage returns and whether my CZ definition is right for replacing ctrl-z
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group