Hi,
I am trying to program the Johnny 5. It has a Bot Board II and Sabertooth. I am trying to program it to move forward and stop after maybe 5 to 10 seconds.
Can anyone help?
Hi,
I am trying to program the Johnny 5. It has a Bot Board II and Sabertooth. I am trying to program it to move forward and stop after maybe 5 to 10 seconds.
Can anyone help?
Try applying some random lightning bolts. Worked for this guy anyways…
http://news.thomasnet.com/IMT/Guttenberg%20sold%20seperately.jpg
(More seriously… I don’t have any of those components, but I think you’ll need to provide more info and/or ask a more specific question. Do you have the Bot Board II and Sabertooth connected to the motors already? Do you have any experience programming the board previously? etc. Did you already look through these: lynxmotion.com/ViewPage.aspx … egoryID=19?)
You don’t have a single line of code to show us?
[code]
;start with a stopped robot. You may need to adjust the 1500 slightly.
serout 15, i38400, “#0 P1500 #1 P1500”]
Start:
;ramp up to full forward speed in two seconds.
serout 15, i38400, “#0 P2000 #1 P2000 T2000”]
;go forward for 5 seconds.
pause 5000
;decelerate to stopped in 2 seconds.
serout 15, i38400, “#0 P1500 #1 P1500 T2000”]
;sit for 5 seconds.
pause 5000
;do it again.
goto start[/code]
What I have so far is:
[code]'Connections
'Pin 16 jumper to battery
'Pin 0 left Sabertooth Channel
'Pin 1 right Sabertooth Channel
'Pin 9 Speaker
left_speed var word
right_speed var word
minspeed con 1750
maxspeed con 1250
left_speed = 1500
right_speed = 1500
low P0
low P1
Sound 9, [100\880, 100\988, 100\1046, 100\1175]
left_speed = (left_speed - 10) min maxspeed
right_speed = (right_speed - 10) min maxspeed
pulsout 0, (left_speed2)
pulsout 1, (right_speed2)
pause 20
goto main[/code]
and it just goes continuosly at one speed.
After pause 20 I added:
[code]serout 15, i38400, “#0 P1500 #1 P1500”]
serout 15, i38400, “#0 P2000 #1 P2000 T2000”]
pause 500
serout 15, i38400, “#0 P1500 #1 P1500 T2000”]
pause 500
goto main…[/code]
this started slow got to the high speed and had that speed continuosly…
I tried putting pause 5000 as is in the program posted but it didn’t do anything at all…
Please just program the Atom with the program I provided and tell me what the robot does. Also I need to see the wiring and I need to know the jumper settings of the motor controller. This is really pretty simple stuff. The changes you are making doesn’t make any sense. You send a command to the SSC-32 to go from stopped to full speed in 2 seconds, but you only pause half a second before you send a new command to the SSC-32 to stop (again in 2 seconds.) The pauses must be the same as the T value in the command preceding it.