how to initialize PORT A of 18F4520 as input

Status
Not open for further replies.


No..i am not using any keyboard or lcd...my idea is little different...when sensor 1(water level) is 1(sufficent water then the motor will on and all other funtctions will be carried out...but if sensor 1 is 0 then there is no water in tank..so this alert shoud be given to the user through message using GSM SIM300 module.....i just want to send a message,,,no receiving or controlling part is there/////

- - - Updated - - -

No..i am not using any keyboard or lcd...my idea is little different...when sensor 1(water level) is 1(sufficent water then the motor will on and all other funtctions will be carried out...but if sensor 1 is 0 then there is no water in tank..so this alert shoud be given to the user through message using GSM SIM300 module.....i just want to send a message,,,no receiving or controlling part is there/////
 

i did not get any datasheet with GSM module,,but found one datasheet of sim300 on net...can i post that?

- - - Updated - - -

baudrate will be normally 9600
 

i already checked that link..but that code is too difficult to understand...bcoz it has a lcd interfacing too
 

to whom you send SMS alert? User. Am I right? If it is only for your personal use, then no problem. You can open the codeand update every time if you want to change the phone numbers to send SMS Alert. But, in case if it is a general purpose, user can be freely allowed to change the Phone numbers whenever they want. So, SMS parsing must be done if you don't use LCD and KeyBoard.

Anyway, Don't need to initiate GSM Module separately, you can Initialize serial port using USART.c & USART.h (provided along with Hi-TECH C compiler) and check the GSM output by sending AT command. For example, issue AT Command ATE0 (This AT Command - ECHO OFF - must be send before any command. Otherwise, some unwanted things can happen when parsing SMS, tc). See the output ("OK") on HyperTerminal. You can connect Hyperterminal to PIC MCU for debugging.

On HyperTerminal - set baud rate (match with GSM - IPR setting), Flow control - none, Parity Bits, etc.
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…