Path: csiph.com!optima2.xanadu-bbs.net!xanadu-bbs.net!news.glorb.com!Xl.tags.giganews.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!local2.nntp.dca.giganews.com!news.giganews.com.POSTED!not-for-mail NNTP-Posting-Date: Fri, 21 Aug 2015 11:01:14 -0500 From: Tim Wescott Subject: Re: 16 analog outputs into 1 digital output Newsgroups: sci.electronics.design References: <55d70301$0$1031$4c5ecfc7@frugalusenet.com> <55d70500$0$1015$4c5ecfc7@frugalusenet.com> <9dfea17d-380e-4db8-af89-a0e06fe26493@googlegroups.com> User-Agent: Pan/0.139 (Sexual Chocolate; GIT bf56508 git://git.gnome.org/pan2) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Message-ID: Date: Fri, 21 Aug 2015 11:01:14 -0500 Lines: 68 X-Usenet-Provider: http://www.giganews.com X-Trace: sv3-v3heKM3GdG4XG0zuBvnup2lRhyZNwJ/FGlu23nXF9cJtnLaLOnbzHAOTXCcoC5ynyyjnhVaMHl14/Qh!lVncD8OUL8HmbXZTGogQUfHG/Yo6ILxhJwC1ZD76hMrMLBnyRU4l5xbOk4HEj5CCx9zluW6zW0Zk X-Complaints-To: abuse@giganews.com X-DMCA-Notifications: http://www.giganews.com/info/dmca.html X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.40 X-Original-Bytes: 3936 Xref: csiph.com sci.electronics.design:373969 On Fri, 21 Aug 2015 13:54:41 +0200, gm wrote: > On 21.08.2015 13:38, tabbypurr@gmail.com wrote: >> On Friday, 21 August 2015 12:01:25 UTC+1, bitrex wrote: >>> On 8/21/2015 6:52 AM, bitrex wrote: >>>> On 8/21/2015 5:41 AM, gm wrote: >>>>> Hi. >>>>> >>>>> I have one alarm station that has 16 outputs. >>>>> On each of this outputs you can read out some voltage change from 1 >>>>> - 1,5V ( when in alarm state ). >>>>> >>>>> To save space and money i was planning to hook up one multiplexer to >>>>> those outputs and then other part of multiplexer to raspberry PI >>>>> GPIO. >>>>> >>>>> Did someone try to make something like this ? >>>> >>>> If all you need to know is if _a_ alarm is going off, not what >>>> particular one, you could use 4 LM339 quad comparators, one section >>>> for each alarm channel. Set them up with a reference voltage on one >>>> input and and some hysteresis, and since they have open collector >>>> outputs, the outputs can be OR-ed together into one "digital" output >>>> that pulls down when one of the comparators is triggered. >>>> >>>> Please see page 10 of the following datasheet: >>>> >>>> https://www.jameco.com/Jameco/Products/ProdDS/838727.pdf >>> >>> Actually, if the threshold voltages on all the comparators are going >>> to be the same, you could use fewer ICs - see page 7 of the datasheet >>> for an "OR" gate that accepts multiple inputs. >>> >>> I don't think I'd like to try to put 16 inputs all to 1 IC, but I'd >>> feel comfortable using a LM339 quad and putting 4 inputs into each, >>> and then ORing the outputs of each 4 input OR gate together. >>> >>> You can also do a multiple input OR gate with hysteresis. >> >> Just use 16 diodes, followed by one comparator to restore levels. >> >> >> NT >> > ------------- > I need to know which alarm is turned ON. This is the main thing. > So you have 16 different alarms. I was thinking that there is a way to > output those signals on single digital line. So i can read them as > binary value. > > Your suggestion is OK but i need to record each alarm state. > Alarm from each sensor... Well, if you have just ONE digital line, how are you going to tell which one of SIXTEEN alarms are active? You can do it with some sort of wacky coding scheme (reinventing asynchronous serial is probably easiest), but it will take a bunch of circuitry -- and you'll need to start with sixteen comparators. Or if you want to stick to a Raspberry PI sort of level of technical expertise, you could use an Arduino as a peripheral. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com