Banner Image Banner Image Banner Image
     Home Page > School > Visitors > Greenpower : Datalogging

    Datalogging
     Printer Icon Printable View      Text Size: A | A | A | A

The key feature of any Greenpower car is efficiency - a lightweight, slim car with good aerodynamics and an efficient driver is required to make the best of the energy available in the batteries and turn it into the greatest distance over the 4 hours of a race.

With this in mind its useful to quantify and measure how the car behaves on the circuit. At the end of the 2007 season just in time for the Goodwood final we assembled our own datalogging for Franc. 12 months on, in time for the Bedford heat we added our own car-to-pits telemetry system so the car could send data back to the pits whilst on circuit.

Picaxe Datalogger

Datalogger unit A school-built logger that records motor temperature and current draw. This is based on a Picaxe microprocessor and logs to 2MB of flash memory - more than enough for practise and race when logging approximately every 2 seconds. The PCB and components for the Picaxe datalogger are available from Rapid electronics as a kit. The unit runs from 3 AA batteries and logged data can be uploaded to a laptop quite easily via USB interface.

The Picaxe kit offers 3 analogue to digital converters, a dedicated channel for a digital temperature sensor and some digital outputs. The temperature sensor is an accurate device which returns a value in whole-degrees Celsius. They are electrically fragile little devices so connections and cable need to be high quality and be kept away from the 24v circuit wiring. That said, we've only had one failure.

We used to use one of the inputs with a reed switch; located next to a magnet set into our drive pulley, bicycle-computer style. By having the Picaxe count the pulses we could estimate and log Franc's speed. We've abandoned that approach as reading the value from the temperature sensor takes around 750ms - long enough to miss a few pulses, which you then have to estimate and the whole thing quickly becomes an inaccurate fudge! (speed logging has since been taken over by our GPS unit).

We have a spare input on the picaxe at the moment which we're considering what to do with. One option is attaching a potentiometer to the steering column to record steering wheel position. It might give some interesting information on the habits of our drivers. Another possibility is interfacing the brake light with the datalogger to record brake activity - again an interesting insight into our driver's behaviour!

There is an optional clock upgrade for the datalogger kit which allows the time to be logged along with the data which is very useful for matching the current and temperature data to the GPS data (see below). However, although they always work when we install them they always break after a few hours of use and don't return the correct time anymore. We don't know what we're doing wrong!

LCD Kit for dataloggerThere is an LCD kit available to work with the Picaxe which we have tried as a way of warning the driver of high motor temperatures or current draw. Although functional it never made it onto the car as since Franc has only a single-gear there's very little a driver can do with the information. We might use one of the outputs to illuminate an LED on the steering wheel if the motor temperature reaches a threshold level.

Example Data

Current draw over two laps of Dunton:

Current draw over 3 laps of Dunton

(Click image to enlarge)

A: Freewheeling into the hairpin

B: Accelerating out of the hairpin

C: The 2 straights and large banked corner. The current drops as the car comes back towards the hairpin as the wind was blowing in that direction.

 

GPS Datalogger

The second datalogger is a small GPS unit powered by a single AA battery. The unit logs time, longitude, latitude and altitude to its internal memory at 1 second intervals. This data can then be uploaded via usb to a laptop. The position information can be turned into speed and acceleration and be used to extract lap and pitstop times. Harsh acceleration and (worst of all!) braking can be identified. The resolution and accuracy is just enough to compare the different lines taken by different drivers through a corner compared to the amount of speed they maintained through the bend. Accuracy of total distance determined by the GPS compares favourably with the figures from the lap counters and cycle computer.

Example Data

Ground plot of Dunton Race

(Click image to enlarge)

The chart above shows the ground plot from the coordinates recorded by the GPS unit and shows the Dunton circuit with its tight hairpin at one end and large banked turn at the other. Note the extra loop on one lap at the hairpin end - that is where we were in the paddock changing two wheels! The other extra trail at the hairpin is pushing the car back to the minibus after the finish of the race.

Comparison of the speed of two drivers around 2 laps of Dunton

(Click image to enlarge)

The chart above shows the speeds of two drivers around two laps of the Dunton circuit. "Driver 1"  (green line) was driving later in the race and had more tired batteries than "Driver 2" hence the lower top speed. The chart shows the slowing down necessary to navigate the hairpin. Notice that "Driver 1" carried much more speed through the hairpin whereas "Driver 1" had to slow right down on one lap - probably due to traffic.

Telemetry

Logging motor temperature is useful information however, its of little use to be able to find out the exact moment your motor goes from being a useful part to an overheated lump of scrap after the event. With that in mind we decided to implement some means for the car to be able to send information back to the pits.

The system uses XBee wireless modules - these are low cost, license free radio modules which use the 2.4Ghz spectrum. They can be configured to provide a simple error-free communication service between two serial devices.

In the Car

One Xbee is built onto a Picaxe Connect board (PCB available from Revolution Education). This is the 'transmitter' end which is linked to the datalogger described above via the datalink port. The picaxe on this board is programmed to wait for a signal from the pits then request data from the datalogger and forward it to the pits via the Xbee. The unit is battery powered and sits on the rear deck of Fireblade, packaged in a (hopefully - but as yet untested) waterproof enclosure.

Xbee on Pixaxe Connect Board

Above: Xbee installed on a Picaxe Connect board.

Car transmitter/receiver

Above: Xbee mounted on Fireblade

In the Pits

The 'pits' end uses another Connect board, instead of having a Picaxe installed this board has an RS232 interface chip which allows the board to be interfaced with a PC via the normal picaxe interface cable.

The PC runs an application written in vb.net which receives the data from the car, displays it and logs it to a database.

Dashboard

Telemetry App

Data is transferred from car to pits each time the car passes the pits.

divider  

Quicklinks: [Webmail], [Return to Homepage] [Search]
School:
[Students] [Staff] [Parents] [Visitors]
College:
[Visitors] [Students]

This page is maintained by M Barker
email: barkerm.
Non Philip Morant users should add @philipmorant.essex.sch.uk to create a full email address
©MMIV The Philip Morant School
Page Last modified: 4/6/2009 2:40:12 PM
How to Contact Us
This site uses Accesskeys
By using this site you are accepting its terms and conditions.