Posts: 1
Joined: Fri Dec 28, 2012 10:23 pm

Re: Race vehicle data logger.

Fri Dec 28, 2012 10:25 pm

Hi All

Has anyone taken this any further?



Posts: 4
Joined: Thu Jan 03, 2013 8:39 pm
Location: Northern California
Contact: Website

Re: Race vehicle data logger.

Thu Jan 03, 2013 9:17 pm

I am new here and to the Raspberry Pi. I am building a race car for Bonneville and have a basic data logger for the engine, which I could barley afford. I need more data from other locations of components in the car, like water tank in and out and air to and from the supercharger and also exhaust. I found some 2 wire analog thermocouples but want to know if they will work with the Raspberry Pi or if you know of any that will work with it so I can record temps.

Any help would be great...

Posts: 5
Joined: Tue Jan 08, 2013 4:59 pm

Re: Race vehicle data logger.

Tue Jan 08, 2013 5:37 pm

This discussion shows one major point: There is a market for a low cost data logger/system/etc, in many fields. I am not a coder, but I do see the need.

I am looking to monitor beehives (weight, temp, humidity, entry/exit counter) and make the raw data accessible via an up-link. What you all have been discussing is one short hop away from what I am looking for.

I came across this in my search: Not sure if it would serve any of the race crowd need.

Has anyone of this crew developed a more formal requirement list, or a sensor interface doc? I know that is not the guts of the issue from the programming side, but it can drive a development process. I'd love to be involved, let me know how I can help. Thnx

Posts: 2
Joined: Wed Dec 12, 2012 5:08 pm

Re: Race vehicle data logger.

Tue Jan 08, 2013 7:02 pm

You know I hadnt really thought about it that way but roger I think your right, as we all tend to get more and more into monitoring our machine data the idea of a generic data logger market for cheap is prob a real one indeed. esp now that people are monitoring everything from home security to their thermostat with data loggers and managing them from their smart phones as well as trending data in the case of thermostats.
While I havent gotten to the point of getting hardware together and attempting anything on that end, I have been developing a backbone of a splunk app (still in the ui phase at the moment as i have no data to parse) to run analytics against the log data that way all a person needs is the logs dump them onto any computer and using an open source software (when using the free license which is fine for personal non enterprise use) can view and trend their data. If your not familiar with splunk check out which is something they did for the 2012 elections kinda a show and tell to the nation on their software. (I'm a splunk admin by day at my company so I'm certainly down to help out on that end if anyone has any log data they can send me I can work with)


Posts: 5
Joined: Tue Jan 08, 2013 4:59 pm

Re: Race vehicle data logger.

Tue Jan 08, 2013 7:58 pm

Brandon, this may work into something.

By the way the DexOS site is way cool, too, and may be a way to deal with data logging. But if it is already built in Splunk...

Dex, how would you deal with multiple real-time sensor streams?

Seems you need some device to interface multiple sensors. I just talked to the Dataq people, just trying to frame out how all this fits together. Being a bear of very little brain, what I think I know is this:
Sensors-->Dataq 145 aggregtor ($29) -->RaspberryPi running Splunk as a data logger, or with DexOS capture built from the ground up. But maybe Dex is talking about both the sensor aggregator and data logging in the same device.

