Author Topic: Triggering a moped digital RPM counter  (Read 839 times)

0 Members and 1 Guest are viewing this topic.

Offline guixTopic starter

  • Newbie
  • Posts: 6
  • Country: fr
Triggering a moped digital RPM counter
« on: October 08, 2023, 05:22:59 am »
Hello :)

I took the dashboard of a moped to my desktop, and I would like to use an Arduino to make the dashboard think it's still on the moped with the motor running.

The RPM counter uses a pickup wire that is wrapped a few turns around the sparkplug wire and not connected to anything on that end, like a radio antenna wire. I would like to make a circuit to generate the signal in that pickup wire so the dashboard think it was a spark, to make the RPM counter show a value.

Writing the Arduino program is not a problem (basically it's just a Blink sketch with pulse frequency modulation), I'm just wondering how to do the electronic part of it. There must be a way to do it without using a high voltage, right?

I haven't tried anything yet, as I don't know much about electronic and I don't want to destroy the dashboard ;D

Here attached is a picture and schematic of the dashboard RPM circuit.

The MC68HC908LJ12 is running at 5V, if that matters.

Any idea ?
« Last Edit: October 08, 2023, 05:34:37 am by guix »
 

Offline Chriss

  • Frequent Contributor
  • **
  • Posts: 534
  • Country: 00
Re: Triggering a moped digital RPM counter
« Reply #1 on: October 08, 2023, 07:54:01 am »
First of all would measure the signal which is going into the mcu with a scope if available.
Based on that signal you can move forward.
The electronic you draw looks like a peak detector.
The diode enables only the positive part of the signal to go through, the first two resistors + the last resistor are acting as a voltage divider and the cap is to hold the peak voltage to feed into the mcu.

Maybe Im wrong but that is the possible way how this works.
 
The following users thanked this post: guix

Offline guixTopic starter

  • Newbie
  • Posts: 6
  • Country: fr
Re: Triggering a moped digital RPM counter
« Reply #2 on: October 08, 2023, 09:10:44 am »
I think you are right, unfortunately I don't have access to an oscilloscope...

But correct me if I'm wrong :

The output voltage of the voltage divider, is connected to a MCU's input capture pin, which will detect a HIGH when the voltage is between 3.5V and 5V (min 0.7 * VDD, max VDD, as seen in page 396 of the datasheet).

So the voltage in the pickup wire (after the D1 diode) must be ~7.4V min ((7.4V*10KΩ)/21KΩ = 3.5V) and ~10.5V max, ((10.5V*10KΩ)/21KΩ = 5V), to be safely detected HIGH by the MCU.

Is it safe to assume that I could simply control a transistor by PFM with the Arduino, to switch 9V in the pickup wire, connect Arduino and MC908 GND together, and it should work ?
 

Online bingo600

  • Super Contributor
  • ***
  • Posts: 2107
  • Country: dk
Re: Triggering a moped digital RPM counter
« Reply #3 on: October 08, 2023, 11:26:10 am »
I'm not an EE , just a hobbyist.
But I would try to connect the Arduino pulses at the R1/R2 point (where they meet) .... That would give you a voltage divider of 1K/10K , and then 5v from the arduino might be enough to trigger the mcu.

/Bingo
 
The following users thanked this post: guix

Offline Chriss

  • Frequent Contributor
  • **
  • Posts: 534
  • Country: 00
Re: Triggering a moped digital RPM counter
« Reply #4 on: October 08, 2023, 05:43:08 pm »
I don't think you can make something bad if you connect the arduino output pin to the desired input pin on the dash.

The two gnd should be connected together. The dash and the arduino gnd.

Without a scope it is very challenging to really find the correct frequency range in which the dash will react.

However it looks for me an interesting project.
 

Offline DavidAlfa

  • Super Contributor
  • ***
  • Posts: 6586
  • Country: es
Re: Triggering a moped digital RPM counter
« Reply #5 on: October 08, 2023, 05:52:46 pm »
Did something like this to test a Mazda RX7 dash.
Try setting a PWM output, 100Hz 10% duty, connect directy to the pickup wire input, you should see about 6000rpm.
The diode and resistors will prevent the mcu inpus from being damaged.
Anyways 5V from the arduino will be at the same logic level so can hardly cause any issue.
« Last Edit: October 08, 2023, 05:56:43 pm by DavidAlfa »
Hantek DSO2x1x            Drive        FAQ          DON'T BUY HANTEK! (Aka HALF-MADE)
Stm32 Soldering FW      Forum      Github      Donate
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf