Lots of new info…
Keep in mind that the whole reason for this test was to weed out batteries that were not up to par. All of the batteries that I have can get a full charge and show 100% charged in System Info. However, they are not all equal. Although they are all fine for practice and small robots that don’t require a lot of power; later in the season, when the robots get bigger, and the auton routines get longer, you are going to want to make sure that you are using a ‘good’ battery.
The 4 motor drivetrain was a good test harness for stressing batteries, but it wasn’t something that could be easily repeated by anyone else, or even myself at a later date. So I setup a flywheel tester. The initial version had 4 motors each with two big tires spinning on a 3:1 gear ratio. That didn’t stress the battery as much as the 4 motor drivetrain, so I went to 8 motors, which was better, but still not draining the battery as fast as the drivetrain. More on setting up a good test later…
The test checked the battery voltage before starting the motors, and then at 3, 5, 10, and 30 seconds. All batteries were charged overnight before being tested. Looking at the test results it is easy to predict which batteries are going to hold a better charge within the first 10 seconds. In some of the earlier tests I kept it going for a couple minutes, but that extra time doesn’t really provide any meaningful data. Testing that the motors are maintaining a consistent speed (as suggested by calvc01) is worth considering; not wise to assume it is proportional to the battery voltage.
Here are the results for the 40+ batteries that I tested.
https://docs.google.com/spreadsheets…it?usp=sharing
Note that the voltage always takes an initial drop and then bounces around for a couple seconds before stabilizing. One other thing worth noting is that the voltage bounces back once you take the load off. So if you look at System Info after the test, almost all of the batteries that I tested would say 100%.
These results are good enough for me to decide which batteries shouldn’t be assign to teams this year. I’ve decided to draw the line at 8.05 volts after 30 seconds. Any sub-par batteries will be marked and kept as spares.
Recommendations…
Teams that are just starting out and are not ultra competitive don’t need to worry about this. Just check the battery voltage in System Info. If the battery says 100% after being charged, then you have a good battery.
For competitive teams the simple solution is to buy new batteries before an important event. They will also want to know how fast they are draining their batteries, and which components of their robot are using the most power. They may even decide to change the their strategy if they discover their designs or drive patterns are stressing the battery too much.
What’s a good battery test? Real robots work the motors much harder than my flywheel test. Motors draw the most current when they are about to stall out. The best test is to monitor battery voltage on your real robot while the robot is running. Remember that if you check the voltage after a match, it may say 100%, even though it got down to 75% in the middle of a match.
Teams that are using Modkit can use an LED as a low battery indicator like in this code snippet. However, more sophisticated teams, the ones that would want to monitor voltage, are less likely to be using Modkit. If they are using Python, then they can output their battery voltage to a debug log every half second or so. Does anyone know if Robot C as any unpublished functions to get battery voltage?