I am researching sensors now. I know what I need, but you race folks, sailboat folks will have a different set of needs. Let's start collecting info on sensors for the following, and folks, add in as needed.
- Temp (multiple, ecoRi, Rogerw, others)
- Humidity
- Weight
- Torque
- Rotation speed/direction (multiple, ecoRi, Rogerw, others)
- Position (multiple, ecoRi, Rogerw, others)
- Flow, liquid and air at temperature (aarone's request)
- GPS position (for calling in airstrikes on your competitor's car.... Sorry, couldn't resist) (ecoRi)
- Acceleration (ecoRi, others probably)
- Video

The Dataq 145 gets power via USB, transfers a stream northbound that has to be captured by some computer, hence the place for the Pi or other system like it (Shiva, etc). It takes inputs of +/- 10v, so all sensors would need to be in this range if using this device. What I don't know is what to do with microV sensor outputs if we run across that, or whether there is any standard for this sort of thing.

EcoRi, DexOS, speak up on how you might see this progressing. Better/worse doing something with more off-the-shelf versus home-cooked? I am thinking longer term support, development, etc., but the appeal of Dex's "InstaBoot" and other points about talking directly to the hardware also make sense. I feel like a one-armed juggler...

Posts: 117
Joined: Thu Jan 12, 2012 11:46 am

Re: Race vehicle data logger.

Tue Jan 08, 2013 8:43 pm

I built a non-pi and non race datalogger using a cheap £0 ELM327 based bluetooth system ... 4ab974bd96

Software was PyODB

Worked okay... update rate sucked though :P

For some funky accelerometers, you can use the 2 axis accelerometer which can interface to the Pi using I2C (4 wires and it will work) ... 0-adxl345/

For Temperature sensors, these work a treat (1 wire digital thermometers that can be connected in parallel) ... r-ds18b20/

For fuel consumption, I used a RS Components fuel flow sender (quite expensive but worth it) to a custom board that counted the pulses although I think the Pi can do it.

Some more advanced monitoring of the fluid levels and such require some interfacing but its not difficult... the fun part was interfacing thermocouples for the cylinder head temperature and the exhaust gas temperature. ( ... r-4-input/ for a USB sampler)
RaspberryPi's galore
Solid run CuBox
ODroid U2

User avatar
Posts: 876
Joined: Wed May 16, 2012 6:32 pm
Contact: Website

Re: Race vehicle data logger.

Wed Jan 09, 2013 6:40 pm

Hi, i am coming at this from a coders point of view, i want to make DexOS (DexBasic) as useful as possible for projects like this, both hobby and commercial.
So i am busy adding the functions, that will make it possible to be used for RT data logging etc.
To this end i have open sourced the DexOS, to help speed up the process of adding more features, by letting other coders add to it or modding the code.
But i am open to requests, for new features and interfaces etc.

I have also done some work with the ELM327 chip and the pi, along with DexOS.
Batteries not included, Some assembly required.

Posts: 5
Joined: Tue Jan 08, 2013 4:59 pm

Re: Race vehicle data logger.

Wed Jan 09, 2013 11:05 pm

Dex, thank very much for your offer. Please let me know how you might want the specs. Not being a coder, I am not sure where our demarc falls, and I need to know the language you need to hear.

For instance, I would think we would the need the ability to take in 16 sensor inputs (picked out of the air, but reasonable for the race crew). Now, if they are to come into your DexOS Pi, we would need to know how they get there, how you deal with them, etc. If you need something in the middle (like the Dataq 145) and want to take input from that, then there is a different set of specs. And, rotation sensors could be only Hall sensors, or they could be someone's built board. The Pi inputs would be different, depending. Could you comment on this?

Then, once you have the data from the sensors, we need to develop a straightforward form for storage, access by higher-level programs that display or manipulate the data, or to send northbound. Being a non-programmer, I am thinking something like a .csv or .rtf type of file - accessible by most anything. But there may be a lower level database model that makes better sense. For instance, Brandon, weigh in on what Splunk could take as an input source. That is what Dex needs to support as his output.

For RichardP, many thanks! I got in touch with Proto-pic from your suggestion, and Richard Winton was kind enough to recommend places on my side of the pond with similar gear. And more generous, he offered outfits that do similar stuff they do in design. !00% kudos to Proto-pic and Mr. Winton. Many thanks!, and were his leads.


Posts: 1
Joined: Fri Jan 18, 2013 2:48 pm

Re: Race vehicle data logger.

Fri Jan 18, 2013 3:13 pm

Roger, you're right in that you need an extra interface between the Pi and the sensors since the Pi doesn't have any analogue input capability. You can use the GPIO directly but you are very limited on the number of sensors and they must all be digital.

I think a better approach might be to use a board that has analogue inputs already on - the mbed here has 6 of these and can be used in multiples connected together. The data can then be downloaded by ethernet or from a SD card on a breakout board.

Since it's much lower power, you could have a much longer battery life. The data processing will also be faster and easier when downloaded to something much faster after a run than on the fly on a Pi. However you wouldn't really be able to have extra interfaces like a screen connected, for example. What do you all think?

Also from my (limited) coding experience I'd save to any kind of text file with an easy to use delimiter like a tab space or a comma (.csv), it makes importing the data into most programs much simpler.

Posts: 5
Joined: Tue Jan 08, 2013 4:59 pm

Re: Race vehicle data logger.

Sat Jan 19, 2013 1:50 am

Jr, looks like this would work, but obviously not out of the box. And I don' t yet understand what it sends upstream, what the Pi (or other computer) might be getting. Need to read more...

For others, this is what already exists in code for the gizmo for what Jr suggested, stuff that might be of interest to the race crowd:


LIS302 Accelerometer - Triple axis digital SPI accelerometer
ADXL345 Accelerometer - Triple axis digital accelerometer
SCA3000 Accelerometer - Triple axis digital accelerometer
Grove 3 axis Accelerometer - Triple axis digital I2C accelerometer


GlobalSat EM-406 GPS Module
GlobalSat BR355 Serial GPS unit - using a Sparkfun RS232 breakout and a PS/2 breakout for power
ITG-3200 Gyroscope - Triple axis digital gyroscope
SRF08 Ultrasonic Ranger - I2C Ranging sensor
SRF05 Ultrasonic Ranger - Simple ranging sensor
Seeed grove ultrasonic ranger - Single wire ranging sensor
Parallax Laser Range Finder - Laser and CMOS camera with 1Hz updates and 15-122CM range
SCP1000 Pressure Sensor - SPI MEMS barometric, absolute pressure sensor
Bosch BMP085 Pressure Sensor - I2C MEMS barometric, absolute pressure sensor
Freescale MPL115A Digital Barometer - I2C MEMS barometric and temperature sensor
RHT03 Humidity and Temperature sensor - A digital humidity and temperature sensor

I didn't see anything specific for rotational or position sensors, but obviously the board has that capability once the code was written or tweaked from other sensors.

Posts: 5
Joined: Tue Jan 08, 2013 4:59 pm

Re: Race vehicle data logger.

Sat Jan 19, 2013 2:19 am

Digging a bit on a site that promotes the Arduino prototyping board, I find a list of possible suppliers that might be of interest to this group:

USA: SparkFun, Maker Store, Adafruit Industries, Little Bird Electronics, Modern Device, FunGizmos, NKC Electronics, Gravitech, RobotShop, Liquidware, Hacktronics, MakerBot Industries, Microcontroller Pros, Curious Inventor, AeroQuad, CuteDigi, EIO, Teach me to make, UltiMachine,, Electronics is Fun, AME - After Midnight Engineering, Trossen Robotics, Jameco, Zagros Robotics, Advanced Micro Circuits Corp, iHeartEngineering, 3D Robotics, Jaycon Systems, Elexp, Abra-electronics, Reuseum, Pololu, 411 Technology Systems, Handmadecircuits, ManyLabs, Epictinker, Woodman Studios, LLC, oddWires, Siliphi LLC, Karlsson Robotic, RadioShack

Posts: 1
Joined: Mon Feb 18, 2013 4:08 pm

Re: Race vehicle data logger.

Mon Feb 18, 2013 4:14 pm

Hey guys. I'm actually building the same thing.

Currently I'm using an Arduino, but since the Pi came out, I'd like to start to expand.

At the moment I inputseveral 0-5V inputs (Engine Oil Temp, Oil Pressure, Coolant Temp) and a couple interrupts (Engine RPM, Vehicle Speed Sensor). I then process them and send serial data via bluetooth to my Android device. I've written a very basic app in Android to process this information and display the values. It was working, but I've hacked the code up to do it in a better method and to enable saving data.

If you guys are interested in working with me on this, let me know. I need more developers. I can do Arduino (C) /Android (Java), but I'd need some Python guys if I start working with Pi.

[email protected]

Posts: 6
Joined: Wed Aug 15, 2012 10:52 pm

Re: Race vehicle data logger.

Sun Feb 24, 2013 10:15 am

Howdy all,

I'd like to point you all to Loguio: it's basically exactly what we're looking about for and it's already working; gps, tri axis accelerometers, temp and position sensors, etc are all currently up and running, but It's a pure logger. There is no reason that the logs cannot be passed realtime onto a pi in order to deal with wireless transmission of data, video recording, diy dash display,etc. It's based on arduino mega so there are tons of inputs and if you have a megasquirt it already will record all engine data. it seems silly to re-invent the wheel, when a solution already exists. Perhaps the talent here should focus on programming for new loguino sensors and getting a rasberry pi to interface with it.


Posts: 1
Joined: Sun May 19, 2013 12:06 pm

Re: Race vehicle data logger.

Sun May 19, 2013 7:25 pm


I have just finished looking at the code of Loguino and could not find any reference to frequency based sensors like rpm sensors and axle/wheel speed sensors.

We can not capture the data from these sensors using the polling system because we might miss some data.

Has anyone added this functionality to loguino?

Or know of any other open source system that does that?


Posts: 1
Joined: Tue May 28, 2013 5:12 pm

Re: Race vehicle data logger.

Tue May 28, 2013 5:30 pm


I will do almost to the same thing for my racing bike. For the moment I just need:

GPS position (10Hz)
Recording HD video (with Rpi cam)
Lap time

Could you tell me where you are in the project?


Posts: 1
Joined: Mon Jun 03, 2013 9:23 pm

Re: Race vehicle data logger.

Tue Jun 04, 2013 1:02 am

Hi guys,

I've just come across this thread last night and have been thinking of something along very similar lines, although was initially thinking using an Android or IOS device as the logger due to the video player, g-sensor, and everything else, and then adding bluetooth for sensors etc. Wasn't sure if this would work because I'm not skilled in these areas.

Where I am skilled though is with front end web development and design, and also industrial design. I'm currently developing browser based data analysis. I have found that every single data logger manufacturer has software for PC only (I'm a designer on a mac) and that for a driver a laptop isn't always the best tool when analysing data, so my browser based software will work on all platforms (as long as the browser is html5 compliant). At this stage it's being setup to read from CSV's only but it would be much better if this was compressed. The idea is that a user can store their files on the cloud and then be able to access their data from anywhere on any computer, that can be downloaded or viewed at anytime. This might be of use to this project?

