I've done this for card node I.D. no problem but my I had plenty of 1% metal film resistors handy, so I used those in the a/d environment. I also compared and verified the a/d result with a couple of hits. As a decoupling capacitor, I used a 0.01uF in order not to affect the response time as much. {slewrate} ----- Original Message ----- From: "Eric Bohlman" To: Sent: Wednesday, February 26, 2003 3:45 AM Subject: Re: [PIC]: A to D convertor use for switch decoding > 2/25/03 11:27:14 PM, Michael Reid wrote: > > >Does anyone have any experience in using an A to D input with a ladder > >resistor array of 8 resistors and 8 switches to allow for the 8 switches to > >be used without taking up more than 1 I/O into the processor? > > There are a couple examples on Microchip's site; the one I remember offhand was in the "tips and > tricks" document for the 12F629/675. > > >If the resistors are all 1k in value then the input voltage will correspond > >to whichever button is pressed? Is this a practical route to explore? > > > >We are designing a keypad for a control system and I/O's are at a premium. > >We need a 1 or 2 color LED per switch so that will use a mess of I/O's. > > Sounds reasonable, but read the application notes; you'll want to watch out for noise pickup and for > boundary ambiguity. -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads