I think you might have meant S2-2 going to Arduino A1 and the end of R4 going to ground. That will create a voltage divider that will give you 5V into the Arduino when you have 30V coming in, assuming your switch S2 has pins 3 & 2 connected. That might be cutting it a little close if your input voltage goes over 30 volts. Your divider for when the switch is in the other position gives you 4.7V out when your input is 40V so that one is probably safe. You could sacrifice a little resolution and use the larger divider for both ranges and just let S2 indicate it's position to the Arduino through a digital input as Magician suggested.I don't get why you need the two position switch unless it is to get the maximum possible resolution of the battery voltage. What is the purpose?
The circuit is designed to test battery chargers at my work. My company make's floor scrubbers, and these systems almost always have 2 12v deep cycle batteries in series, for a 24v system. The battery chargers on these machines is what needs to be tested. The largest chargers will put out 30A at 24V, and 25A at 36V. There is only one machine that uses 36V, but I wanted to have the ability to test this as well. However, since the vast majority of the chargers tested will be designed to charge 24V batteries, I wanted the most precision I could get, within safe limits. I am completely open to other ideas as to how to get there.
Sound like a good idea? Or is my logic somehow off in left field.
Please enter a valid email to subscribe
We need to confirm your email address.
To complete the subscription, please click the link in the
email we just sent you.
Thank you for subscribing!
via Egeo 16