Saturday 30 May 2015

ArduSat; Arduino in Space.

Well I don't know about you but I love Electronics, Arduino, TI LaunchPad, Freescale FRDM Platform and every other development board out there and I get up to 10 e-mails a day from all the popular electronic stores and the like and I got one the other day and I was instantly hooked. It was about Arduinos and Space, NASA's Curiosity Rover team member Luke Dubord and our very own Jonathan Oxer from "Freetronics", it was Freetronics that sent the e-mail and I use a bit of his gear in my robotics development etc. All of my robots use the Arduino Platform, I have a few genuine boards and a lot of clones but it is all Arduino based. I have ordered all of the components and I will be playing with them in a very low orbit, ie my computer room, but you must check it out,
https://www.ardusat.com and also check out;
 www.youtube.com/watch?v=0GHMTXiDqoA
and another one to look at is;
www.edn.com/electronics-blogs/esc/4439386/13-engineering-truths-proved-by-NASA-s-Curiosity-Rover
This should be the link to the e-mail online;
http://us6.campaign-archive2.com/?u=6c6eae339297e03e05631429d&id=6fe06ca8b0&e=106891729c
just copy and paste it into your browser, it worked perfectly for me.

The sensors that you will need include a Luminosity Sensor, Temperature Sensor, Accelerometer, Gyroscope, Magnetometer, Ultraviolet Light Sensor and Infrared Thermopile but one of them is a 10DOF IMU Sensor Module that has a number of the sensors built into it, I got mine from Core Electronics in Australia on eBay for $24.00AUD but they are available on eBay from China for a lot less, I like to shop at home as much as I can.

The Ardusat site has most of the information required and links to github for the Arduino libraries etc needed for all of the sensors and example sketches to test them and away you go, some of the best education information that I have found on the Internet from anywhere in the world about electronics and Arduino, it's a must.

Cheers, Terry.

Monday 18 May 2015

TJ's Rover 5 (Product Report and Build)

The Rover 5 from HobbyKing.com

This is for entertainment only but it worked perfectly for me.

I have wanted a rolling robot but "Track Driven" for some time and when I saw the Rover 5 advertised on HobbyKing.com I just had to have one. The pricing varied a bit depending on whether you wanted Two Motors, Four Motors and Speed Encoders. I don't have the need for speed encoders and the cost for two extra motors was a bit out of my reach so I settled on the basic two motor no speed encoder version. I purchased it when I purchased the Line Tracing Robot so they shared the cost of the freight but it still cost a lot but it did arrive very quickly from China so it was worth it. Total Cost was $39.44 delivered to my door, not bad really.

                    This is what you get in the kit plus a 6 Cell Battery Holder


                            My version has Two Motors and No Encoders

You can dismantle the motor and drive wheels front and rear and adjust the ground clearance as well as tension the rubber track if required. I left mine as it came in the box. I had to consider what style of control I was going to use and whether I wanted to add to its operational capabilities later or not. I chose a simple set up first and decided to use Infrared sensor for obstacle avoidance, a servo to point the IR sensor across the front of the robot and I had a few Arduino Adafruit Motor Shields made by DK Electronics as well as a DCcduino Arduino Uno in my parts bin so that dictated how it was to be controlled.

                                      This is the Infrared Sensor I used

                               I put some Heat Shrink on it for Protection

I had some IR sensors that I purchased a few months ago and I got then for $1.00AUD. I protected it with some heat shrink and glued a servo horn on the underside and left the adjustment trim pot uncovered so I could adjust the sensitivity of the sensor later on in the build. I will use four more later on when I design and build a robot arm for the robot, that will give it finer control over it's position.

                           The Servo Arm or Horn glued to the underside

I used a standard size Servo, one with plastic gears because it isn't doing heavy work and they were very cheap, $13.00AUD from Micro Engines in Australia, supporting the Local Bloke.

                                            The Servo that I used

                                      IR Sensor mounted on the servo

