[wpilib] Pregenerate PWM motor controllers (#6742)

Co-authored-by: Gold856 <117957790+Gold856@users.noreply.github.com>
This commit is contained in:
PJ Reiniger
2024-06-18 10:43:08 -04:00
committed by GitHub
parent 66c0abb732
commit b6bd798f9e
49 changed files with 790 additions and 271 deletions

View File

@@ -0,0 +1,48 @@
// Copyright (c) FIRST and other WPILib contributors.
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* {{ Manufacturer }} {{ DisplayName }} Motor Controller.
*
* <p>Note that the {{ DisplayName }} uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the {{ DisplayName }} User Manual available from
* {{ Manufacturer }}.
*
* <ul>
* <li>{{ "{:.3f}".format(pulse_width_ms.max) }}ms = full "forward"
* <li>{{ "{:.3f}".format(pulse_width_ms.deadbandMax) }}ms = the "high end" of the deadband range
* <li>{{ "{:.3f}".format(pulse_width_ms.center) }}ms = center of the deadband range (off)
* <li>{{ "{:.3f}".format(pulse_width_ms.deadbandMin) }}ms = the "low end" of the deadband range
* <li>{{ "{:.3f}".format(pulse_width_ms.min) }}ms = full "reverse"
* </ul>
*/
public class {{ name }} extends PWMMotorController {
/**
* Constructor.
*
* @param channel The PWM channel that the {{ DisplayName }} is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public {{ name }}(final int channel) {
super("{{ name }}", channel);
m_pwm.setBoundsMicroseconds({{ (pulse_width_ms.max * 1000) | int }}, {{ (pulse_width_ms.deadbandMax * 1000) | int }}, {{ (pulse_width_ms.center * 1000) | int }}, {{ (pulse_width_ms.deadbandMin * 1000) | int }}, {{ (pulse_width_ms.min * 1000) | int }});
m_pwm.setPeriodMultiplier(PWM.PeriodMultiplier.k{{ PeriodMultiplier | default("1", true)}}X);
m_pwm.setSpeed(0.0);
m_pwm.setZeroLatch();
HAL.report(tResourceType.kResourceType_{{ ResourceName }}, getChannel() + 1);
}
}

View File

@@ -0,0 +1,172 @@
[
{
"name": "DMC60",
"Manufacturer": "Digilent",
"DisplayName": "DMC 60",
"ResourceName": "DigilentDMC60",
"pulse_width_ms": {
"max": 2.004,
"deadbandMax": 1.520,
"center": 1.500,
"deadbandMin": 1.480,
"min": 0.997
}
},
{
"name": "Jaguar",
"Manufacturer": "Luminary Micro / Vex Robotics",
"DisplayName": "Jaguar",
"ResourceName": "Jaguar",
"pulse_width_ms": {
"max": 2.310,
"deadbandMax": 1.550,
"center": 1.507,
"deadbandMin": 1.454,
"min": 0.697
}
},
{
"name": "PWMSparkFlex",
"Manufacturer": "REV Robotics",
"DisplayName": "SPARK Flex",
"ResourceName": "RevSparkFlexPWM",
"pulse_width_ms": {
"max": 2.003,
"deadbandMax": 1.550,
"center": 1.500,
"deadbandMin": 1.460,
"min": 0.999
}
},
{
"name": "PWMSparkMax",
"Manufacturer": "REV Robotics",
"DisplayName": "SPARK MAX",
"ResourceName": "RevSparkMaxPWM",
"pulse_width_ms": {
"max": 2.003,
"deadbandMax": 1.550,
"center": 1.500,
"deadbandMin": 1.460,
"min": 0.999
}
},
{
"name": "PWMTalonFX",
"Manufacturer": "Cross the Road Electronics (CTRE)",
"DisplayName": "Talon FX",
"ResourceName": "TalonFX",
"pulse_width_ms": {
"max": 2.004,
"deadbandMax": 1.520,
"center": 1.500,
"deadbandMin": 1.480,
"min": 0.997
}
},
{
"name": "PWMTalonSRX",
"Manufacturer": "Cross the Road Electronics (CTRE)",
"DisplayName": "Talon SRX",
"ResourceName": "PWMTalonSRX",
"pulse_width_ms": {
"max": 2.004,
"deadbandMax": 1.520,
"center": 1.500,
"deadbandMin": 1.480,
"min": 0.997
}
},
{
"name": "PWMVenom",
"Manufacturer": "Playing with Fusion",
"DisplayName": "Venom",
"ResourceName": "FusionVenom",
"pulse_width_ms": {
"max": 2.004,
"deadbandMax": 1.520,
"center": 1.500,
"deadbandMin": 1.480,
"min": 0.997
}
},
{
"name": "PWMVictorSPX",
"Manufacturer": "Cross the Road Electronics (CTRE)",
"DisplayName": "Victor SPX",
"ResourceName": "PWMVictorSPX",
"pulse_width_ms": {
"max": 2.004,
"deadbandMax": 1.520,
"center": 1.500,
"deadbandMin": 1.480,
"min": 0.997
}
},
{
"name": "SD540",
"Manufacturer": "Mindsensors",
"DisplayName": "SD540",
"ResourceName": "MindsensorsSD540",
"pulse_width_ms": {
"max": 2.05,
"deadbandMax": 1.55,
"center": 1.50,
"deadbandMin": 1.44,
"min": 0.94
}
},
{
"name": "Spark",
"Manufacturer": "REV Robotics",
"DisplayName": "SPARK",
"ResourceName": "RevSPARK",
"pulse_width_ms": {
"max": 2.003,
"deadbandMax": 1.550,
"center": 1.500,
"deadbandMin": 1.460,
"min": 0.999
}
},
{
"name": "Talon",
"Manufacturer": "Cross the Road Electronics (CTRE)",
"DisplayName": "Talon",
"ResourceName": "Talon",
"pulse_width_ms": {
"max": 2.037,
"deadbandMax": 1.539,
"center": 1.513,
"deadbandMin": 1.487,
"min": 0.989
}
},
{
"name": "Victor",
"Manufacturer": "Vex Robotics",
"DisplayName": "Victor 888",
"ResourceName": "Victor",
"PeriodMultiplier": 2,
"pulse_width_ms": {
"max": 2.027,
"deadbandMax": 1.525,
"center": 1.507,
"deadbandMin": 1.490,
"min": 1.026
}
},
{
"name": "VictorSP",
"Manufacturer": "Vex Robotics",
"DisplayName": "Victor SP",
"ResourceName": "VictorSP",
"pulse_width_ms": {
"max": 2.004,
"deadbandMax": 1.520,
"center": 1.500,
"deadbandMin": 1.480,
"min": 0.997
}
}
]

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -11,7 +13,7 @@ import edu.wpi.first.wpilibj.PWM;
/**
* Digilent DMC 60 Motor Controller.
*
* <p>Note that the DMC uses the following bounds for PWM values. These values should work
* <p>Note that the DMC 60 uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the DMC 60 User Manual available from
@@ -29,8 +31,8 @@ public class DMC60 extends PWMMotorController {
/**
* Constructor.
*
* @param channel The PWM channel that the DMC60 is attached to. 0-9 are on-board, 10-19 are on
* the MXP port
* @param channel The PWM channel that the DMC 60 is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public DMC60(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,12 +11,13 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* Texas Instruments / Vex Robotics Jaguar Motor Controller as a PWM device.
* Luminary Micro / Vex Robotics Jaguar Motor Controller.
*
* <p>Note that the Jaguar uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the Jaguar User Manual available from Vex.
* recommended. The calibration procedure can be found in the Jaguar User Manual available from
* Luminary Micro / Vex Robotics.
*
* <ul>
* <li>2.310ms = full "forward"
@@ -28,8 +31,8 @@ public class Jaguar extends PWMMotorController {
/**
* Constructor.
*
* @param channel The PWM channel that the Jaguar is attached to. 0-9 are on-board, 10-19 are on
* the MXP port
* @param channel The PWM channel that the Jaguar is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public Jaguar(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,7 +11,7 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* REV Robotics SPARK Flex Motor Controller with PWM control.
* REV Robotics SPARK Flex Motor Controller.
*
* <p>Note that the SPARK Flex uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
@@ -27,9 +29,10 @@ import edu.wpi.first.wpilibj.PWM;
*/
public class PWMSparkFlex extends PWMMotorController {
/**
* Common initialization code called by all constructors.
* Constructor.
*
* @param channel The PWM channel number. 0-9 are on-board, 10-19 are on the MXP port
* @param channel The PWM channel that the SPARK Flex is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public PWMSparkFlex(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,7 +11,7 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* REV Robotics SPARK MAX Motor Controller with PWM control.
* REV Robotics SPARK MAX Motor Controller.
*
* <p>Note that the SPARK MAX uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
@@ -27,9 +29,10 @@ import edu.wpi.first.wpilibj.PWM;
*/
public class PWMSparkMax extends PWMMotorController {
/**
* Common initialization code called by all constructors.
* Constructor.
*
* @param channel The PWM channel number. 0-9 are on-board, 10-19 are on the MXP port
* @param channel The PWM channel that the SPARK MAX is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public PWMSparkMax(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,13 +11,13 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* Cross the Road Electronics (CTRE) Talon FX Motor Controller with PWM control.
* Cross the Road Electronics (CTRE) Talon FX Motor Controller.
*
* <p>Note that the TalonFX uses the following bounds for PWM values. These values should work
* <p>Note that the Talon FX uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the TalonFX User Manual available from
* CTRE.
* recommended. The calibration procedure can be found in the Talon FX User Manual available from
* Cross the Road Electronics (CTRE).
*
* <ul>
* <li>2.004ms = full "forward"
@@ -27,10 +29,10 @@ import edu.wpi.first.wpilibj.PWM;
*/
public class PWMTalonFX extends PWMMotorController {
/**
* Constructor for a TalonFX connected via PWM.
* Constructor.
*
* @param channel The PWM channel that the Talon FX is attached to. 0-9 are on-board, 10-19 are on
* the MXP port
* @param channel The PWM channel that the Talon FX is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public PWMTalonFX(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,13 +11,13 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* Cross the Road Electronics (CTRE) Talon SRX Motor Controller with PWM control.
* Cross the Road Electronics (CTRE) Talon SRX Motor Controller.
*
* <p>Note that the TalonSRX uses the following bounds for PWM values. These values should work
* <p>Note that the Talon SRX uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the TalonSRX User Manual available from
* CTRE.
* recommended. The calibration procedure can be found in the Talon SRX User Manual available from
* Cross the Road Electronics (CTRE).
*
* <ul>
* <li>2.004ms = full "forward"
@@ -27,10 +29,10 @@ import edu.wpi.first.wpilibj.PWM;
*/
public class PWMTalonSRX extends PWMMotorController {
/**
* Constructor for a TalonSRX connected via PWM.
* Constructor.
*
* @param channel The PWM channel that the Talon SRX is attached to. 0-9 are on-board, 10-19 are
* on the MXP port
* @param channel The PWM channel that the Talon SRX is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public PWMTalonSRX(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,12 +11,13 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* Playing with Fusion Venom Smart Motor with PWM control.
* Playing with Fusion Venom Motor Controller.
*
* <p>Note that the Venom uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended.
* recommended. The calibration procedure can be found in the Venom User Manual available from
* Playing with Fusion.
*
* <ul>
* <li>2.004ms = full "forward"
@@ -26,10 +29,10 @@ import edu.wpi.first.wpilibj.PWM;
*/
public class PWMVenom extends PWMMotorController {
/**
* Constructor for a Venom connected via PWM.
* Constructor.
*
* @param channel The PWM channel that the Venom is attached to. 0-9 are on-board, 10-19 are on
* the MXP port
* @param channel The PWM channel that the Venom is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public PWMVenom(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,13 +11,13 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* Cross the Road Electronics (CTRE) Victor SPX Motor Controller with PWM control.
* Cross the Road Electronics (CTRE) Victor SPX Motor Controller.
*
* <p>Note that the Victor SPX uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the Victor SPX User Manual available from
* CTRE.
* Cross the Road Electronics (CTRE).
*
* <ul>
* <li>2.004ms = full "forward"
@@ -27,9 +29,9 @@ import edu.wpi.first.wpilibj.PWM;
*/
public class PWMVictorSPX extends PWMMotorController {
/**
* Constructor for a Victor SPX connected via PWM.
* Constructor.
*
* @param channel The PWM channel that the PWMVictorSPX is attached to. 0-9 are on-board, 10-19
* @param channel The PWM channel that the Victor SPX is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -18,19 +20,19 @@ import edu.wpi.first.wpilibj.PWM;
* Mindsensors.
*
* <ul>
* <li>2.05ms = full "forward"
* <li>1.55ms = the "high end" of the deadband range
* <li>1.50ms = center of the deadband range (off)
* <li>1.44ms = the "low end" of the deadband range
* <li>0.94ms = full "reverse"
* <li>2.050ms = full "forward"
* <li>1.550ms = the "high end" of the deadband range
* <li>1.500ms = center of the deadband range (off)
* <li>1.440ms = the "low end" of the deadband range
* <li>0.940ms = full "reverse"
* </ul>
*/
public class SD540 extends PWMMotorController {
/**
* Constructor.
*
* @param channel The PWM channel that the SD540 is attached to. 0-9 are on-board, 10-19 are on
* the MXP port
* @param channel The PWM channel that the SD540 is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public SD540(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -14,8 +16,8 @@ import edu.wpi.first.wpilibj.PWM;
* <p>Note that the SPARK uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the Spark User Manual available from REV
* Robotics.
* recommended. The calibration procedure can be found in the SPARK User Manual available from
* REV Robotics.
*
* <ul>
* <li>2.003ms = full "forward"
@@ -29,8 +31,8 @@ public class Spark extends PWMMotorController {
/**
* Constructor.
*
* @param channel The PWM channel that the SPARK is attached to. 0-9 are on-board, 10-19 are on
* the MXP port
* @param channel The PWM channel that the SPARK is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public Spark(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,12 +11,13 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* Cross the Road Electronics (CTRE) Talon and Talon SR Motor Controller.
* Cross the Road Electronics (CTRE) Talon Motor Controller.
*
* <p>Note that the Talon uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the Talon User Manual available from CTRE.
* recommended. The calibration procedure can be found in the Talon User Manual available from
* Cross the Road Electronics (CTRE).
*
* <ul>
* <li>2.037ms = full "forward"
@@ -26,10 +29,10 @@ import edu.wpi.first.wpilibj.PWM;
*/
public class Talon extends PWMMotorController {
/**
* Constructor for a Talon (original or Talon SR).
* Constructor.
*
* @param channel The PWM channel that the Talon is attached to. 0-9 are on-board, 10-19 are on
* the MXP port
* @param channel The PWM channel that the Talon is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public Talon(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,16 +11,13 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* VEX Robotics Victor 888 Motor Controller The Vex Robotics Victor 884 Motor Controller can also be
* used with this class but may need to be calibrated per the Victor 884 user manual.
* Vex Robotics Victor 888 Motor Controller.
*
* <p>Note that the Victor uses the following bounds for PWM values. These values were determined
* empirically and optimized for the Victor 888. These values should work reasonably well for Victor
* 884 controllers also but if users experience issues such as asymmetric behavior around the
* deadband or inability to saturate the controller in either direction, calibration is recommended.
* The calibration procedure can be found in the Victor 884 User Manual available from VEX Robotics:
* <a
* href="http://content.vexrobotics.com/docs/ifi-v884-users-manual-9-25-06.pdf">http://content.vexrobotics.com/docs/ifi-v884-users-manual-9-25-06.pdf</a>
* <p>Note that the Victor 888 uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the Victor 888 User Manual available from
* Vex Robotics.
*
* <ul>
* <li>2.027ms = full "forward"
@@ -32,8 +31,8 @@ public class Victor extends PWMMotorController {
/**
* Constructor.
*
* @param channel The PWM channel that the Victor is attached to. 0-9 are on-board, 10-19 are on
* the MXP port
* @param channel The PWM channel that the Victor 888 is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public Victor(final int channel) {

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
// THIS FILE WAS AUTO-GENERATED BY ./wpilibj/generate_pwm_motor_controllers.py. DO NOT MODIFY
package edu.wpi.first.wpilibj.motorcontrol;
import edu.wpi.first.hal.FRCNetComm.tResourceType;
@@ -9,13 +11,13 @@ import edu.wpi.first.hal.HAL;
import edu.wpi.first.wpilibj.PWM;
/**
* VEX Robotics Victor SP Motor Controller.
* Vex Robotics Victor SP Motor Controller.
*
* <p>Note that the VictorSP uses the following bounds for PWM values. These values should work
* <p>Note that the Victor SP uses the following bounds for PWM values. These values should work
* reasonably well for most controllers, but if users experience issues such as asymmetric behavior
* around the deadband or inability to saturate the controller in either direction, calibration is
* recommended. The calibration procedure can be found in the VictorSP User Manual available from
* CTRE.
* recommended. The calibration procedure can be found in the Victor SP User Manual available from
* Vex Robotics.
*
* <ul>
* <li>2.004ms = full "forward"
@@ -29,8 +31,8 @@ public class VictorSP extends PWMMotorController {
/**
* Constructor.
*
* @param channel The PWM channel that the VictorSP is attached to. 0-9 are on-board, 10-19 are on
* the MXP port
* @param channel The PWM channel that the Victor SP is attached to. 0-9 are on-board, 10-19
* are on the MXP port
*/
@SuppressWarnings("this-escape")
public VictorSP(final int channel) {