Home Contents Start 1 2 3 4 Next

Sandy the Sandbox Robot

Make a Small Robot Suitable for Prototyping Ideas

ldrs

Sandy the Sandbox Robot

In order to get a better understanding of robotics, you need a robot to play with. With the availability of microcontroller 'brains' and many pre-assembled sensors, it seems that building a robot these days would be a lot less labour intensive than it once was. I'd like to experiment with a programmable microcontroller based device so decided to set about building a platform that would enable me to do some research. Such a platform should have an array of sensors and actuators onto which a microcontroller could be easily added to drive it.

Goal

Build a generic robotic platform suitable for experimentation.

A few Requirements

A few items on my wish-list:

  • A small wheeled device that carries its own batteries.
  • Light Sensors
  • Distance Sensors
  • Line following sensors
  • Servo(s) control
  • Bump sensors
  • Object avoidance
  • IR/Wireless receptive
  • Wheel encoders
  • Pluggable and configurable
  • In circuit programmable
  • Some kind or IR/temp sensor for people? - motion
  • Self docking (charging)

There are a lot of desirables in there and I do not envisage that they can all be achieved on one platform and compromises will need to be made but its somewhere to start. In the first instance, making s machine that can fumble its way around the floor without bumpimng into anything seems a good a starting place as any.

Mechanics and Electronics

I'm keen to separate the mechanical parts from the electronic parts in this robot. Spending a bit of time up-front build the mechanical section completed with (possibly) more sensors and actuators than I need initially will mean I can concenrate on the electronics/software side and upgrade to larger microcontrollers without having to rebuild the whole mechanical infrastructure. This is to be my development platform, used as a sandbox to try ideas.

With this goal in mind, I decided to make a robot sandwich. The chassis should contain motors, batteries and those sensors that I think may be useful and these should all be brought out to a pluggable interface. If possible, room should be left available to add new sensors which can be connected to the pluggable interface. I intend to use recharable batteries so a socket will be provided to recharge the batteries in-situ without the need for dismantling as I suspect battery use will be heavy.

So the base layer will be power, sensors and actuators. Mounted over this will be the electronics layer where the microcontroller (and possibly associated electronics) will sit. It will connect via flying leads to the pluggable interface below it. This will make it easy to take off the electronics board to access the layer below, just by unplugging wires. This should allow the 'brain' of the robot to be upgraded to larger more powerful PICs as needed.

The design should be such that more boards can be stacked over the microcontroller board. This would primarily be for user interfaces such as LEDs/LCD displays etc which can be used to determine what the robot is doing. Again, a pluggable interface would be desirable although it may be a more generic interface than that used to connect to the sensor layer.

New sensors/actuators can be added to ancilliary boards mounted above the microcontroller board if necessary (as the robot might actually end up doing something rather than bumbling around). Again, each board should be made modular with pluggable interfaces so I can mix-and match them with different microcontrollers etc. My time is limited so only needing to build a board once, and be able to reuse it on multiple projects is the aim here!

Choosing the Chassis

The chassis should be simple, cheap and come in standard 'bricks' to make it easy to work with. I was very tempted to use old CDs as these are plentiful and a fixed size. However, for a testbed robot, I felt the footprint was a little too small and would limit what I could do, although they may prove ideal for a custom robot.

In the end, I decided to use standard PCB boards, as these provided a larger footprint, and being rectangular, were easier to work with. These are 100 x 160mm (half eurocard) and I bought 5 of these for a few pounds. They are copper clad on one side which I could have etched off but thought the copper may prove useful later (perhaps for ground planes, screening?). The copper also adds some rigidity to the board making it a good compromise between metal and wood.

Locomotion

The microcontroller will run from a 5v supply (4x 1.2v AA cells) and servos and many electronic devices use this voltage. It may be necessary to have the power-hungry motors run at a higher voltage and step it down to run the electronics. I had a couple of 12-24v geared motors handy and these seem to work admirably at 5v, still with plenty of torque. My only concern is that once the supply goes through an motor controller circuit, the available voltage might mean they are a little underpowered but I reasoned that I could always use a higher supply voltage and step down for the electronics if necessary. As these MFA motors have a standard footprint, I could always swap them out for lower voltage motors if I have to. Initially, I will use the 12V motors as I have them already.

Sensors

The base chassis layer is where I will mount as many sensors as possible so that they can be reused with other controller cards. So now is the time to get the hardware on the platform, even if I do not envisage using it immediately. The second layer of the chassis will be a platform for mounting the microcontroller boards but there will be limited space for a few additional sensors (eg wheel encoders) although the more that can put on the lower platform the better.

Light

A couple of Light Dependant Resistors (LDRs) could be mounted near the front of the machine. This could be used to make the robot light-seeking and the difference between the two LDR outputs can be used to steer towards (or away) from the light source. This is a possible option for homing in on a docking station although LDRs have a fairly slow response time. I may change these to photo-transistors if necessary. Ideally we could have one or two LDRs at the back of the machine as well so we know when to turn around.

Line Tracking

This can be achieved by shining a light/IR source at the ground and using a receiver to detect the reflection. Black/White/Shiney surfaces will reflect the light to differnt degrees so can be utilized for line tracking. My thoughts are that this may be useful for fine-grain control when docking. Although building a transmitter/receiver for the task is not onerous, several modules can now be purchased complete and (most importantly for my application), they are very small. I found two types, one that outputs an analogue voltage proportional to the reflected signal, and one that produced a digital output that requires some form of sample clock. The second has a better range (9mm) while the first has a range of (6mm). I decided that as the devices are so small, I would use both, one near the front of the machine and one at the rear. It would then be possible to try both types and having one near the back of the robot gives options for reversing into a docking station.

The clearance between the bottom of the robot and the ground is more than 9mm. This may mean the sensors do not work that well, if at all. This can be overcome by mounting the sensors on a bush to make them lower or using smaller robot wheels. I'll cross that bridge when I come to it.

Obstacle Avoidance

This is the primary sensor and one I intend to mount on a servo to form a 'head' that allows the robot to look around to determine the best path to take. It uses a radar principle just as for line tracking, but over a far greater range. There are many options available, either using ultrasound or Infra-red. I decided to go for an infra-red sensor that had a range of 5-30cm. The interface is a simple analogue voltage, the output proportional to the reflected signal. There are several different type of longer-range reflectance sensors but I only need a range great enough not to bang into anything and don't want to flood the room with IR because I may use longer range IR for a homing beacon (docking) and/or a remote control interface.

Edge Detection

Another reflectance sensor, this one with a max range of about 10cm. This could be used to follow a wall but I may decide to point in forward and down and use it to detect when the floor is not there. May be useful to stop the machine falling down stairs or off a table.

Human movement Detection

I recently stumbled across some small PIR detectors which are like the sensors used on security lights. These are optimized to detect only the infra read in the range generated by animals so could be useful to detect when a person is in the room. They work by using deltas so it will be necessary for the robot to be stationary before enabling the sensor. I like I the idea of having one of thes on-board as a homing abuse-and-run robot apeals to me :-)

Sound/Ultra Sound

I could use a microphone and/or ulta-sound sensor that could be used to make decisions. In fact, the main sensor mounted on the servo may be replaced by an utrasound pinger as it does seem rather IR-heavy and I may find one sensor interfering with another otherwise. These are more analogue inputs and I will be running out of these on most PICs by now!. However, if room permits, I will try and get a microphone in there too.


Home Contents Start 1 2 3 4 Next