speedometer update

May 21, 2008 – 5:54 pm

I’ve been done with the first speedometer prototype for a few weeks now, so it’s time for a tiny follow-up post. Short version: it rocks! Clear, readable, accurate, useful, gets comments. So far, it hasn’t skipped a beat even with all the vibration from the TS1.

The thing on the left is a bar that grows with RPM. The right hand readout and bar graph is for EGT or CHT, but I don’t have a sender hooked up to it yet.

On the other hand, I’m compiling a list of improvements that I’d like to make. The speed and RPM update in real time, which is great for the speed and terrible for the RPM. RPM needs to have bigger leading digits and update maybe once every quarter second. The backlight needs to turn on sooner than it does; it doesn’t impact readability at all in bright light like I worried it might. I need to be more careful about startup and power-down so that the display never blinks or gets stuck in weird states when the power is going on and off.

My biggest irritation is that I really want to have a button for function selection, but I can’t think of a sufficiently rugged and unintrusive way to add one. I don’t think it’s going to happen. This makes a trip odometer pretty much impossible.

I’m also starting to think about production issues. The faceplate needs to be prettied up a little, there are some light-blocking and anti-vibration bits inside that I made by hand, and the cabling and connectors are going to be labor-intensive. Everyone will have slightly different needs depending on their stator voltage, number of coils, and whether they’re running a temperature gauge. Then there’s the question of faceplate color and backlight color. It’s going to be interesting getting all of this stuff worked out in a practical manner.

