コード例 #1
0
 //reads the talons and updates the data
 public void updateStatusData()
 {
     talonCurrent             = (talon.GetOutputCurrent());
     talonTemperature         = (talon.GetTemperature());
     talonVoltage             = (talon.GetOutputVoltage());
     talonSpeed               = (talon.GetSpeed());
     talonPosition            = (talon.GetPosition());
     talonSetpoint            = (talon.GetSetpoint());
     talonForwardLimitReached = talon.IsFwdLimitSwitchClosed() ? 1 : 0;
     talonReverseLimitReached = talon.IsRevLimitSwitchClosed() ? 1 : 0;
     controlMode              = talon.GetControlMode();
 }