EricFr@nkenberger.com

HOME   RESUME/CONTACT   GITHUB

[04-01-2020] | Arduino RPM and Gear indicator


Animated shift light

Instructions specific to Arduino Nano Every Project requires:

I started to get in to sim racing at the beginning of the pandemic, like everyone else who recently got into it. I had been wanting a wheel for awhile and finally pulled the trigger on it. From there everything went out of hand in usual fashion and within a month I had triple monitors, an 8020 sim rig, and a racing seat.



I kept thinking it would be fun to start messing with an Arduino, and that LED's were relatively simple to control. I also really like the customizable LEDs that the steering wheels on the IndyCars run, so I wanted to see if I could make it all come together in a racing sim with my own setup.

I ended up finding the incredibly powerful Simhub software. It taps into the shared RAM or UDP stream that most sims output, formats everything into a common type, then allows you to output that data to a number of different devices.

I used the Arduino capabilities mainly, but you can even use an existing analog gauge cluster from a car to output telemetry to. An example even uses an e36 cluster which I had laying around at the time. Anyway, here's the basic instructions on how to replicate what I did. The repository mentioned can be found on my Github.

Arduino Nano Every wiring diagram

Neopixel setup

OLED setup - SSD1306 128x64

Everything can now be placed in the case.

SIMHUB setup


    void Init() {
        glcd1.begin(SSD1306_SWITCHCAPVCC, 0x3C);
        glcd1.clearDisplay();
        glcd1.setFont();
        glcd1.setTextSize(2);
        glcd1.setTextColor(WHITE);
        glcd1.setRotation(3);
        glcd1.setCursor(0, 0);
        glcd1.print("");
        glcd1.display();
        }
                 

    [Text]
    X=37
    Y=100
    Color=1
    Text=[DataCorePlugin.GameData.NewData.Gear]
    FontSize=3
    FontType=2
    Align=3