The Adafruit Motor Control Shield is one of the simplest motor control shields to use, it has a huge number of sketches already written by the Arduino Family and as always I Stand on the Shoulders of the great Women and Men that went before me and use the sketches that are out there for most of my builds and this one is no different. It was George Frick that did the original work on the sketch that I am using.

                                          The Adafruit Motor Controller

                                    The Arduino Uno Clone that I used

The Arduino Uno Clone that I used can be purchased from China for about $5.50AUD at the moment, it doesn't use the DIP chip so if it fails you have to replace the unit as a whole but they are very cheap anyway. I do have a genuine Arduino Uno that I use for programing the chips that I use in homemade builds and prototyping work.

                        The Beauty of the Adafruit shield and Arduino Uno

As you can see from the above image the beauty of the Adafruit Shield and the Arduino Uno is they clip together and occupy the same footprint in the build as well as having two servo outputs and the six A0 to A5 inputs, six 5V+ and 0V- pins all close together for easy wiring. I think that this is V2 but it is still available in clone forms for about $5.00AUD from China so they are very cheap as well.
As I mentioned you get a six cell battery holder in the Kit and I wired a switch to the earth or 0V line as well as a 2.1mm plug for the arduino power socket and two power wires to connect the 9V to the Motor Control Shield for maximum power for the motors. The combination or parts that I used makes it very easy to power and wire up the robot and lends itself beautifully to modifications and upgrades later on which is what I want to do in time with this robot base.

                                   The Six Cell Battery Holder in the Kit


              The Switch, 2.1mm Plug and Power Wires for the Motor shield

I have cut out a bit of 3mm MDF for the Rover 5 chassis that fits over the opening on the top of the robot so I can mount the components on the robot. I have cut out an opening for the servo motor to mount in and some holes for screws and wiring to go through so it is all safe and secure for operation. I mounted the components onto the MDF and had to put some spacers or standoffs under the mounting brackets for the servo as well as long screws, nuts and washers to get the clearance required for the batteries and wiring etc in the chassis. As it happens it worked out fine and stage one works well given how simple it really is.

                                      Rover 5 Looking at the Front


                                              Rover 5 Side View

The wiring is simple, the motor shield does most of the connections required for the Arduino Uno and then all you need to connect is the servo to the Servo 1 connection on the shield and the 5V+, 0V- and the output from the IR Sensor to power supply terminals on the shield and to A5 on the analog pins on the shield as well as the motor connections. You can have as many as four DC Motors controlled via this shield and in this case M1 and M2 are used and if the motors are going the wrong way just swap the motor wires around, M1 is the right hand motor and M2 is the left so it really is very simple.

           The ON/OFF Switch is mounted between the servo and arduino


                                    The Servo has just enough clearance

You will need to adjust the IR sensor to get the best result but other than that the Sketch works perfectly on my Arduino Clone and adafruit motor shield, This is the code that I used, enjoy.


/*
 * George Frick (george.frick@gmail.com)
 * Jan/Feb 2010.
 * Arduino Robot 2 - Wandering Tank
 * This robot will wander around, scanning with a very short range forward IR.
 * When an object is detected, the robot will turn based on the position of the IR sensor
 * during the detection. The robot will move backwards, then turn away from the detected object
 * and continue. The robot runs continuously.
 */
#include <AFMotor.h>
#include <Servo.h>

// Two motors, a servo, and an IR sensor.
AF_DCMotor motor1(1, MOTOR12_64KHZ); // create motor #1, 64KHz pwm
AF_DCMotor motor2(2, MOTOR12_64KHZ); // create motor #2, 64KHz pwm
Servo sensorServo;
const int irPin = 19; // pin 5 as digital is pin 19

// Timing. I don't like using delay.
unsigned long tCnt = 0;
unsigned long tStart = 0;
unsigned long tDelta = 0;
unsigned long tTurn = 0;

int state;               // Current Robot State
int lastState;           // Previous Robot State
int servoPos;            // Position to send servo
int servoDirection;      // Direction servo is turning
int lastDetectionAngle;  // Position of servo at last IR detect.

// Constants for state of tank tracks.
const int STATE_FORWARD = 1;
const int STATE_TURN_RIGHT = 2;
const int STATE_BACKWARD = 3;
const int STATE_TURN_LEFT = 4;

