Forum Replies Created
-
AuthorPosts
-
Rajesh K
Participant>problem is here “inchar=UART1_Read();”
>i cant suceesfully store data into “inchar” from UART1_Read1. how do u kno data fm UART1_Read() is gud?
2. what exact prblem u get – compile err? run err? what? same problem every time (with same SMS txt) or no?
3. only when 2 points abve r clear, then we discuss how to stor gud data. OK bro?
>actaully i want to print received data on LCD 16*2 ,i tried many times but i get wrng result
>can u tell me how to correct this code.how can i print received string on lcdfix depnds on ur hw (pic+lcd+circuit) and sw (code+lib).
Rajesh K
Participanti hv not used proteous in that way so unless u know it vry well, you can add more prblems instead of solve them!
ur reslts cn happn eg due to ur exact new code
this is y i wud use serial tap – no new code needed!
remembr p18f877a uart rx fifo is very small – mayb u need to chk for rx over run, if u do to much than just rx chars
Rajesh K
Participantwhen i do this proj in past,,, i use differnt algo to u ,,,,, eg init UART once, setup sim900 once, then loop waiting 4 chars to start, then loop reading chars into buffer or state machne testing 4 cmd start char eg #, then action on recd cmd (led, relay,,,), then back to loop waiting 4 chars. u shld not need delay_ms after UART1_Read!
Rajesh K
Participantmany ways 2 debug this… some loops r wrong (or too complx til bugs r fixd). ur code has no err chking so how can u find the problem???
examples:
add serial tap 2 chk io to sim900a (connect 2 pc via max232 or similr n thn use hyprterm)
or add i2c lcd display n add code to out all recd data to lcd
or add soft uart code in microc compiler n out all recd data to it
or use microc sw simulatr
Rajesh K
Participantyes… ur code hs a few prblems I cn see. U r using MikroC, yes?
what is ur current state….? do u hv a deadline when this musst b fixed?
-
AuthorPosts