PC Services

 

PC Services (Electronics)

Arduino Uno Based - Robot Cars doing maze solving

Tel: 0118 946 3634
Email

linked-in profile facebook profile

   The Company 
   Resources / Examples 
     Robotic Cars 
   Commentaries           
   Personal 

Robot Cars doing maze solving

In 2017, two students decided to do different maze solving/route mapping projects using what I would call robot cars. These A level students for their Computer Science project for them to design and write the software and add various peripherals to the robot to assist in navigation of the robot car.

They used some fairly commonly available parts -

  • Robot car frame (22 cm x 16 cm)
  • Two geared down motor drives with wheels
  • A front caster to allow front to turn
  • Ardunino Uno
  • Motor Shield to drive the two motors
  • Breadboard for mounting components to connect to Arduino Uno
  • Forward facing Ultrasonic distance sensor
  • One also had an IR (Infra Red) tracker with analogue outputs, to locate another IR beacon
  • Two battery packs both upgraded to 9V later, one to drive the electronics and one to drive the motors
Arduino Uno + Motor Shield + Ultrasonic + IR Tracker
Arduino Uno + Motor Shield + Ultrasonic + IR Tracker

By using this setup they could do projects that went from a known starting position, and using decision algorithms, get to their target location avoiding other objects, and mapping where they had been. If they had been more successful they also would have done a reverse journey to starting point to dump out the best route to target.

Click on an image for an enlarged view of the picture.

The IR tracker consists of
  • Three IR detectors with analog outputs to measure the IR signals
    • Straight Ahead
    • 45 ° to Left
    • 45 ° to Right
  • Upward facing IR detectors for when ambient (background) IR too strong to confuse sensors
  • Mounted on stripboard with pins to connect to a breadboard
IR Tracker with four IR sensors at 45 degrees
IR Tracker with four IR sensors at 45 degrees
The IR beacon consists of
  • Seven IR LEDs
    • Straight Ahead
    • 30 ° to Left and Right
    • 60 ° to Left and Right
    • 00 ° to Left and Right
  • Mounted on stripboard with pins to connect to an Arduino Uno or similar
  • Directly plugs onto an Arduino Uno with 9V battery pack
IR Beacon on Arduino Uno - LEDs at 30 degree spacing
IR Beacon on Arduino Uno - LEDs at 30 degree spacing

The program on the IR Beacon Arduino Uno pulses LEDs for 100 ms in turn sweeping in and out, in sequence of

  1. both 90 ° lit at same time
  2. both 60 ° lit at same time
  3. both 30 ° lit at same time
  4. One straight Ahead LED lit
  5. both 30 ° lit at same time
  6. both 60 ° lit at same time
  7. repeat from step 1

This way a scan of the IR Tracker detectors can be performd, to check for pulses against background level and determine which direction is the strongest, or even partial angles between the sensors.

Below is a series of scope screen shots, showing what drives the LEDs on the IR beacon (LOW is LED Lit), and how the sensors perform on the IR tracker.

Sequence of 100 ms pulses on IR LEDs
Sequence of 100 ms pulses on IR LEDs
Received pattern when beacon to Left
Received pattern when beacon to Left
Received pattern when beacon ahead
Received pattern when beacon ahead
Received pattern when beacon to Right
Received pattern when beacon to Right

Putting it all together

When the student put it together, they eneded up at least with a working design, even if it did not get to fully match the requirements. See the video below of one of the tests runs.

Interested in something similar contact sales.

© 2017 onwards by PC Services, Reading UK Last Updated: 9th August 2017
If you encounter problems with this page please email your comments to webmaster