Would it be possible to have the device 3G compatible t then automatically send data directly to a server - by the time you're back in the pits the data is available to the crew or driver.... just a thought.

On a different note I would also be happy to design and manufacture casings to a motorsport spec and then offer them at close to cost price.

Very keen to see this up and running.

Posts: 1
Joined: Wed Jul 31, 2013 8:03 am

Re: Race vehicle data logger.

Wed Jul 31, 2013 9:58 am

I'm going to capture Steering, Throttle and Brakes via potentiometers on the car (in progress). I'll also capture revs and speed from the onboard computer socket in the dash.

I've got an Arduino Mega hooked up to a Pi just using the usb cable. Some pots connected to the Arduino which sends the state of each in a comma seperated line to the PI, which timestamps (in miliseconds) to a log available on it's web server, so I can wifi the laptop and take a look. Eventually I'll write a web app that produces graphs, lets my download the raw csv etc. All works brilliantly so far on the kitchen table!

My issue is with making the brackets for the potentiometers and faders for the steering throttle and brake. It's a bit of fabrication skills I lack really.

Long term, the PI will log the data, and my phone will capture the video, accelerometer and GPS so I can at least overlay (quite easily) via the trackmaster app data on the video r just sync the video up with the telemetry to see where I'm going wrong :lol:

