public class PowerDistributionData extends edu.wpi.first.shuffleboard.api.data.ComplexData<PowerDistributionData>
Constructor and Description |
---|
PowerDistributionData(double[] currents,
double voltage,
double totalCurrent)
Creates a new data object for PDP data.
|
PowerDistributionData(java.util.Map<java.lang.String,java.lang.Object> map)
Creates a new data object for PDP data.
|
Modifier and Type | Method and Description |
---|---|
java.util.Map<java.lang.String,java.lang.Object> |
asMap() |
double[] |
getCurrents()
Gets an array of all the currents of the PDP.
|
double |
getTotalCurrent()
Gets the total current draw of the PDP.
|
double |
getVoltage()
Gets the current voltage being sourced by the PDP.
|
public PowerDistributionData(double[] currents, double voltage, double totalCurrent)
currents
- an array of the currents. This must have 16 entriesvoltage
- the current voltage of the PDPtotalCurrent
- the total current sourced by the PDPpublic PowerDistributionData(java.util.Map<java.lang.String,java.lang.Object> map)
public double[] getCurrents()
public double getVoltage()
public double getTotalCurrent()
public java.util.Map<java.lang.String,java.lang.Object> asMap()
asMap
in class edu.wpi.first.shuffleboard.api.data.ComplexData<PowerDistributionData>