Searching \ for '[PIC]: Converting PIC port output to +-5V @ 20 ma' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: massmind.org/techref/microchip/ios.htm?key=output
Search entire site for: 'Converting PIC port output to +-5V @ 20 ma'.

Exact match. Not showing close matches.
PICList Thread
'[PIC]: Converting PIC port output to +-5V @ 20 ma '
2003\02\04@204000 by Johnathan Corgan

flavicon
face
I hope this isn't embarrasingly simple.

I need to have a PIC port drive a signal, referenced to ground, at 5V or
-5V, either sourcing or sinking up to 20 ma (per bit, 8 bits).
Furthermore, it would be prudent, but not necessarily required, to have
galvanic isolation between the input and output, as the output may be
subject to static electricity.

This would be easy to build with discrete parts, using two FETs arranged
similarly to a CMOS output, but with the lower one connected to -5V
instead of ground.  Depending on which FET is conducting, the driver
output gets "hooked" to +5V or -5V.  (And opto FETs could be used for
isolation if needed.)

To save parts count (16 FETs!) and $$$, I'd rather go for an integrated
approach.  There are many quad 1:2 analog multiplexers out there, which
is what the discrete circuit above really is.  A couple of these could
switch eight outputs between +5V and -5V inputs very easily.
Unfortunately, none seem to be able to handle the -5V swing on an analog
input port.  The TI SN74CBT3257, for example, has absolute max ratings
of -0.5V to 7V analog input swing:

http://www-s.ti.com/sc/psheets/scds017l/scds017l.pdf

I've also thought of using a comparator, with +-5V supplies and an input
reference set between the PIC high and low output voltage.  The LM339
can only sink 16 ma maximum, typical is 6 ma, and in general, 20 ma
seems to be on the high end of the current sinking capability of common
comparators.

Any suggestions?  Am I completely missing some other, simpler approach?
 Does someone make an "Octal +-5V input swing analog multiplexer using
CMOS level inputs" part that I can order from Digikey?

Thanks, Johnathan

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email spam_OUTlistservTakeThisOuTspammitvma.mit.edu with SET PICList DIGEST in the body

2003\02\04@204904 by Spehro Pefhany

picon face
At 05:10 PM 2/4/2003 -0800, you wrote:
{Quote hidden}

You could consider 3 74HC4053s. No isolation, but < 80 cents total.

Best regards,

Spehro Pefhany --"it's the network..."            "The Journey is the reward"
.....speffKILLspamspam@spam@interlog.com             Info for manufacturers: http://www.trexon.com
Embedded software/hardware/analog  Info for designers:  http://www.speff.com

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email listservspamKILLspammitvma.mit.edu with SET PICList DIGEST in the body

2003\02\04@204914 by hard Prosser

flavicon
face
Just off the top of my head - could you just use a MAX 232 driver chip -
possibly with modified supply rails/charge pump circuit????
May not be viable but should be OK for +/- 20mA,  & Static protected to a
degree. although not isolated.

Or a different line driver chip??

Richard P




                   Johnathan
                   Corgan                To:     .....PICLISTKILLspamspam.....MITVMA.MIT.EDU
                   <jcorgan@AEINE        cc:
                   T.COM>                Subject:     [PIC]: Converting PIC port output to +-5V @ 20 ma drive
                   Sent by: pic
                   microcontrolle
                   r discussion
                   list
                   <PICLIST@MITVM
                   A.MIT.EDU>


                   05/02/03 14:10
                   Please respond
                   to pic
                   microcontrolle
                   r discussion
                   list






I hope this isn't embarrasingly simple.

I need to have a PIC port drive a signal, referenced to ground, at 5V or
-5V, either sourcing or sinking up to 20 ma (per bit, 8 bits).
Furthermore, it would be prudent, but not necessarily required, to have
galvanic isolation between the input and output, as the output may be
subject to static electricity.

This would be easy to build with discrete parts, using two FETs arranged
similarly to a CMOS output, but with the lower one connected to -5V
instead of ground.  Depending on which FET is conducting, the driver
output gets "hooked" to +5V or -5V.  (And opto FETs could be used for
isolation if needed.)

