I thought that now that Github is back up, I’d upload my library for driving the REV Robotics Digit Board MXP upgrade. I tested it tonight, and it can display strings and decimals optimized for battery voltage. It’s by no means finalized.
It was mostly based off the example code from here: http://www.chiefdelphi.com/forums/showthread.php?t=142054
Functions implemented:
REVDigitBoard() : constructor
void display(String str) : displays the first four characters of the string (only alpha (converted to uppercase), numbers, and spaces)
void display(double batt) : displays a decimal number (like battery voltage) in the form of 12.34 (ten-one-decimal-tenth-hundredth)
void clear() : clears the display
boolean getButtonA() : button A on the board
boolean getButtonB() : button B on the board
double getPot() : potentiometer value
Example:
REVDigitBoard disp = new REVDigitBoard();
disp.clear();
disp.display("3216");
// run this repetitively to get voltage readout, assuming pdp is a PowerDistributionPanel object
disp.display(pdp.getVoltage());
I can’t figure out decimal points yet, but I’ll work on it. Also better documentation is coming here and on Github (assuming it’s staying up).