My first thought would not be to use a processor at all. I would run the 50 inputs to 50 open collector buffers pulling down a resistor network. Something like a R2R network but it might be simpler as you don't have to distinguish when multiple lines are low together. Finally use an op amp to buffer and filter the output. Sherpa Doug > -----Original Message----- > From: tim [mailto:stm800@CITY-NET.COM] > Sent: Wednesday, August 29, 2001 8:37 PM > To: PICLIST@MITVMA.MIT.EDU > Subject: PIC UNUSUAL D/A APPLICATION > > > I have 50 seperate logic lines that switch in sequence from > # 1 to # 50 then reverse from # 50 to # 1 > at any one time only one line is in a low state and all > others are high state. what I need is an analog output > voltage generated from the pic in response to which switched > line is enabled. > example: > > max reference voltage output is 1 volt at line 50 switched on. > half of the reference voltage is 500 mv at line 25 switched on. > each switched line represents a 20 mv change in output voltage. > > these parameters are not set in stone and the analog > reference voltage could > change if it made code and chip selection easier. > > any thoughts on which pic chip to use as i have not bought > any chips yet. > is there a simple mixed signal or d/a chip that will do > this instead of using a pic chip? > it seems that this type of digital line switching (single > line enabled only ) > to generate an analog voltage is really not what the D/A > chips do that are > presently out there on the market. well as easy as this > application seems to be > i want to ask before i begin re-inventing sliced bread.... > > thanks alot for reading this and all comments and > suggestions welcome tims 800 > > > > -- > http://www.piclist.com hint: To leave the PICList > mailto:piclist-unsubscribe-request@mitvma.mit.edu > > -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads