diff --git a/src/main/resources/PaletteDescription.yaml b/src/main/resources/PaletteDescription.yaml index d6b25e2..9612781 100644 --- a/src/main/resources/PaletteDescription.yaml +++ b/src/main/resources/PaletteDescription.yaml @@ -586,7 +586,7 @@ Palette: properties: - !ChoicesProperty name: Type - choices: ["Victor", "Jaguar", "Talon", "VictorSP", "TalonSRX"] + choices: ["Victor", "Jaguar", "Talon", "VictorSP", "TalonSRX", "CAN TalonSRX"] default: "Talon" #PWMOutput("Output") @@ -601,6 +601,16 @@ Palette: choices: ["2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20"] default: "2" - !Component + name: CAN TalonSRX + type: PIDOutput + help: A speed controller that allows you to set the speed of a motor using CAN. + properties: + - !ChoicesProperty + name: CAN ID + validators: [CANID] + choices: ["2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20"] + default: "2" + - !Component name: Servo type: Actuator help: A controllable motor; typically has a limited rotation. diff --git a/src/main/resources/export/cpp/ExportDescription.yaml b/src/main/resources/export/cpp/ExportDescription.yaml index ebeda6c..7ff4c09 100644 --- a/src/main/resources/export/cpp/ExportDescription.yaml +++ b/src/main/resources/export/cpp/ExportDescription.yaml @@ -244,6 +244,10 @@ Instructions: Defaults: "Component,None" ClassName: "CANJaguar" Construction: "#variable($Name) = new ${ClassName}($CAN_ID);" + CAN TalonSRX: + Defaults: "Component,None" + ClassName: "CANTalon" + Construction: "#variable($Name) = new ${ClassName}($CAN_ID);" Servo: Defaults: "PWMOutput,Component,None" ClassName: "Servo" diff --git a/src/main/resources/export/java/ExportDescription.yaml b/src/main/resources/export/java/ExportDescription.yaml index c4908a6..0704b76 100644 --- a/src/main/resources/export/java/ExportDescription.yaml +++ b/src/main/resources/export/java/ExportDescription.yaml @@ -259,6 +259,11 @@ Instructions: ClassName: "CANJaguar" Import: "import edu.wpi.first.wpilibj.can.*;" Construction: "#variable($Name) = new CANJaguar($CAN_ID);" + CAN TalonSRX: + Defaults: "Component,None" + ClassName: "CANTalon" + Import: "import edu.wpi.first.wpilibj.can.*;" + Construction: "#variable($Name) = new CANTalon($CAN_ID);" Servo: Defaults: "PWMOutput,Component,None" ClassName: "Servo"