// Constants for Servo.
const int DIR_LEFT = 0;
const int DIR_RIGHT = 1;
const int MIN_DEGREE = 40;
const int MAX_DEGREE = 140;

/*
 * Initializes everything. Is run once.
 */
void setup() {
  Serial.begin(9600);           // set up Serial library at 9600 bps
  sensorServo.attach(10);  // attaches the servo on pin 10
  pinMode(irPin, INPUT);
  motor1.setSpeed(255);     // set the speed to 200/255
  motor2.setSpeed(255);     // set the speed to 200/255
  tStart = millis();
  lastState = state = STATE_FORWARD;
  servoPos = 90;
  servoDirection = DIR_RIGHT;
  sensorServo.write(servoPos);
  //state = 0; // Uncomment to have robot not move tank tracks.
}

/*
 * Runs continuously.
 * 1. Update Servo.
 * 2. Check IR sensor.
 * 3. Move Robot
 */
void loop() {
  tDelta = millis() - tStart;
  tCnt += tDelta;
  tStart += tDelta;

  // Tell the servo to move 2 degrees every 25 ticks.
  if( tCnt > 25 ) {
    tCnt = 0;
    if( servoDirection == DIR_LEFT ) {
      servoPos -= 2;
    } else if( servoDirection == DIR_RIGHT) {
      servoPos += 2;
    }

    // Servo position will be beyond desired angles, turn around.
    if( servoPos >= MAX_DEGREE ) {
      servoDirection = DIR_LEFT;
    } else if( servoPos <= MIN_DEGREE ) {
      servoDirection = DIR_RIGHT;
    }
    sensorServo.write(servoPos);
  }

  // Allows disabling of tracks by setting state to 0.
  if(state == 0) {
    moveRobot();
    return;
  }

  // Double read the pin, @see forums.adafruit.com
  digitalRead(irPin);
  delay(5);
  if( digitalRead(irPin) == 0 ) {
    lastDetectionAngle = servoPos;
    state = STATE_BACKWARD;
  } else {
    if( state == STATE_BACKWARD ) {
      if( lastDetectionAngle > 105 ) { // right
        state = STATE_TURN_LEFT;
        tTurn = 1000; // turn for ~1 seconds
      } else if( lastDetectionAngle < 75 ) { // left
        state = STATE_TURN_RIGHT;
        tTurn = 1000; // turn for ~1 seconds
      } else { // center
        state = STATE_TURN_RIGHT; // for now, turn right by default.
        tTurn = 1500; // turn for ~1 seconds
      }
    } else if ( state == STATE_TURN_RIGHT || state == STATE_TURN_LEFT ) {
      tTurn -= tDelta;
      if( tTurn <= 10 ) {
        state = STATE_FORWARD;
      }
    } else {
      state = STATE_FORWARD;
    }
  }

  moveRobot();
}

/*
 * Uses the state of the robot to move tank treads accordingly
 */
void moveRobot() {

  // The motors seemed to respond better if they receive a stop before a switch in direction.
  if( state != lastState ) {
    motor1.run(RELEASE);      // stopped
    motor2.run(RELEASE);      // stopped
  }

  switch( state ) {
    default:
      return; // helps test, state 0 = dont move.
    case STATE_FORWARD: {
      motor1.run(FORWARD);      // turn it on going forward
      motor2.run(FORWARD);      // turn it on going forward
      break;
    }
    case STATE_BACKWARD: {
      motor1.run(BACKWARD);      // turn it on going forward
      motor2.run(BACKWARD);      // turn it on going forward
      break;
    }
    case STATE_TURN_RIGHT: {
      motor1.run(FORWARD);      // turn it on going forward
      motor2.run(BACKWARD);      // turn it on going forward
      break;
    }
    case STATE_TURN_LEFT: {
      motor1.run(BACKWARD);      // turn it on going forward
      motor2.run(FORWARD);      // turn it on going forward
      break;
    }
  }

  lastState = state;
}

/* EOF */

