In my project I'd like to check the 20 contacts of a particular relay type. A simulator power every contact with 12 VDC (max) and this goes to LMxxx comparator logic that drive some BJT transitors connected to LED bi-color for visual check. The same voltage need to be scaled down gradually (based on the contact resistance) to 5 VDC (max) for Attiny85 ADC, because I would like to show the Ohm contact value on a LCD screen.
How to get a precise voltage translation?
Here a schematic example of the circuit (SW1 is like relay contact):
Example:
- 12V -> 5V
- 10V -> 4.1(6)V
- 8v -> 3.(3)V
- 6V -> 2.5 V
- 4V -> 1.(6)V
and so on.
Thanks in advance.
EDIT 1
Many thanks for your help and time.
The voltage divider solution would be good but the resistance values, obtained by calc., are different to commercial ones and hard to achieve (with precision). We can combine them but there is still a slightest inaccuracy.
Searching on web I found this solution with an op-amp with Ao set to 0.41(6). Resistance values are a little closer to commercial ones but there is still a slightest measurement inaccuracy.
Since I'm only an electronic apprentice what do you think about it? There could be other solutions you might suggest me please?
Thanks again in advance.