Need help with Boe Bot Maze race program Race is tomorrow help plz
Sandhuamarinder
Posts: 85
Hi Guys
I need Boe Bot program so i can see how it works and stuff. Bcoz i dont know how many servos it have etc etc how the sensor works.
Why i need this program?
Bcoz in my class professor said that you will get bonus marks if u will make your boe bot win in the race and also in the maze.
So i need those bonus marks and we will be given limited time to figure that thing out . so PLZ some one help me
It is obvious people will come ready so i dont have anyone who help in programming except parallax people. So help me and save me.
I dont know anything about Boe Bot or What kind of sensor does Boe bot use and how many servos. Some one give me information in detail plz and give me some codes for that.
I will really appreciate that.
Post Edited (Sandhuamarinder) : 4/16/2010 1:53:14 AM GMT
I need Boe Bot program so i can see how it works and stuff. Bcoz i dont know how many servos it have etc etc how the sensor works.
Why i need this program?
Bcoz in my class professor said that you will get bonus marks if u will make your boe bot win in the race and also in the maze.
So i need those bonus marks and we will be given limited time to figure that thing out . so PLZ some one help me
It is obvious people will come ready so i dont have anyone who help in programming except parallax people. So help me and save me.
I dont know anything about Boe Bot or What kind of sensor does Boe bot use and how many servos. Some one give me information in detail plz and give me some codes for that.
I will really appreciate that.
Post Edited (Sandhuamarinder) : 4/16/2010 1:53:14 AM GMT
Comments
You want to download "Robotics with the Boe-Bot" here: www.parallax.com/tabid/535/Default.aspx
I hate reading manuals. But still going to read it.
One quick question
I had never played with 360 degree servo. So to make that one turn fast what i have to do.
Can you give me
Any small loop example for that so i can understand the commands.
R/C servos respond to pulses in the range of 1ms to 2ms repeated about 50 times a second. Some servos respond to narrower or wider pulses, sometimes in the range of 0.5ms to 2.5ms. Continuous motion servos like those on the Boe-Bot move in one direction with pulses narrower than 1.5ms and move in the other direction with pulses wider than 1.5ms. The further the pulse width is from the center of the range (roughly 1.5ms), the faster it goes.
Page 79 of the Manual shows one example of the code needed to move the two wheel servos of a Boe-Bot.
One will run in clock wise and one will run in anti clockwise.
To position the servos check down there sir Mike Green post
Page 76 and 78 for speed in manual.
Sorry sir i was editing my message at that time. When u posted
Thanks Sir for helping this Dumb student.
Hope u are not my professor with different pic and different id hahaha just joking.
Post Edited (Sandhuamarinder) : 4/13/2010 5:53:38 AM GMT
Read page 76 in the Manual.
Sir i had seen that in manual they had used
for i = 1 to 200
why such a big loop can i use for i = 1 to 35 whats the difference. Above one is for 360 degree servo and bottom one is for 180 degree servo bcoz of that.
Do remember that there are two types of servos ... one that's used for the BoeBot's wheels called a "continuous motion servo" and the other is just a standard servo. In the first case, the pulse width has the effect that I've described earlier. With a standard servo, the pulse width specifies the actual desired position for the servo. Here's a good description: www.seattlerobotics.org/guide/servos.html
How hard you press on the gas pedal is your PULSOUT value. Your foot off of the gas pedal is a PULSOUT pin, 750 value. The amount of difference (above or below) from 750 is your speed.
How long you maintain this speed is the number of loops in which you PULSOUT. Try 35. Try 200. Try 1000.
Read Mike's posts above again, carefully. You're on the right track and asking the right questions.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Ken Gracey
Parallax Inc.
Follow me at http://twitter.com/ParallaxKen for some insider news.
So 150 or 200 is good enough i think rest i will see if they will change the floor for the race.
Thanks alot Sir for the help.
Time is coming close for the race. Hoahhhh Hoahhhh
Post Edited (Sandhuamarinder) : 4/13/2010 4:25:13 PM GMT
I dont have Boe Bot with me. So help PLZ I am just giving a shot in the air. So can some one check it for me. So i dont have to spend time figuring this thing out in school.
' {$STAMP BS2}
' {$PBASIC 2.5}
dist1 VAR Byte
dist2 VAR Byte
dist3 VAR Byte
t VAR Byte
i VAR Word
Left PIN 14
Right PIN 15
Sensors:
HIGH 3
HIGH 4
HIGH 5
PAUSE 3
LOW 3
LOW 4
LOW 5
FOR t=1 TO 30
PAUSE 1
IF IN2=1 THEN
IF IN7=1 THEN
IF IN8=1 THEN
GOTO display
ENDIF
ENDIF
ENDIF
NEXT
GOTO Sensors
display:
DEBUG CLS
SHIFTIN 2,0,2,[noparse][[/noparse]dist1\8] 'Left
SHIFTIN 7,0,2,[noparse][[/noparse]dist2\8] 'Middle
SHIFTIN 8,0,2,[noparse][[/noparse]dist3\8] 'Right
DEBUG"distance=",DEC dist1,CR
DEBUG"distance=",DEC dist2,CR
DEBUG"distance=",DEC dist3,CR
PAUSE 50 'if pause increased will get reading slowly if decreased will get reading faster
IF dist1 > 200 THEN 'if left sensor got distance less than 200 the turn left
FOR i= 1 TO 35 STEP 1
PULSOUT left,800 'anticlockwise
PULSOUT right,650 'clockwise
PAUSE 18
NEXT
IF dist3 > 200 THEN 'if right sensor got distance less than 200 then turn right
FOR i= 1 TO 35 STEP 1
PULSOUT left,850 'anticlockwise
PULSOUT right,700 'clockwise
PAUSE 18
NEXT
IF dist2 = 200 THEN
PULSOUT left,750 'anticlockwise
PULSOUT right,750 'clockwise
PAUSE 18
FOR i= 1 TO 35
PULSOUT left,850
PULSOUT right,650
PAUSE 18
NEXT
ENDIF
ENDIF
ENDIF
GOTO Sensors
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen
' {$STAMP BS2}
' {$PBASIC 2.5}
dist1 VAR Byte
dist2 VAR Byte
dist3 VAR Byte
t VAR Byte
i VAR Word
Left PIN 14
Right PIN 15
Sensors:
HIGH 3
HIGH 4
HIGH 5
PAUSE 3
LOW 3
LOW 4
LOW 5
FOR t=1 TO 30
PAUSE 1
IF IN2=1 THEN
IF IN7=1 THEN
IF IN8=1 THEN
GOTO display
ENDIF
ENDIF
ENDIF
NEXT
GOTO Sensors
display:
DEBUG CLS
SHIFTIN 2,0,2,[noparse][[/noparse]dist1\8] 'Left
SHIFTIN 7,0,2,[noparse][[/noparse]dist2\8] 'Middle
SHIFTIN 8,0,2,[noparse][[/noparse]dist3\8] 'Right
DEBUG"distance=",DEC dist1,CR
DEBUG"distance=",DEC dist2,CR
DEBUG"distance=",DEC dist3,CR
PAUSE 50 'if pause increased will get reading slowly if decreased will get reading faster
IF dist1 > 200 THEN
GOTO M1
IF dist3 > 200 THEN
GOTO M2
IF dist2 = 200 THEN
GOTO M3
else
GOTO M4
M1:
IF dist1 > 200 THEN 'if left sensor got distance less than 200 the turn left
FOR i= 1 TO 35 STEP 1
PULSOUT left,800 'anticlockwise
PULSOUT right,650 'clockwise
PAUSE 18
NEXT
M2:
IF dist3 > 200 THEN 'if right sensor got distance less than 200 then turn right
FOR i= 1 TO 35 STEP 1
PULSOUT left,850 'anticlockwise
PULSOUT right,700 'clockwise
PAUSE 18
NEXT
M3:
IF dist2 = 200 THEN
PULSOUT left,i 'anticlockwise
PULSOUT right,i 'clockwise
PAUSE 18
M4:
FOR i= 1 TO 35
IF dist1 > 200 THEN
GOTO M1
IF dist3 > 200 THEN
GOTO M2
IF dist2 = 200 THEN
GOTO M3
ELSE
PULSOUT left,850
PULSOUT right,650
PAUSE 18
ENDIF
ENDIF
ENDIF
NEXT
Goto M4
ENDIF
ENDIF
ENDIF
GOTO Sensors
Post Edited (Sandhuamarinder) : 4/16/2010 2:07:55 AM GMT
I'm not sure if you're indenting in your source code, but you should be. If you're not then take a look at the sample code that Parallax provides.
BTW, generally you tell the forum what the problem is, and the forum will try and tell you where the source is. If we don't know what is wrong then we can't provide any useful feedback.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Powered by enthusiasm