To save parts count (16 FETs!) and $$$, I'd rather go for an integrated
approach.  There are many quad 1:2 analog multiplexers out there, which
is what the discrete circuit above really is.  A couple of these could
switch eight outputs between +5V and -5V inputs very easily.
Unfortunately, none seem to be able to handle the -5V swing on an analog
input port.  The TI SN74CBT3257, for example, has absolute max ratings
of -0.5V to 7V analog input swing:

http://www-s.ti.com/sc/psheets/scds017l/scds017l.pdf

I've also thought of using a comparator, with +-5V supplies and an input
reference set between the PIC high and low output voltage.  The LM339
can only sink 16 ma maximum, typical is 6 ma, and in general, 20 ma
seems to be on the high end of the current sinking capability of common
comparators.

Any suggestions?  Am I completely missing some other, simpler approach?
 Does someone make an "Octal +-5V input swing analog multiplexer using
CMOS level inputs" part that I can order from Digikey?

Thanks, Johnathan

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email EraseMElistservspam_OUTspamTakeThisOuTmitvma.mit.edu with SET PICList DIGEST in the body

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email listservspamspam_OUTmitvma.mit.edu with SET PICList DIGEST in the body

2003\02\04@211222 by Ian McLean

flavicon
face
I doubt you will get a logic chip that can drive a -+5 voltage swing.  Why
not stick with the TI chip design, and invert 8 of the outputs into -5V
using a couple of chips such as the LMC7660 switched capacitor voltage
converter - this chip is designed to switch a +v to a -v with just two
capacitors?  Just a suggestion ...  Trouble is - this design comes up to at
least 4 IC's and I am wondering if that would be any cheaper than using 16
FETS in a cascaded Mosfet switch design.

Regards
Ian

{Original Message removed}

2003\02\04@222611 by Johnathan Corgan
flavicon
face
Spehro Pefhany wrote:

> You could consider 3 74HC4053s. No isolation, but < 80 cents total.

These come really close.  10V Vcc-Vee is the absolute max, though, I'd
hate to push this.

Also, the ON resistance is fairly high (typical 70, max 160).  The
signal must drive a line that ultimate terminates in two diode drops to
ground, so a total of about 200 ohms needs to be used in series to drop
from 5V Vcc to 1.2V nominal at 20 ma.  The output FET would then be
about a third to two thirds of this--wouldn't this make for a lot of
spread in current values between parts?

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email @spam@listservKILLspamspammitvma.mit.edu with SET PICList DIGEST in the body

2003\02\04@223905 by Spehro Pefhany

picon face
At 07:25 PM 2/4/2003 -0800, you wrote:
>Spehro Pefhany wrote:
>
>>You could consider 3 74HC4053s. No isolation, but < 80 cents total.
>
>These come really close.  10V Vcc-Vee is the absolute max, though, I'd
>hate to push this.

http://www.fairchildsemi.com/ds/MM/MM74HC4053.pdf

+/- 7.5 seems to be abs. max.

>Also, the ON resistance is fairly high (typical 70, max 160).

The on resistance is highest well inside the Vcc- Vee voltage range, and
is lowest at the rails, right where you'd use it. Typical is more like
20-30 ohms, you can probably scale that safely by the typ:max ratio.
See the curve on page 7.

>The
>signal must drive a line that ultimate terminates in two diode drops to
>ground, so a total of about 200 ohms needs to be used in series to drop
>from 5V Vcc to 1.2V nominal at 20 ma.  The output FET would then be
>about a third to two thirds of this--wouldn't this make for a lot of
>spread in current values between parts?

I'll leave those calculations to you, as I don't know your
application.

Best regards,

Spehro Pefhany --"it's the network..."            "The Journey is the reward"
KILLspamspeffKILLspamspaminterlog.com             Info for manufacturers: http://www.trexon.com
Embedded software/hardware/analog  Info for designers:  http://www.speff.com

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email RemoveMElistservTakeThisOuTspammitvma.mit.edu with SET PICList DIGEST in the body

2003\02\04@230350 by Johnathan Corgan

flavicon
face
Spehro Pefhany wrote:

> http://www.fairchildsemi.com/ds/MM/MM74HC4053.pdf
>
> +/- 7.5 seems to be abs. max.
>
> The on resistance is highest well inside the Vcc- Vee voltage range, and
> is lowest at the rails, right where you'd use it. Typical is more like
> 20-30 ohms, you can probably scale that safely by the typ:max ratio.
> See the curve on page 7.

