MO-Bot

Posted on 05/10/2011 by droidman
Modified on: 13/09/2018
Project
Press to mark as completed
Introduction
This is an automatic import from our previous community platform. Some things can look imperfect.

If you are the original author, please access your User Control Panel and update it.

This was built about 7 years ago, the idea for the chassis came from the BOE-BOT, the controller is an Out of production Stampbug 2 board, from Milford Instruments Ltd, in the UK. it contains a OEM Basic Stamp 2, small proto area, the only problem is it contains no voltage regulator, so i had to build my own. I also build a board to power the servos, this provided the pins for the servo plugs, logic from the stamp and a seperate power supply. It uses a Daventech SRF-04 ultrasonic ...


MO-Bot

This was built about 7 years ago, the idea for the chassis came from the BOE-BOT, the controller is an Out of production Stampbug 2 board, from Milford Instruments Ltd, in the UK. it contains a OEM Basic Stamp 2, small proto area, the only problem is it contains no voltage regulator, so i had to build my own.

I also build a board to power the servos, this provided the pins for the servo plugs, logic from the stamp and a seperate power supply.

It uses a Daventech SRF-04 ultrasonic sensor, for collision avoidence.

This is the code that the stamp is running, feel free to copy and use it if you wish.


' MO-bot roaming with Devantech SRF04'

counter VAR Word
Dist VAR Word
INIT CON 6
ECHO CON 7

' CONVERSION FACTORS: '
' The PULSIN command returns the round-trip echo time in 2us units
' which is equivalent to the one-way trip time in 1us units. '
' Filename: srf04-1.bs2 ' distance = (echo time) / (conversion factor) '
' use 74 for inches (73.746us per 1 in) ' use 29 for centimeters (29.033us per 1 cm) '

convfac CON 74 ' use inches '

main
GOSUB sr_sonar

GOTO main

sr_sonar:
PULSOUT INIT,5 ' 10us init pulse
PULSIN ECHO,1,Dist ' measure echo time
Dist=Dist/convfac ' convert to inches
IF Dist > 6 THEN forward
IF dist < 6 THEN left
PAUSE 10
RETURN

Forward:
FOR counter = 1 TO 10
PULSOUT 15, 500
PULSOUT 14, 737
PAUSE 20
NEXT
RETURN

Left:
FOR counter = 1 TO 24 'adjust this number till robot turns 90
PULSOUT 15, 750
PULSOUT 14, 750
PAUSE 20
NEXT
RETURN  

Roming around using an SRF-04 for obsticle aviodance

  • Actuators / output devices: 2 x Futaba modified Servos
  • Control method: autonomous
  • CPU: Basic Stamp 2
  • Power source: one 9V battery for MCU, 4 AA batteries for servo motors
  • Programming language: Parallax Basic
  • Sensors / input devices: 1 x SRF-04
  • Target environment: indoor on smooth surfaces
LikedLike this to see more

Spread the word

Flag this post

Thanks for helping to keep our community civil!


Notify staff privately
It's Spam
This post is an advertisement, or vandalism. It is not useful or relevant to the current topic.

You flagged this as spam. Undo flag.Flag Post