My thoughts on the product or if I had to give it a score out of 10 I would give it an eight, 8/10, it lost two points because the battery holder had an opencircuit on the 0V- line at the soldered joint in the holder itself. Other than that it has huge amounts of power and remember I have the two motor version so four motors must be twice as powerful and ease of mating your build to the chassis is excellent with four screw mounting points that you can tap out for 3mm machine thread screws, that is what I did on mine and it worked perfectly. If you are looking for a tank style chassis motor setup this is one that I would highly recommend.
If you copy and paste the above code into your Arduino IDE it should work perfectly when used with the components that I used so have fun.

This is a very short video of it in operation;









Tuesday 12 May 2015

DC Bot, Product Test, HG7881CP Motor Controller

As always this is for entertainment purposes only but worked perfectly for me when used with the components listed, it won't work with other motor controllers so please don't ask, but have fun with it.

I have had some very small DC motor controllers for some time now and didn't feel confident enough to write my own sketch for them and I couldn't find one that suited the unit so they sat in my parts box not being used. So I have been modifying sketches for a while now and finally I decided to write a sketch for the motor controller, it's the LC Technology HG7881CP Motor Controller, it's a full H Bridge and can carry 800mA total as well as 12V operation if you wish, it will run on 2.5V to 12V. The cost for this controller on eBay is about $2.00 to $5.00 delivered so it's as cheap as chips and will handle those cheap Arduino Robot Kits that use the little yellow geared motors. My tests showed that this motor only drew about 200mA to 600mA at stall on 5V so they should be perfect and that is what I used for this build except I purchased the robot kit from Jaycar Australia mainly because of the wheels that were in the kit so it cost me a lot more than you can buy them from China but I had to support the local bloke at least once, but at $54.00AUD it will be the last time, I'll make my own in future.


                                  This is the Schematic for the Controller

                               The HG7881CP H Bridge Motor Controller

The other components were a HC-SR04 Ultrasonic Sensor, an Arduino Pro Mini Clone, some 3mm MDF, 10mm dowel, assorted small washers, screws and plastic components for insulation and mounting the components not to mention wire, terminals and rechargeable batteries. As I mentioned I purchased the robot kit from Jaycar which came with a switch, two yellow geared motors, caster wheel, plastic chassis and nuts, screws standoffs and encoder wheels which I didn't use.

So, the first thing I did was research the HG7881CP controller and get all the information I could on it, the best bit of information was a Truth table and a list of terminal IDs.
  1. B - IA; Motor B input A, (IA)
  2. B - IB; Motor B input B, (IB)
  3. GND; Ground, 0 Volts
  4. VCC; Supply + Voltage, 2.5 to 12 Volts
  5. A - IA; Motor A input A, (IA)
  6. A - IB; Motor A input B, (IB)
Truth Table:   IA - IB      Motor State
                        L - L      |       OFF
                        H - L     |    Forward
                        L - H     |    Reverse
                        H - H    |        OFF

The other bit of information was that the IA connections should be PWM signals and that the IB connections should be Digital High or Low for Direction Control. With this information I stood on the shoulders of the great women and men that went before me and imported some code that I have used many times for control of the ultrasonic sensor, and went with  NewPing.h and using the truth table I wrote the void moveBackward, move Forward, moveRight and moveLeft as well as moveStop sketch instructions and rats nested the circuit on the bench and loaded the sketch into the Arduino Pro Mini clone and tested the operation of all components and to my surprise it worked perfectly first try, but needed some fine tuning once the robot was built.

                                    The components on the Bread-Board


Okay, the build started with me cutting out the top deck of the robot out of 3mm MDF, I like the robots I build to have a lower and upper deck and I also like to paint the bot to liven it up a bit, which is just what I did for this build. While the Paint was drying I started on the other components.

The HC-SR04 Ultrasonic Sensor needed a bracket and as always I make mine out of some universal PCB and solder the bits together to make up the bracket, see images below.

                                    The PCB cut to form the bracket

                The two parts soldered together so they are at 90 degrees

I then make up some wire supports to hold the Ultrasonic Sensor to the bracket and solder it all together so it becomes a sturdy mounting support,see images below.

                             The mounting wires soldered to the HC-SR04

                                     The finished bracket and HC-SR04

