Readadc

thunderace7

New Member
Hi, again.
I need to read an analogue input of 10 discrete levels (approx 0.5 volt spacing) and I intend to use a rotary switch and resistor chain. I have a few questions, however.
1. Is it OK to use direct 0v and +5v as inputs or should they be protected by an additional resistor (making a chain of 12 resistors)? If protection is needed, could I add a resistor in series with the input from the rotary switch wiper instead (leaving the resistor chain at 10 and making calculation of voltage levels easier)? If I go for a series resistor, what value would you recommend?
2. I had intended to use 10K resistors in the chain, is this too large (making the chain 100K across the power line). It depends on the current drawn by the input, I suppose. What current is an analogue input likely to draw?
3. Would I be better using readadc10 rather than readadc or is it not important for only 10 levels?

Thanks for your help. I should be ready to post a diagram and programme soon. :)
 

hippy

Ex-Staff (retired)
1) I've had no problem with direct +V and 0V connection to ADC input. I've never used a series resistor though it's a good idea to include one, probably 330R-1K.

2) This comes down to input impedance. Using 1K in the ladder is probably a reasonable choice.

3) READADC10 will allow a better resolution which can make it easier to distinguish individual levels, but with only 10 levels each should differ by 25 when read which should be plenty.
 
Top