Not Going the Distance
AngDeaver
Posts: 4
I am on Chapter 4 in "Robotics with the Boe-Bot". I just measured how far my Boe-Bot goes in one minute, 8.4 inches. So using that I calculated how many seconds it would take to travel 24 inches. 24in / 8.4in = 2.86s. If a count of 1 to 41 = 1s; shouldn't I just be able to multiply 41 * 2.86 and change the count to 1 to 117? However, when I run it it falls short nearly 2 inches.
On a side note to go straight I had to adjust the P13 to 808 and the P1 is 650.
Can someone help me?
Here is the program I used:
' Example Program: ForwardOneSecond.bs2
' Robotics with the Boe-Bot - ForwardOneSecond.bs2
' Make the Boe-Bot roll forward for one second.
' {$STAMP BS2}
' {$PBASIC 2.5}
DEBUG "Program Running!"
counter VAR Word
FREQOUT 4, 2000, 3000 'Signal program start/reset
FOR counter = 1 TO 117
PULSOUT 13, 808
PULSOUT 12, 650
PAUSE 20
NEXT
END
On a side note to go straight I had to adjust the P13 to 808 and the P1 is 650.
Can someone help me?
Here is the program I used:
' Example Program: ForwardOneSecond.bs2
' Robotics with the Boe-Bot - ForwardOneSecond.bs2
' Make the Boe-Bot roll forward for one second.
' {$STAMP BS2}
' {$PBASIC 2.5}
DEBUG "Program Running!"
counter VAR Word
FREQOUT 4, 2000, 3000 'Signal program start/reset
FOR counter = 1 TO 117
PULSOUT 13, 808
PULSOUT 12, 650
PAUSE 20
NEXT
END
Comments
When attempting to get one of my robot to perform a figure 8 I couldn't get the robot to behave in a repeatable fashion until I used a voltage regulator with a higher voltage battery pack. The regulator kept the voltage at a constant level so I was finally able to set the timing needed for a figure 8. Post #3 of the this thread discusses the voltage regulator. The figure 8 video in is post #1.
BTW - welcome to the Parallax forums!
Doc
8.4ft / 60 sec = 24ft / x sec
8.4x = 60 * 24
8.4x = 1440
x = 1440 / 8.4
x = 171.4 sec = 2.86 min
Yes, it would help with anything except for slippage. If you used a separate drag wheel for the encoder it will also account for slippage.