background image

Parallax, Inc.  

  Boe-Bot Tank Tread Kit (#28106)      

03/2004 

Stamp Code 
 

' ========================================================================= 

'   File...... Advanced_Tank_Bot.BS2 
'   Purpose... Tank Bot with Tilt Sensing 
'   Author.... Parallax 
'   E-mail.... support@parallax.com 
'   Started... 
'   Updated... 12 APRIL 2004 

'   {$STAMP BS2} 
'   {$PBASIC 2.5} 

' ========================================================================= 
 
 
' -----[ Program Description ]--------------------------------------------- 

' This program incorporates the Memsic 2125 accelerometer into the BOE-Bot 
' tank kit to allow the tank to exlore uneven terrain without tipping over. 
 
 
' -----[ Revision History ]------------------------------------------------ 
 
 
' -----[ I/O Definitions ]------------------------------------------------- 
 
LfIrOut         PIN     8                       ' left IR LED output 
LfIrIn          PIN     9                       ' left IR sensor input 
RtIrOut         PIN     1                       ' right IR LED output 
RtIrIn          PIN     0                       ' right IR sensor input 
 
LMotor          PIN     13                      ' left servo motor 
RMotor          PIN     12                      ' right servo motor 
 
TiltX           PIN     4                       ' X tilt input 
TiltY           PIN     5                       ' Y tilt input 
 
 
' -----[ Constants ]------------------------------------------------------- 
 
LFwd            CON     1000                    ' left motor forward 
LStop           CON      750                    ' left motor stop 
LRev            CON      500                    ' left motor reverse 
 
RFwd            CON      500                    ' right motor forward 
RStop           CON      750                    ' right motor stop 
RRev            CON     1000                    ' right motor reverse 
 
IsHigh          CON     1                       ' high-going pulse 
IsLow           CON     0                       ' low-going pulse 
 
YThresh         CON     20                      ' Y tilt threshold 
 
 
' -----[ Variables ]------------------------------------------------------- 
 
pulses          VAR     Byte                    ' counter for servo control 

Summary of Contents for Boe-Bot Tank Treads

Page 1: ...ist Verify the contents of your Boe Bot Tank Tread App Kit to include Documentation 2 metal sides 720 28106 1 Plastic wheel set and 1 Rubber tread set 721 28106 2 Servo horn standard or disk 725 00013...

Page 2: ...ize 3 32 2 2 mm Figure 1 Modify Disk Horn with Drill or Knife Modify the disk servo horn by drilling or reaming the middle holes larger If using a knife ream from the top and bottom but leave material...

Page 3: ...8 Screws to Wheels Attaching the 7 8 screws to the wheels 2 large and 6 medium in size Remove the wheels from your Boe Bot The servos should be mounted with the head toward the rear ball wheel as in F...

Page 4: ...el Attach the remaining wheels by first tightening the nut on the wheel then loosening it a 1 3 a turn Mount with a nut on each side of the frame When the two nuts on each wheel are tightened check to...

Page 5: ...y wheels bind loosen the nut and remount to maintain a small gap between the wheel and nut Stretch the tread over the wheels and the assembly is done P15 P14 P13 P12 P11 P10 P9 P8 P7 P6 P5 P4 P3 P2 P1...

Page 6: ...Full Kit Memsic 2125 Accelerometer and the Boe Bot Tank Tread Kit Specifically you will be adding the following components to your Board of Education 2 Infrared transmitter assemblies 350 00017 2 Infr...

Page 7: ...7 Parallax Inc Boe Bot Tank Tread Kit 28106 03 2004 Schematic 1 2 4 3 5 6 X Vss Vss P5 P4 5 Memsic 2125 Vdd Vss P0 220 Vdd Vss P9 220 P8 IR LED Vss 1 k P1 IR LED Vss 1 k...

Page 8: ...Definitions LfIrOut PIN 8 left IR LED output LfIrIn PIN 9 left IR sensor input RtIrOut PIN 1 right IR LED output RtIrIn PIN 0 right IR sensor input LMotor PIN 13 left servo motor RMotor PIN 12 right...

Page 9: ...e around obstacles GOSUB Read_IR_Sensors ON irBits GOSUB Forward Go_Left Go_Right U_Turn LOOP END Subroutines Check_Level PULSIN TiltY IsHigh yAxis check longitudinal tilt yAxis yAxis 100 filter readi...

Page 10: ...n turn around IF yAxis YThresh THEN GOSUB Back_Up back up if flat terrain ENDIF PULSIN TiltX IsHigh xAxis check longitudinal tilt xAxis xAxis 100 filter reading IF xAxis 24 THEN turn left FOR pulses 1...

Reviews: