Close
0%
0%

Motorcycle Dashboard

Dashboard with sensors using Arduino and Nextion touchscreen display

Public Chat
Similar projects worth following
I wanted to make a dashboard that has all of the features I wanted, and cheaper than the aftermarket speedos.

As you can see in the pictures I used an Arduino Pro Mini, and  a Nextion 3.5" Basic display.  Since the GUI can be designed on the computer with its on software, it was pretty easy, but really time consuming to make it look like this. It's a touchscreen display, which make real buttons unnecessary, because all the setting can be done with a few touches. 

You have the set the size of the wheel and the magnet's distance from the axle, to make the speedometer accurate. 

I used and magnet in the rotor and a hall effect sensor on the forks, to measure the speed.

Hall sensor on fork.
Hole in the rotor.

As you can see the brightness is also adjustable, which isn't really needed since the maximum brightness is perfect in every occasions. I just wanted the try out the slider component :) (that white circle can be moved up and down to adjust)

The RPM can been seen with actual numbers, but there's also a "progress bar" which shows the RPM to make it more like a real dashboard. Since the progress bar have a range from 0 to 100 percent, you have the set the maximum RPM the engine can reach. The measurement is done with a single wire, that has to be wrapped around the spark plug wire.

Of course, all of the settings are saved in the Arduino's EEPROM, so they don't reset every time the bike is turned off. 

Another feature is the voltage sensor, which examines the battery's voltage every few seconds, and turns on the low voltage (red battery) icon, when the voltage is under ~12.4 Volts. At first, I wanted to display the voltage real time on the screen, but since the Arduino's internal voltage sensor really inaccurate, I gave up on this idea. The critical voltage range will be calibrated manually it the Arduino code, which I haven't done yet. BTW, I used a simple voltage divider to make the Arduino able the read voltages above 5 Volts. 

There will be also an engine temperature sensor. I ordered some sensors from Aliexpress, but I haven't got them, so I have no idea whether it's going to work as a charm or will be a complete failure.  Measuring the temperature will be done by using a sensor which changes it's resistance when the temperature changes. The actual temp is calculate from the resistance. There's also a high temp indicator, which shows up when the temp is above 95 or 100 Celsius.

Obviously, there is a Turn Indicator and High Beam lamp, which connect to the factory indicator lamps, so the bike don't have to be modified.

When it comes to the fuel sensor, there are more option:

-If the bike has a fuel level sensor, a progress bar can be used to display how much fuel we have.

-If bike has only a low fuel level indicator from the factory, it can be wired to the Arduino (like the high beam indicator).

-Or, if the bike has neither of them, we can add our own low fuel level indicator using for example reed switches or hall effect   sensors. 

The bike I am testing the dashboard with is a Derbi Senda, which has a low fuel level indicator from the factory, so I use that.

I wanted to add a clock, which is quite difficult, since the Arduino does not have an internal clock, so a Real Time Clock module has to be used, which unfortunately has not arrived yet. 

There's also 3 odometers. There's a main, which can't be reset. I added also Trip A and Trip B which can be reset any time separately with a tap on the screen. These are also saved in the EEPROM. 

That's all I've done so far, there's a lot of work left to finish the project. I think the most difficult part will be to make a housing for the screen and the electronics.

ino - 14.77 kB - 05/23/2021 at 11:54

Download

Portable Network Graphics (PNG) - 100.96 kB - 05/23/2021 at 11:54

Preview
Download

hmi - 4.47 MB - 05/23/2021 at 11:52

Download

  • Shift warning

    Mateja11/09/2019 at 23:09 0 comments

    I little feature I added is a shift notification. It pops up at the given rpm value given by the user.

  • Temperature sensors

    Mateja11/09/2019 at 23:04 0 comments

    Both of the temp sensors have finally arrived, so I could finally spend some time with tinkering the display of the engine and ambient temperature.


    Engine temp

    I ordered this sensor from Aliexpress, it was around 3 dollars. It's 10mm and has a 1/8 thread. The seller claims that it is a 50K thermistor, that's why it only has 2 wires. I measured a 4.68K resistance at room temperature, which is pretty strange. 

    It's basically a thermistor, so it changes its resistance when the temperature changes. The conversion from resistance to temperature requires some data about the sensor, which the seller didn't provide. Without these, it's almost impossible to make it accurate through the whole temperature range, but it's gonna be used mainly the 90 - 110 Celsius range.

    I found a random thermistor conversion code for Arduino on the web, using this and with a few experiments with resistor I managed to get it quite accurate in the given range. I made a voltage divider in which the first resistor is a 35K resistor, the second one is the thermistor. The Arduino measures the given voltage and from that and the given resistor, it calculates the resistance of the thermistor, which can later be converted to temperature.    

    The sensor is going the measure the temp of the water coolant with this bracket on the picture. A sensor can be screwed into that. 

    Ambient temp

    The second is also from Aliexpress, but it works differently. 

    A sensor is a DS18B20, which is one the of most accurate sensors in my opinion. It needs 5V Volts, and the temp value can be read with a digital pin on the Arduino. According to its datasheet, it has an accuracy of 0,5 Celsius up to 80 Celsius. It doesn't need any calibration or calculation, it's easy to use. The probe has a 1 meter long wire, so it can be put anywhere on the motorcycle.

    On the screen, the user can switch between the Engine Temp and the Ambient Temperature instantly with a simple touch. 

