Beispiel #1
0
        public VictorSPXConfiguration()
        {
            primaryPID  = new  VictorSPXPIDSetConfiguration();
            auxilaryPID = new VictorSPXPIDSetConfiguration();

            forwardLimitSwitchSource = RemoteLimitSwitchSource.Deactivated;
            reverseLimitSwitchSource = RemoteLimitSwitchSource.Deactivated;
            sum_0  = RemoteFeedbackDevice.RemoteFeedbackDevice_RemoteSensor0;
            sum_1  = RemoteFeedbackDevice.RemoteFeedbackDevice_RemoteSensor0;
            diff_0 = RemoteFeedbackDevice.RemoteFeedbackDevice_RemoteSensor0;
            diff_1 = RemoteFeedbackDevice.RemoteFeedbackDevice_RemoteSensor0;
            //NOTE: while the factory default value is 0, this value can't
            //be set by the API. Thus, RemoteSensor0 is the default
        }
Beispiel #2
0
        public static string ToString(RemoteLimitSwitchSource value)
        {
            switch (value)
            {
            case 0: return("None (factory default value)");

            case RemoteLimitSwitchSource.RemoteTalonSRX: return("RemoteLimitSwitchSource.RemoteTalonSRX");

            case RemoteLimitSwitchSource.RemoteCANifier: return("RemoteLimitSwitchSource.RemoteCANifier");

            case RemoteLimitSwitchSource.Deactivated: return("RemoteLimitSwitchSource.Deactivated");

            default: return("InvalidValue");
            }
        }
Beispiel #3
0
        public ErrorCode ConfigReverseLimitSwitchSource(RemoteLimitSwitchSource type, LimitSwitchNormal normalOpenOrClose, int deviceID, int timeoutMs = 0)
        {
            var cciType = LimitSwitchRoutines.Promote(type);

            return(_ll.ConfigReverseLimitSwitchSource(cciType, normalOpenOrClose, deviceID, timeoutMs));
        }
Beispiel #4
0
 public static LimitSwitchSource Promote(RemoteLimitSwitchSource limitSwitchSource)
 {
     return((LimitSwitchSource)limitSwitchSource);
 }
 public virtual ErrorCode ConfigReverseLimitSwitchSource(RemoteLimitSwitchSource type, LimitSwitchNormal normalOpenOrClose, int deviceID)
 {
     return(_motor.ConfigReverseLimitSwitchSource(type, normalOpenOrClose, deviceID));
 }