Robert Adsett wrote:
>
> > At 12:33 AM 7/9/06 -0500, Thomas J Keller wrote:
> >> Best bet is to diode protect (for polarity) the input to an
> >> opto-isoltor on each GPIO. This will protect you against
> >> static discharge, excessive positive or negative inout, etc, etc., at
> >> very little cost. Cost of a single diode, and a $0.25 (US)
> opto-isolator.
> >
> > A question, where do you get a good linear opto for $0.25?
> Especially if
> > you are not dealing with a low impedance signal source.
>
I don't know. Since I referr34ed to GPIOs, I don;t see the relevance of
the question. A simple 4N25 opto-isolator should be more than adequate
for AVR GPIO inputs. Purchase them in any quantity at all, and they run
about $0.25 (US) each.
As for linear opto-isolators, those might cost you $1 or $2 (US)
each. Most of them are
pretty linear, and plenty fast enough for any analog signal you're
likely to be digitizing with
the onboard ADC of an AVR.
<rant mode>
This isn't multi-Ghz engineering, and it ain't rocket science,
folks. Even given the rather extreme
protection levels sought by Ryan, we're not building stuff that needs to
meet NASA-esque levels
of reliability. It isn't cost effective to do so, since our projects
(for the most part, I suspect) will
remain within ready accvess for repair or replacemnt, should something
fail unexpectedly
(unlike, for example, a deep space probe).
Nor, given that we're discussing the onboard peripherals of an AVR,
are we looking at ultra-precision
instrumentation. Let's face it, with a 10 bit resolution, any
non-linearities in an inexpensive linear opto-
isolator are not likley to be very noticeable in the final results.
And the conversion speeds of the onboard ADCs
inVRs are sufficiently slow that even the least expensive of linear
opto-isolators should have MORE than
enough bandwidth to do the job.
There is no sense in paying for precision and accuracy which we canot
use in our circuitry. Sure, you *CAN*
purchase linear opto-issolators that will accurately (wuithin, say, 1%
linearity) handle analog signals of up to
many, many Mhz (posssibly hundreds?). Once you have so accurately and
quickly so coupled the signals,
to pass them into an AVR is a joke. Scale your expectations to the
capabilities of the processor you are
working with.
I am an absolute fan of the AVR family (indeed, my "nick" on eFnet IRC
is avrFreak), but I think I have a
realistic view of what the AVR can and cannot do. I am not likely to
attempt to use an AVR to build a
spectrum analyzer, or a video data stream encryption block. On the
other hand, I am not likely to use a much
more expensive and more difficul to program DSP to control my AC
induction motor speed, either. Granted,
I might achieve somewhat better precision of control, but in very few
instances would that additional precision
prove of any usefulness whatsoever. So why pay the costs associated
with achieving it? (monetary costs,
as well as costs in complexity and time-to-market, etc.)
</rant mode>
tom
aka avrFreak on eFnet IRC
Check out #avrFreaks chat channel on eFnet ISCMessage
Re: [AVR-Chat] Re: Circuit for protecting analog inputs?
2006-07-09 by Thomas J Keller
Attachments
- No local attachments were found for this message.