View all 2 project logs

Enjoy this project?

Share

Discussions

evan nichols wrote 07/15/2021 at 00:53 point

Hi where can i find the libraries or whatever i need to include that is listed at the top of the code? thanks 

  Are you sure? yes | no

evan nichols wrote 07/15/2021 at 15:04 point

Found all of the libraries on the nextion website but now I am getting an error "'DEVICE_DISCONNECTED_C' was not declared in this scope" when trying to run the code.  any idea why? 

  Are you sure? yes | no

dicko101 wrote 11/06/2020 at 23:32 point

This is really cool, I want to do something like this with my M109R, would love to get your code and schematic if possible, great work.

  Are you sure? yes | no

Mateja wrote 05/23/2021 at 11:59 point

Hi!  I know Iam a bit late, but I uploaded the code and the schematic as well. Haven't had time to try the whole circuit, so not sure if the schematic is working properly. The RPM counter part of the schematic (bottom left on the picture) is working properly as I remember.

  Are you sure? yes | no

Gene Pavlovsky wrote 10/09/2020 at 07:15 point

Interesting project!

How are you powering the Arduino and the Nextion display, with a DC-DC converter like one found in a car phone charger?

Can you describe your implementation of reading the engine RPM via a single wire wrapped around the ignition coil? I know that TrailTech's odometer uses this method, I'd like to know how to do it with an Arduino.

I wonder if you've taken some measures to protect the electronics and various sensors from vibrations and harsh environmental conditions (e.g. enclosures, potting, conformal coatings)?

You mentioned that magnet's distance from the axle should be set up, why is it necessary? Aren't you just counting the number of times the magnet passes the sensor?

Rotations per second * distance traveled by the wheel per rotation = speed

I don't see how magnet distance would affect anything, all the bicycle speedometers I've seen, as well as TrailTech Vapor motorcycle speedometer I had before, require setting just the wheel circumference.

Any new improvements / modifications you've done since the last post?

Cheers

--Gene

  Are you sure? yes | no

Mateja wrote 05/23/2021 at 12:10 point

Hi!

I haven't worked on the project for a project so it is sitting on the shelf, but I will try to answer some of your questions.

1. Yes, I used a simple DC-DC step-down converter to power the Arduino with the Display from the 12V battery of the bike.

2. I don't really understand the how RPM counter works I just found its schematic on a forum.  I couldn't find the schematic I used, but you can find it on my schematic (bottom left on the picture) that I uploaded to the files. I uploaded the Arduino code as well. 

3. I haven't installed the project to my bike so I don't have any enclosures yet. 

4. You're actually right, the wheel's circumference is enough. Haven't had a chance to test the speedometer so I haven't given much thoughts to it.

5. Unfortunately not much. I ordered some PCB-s based on the schematic I uploaded, but it didn't really work, so I given up on the project for some time. Since then I got a new motorcycle with a digital dashboard, so I am sure I will continue this project.

  Are you sure? yes | no

Gene Pavlovsky wrote 06/04/2021 at 12:15 point

Thanks. Looking forward to what you come up with when you continue

  Are you sure? yes | no

stefano wrote 01/10/2020 at 16:28 point

Hi,

can you give me more information about hardware for read rpm?

  Are you sure? yes | no

Mateja wrote 05/23/2021 at 12:11 point

Uploaded the schematic, you can find the RPM circuit in the bottom left corner.

  Are you sure? yes | no

seilerjacinda925 wrote 11/19/2019 at 16:23 point

Hi
Nice to meet you after viewing your profile i am Jacinda, from (jakarta) indonesia,

i have a project discussion with you please email me on: (jacinda.seiler@yahoo.com)

  Are you sure? yes | no

Mateja wrote 11/21/2019 at 16:56 point

Hi!

You can send me private message on this site, I would appreciate if we used that.

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates