[wpilib] Set AnalogPotentiometer dashboard type (#2825)

There's not a specific dashboard type for potentiometers, so use analog input.
This commit is contained in:
Peter Johnson
2020-11-01 20:44:04 -08:00
committed by GitHub
parent 7b7548196a
commit e021c33191
2 changed files with 2 additions and 0 deletions

View File

@@ -44,6 +44,7 @@ double AnalogPotentiometer::Get() const {
double AnalogPotentiometer::PIDGet() { return Get(); }
void AnalogPotentiometer::InitSendable(SendableBuilder& builder) {
builder.SetSmartDashboardType("Analog Input");
builder.AddDoubleProperty(
"Value", [=]() { return Get(); }, nullptr);
}