1
\$\begingroup\$

I'm trying to build a custom dashboard for a car (Daewoo Lanos 1998 with Delco ECU). Tachometer signal, that comes to dashboard with a separate wire looks a bit strange to me. It seems that the signal is related to the ignition coils, and after a little digging around on the Internet I realized how to convert the frequency of this signal into a real RPM value.

Let me show you what I'm talking about: Overall look

Each cycle begins with a gradual increase from 0 to ~ 0.7V. Then for a few milliseconds it stays at that level. After that we can see sharp falling edge. This part is completely understandable to me and does not create any difficulties. Problems begin further: after this pulse there can be a surge up to 1V for a few microseconds. But also these surges can sometimes not be observed. But the worst part is that some of the main pulses can be interrupted by other bursts with a length of about 100 microseconds.

enter image description here This is an example of a typical burst after main pulse.

enter image description here And here is what this surge looks like at a closer look.

enter image description here Here is an example of how a useful signal being interrupted.

enter image description here And here we can observe something like a double rise.

Measurements has been done with Saleae Logic 8 at 10MHz resolution (without any scaling probes).

What I'm know for sure is that somehow, tachometer in the car can cope with signal well. Unfortunately, my ideas do not go beyond using an RC circuit with an op amp. However, this will not solve the entire problem. Please tell me how best to filter/convert this signal so that it can be used as an interrupt for the microcontroller. I would also be very interested to know the nature of this signal, why it is exactly the way we observe it, and why these bursts and other artifacts appear.

Thank you in advance!

\$\endgroup\$
  • \$\begingroup\$ Capture data and learn DSP basics. Make sure that you capture several sets of this data at slow, medium, and very fast rates so that you have enough to test your algorithm. This is a great learning experience. And it's the kind of signal that's (so far as I can see right now) easily "cleaned up" to create something robust for your needs. None of the surges, double rises, etc. make this look at all hard to me. (Of course, who knows what else you might collect? I suspect there will be more surprises as you collect more data, but this looks more fun than work to me.) \$\endgroup\$ – jonk Aug 18 '19 at 21:28
  • 1
    \$\begingroup\$ It is highly unlikely that you are measuring the signal correctly. Are you sure you are measuring it correctly? In general signals in cars are designed to be very robust and immune to interference. As such they are often full supply rail (12V) or if they are small signals will be signalled differentially. Cars generate interference signals of one volt or more. I would expect the tacho signal to come straight from the ignition circuit and be many volts in amplitude. \$\endgroup\$ – Kevin White Aug 18 '19 at 21:59
  • \$\begingroup\$ @KevinWhite, Your comment makes sense. For me it is also strange that the signal amplitude is about 1V. However, I made sure that all GND pins are common, so it is unlikely that I chose the wrong measurement reference point. The signal presumably comes directly from the ECU, so I assume that such an amplitude is possible. For measurements, I used the original Saleae Logic with 10MHz bandwidth. It can measure voltage up to 5V. We would see clipping if the signal was higher, and also I used direct probing without any 10X or 100X dividers. \$\endgroup\$ – Ruslan Aug 19 '19 at 8:44
  • \$\begingroup\$ @jonk Do you know a good method of capturing and then replaying a signal? This would greatly simplify my work, as it would not be necessary to have a car nearby with the engine running) \$\endgroup\$ – Ruslan Aug 19 '19 at 8:47
  • \$\begingroup\$ @Ruslan You usually create or buy a simple tool that records ADC readings. Most digital scopes can be used for this, if you can power them up near the car. (Long cord?) The digital scope may include a place to put a USB memory stick, for example, where it saves the captured data. A battery-powered, portable digital scope might be still better, of course. Or at least, more convenient. But if you don't have one, then you don't. \$\endgroup\$ – jonk Aug 20 '19 at 7:46
1
\$\begingroup\$

You need to debounce your signal, counting only instances when the signal remains above a certain level for a certain time.

If your microcontroller has analog pins, you can implement both the threshold comparison and the debouncing in software. If you only have digital pins, I'd still recommend to make debouncing in software, producing a digital signal using a comparator IC. Of course, it's possible to debounce the comparator output in hardware (using a low-pass filter and a Schmitt trigger), but I see no compelling reason to do so, if you'll use a microcontroller anyway.

| improve this answer | |
\$\endgroup\$
  • \$\begingroup\$ There is no way that the signal is intentionally so low - cars have a lot of interference so they usually use 12v signalling. \$\endgroup\$ – Kevin White Aug 19 '19 at 1:00
  • \$\begingroup\$ @KevinWhite Could be something as simple as a 10x probe on a 1x scope channel. \$\endgroup\$ – Dmitry Grigoryev Aug 19 '19 at 7:21
1
\$\begingroup\$

It turned out that I sampled this signal incorrectly. After studying the car wiring diagram, I realized that the ECU only pulls tachometer line down to the ground: enter image description here Simply speaking, the signal is GND-OPEN, not GND-12V. Moreover, it is also pulled to the ground through a 10 kΩ resistor (I suppose that is somehow related to the operation principle of analog tachometer, but I'm not sure). So after pulling this signal to 5V using a 2 kΩ resistor, I got a nice healthy tachometer signal with the amplitude of 4.1V: tachometer signal sample

This case shows that you should always study as much information as possible about what you are working with before starting to actually do something. I spent a lot of time trying to figure out the signal, which was just noise). So, as experienced guys say - RTFM!

Big thank you to all who helped me to resolve this issue!

| improve this answer | |
\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.