Sensor ready for mounting it now came time to mount the Arduino Pro Mini Clone to some PCB and fit some connection pins on the PCB as well so it can all be wired together and mounted on the robot chassis, doing it this way makes it very easy to mount and wire up. Now fit a 0.1 uF cap across the motor supply terminals to filter the brush noise from the motor to help protect the motor controller, I always do this. The paint was now dry and so I was able to start mounting the components onto the lower chassis, see images below.

                  The Motor with Mounting Bracket and Filter Capacitor


                A shape proof washer is always used on the motor bracket

I like to use a shake proof or star washer on the motor brackets and flat washers under the head of the screws to spread out the load of the screw over a larger area, helps prevent breakage especially on the plastic chassis.

           Flat washers under the head of the mounting screws for the motors


                 Both motors mounted to the underside of the lower chassis

                     Mounting screws and standoffs on the battery holder

I use plastic screws and standoffs on the battery holder to mount the holder to the lower chassis, safer so far as rubbing through the batteries etc and very easy to trim the head down so the batteries lay flat in the holder, works very well.

           Screws with flat washers to hold the standoffs for the rear caster


            Rear caster mounted on the standoffs with two flat washers per nut

The holes in the caster wheel are a bit big so I always put a flat washer both sides of each hole so it is a much safer and secure mount. You can also use a thread locker if you wish, up to you.

                              Caster mounted to rear of the lower chassis


               Pro Mini Clone and HG7881CP mounted to the lower chassis

The mounting of the other components depends on how you make up your bits and I also think about balance of the robot so it has good traction and weight distribution for stability on rough outside ground, yes this bot is intended for outdoor use in the sun.

                   With the components mounted the wiring can now be done


        The ON/OFF switch and Ultrasonic Sensor mounted on the upper chassis

The ultrasonic sensor and on/off switch were mounted on the upper chassis or top of the bot, no real reason other than it made it easy to get to the switch and to also get to the arduino for sketch uploading during the fine tuning process. Believe me it will take some fine tuning, no two motors are the same so you will need to adjust the speed of each motor etc.

                                    HC-SR04 mounted right at the front


                               Top deck on and wiring cable tied together

                                       Finished product ready for play

The sketch is a very simple one, the forward speed is controlled by PWM with respect to the positive part of the signal, if you look at the truth table you can see that it needs a High on IA and a Low on IB for forward BUT reverse needs the exact opposite so it needs more negative on IA to go faster in reverse, seems strange but you will see it as you play with the sketch, and do play with the sketch to make your bot perform better than the basic setup. Anyway here is the basic sketch;


//Code by Terrence J MacCabe and Arduino World Family
//Arduino ProMini is used in my Robot but most Arduinos could be used
//HG7881CP Motor Controller from LC Technology is used
//Max Motor Voltage is 12Volts with the HG7881CP but don't exceed motor safe voltage
//Max Current for the HG7881CP is 800mA (0.800A), test the current of your motors
//Motor1 IS Motor A and Motor2 IS Motor B
//For this code you need to install the NewPing libraries to your arduino software

#include <NewPing.h> 


#define TRIGGER_PIN  A4 //Trigger pin of Ultrasonic sensor connected to pin A4

#define ECHO_PIN     A5 //Echo pin of Ultrasonic sensor connected to pin A5 

#define MAX_DISTANCE 100 //The maximum distance we want the sensor to look for is 1m


const int Motor1PinIB = 8; //This selects forward or reverse via Digital High or Low

const int Motor2PinIB = 9; //This selects forward or reverse via Digital High or Low

const int Motor1PinIA =10; //This sets the speed via Analog PWM

const int Motor2PinIA = 11; //This sets the speed via Analog PWM



NewPing sonar(TRIGGER_PIN, ECHO_PIN, MAX_DISTANCE); //Create Ultrasonic Sensor Object


unsigned int time; //Variable to store how long it takes for the ultrasonic wave to come back          

int distance; //Variable to store the distance calculated from the sensor               

int triggerDistance = 20; //The distance we want the robot to look for a new path  