Posts: 2
Joined: Thu Nov 14, 2013 11:18 pm

Re: Race vehicle data logger.

Thu Nov 14, 2013 11:29 pm

I have been looking at data logging for motorcycle applications using conventional sensors. I already use a blue tooth OBD2 dongle to send OBD2 data in my Honda Ridgeline to my Nexus7 running the Torque app.

So my questions is this, as the display function is already built why not write code for the Pi that generates generic OBD2 data that can then be sent via blue tooth module to an android device for display and logging (Shadow Dash)?

I am under the impression that OBD2 is open source as it is mandatory for all vehicles now. I realize that some of the "behind the scenes" CAN bus information is proprietary but surely the generic code pumped out at my OBD2 connector is well known.


Posts: 58
Joined: Sun Sep 29, 2013 4:28 pm

Re: Race vehicle data logger.

Sun Nov 17, 2013 12:49 pm

I think that's a good idea Greg.

If you use an Android app which looks to 'speak' ELM327, then generating ELM327 at the Pi is totally feasible.

I've completed a couple of projects using the ELM327 and found the command structure to be very easy to work with. The datasheets contain all the important information, on command structure and timing.

The standard PIDs are all easy to use. Just need to remember to program PIDs 20, 40 and 60 etc accordingly to produce the correct response for Torque etc (If Torque even pays attention to PIDs 20, 40, 60 etc ?)


