Hi...may i ask first what's the purpose of the a0...a3 variables?
am I understanding correctly that your program waits for "SM" from the modem for 5 seconds if not goes to main2? then if the modem does reply with "SM" yo go directly to reply...
Hi...may i ask first what's the purpose of the a0...a3 variables?
am I understanding correctly that your program waits for "SM" from the modem for 5 seconds if not goes to main2? then if the modem does reply with "SM" yo go directly to reply...
hellow master_olan... the purpose of the a0...a3 is just to declared it as port.a0...port.a5 and etc... because my input for my sensor is port a,b,c,e...
yes you are right about the purpose of the program it is to waits for "SM" from the modem for 5 seconds if not it goes to main2... then if the modem does reply with "SM" it go directly to reply.
The replying program only is working well... but when i put it in the program of sensors and send it doesnt work... i dont know the problem why is not working... may be the declaration of
i dont know if i declared it right....DEFINE OSC 4
DEFINE HSER_TXSTA 20h
DEFINE HSER_RCSTA 90h
DEFINE HSER_BAUD 9600
DEFINE HSER_CLROERR 1
DEFINE HSER_SPBRG 12
adcon1=7
cmcon=7
Well I programmed a PIC16f877a to a GSM modem for a friend some months ago... I also had problems with receiving data from Modem to PIC and added a buffer (74LS125)... It worked after that... also try changing this:
DEFINE HSER_TXSTA 20h
to this:
DEFINE HSER_TXSTA 24h
the manual says 24h works with high speed baud rates.. It's what I did with mine...
Last edited by master_olan; - 4th March 2011 at 02:44.
Hellow master_olan thanks again for your help and reply... sorry for my noob question but where i should put the buffer... sorry im just a beginer in making circuits... it would be a great help if you can post a schematic diagram of your MUC with buffer... and thanks a lot
Well... just connect GSM Mod. TX to input of buffer then output of buffer to RX of PIC... Just like this...
If that doesn't work i suggest you spy in your system by using the PCs hyperterminal.. That way you will know if the Module or the PIC does respond to the commands...
I hope any of these will help you...
hi master_olan
I Did all the things you said but it did not work... i also check it in pc but still the reply did not work... any suggestion or solution? thank you for your help and effort![]()
Bookmarks