hi,
i am working on 4wd1 rover. i want to turn the rover 90 degrees left and right. i am not using any kind of extra hardware like encoder and etc..,
my logic to turn right
[code]
LSpeed = 1450
RSpeed = 1650
turn
a var word
a = 0
while a < 120 // number of loops for rotating rover
gosub run
a=a+1
wend
return
run
; Send out the servo pulses
pulsout 0,(LSpeed2) ; Left Sabertooth channel.
pulsout 1,(RSpeed2) ; Right Sabertooth channel.
pause 20
return[/code]
Every time i run this code, it behaves differently, some time it is taking more and less than 90 degrees.
Could you please help me out.
Anything idea , code or proper command is helpful.
thanks.