yes, i took it low before doing anything. heres a little more of the code:
trigger con 5
baudLCD CON 32 'baud rate for lcd
lcd VAR PORTF.0 'lcd port
ping VAR byte
ultra VAR PORTF.1
PORTF.1 = 0
ping = 0
SerOut2 lcd, baudlcd,[254,"G",1,1,"Ping Test"] 'display test on lcd in position 1,1
start:
Pause 1000
PulsOut ultra, trigger 'send trigger to ping
PulsIn ultra, 1, ping 'wait for ping variable
Pause 1000
SerOut2 lcd, baudlcd,[254,"G",2,2,#ping," "] 'display pin var in position 2,2
GoTo start
End
so wheni take out the "pulsout ultra, trigger" line, everything works great (except the ping sensor cause it doesnt get its pulse). i added in long pauses so i could tell where the problem is. my LCD will display "ping test" in the correct position, then waits a second, displayes a wierd character, waits another second and then displays a couple wierd characters and then the ping variable. when it shows the wierd characters and ping variable, it just adds them right behind "ping test", not in the position its supposed to be in..
Bookmarks