…and I am seriously thinking about adding a USB port somehow to download speed and RPM data so you can use this thing like a mini-dynamometer. We’ll see.

  1. 19 Responses to “speedometer update”

  2. Excellent, how is the speed sent to the speedometer, is it via a magnet sensor like on bicycle computers.

    I tried similar myself using a bike computer, see this link:

    http://forums.lcgb.co.uk/phpBB2/viewtopic.php?t=15082&highlight=

    But yours is much better, do you think you will sell them and how much?

    If not have you got plans you could send me and suppliers etc.

    Cheers.

    By Lamb.Man on Jun 3, 2008

  3. Sticking the bike computer into a gutted speedometer casing is a good trick! Nice work.

    That thread mentions a fuel warning light… do you have one working? I’m really curious how something like that would work.

    Thanks for the feedback. Yeah, I intend to produce and sell these, although it will probably take me a few months to get everything worked out. If that ends up not happening for some reason then I’ll post the plans.

    The speedometer pickup is a magnet sensor, although I’m using a hall effect sensor for the pickup instead of an inductive sensor like most bike computers use.

    By jsco on Jun 3, 2008

  4. Hello again,

    I will look forward to seeing how much you will sell these for, I am very interested, please keep me updated.

    Here are a couple of links to the fuel warning light mentioned:

    http://ccgi.bowden.force9.co.uk/catalog/product_info.php?cPath=128_46&products_id=707

    http://ccgi.bowden.force9.co.uk/catalog/product_info.php?cPath=128_46&products_id=2677

    Hope this helps you out!

    By Lamb.Man on Jun 4, 2008

  5. ah, it’s a custom tap with what looks like a float switch. that’s fantastic! i think i need another LED on the speedometer now.

    By jsco on Jun 4, 2008

  6. How have you done your backlight?

    Which pic have you used and how easy was the code to write?

    Cheers

    By Lamb.Man on Jun 5, 2008

  7. the backlight is four of these:
    http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail?name=475-1173-1-ND
    the lcd comes mounted on a plastic diffuser already, so the leds work well.

    and the controller is an atmel avr atmega16. i would say the code was really easy to write, but this is what i do for a living. it would be hard but not impossible to pick up from scratch.

    the selling price on these things is going to depend almost entirely on how much of the building process i can automate or outsource. worst case is about $200 and best case is about $100.

    By jsco on Jun 5, 2008

  8. I’m building my second GP at the moment, so need to source my next speedo quite quickly.

    Could I purchase the code and circuit schematic off you, I could even get one of the petrol taps you were interested in and send this as payment if you wanted?

    Cheers.

    By Lamb.Man on Jun 6, 2008

  9. honestly, i’m not ready to release the code and schematics yet, and there are still some details that need to be fixed. you stumbled on this project while it is still very much in the development stage. :) i do plan to get these things into production within the next several months, but i don’t think there’s much i can do to help you out in the short term.

    By jsco on Jun 6, 2008

  10. Is it possible to give me a hint on how you got the speed to display in such a big font?
    Cheers.

    By Lamb.Man on Jun 6, 2008

  11. sure! the LCD is a nokia 3310 that i got from sparkfun electronics:
    http://www.sparkfun.com/commerce/product_info.php?products_id=8629

    this LCD is an 84×48 pixel graphical display, so you can pretty much display whatever you want on it. my “fonts” are just collections of bitmaps, one for each digit.

    By jsco on Jun 6, 2008

  12. Hello Jon,

    Just a couple more questions if I may, how are you measuring rpm, is it just an input to the atmega which measures the spark rate?

    Also what have you used to measure temperature, I can’t find a component that measures temp.

    Cheers.

    By Lamb.Man on Jun 10, 2008

  13. i used one of these for ambient temperature:
    http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail?name=MCP9701T-E%2FLTCT-ND
    http://ww1.microchip.com/downloads/en/DeviceDoc/21942D.pdf
    and then for EGT or CHT i just have an op-amp to boost the voltage from a thermocouple into the range of the atmega’s ADC. i threw the ambient temperature sensor in just so i could do compensation for the thermocouple. you can get by without any ambient temperature sensor at all; you’ll just have an uncompensated thermocouple gauge.

    RPM is my super secret trick. i filter the AC power, feed it into an optoisolator, and use the output to determine RPM. depending on your stator, you’ll probably need to divide the frequency of the AC power line by 3 to get RPM.

    By jsco on Jun 10, 2008

  14. You are a very clever man, even if I could work out how to wire the components etc I’d have no chance writing the code!

    Oh well, guess I’ll have to stick to my home made cycle speedos bodged into an old housing.

    Cheers for the info though.

    By Lamb.Man on Jun 10, 2008

  15. Hello again, how is it going?
    I am really struggling with writing the code from scratch, I keep getting “overlap in .cseq” errors, I don’t thing AVR programming is my thing.
    Could you just send my the Atmega16 code for the speedo bit without the temp guage and rev counter, pleeeeessee? :-)
    Cheers.

    By Lamb.Man on Jun 25, 2008

  16. all of my code is written in C, using the winavr toolchain. the C compiler takes care of most of the memory segmentation issues for you.
    http://winavr.sourceforge.net/
    like i said, i’m not ready to release any of the source yet.

    By jsco on Jun 25, 2008

  17. ok thanks.

    By Lamb.Man on Jun 25, 2008

  18. Sorry to bother you again, I am still struggling. I can’t seem to get any output to my Nokia display:

    Here are my pinouts

    1. VCC - 3.3v
    2. SCK - atmega16 pin 6 = mosi pb5
    3. SDIN - atmega16 pin 3 = oc0/ain1 pb 3
    4. D/C - atmega16 pin 5 = ss pb4
    5. SCE - atmega16 pin 7 = miso pb6
    6. gnd - gnd
    7. vout - gnd via 4.7 uF cap
    8 reset - atmega pin 3 = int2/ain0 pb2

    And my lcd driver prog contains this (in assem)
    .Equ ResetA = 2
    .Equ CdA = 4
    .Equ SckA = 7
    .Equ DataA = 5
    .Equ PortData = PORTB
    .Equ PortConfigA = DDRB

    Is this totally inccorect, could you give me a bit of guidance please.

    Lamb.man@blueyonder.co.uk

    Thanks alot.

    By Lamb.Man on Jun 28, 2008

  1. 2 Trackback(s)

  2. Jun 29, 2010: ALVIN
  3. Jul 5, 2010: EUGENE

You must be logged in to post a comment.