Posts: 2
Joined: Thu Nov 14, 2013 11:18 pm

Re: Race vehicle data logger.

Wed Nov 20, 2013 2:37 am


Thank you so much for taking the time to reply to my post, while I am not new to programming my knowledge comes from writing very crude BASIC programs some 35 years ago so to all intents and purpose I am a total novice.

I'm sure that most, if not all I was contemplating could be accomplished using Arduino, but the RP is so inexpensive & versatile that I thought it would make a great project for adding sensor monitoring to motorcycles that until recently have not used it in the same way automobiles have.

I recently purchased a 2001 motorcycle and was looking for gauges to add to it, oil pressure and temperature, tachometer, coolant temp etc etc, but the commercially available gauges gave me sticker shock. So I started to investigate measurement & data logging options, which led me to this thread, I already knew about the Pi.

Thanks for the links, I need to read more, lots more but it's a starting point. If you have any other pointers and suggestions please let me know. I think something so basic and inexpensive would be quite popular with the motorcycle and carting enthusiasts.

Probably time for me to pony up some cash and invest in a Pi and some peripherals, hopefully my 62 year old brain will still be able to cope with something new when I try to teach it programming, what language would you suggest? I was thinking Python!!! I'm okay with the electronics parts.


Posts: 58
Joined: Sun Sep 29, 2013 4:28 pm

Re: Race vehicle data logger.

Wed Nov 20, 2013 11:14 am

No problem Greg, the key thing (for an easy time with this) is to use the ELM327.

It has an AT command set (remember that from the dialup days ? )

You would need to only start the bluetooth connection, then send it a couple of AT commands which tell it which OBD protocol to use, EG 'ATP5' for protocol 5, and a couple of simple CANbus initialisation commands (but even they are sometimes optional) and it's ready to talk to you

You now know almost everything that you need to know....

There are just two other things yoiu need to know exist - a 'mode', and a 'parameter ID (PID)'

Mode '01' (in ascii) is a read reaquest. So the start of your message begins '01xx' and yoiu replace 'xx' with the parameter ID which you want to read, for example RPM has a standard parameter ID of '0C'

So you've made the bluetooth connection and have a terminal open on your Android/Windows device or send a couple of AT commands to initialise the ELM (the ELM327 will usually store those for the next session too so yoiu might only ever need to enter them one time).....and then if you want to know the current RPM then you really honestly and truthfully only need to transmit '01OC' from your terminal.

For 010C you will get a response which will include the RPM of the engine. The response will need a little bit of decoding, but it is nothing more difficult usually than a coup;le of hex bytes.

So to finsh the job...
for coolant temperature send '0105'
for oil temp send '015C'

Using the list o f PIDs from here, ,you can see that you only need to send the first couple of bytes to the ELM327 and it will do all the hard work and give you a meaningful response....

There are a couple of caveats. The first is that there is usually a limit to the rate at which you can request parameters. Asking for a 20Hz refresh rate will cause problems (there will be no ill effects, but the ECU will respond with a 'request refused' message). The other problem is that some manufacturers mask off some PIDs and you need to be in a factory diagnostic mode to be able to read those....hence how they charge so much for diagnostic equipment sometimes....

There is enough info on the web to make the trickier PIDs simple to read so I would have a go anyway.

You can save some money too,because if you connect to your bluetooth dongle and you have an EML light on your dashboard showing a fault, which you need to clear, then you simply send ascii '04' to the ELM and it clears the ECU warning light !