int fDistance; //Variable to store the distance in front of the robot              

int lDistance; //Variable to store the left distance from the robot

int rDistance; //Variable to store the right distance from the robot



void setup()

{

  pinMode(Motor1PinIB, OUTPUT);  

  pinMode(Motor2PinIB, OUTPUT);  

  pinMode(Motor1PinIA, OUTPUT);  

  pinMode(Motor2PinIA, OUTPUT);

}


void loop()

{

  scan();                               

  fDistance = distance;                 

  if(fDistance < triggerDistance){   

    moveBackward();                     

    delay(1000);

    moveRight();                        

    delay(600);

    moveStop();                         

    scan();                            

    rDistance = distance;               

    moveLeft();

    delay(1000);                        

    moveStop();                        

    scan();                            

    lDistance = distance;              

    if(lDistance < rDistance){          

      moveRight();                     

      delay(1000);

      moveForward();                   

    }

    else{

      moveForward();                    

    }

  }

  else{

    moveForward();                     

  }

}


void scan(){

  time = sonar.ping(); //Send out ping and store the time it took to return               

  distance = time / US_ROUNDTRIP_CM; //Convert time to distance  

  if(distance == 0){ //If no ping was received                  

    distance = 100; //Set the distance to Max Distance of 1m                   

  }

  delay(10);

}


void moveBackward(){

  digitalWrite(Motor1PinIB, HIGH); //Truth Table for the HG7881CP IB Reverse

  digitalWrite(Motor2PinIB, HIGH); //Truth Table for the HG7881CP IB Reverse

  analogWrite(Motor1PinIA, 100); //For reverse the Truth table indicates IA must be low most of the time for max speed

  analogWrite(Motor2PinIA, 100); //For reverse the Truth table indicates IA must be low most of the time for max speed

}


void moveForward(){

  digitalWrite(Motor1PinIB, LOW); //Truth Table indicates Low for the HG7881CP IB Forward

  digitalWrite(Motor2PinIB, LOW); //Truth Table indicates Low for the HG7881CP IB Forward

  analogWrite(Motor1PinIA, 170); //Speed set to 170 out of 255, Truth Table indicates IA must be High (PWM) for forward, change as required but do not exceed 255

  analogWrite(Motor2PinIA, 200); //Speed set to 200 out of 255, Truth Table indicates IA must be High (PWM) for forward, change as required but do not exceed 255

}


void moveRight(){

  digitalWrite(Motor1PinIB, LOW); //Truth Table for the HG7881CP IB Forward

  digitalWrite(Motor2PinIB, LOW); //Truth Table for the HG7881CP IB Forward

  analogWrite(Motor1PinIA, 10); //Right motor low speed, change as required

  analogWrite(Motor2PinIA, 200); //Left motor higher speed, change as required

}


void moveLeft(){

  digitalWrite(Motor1PinIB, LOW); //Truth Table for the HG7881CP IB Forward

  digitalWrite(Motor2PinIB, LOW); //Truth Table for the HG7881CP IB Forward

  analogWrite(Motor1PinIA, 200); //Right motor higher speed, change as required

  analogWrite(Motor2PinIA, 10); //Left motor low speed, change as required

}


void moveStop(){

  digitalWrite(Motor1PinIB, LOW); //Truth Table for the HG7881CP IB Stop

  digitalWrite(Motor2PinIB, LOW); //Truth Table for the HG7881CP IB Stop

  analogWrite(Motor1PinIA, 0); //Truth Table for the HG7881CP IA Stop

  analogWrite(Motor2PinIA, 0); //Truth Table for the HG7881CP IA Stop
 
  //Truth Table indicates all Pins on the HG7881CP must ALL be LOW OR HIGH for Stop

}


If you copy and paste the above code into your Arduino IDE it should work OK with the LC Technology Motor Controller HG7881CP and most Arduino Boards, it is intended for the above components only and will need to be rewritten for other components. As I said the sketch is very basic and was written for me to test the HG7881CP which was a great success, the motor controller works very well and doesn't get very warm at all so I highly recommend the HG7881CP for small low current motors and according to the information can be used to control a 4 wire stepper motor so it has many uses and is very cheap, I'll be getting a few more to add to my parts list. Hope this helps and have fun playing, Cheers, TJ.
This is a very short video of the above rolling robot, DC Bot.