I was looking at the TI version, this Fairchild part is considerably
better, and in fact meets the specs for what I need.  A couple of these
does the trick.  Thanks.

> I'll leave those calculations to you, as I don't know your
> application.

The output drives a PIN diode RF switching circuit that uses the 20 ma
to get the ON resistance of the PIN diodes down to a fraction of an ohm.

Driver -> RF Choke -> PIN Diode -> Coax -> PIN Diode -> RF Choke -> GND

The two diodes drop about 1.2V total, so 3.8 volts/20ma = ~200 ohms
series resistance needed.  This would be split between the ON resistance
of the output FET and a series resistor.  If the ON resistance of the
FET is only 30 ohms, then this is only 15% of the total, and part
variances would be limited to affecting the current by only this amount.
If the ON resistance were 160 ohms (TI part worst case), then part
variances would affect the current dramatically.

The -5V reverse biases these same PIN diodes, as well as forward biases
a different set of PIN diodes acting as shunts across the coax to
provide even further isolation.

-Johnathan

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email spamBeGonelistservspamBeGonespammitvma.mit.edu with SET PICList DIGEST in the body

2003\02\04@234930 by Dave Tweed

face
flavicon
face
Johnathan Corgan <TakeThisOuTjcorganEraseMEspamspam_OUTAEINET.COM> wrote:
> I hope this isn't embarrasingly simple.

I think so.

> I need to have a PIC port drive a signal, referenced to ground, at 5V or
> -5V, either sourcing or sinking up to 20 ma (per bit, 8 bits).
> Furthermore, it would be prudent, but not necessarily required, to have
> galvanic isolation between the input and output, as the output may be
> subject to static electricity.

Somebody already suggested MAX232 (or similar), but if you've already
got the +/- power supplies, why not a plain old 1488 driver? Four per
chip, and they're pretty rugged.

-- Dave Tweed

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email RemoveMElistservspamTakeThisOuTmitvma.mit.edu with SET PICList DIGEST in the body

2003\02\04@235553 by Roman Black

flavicon
face
Johnathan Corgan wrote:
>
> I hope this isn't embarrasingly simple.
>
> I need to have a PIC port drive a signal, referenced to ground, at 5V or
> -5V, either sourcing or sinking up to 20 ma (per bit, 8 bits).


No isolation, but 2 cheap ideas for low chip count;
* use a CMOS 8 buffer chip good for 10v supply rails,
connect it between +5 and -5 rails.
* use a UCN5804 chip (8 darl drivers), and 8 pullup
resistors.
Obviously some resistors are needed for biasing etc
but resistors are cheap.
-Roman

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email listservEraseMEspam.....mitvma.mit.edu with SET PICList DIGEST in the body

2003\02\05@005904 by Johnathan Corgan

flavicon
face
Dave Tweed wrote:

> Somebody already suggested MAX232 (or similar), but if you've already
> got the +/- power supplies, why not a plain old 1488 driver? Four per
> chip, and they're pretty rugged.

I might be able to coerce one of these into duty; looks like the
source/sink current is limited to about 10 ma though.

-Johnathan

--
http://www.piclist.com hint: To leave the PICList
EraseMEpiclist-unsubscribe-requestspammitvma.mit.edu>

2003\02\05@010847 by William Chops Westfield

face picon face
   > www.fairchildsemi.com/ds/MM/MM74HC4053.pdf
   > +/- 7.5 seems to be abs. max.

   I was looking at the TI version, this Fairchild part is considerably
   better, and in fact meets the specs for what I need.  A couple of these
   does the trick.  Thanks.

You may want to get CD4053B parts rather than the 74HC parts.  The 4000
series has always had a wider supply range than the 74HC part, and I expect
the analog multiplexor voltages go up accordingly...  (And since fairchild
makes a 4053, I'll bet there 74HC part is the same as that, where as TI's
part is perhaps true 74HC technology.)

BillW

--
http://www.piclist.com hint: To leave the PICList
RemoveMEpiclist-unsubscribe-requestEraseMEspamEraseMEmitvma.mit.edu>

More... (looser matching)
- Last day of these posts
- In 2003 , 2004 only
- Today
- New search...