Other things you can do are more interesting. For example my car has had a problem with the diesel particulate filter in the exhaust system which blocked and caused me problems. To reset the soot counters for it (and to tell the car I have a new filter) I needed to only go into the test mode '06' and issue command '15', and now I have control of when the car regenerates the filter. It normally regenerates a new filter 15 hours after the test has been run. I drilled a hole through my filter to make it free flowing and have piggy-backed a microchip pic in the dongle, where the old bluetooth module was and now it resets the filter every 12 hours, so it never trieds to regenerate an empty filter !


Posts: 58
Joined: Sun Sep 29, 2013 4:28 pm

Re: Race vehicle data logger.

Wed Nov 20, 2013 12:24 pm


I'm actually new to the Pi too. I'm using Python to make an internet RSS feed reader, parse the information and send the output to the serial port so that we can have a scrolling news display in the lounge (wife is an ex journalist) The control panel for it is an inbuilt web interface running on the Pi, so I just connect to it via my wifi and deal with it's web pages.

This is my first Python project, I've previously uised Basic and done a lot of work using assembler on Microchip PICs. In fact this project was going to be PIC/Arduino based (new to Arduino too..) but then i sketched out the amount of coding which would be required....and when I added in the cost of the wifi module, and then the power supply, and if I wanted to have a user screen I would have to add an LCD...then jumping to the Pi seemed the better deal.

I'm so far pleased with Python (very pleased), it has some quirks - I'm new to object oriented programming, OOP, so learning the details of that is an ongoing process....but, my script isn't particularly object orientated and I can use traditional sequential processing quite well.

For the amount of time which I've spent on the actuall coding, and the fact that I've got a near working solution in under 100 lines of Python is a testament to the ease of use, and especially the overall quality of built in functions and libraries which come with Python.

For your application, then I guess you need to only use the serial port to send messags and receive the responses into a buffer. then dig out the impoirtant part of the response (easy with Python which has good string handling capability), then you just use some of the inbuilt stuff, maybe 'Tkinter', to show the values on a composite video or HDMI based portable screen. I would think it's very easy to tackle and the ability to use the inbuilt modules means that, importantly, changing the code do something else is very don't have to tear up hundreds of lines of custom code, when you use the inbuilt modules.

If you want to try then check this out....I wondered if the Python I was writing on the Pi would run also run on my laptop (Windows) so that I could work on the code while at work (mobile service engineer, so often standing about on customer sites waiting for things to go wrong). I donloaded Python 2.7 for Windows, then copied my Pi Python code into a file on my laptop and ran it _*without making a single change*_ and it worked immediately, in exactly the same way as it does on my Pi.

2 things here - I am so pleased at this cross platform compatibility first of all, finally we seem to have a true cross-platform language (C never was this easy for me), and Python is so much easier to work with than JAVA. And Also it means that you can get started with Python, for free, without needing to buy a Pi. Of course, you should still buy a Pi anyway ;)


Posts: 2
Joined: Mon Jun 15, 2015 4:17 am

Re: Race vehicle data logger.

Mon Jun 15, 2015 4:38 am

I am very excited to have found my way to this thread.

I am racing Superkarts and looking to create a data logger to capture Revs, Speed, Track map/Times (using GPS), EGT (Exhaust Gas Temp x2) and Water Temperature in real time for immediate Dashboard display as well as for analysis after race day.

I have seen most of what I am looking for here which is simply awesome, but haven't seen anything yet on Exhaust Gas Temperature. We run around the 600 Degree Celsius mark with twin a cylinder machine and although I've just started looking for sensors or probes for this temp range I haven't found any yet.

Anyone have any suggestions or recommendations?

Posts: 2
Joined: Tue Dec 08, 2015 12:35 pm

Re: Race vehicle data logger.

Tue Dec 08, 2015 1:08 pm


Use brake temps sensors, 600P° is the sweet spot for them, they can go up to 1200° (not for long), you can get the "spring" type which will push the thermocouple on the exhaust (use outside of exhaust) or the "sliding" bit which will rest on the the exhaust.

Since you have no movement (remember they are used on brake discs which rotate all the time) they will last forever...

Google for "brake temperature sensor" and pick your choice....

Return to “Other projects”