Is a “dynamic voltage divider” even a thing? I am using an ADC ADS1115 to measure voltage on batteries. Now these batteries are sometimes 12 volts, 24 volts or a bank of 48 volts or even 72 volts.
To get 5 volts at the output of a voltage divider with 72 volts input, I need R1 to be 20 kΩ and R2 to be 1.5 kΩ. Like this I can have 0 to 72 volts measured.
However if now the input voltage is 12 volts… using the same voltage divider, I get 0.833 volts output and with 24 volts battery input, I get 1.667 volts output.
Is there a way I can measure these voltages without doing any hardware or source code modification and re-upload to code to Arduino?