Tuesday 5 May 2015

DAGU, Line Tracing Car V2 Product Review

I purchased this kit car from Hobby King and had no intention of doing a product review until I was all but finished the build, it was great fun building it, took me back to when I used to build electronic kits on a very regular basis and I thought it is a fantastic starting kit for the young robot pilots out there. The kit comes complete, well 99.9% complete, you need to supply your own batteries which is best in my opinion. DAGU from China makes the kit and in Dagu form it is a well made kit and the price was very good, actually it was fantastic given what you get, $14.85AUD in my book is cheap but the killer was the freight, I purchased two items and it cost $22.90AUD to get them posted to Australia from China so the total cost was $26.30AUD when you share the post between the two items. On the plus side it only took 8 days to get here instead of the normal 20 plus days it can take.


                                   The Instruction manual DG-2000V2

The instruction manual is very good and easy to read given the English translation is at times a bit funny but good enough to totally understand. The illustrations are very good but you will need your glasses on to see some of the numbering on the circuit diagram. As always you need to read all the instructions first that way you won't make silly mistakes as you build the robot car like I did so be patient and read.

                                     The Line Tracing Car V2 Finished

                                               The Car from Above

The control circuit is built around a Quad 2 Input NAND gate (Not AND Gate) 74HC00 and two sets of Red LEDs and Photo transistors mounted in a plastic light shielding holders and is wired in a voltage divider network that can be set by two 500K variable resistors as they call them (potentiometer) and two C2120 NPN transistors wired to switch the negative side of each motor to earth. I added two 0.1uF capacitors across the motor power supply terminals (they didn't come in the kit) at the motor terminals to act as filters to help protect the transistors. The circuit is simple and it works very well, I set both pots to 0.8V and this setting worked perfectly first try, a bit of simple maths gave me that voltage from the 74HC00 data sheet that can be downloaded from the net, rough maths at that let me tell you.

                                 The Light Shield and 74HC00 NAND Gate

The only little bit that wasn't 100% was the polarity of the RHS motor wiring, it had to be reversed to get it to run the correct way but that is simple with permanent magnet motors you just swap the wires around and away it went, otherwise the instructions are perfect. The car is built on the PCB which forms the chassis and the gear set are open so you can see the operation of the gear train which is perfect for learning how a gearbox works. The complete kit is one of the best learning kits I have ever built, it's easy, fun and the finished product is fun as well.

                                      The Gear Train, Motor and Wheel

                                    The Rear Wing and associated LEDs

The rear wing has two Red LEDs and three RGB LEDs, the red LEDs are connected in parallel to the output from the 74HC00 that goes to the base of the transistor so it comes on when ever the LH or RH motors are working and the three RGB LEDs have a chip inside them that switches the LEDs through the three colours Red, Green and Blue at random and they are powered all the time and it looks fantastic as the car follows the line on the floor, table or whatever you set up the track on.

                             The Ball Caster, Axle Mount and Light Shield

You can see the Light Shield on the right in the above image, the Red LEDs were mounted in the front holes and the photo transistors were mounted in the rear holes and both were of different sizes so you couldn't make a mistake and it even had flats so you could get the components around the correct way when you put them through the holes, an excellent set up for the beginner. The other thing that worried me a bit was the metal ball caster, it was mounted on the printed circuit side of the PCB so I cut out two small bits of plastic and insulated the board with them just in case the caster rubbed through and shorted the circuit, I also didn't over tighten the mounting screws, just to be safe.
My final verdict of this kit is 8 out of 10 and I highly recommend it to the novice robot pilot, all you need is good soldering skills and the patients to follow the instructions and you will have a lot of fun with this kit and with the finished car. The Line that it Follows is simply Black Electricians Tape on a white surface, my kitchen table is white but you could use a few white cardboard sheets taped together and it needs to be used in a room with dull light for best results, so have fun, cheers.