----- Original Message -----
From: richardlfry@btinternet.com
To: AVR-Chat@yahoogroups.com
Sent: Wednesday, July 29, 2009 3:33 PM
Subject: [AVR-Chat] Re: AVR inputs
--- In AVR-Chat@yahoogroups.com, "s.holder123@..." <s.holder123@...> wrote:
>
> Put a pull up resistor between Vcc and the microcontroller input pin, then a diode (1n4001)Anode between the junction of the resistor and the microcontroller pin and the cathhode to the Car input (Perhaps a cap between junction of pull up resistor and microcontroller pin as well. This isolates the microntroller from excessive input values and limits and current via the pull up resistor, the cap provides a simple low pass filter. As long as the input doesn't exceed the reverse breakdown voltage all will be well. Auto electrics tend to have lots of nasty stuff "hanging" on the signal and power lines so you need to isolate the microcontroller inputs form this. The opto-isolater idea might be required but i think this might doe the trick.
>
> Regards
>
> --- In AVR
> -Chat@yahoogroups.com, David Kelly <dkelly@> wrote:
> >
> >
> > On Jul 28, 2009, at 9:51 PM, Jim Wagner wrote:
> >
> > > One way is to add a series resistor to each input (say 4.7K to 10K),
> > > then add a diode (preferably Schottkey,j but silicon junction will
> > > work) from each input to the processor Vcc, cathode to Vcc. That will
> > > limit each input at the micro to the current Vcc )(plus one diode
> > > drop).
> >
> >
> > There is an Atmel apnote describing how one might monitor AC zero
> > crossings which states there is already a protection diode on all
> > inputs which is good for up to 1 mA. The apnote used a large value
> > 1000V rated resistor in series to connect direct to 120V AC. And then
> > goes on to say something to the effect, "Use at own risk."
> >
> > --
> > David Kelly N4HHE, dkelly@
> > ========================================================================
> > Whom computers would destroy, they must first drive mad.
> >
>
Hi,
I've used an AT90CAN128 to monitor car signals in the past.
I expect you've already thought of it, but a lot of signals on a car are +12V. Infact the altenator output can be up to 14.8V. I've just used a 10K / 22K potential divider (plus some filter capacitors) to divide the signal by approx 3 before it gets to the A/D inputs.
This obviously makes the 10bit resolution approx 3 times worse, but most signals on a car aren't that critical.
Another though on the subject is that if you are planning to measure signals like air flow or throttle posistion, these signals are generally on the 5V sensor bus (maybe that's your 5v signal as you have mentioned) but they are also generally very low impedance - less than 10K. So often, just a potential divider will affect the signal so much that the engine ECU reports problems. Generally just a general purpose buffer circuit works for this, and also gives you a bit more protection so you don't blow up the expensive processor - just the 30p LM321!!
Rich
[Non-text portions of this message have been removed]