I was wondering if I could measure battery voltage simply by hooking the battery's + to an analog Arduino pin so that my robot can know when it's low on power. From what i've understood, a battery of 1.5 volts is dead when it outputs 1.4 volts (gonna do some research about this). I guess I can apply this approximation to different voltages battery. The only problem is that, if I want to use a battery with voltage superior to 5v (Arduino analog pins set 5v as a maximum), how do I divide the voltage? Again, I guess I'll need op-amps to do that and voltage dividers, but what do I exactly do?