Go Down

### Topic: Automotive grade (12 volt) Oscilloscope \logic analyser. (Read 3470 times)previous topic - next topic

#### Ownage

##### Dec 10, 2012, 12:57 am
I am interested in turning my Arduino into a simple oscilloscope so I can probe sensors on autos such as the crank, cam, and several others.  Some of these sensors such as wheel speed sensors create outputs that are only a few volts.  Others such as injectors pulse on and off at a full 12v (not really sensors but seeing injector square wave is helpful in some circumstances).  The voltage output of CAM\Crank sensors varies based upon the manufacturer.

I have seen some Oscilloscopes such as XOscillio but I am unsure if they are capable of reading up to 12v.  There are others that use an onboard LCD, but I am unsure if they are capable of reading up to 12v as well.  I would like the onboard LCD approach.

Any projects I can use to get started?

#### vasquo

#1
##### Dec 10, 2012, 02:08 am
Of course, you can just buy a 1ch or 2ch oscilloscopes from eBay... around \$40 to \$50 + shipping.

#### Ownage

#2
##### Dec 10, 2012, 03:46 am
They are around \$69 and I would enjoy making one on my own.  I have a working LCD circuit and there are libraries to prnt data to it.

I figure that I can analog read every n milliseconds and plot that point on a graph.

Would it be possible to use a voltage divider to lower the voltage to < 5 volts then scale this using:

Vmeasured / 5v = Xv / 12v

12*Vmeasured = 5x

(12*VMeasured)/5 = X

#### vasquo

#3
##### Dec 10, 2012, 05:26 am
Yeah you can use a voltage divider to scale it down. But I'd still put input protection, see this page.
http://www.kevinmfodor.com/home/My-Blog/microcontrollerinputprotectiontechniques

#### Ownage

#4
##### Dec 10, 2012, 06:54 pm
Another issue I thought of is that some sensors put out AC, a wheel speed sensor is one of them.  How would I be able to capture the AC waveform varying between about +1 and -1v on a analog in pin?

#### vasquo

#5
##### Dec 10, 2012, 07:04 pm
You can use a voltage divider here, 2 equal value resistors.

So your 2.5Volts is now your "0 V" line.  That gives you + 2.5VDC and -2.5VDC range.
A measured 3.5volts is your +1V input.
A measured 1.5volts is your -1V input.

#### PeterH

#6
##### Dec 10, 2012, 08:59 pm
I occasionally use a scope to check the eccentricity of a trigger wheel or check the polarity of trigger wheel sensors on new installations, but it's pretty rare. Injectors, for example, I usually debug by a continuity check, monitoring the supply voltage to see when they're operating (an LED in parallel is brilliant for this), and simply listening to them - with an occasional clean and spray test. If I wanted to know what the precise pulse length was, for example to know what the min and max duty cycle was, I'd ask the ECU. Similarly if I wanted to know whether it had a lock on the cam/crank sensors I'd look at the ECU's view of the world to see whether there was a problem rather than look at the wires.

If you really need a scope then I suggest buying one - there are plenty of automotive scopes around already - but you might find your time and money was better spent on test equipment such as EGO sensing, EGT monitoring, and the know-how to talk to the ECU.
I only provide help via the forum - please do not contact me for private consultancy.

#### Ownage

#7
##### Dec 10, 2012, 10:35 pm
@PeterH

Generic OBD II can show very basic sensors\outputs such as TPS position, RPM, speed, and O2 voltage.  For almost all vehicles the only thing that can view more advanced things such as injector pulse width, cam\crank raw output, ABS wheel speed sensor waveforms, and EGR position is the dealer scan tool.  Tools such as MODIS can also do most of these things on most cars but it is NOT guaranteed.  Both the dealer tools and MODIS are very expensive.  Toyota guys are lucky with an inexpensive Techstream, Honda guys can get by with HDS, and VW\Audi guys have VAGCOM.  Every other platform is SOL.  For example older GMs require the Tech2 and newer ones use the GM MVCI.  Both are > \$1500 on ebay.  I've gotten by with an LED test light for most things but a scope would help.

#### PeterH

#8
##### Dec 11, 2012, 12:44 am

They are around \$69 and I would enjoy making one on my own.

If it's something that you simply want to do then that's all the justification you ever need. It's certainly feasible.

But if you still think that this is a cost effective and practical way to get a small working scope, I'm not convinced. Amazon are offering several pocket scopes in the £25-£50 range which you would be hard-pressed to beat just for the components let alone a working and neatly packaged solution, and I'm sure there are other specialist suppliers with a wider choice. Raise the budget to £100 and you have a wider choice. You can even get digital multimeters with storage scope functions. I forget what I paid for my CRT 'scope second hand but it wasn't a lot, and the picoscope for my laptop was also pretty cheap. I've got a plain old digital multimeter with serial output which could be used as a cheap and cheerful way to sample an analog signal if it came to that. This sort of thing is not expensive.

There's no reason at all why you couldn't DIY your own, but you'd need to integrate the display, buttons, external storage, batteries, charging system, probably external ADCs, sort out the physical packaging and so on which would take a lot more work that just picking up something equivalent off the shelf. You might be able to save a few quid building your own (then again, you might not), but the amount of money at stake isn't much compared to the amount of work involved.
I only provide help via the forum - please do not contact me for private consultancy.

#### cr0sh

#9
##### Dec 11, 2012, 06:00 am

Yeah you can use a voltage divider to scale it down. But I'd still put input protection, see this page.
http://www.kevinmfodor.com/home/My-Blog/microcontrollerinputprotectiontechniques

I wouldn't use a voltage divider - instead, pay particular close attention to the "zener diode clamp" section of the above link; in particular, look into "diode clamp" circuits, and "zener diode clamp" circuits. Using such a circuit, you can clamp the voltage to keep it between 0 and 5 volts for digital HIGH/LOW signals.

Another way to do it would be to use an optoisolator; this would also have the advantage of isolating your Arduino from any potential high-voltage spikes on the electrical system. An automobile's electrical system is a nasty environment; I don't recall the number off-hand, but if you look at Atmel's site, you will find an application note on how to use their microcontrollers in such a system (they show protection circuits, etc for filtering and such).
I will not respond to Arduino help PM's from random forum users; if you have such a question, start a new topic thread.

#### Osgeld

#10
##### Dec 11, 2012, 06:05 am
Quote
Another way to do it would be to use an optoisolator; this would also have the advantage of isolating your Arduino from any potential high-voltage spikes on the electrical system.

It also helps keep noise from "gettin in there"

Go Up

Please enter a valid email to subscribe