Current limits
Stator and supply limits in amperes, set per mechanism.
Limits
Cyclone has two configurable current limits. Set both. Stall current is 253 A — do not use that as a mechanism limit.
| Limit | Caps | Maximum you can request |
|---|---|---|
| Stator | Torque-producing current | 160 A |
| Supply | Current from the PDH / battery | 60 A |
Apply
Set limits in robot code at boot. SWYFT Link is for the pit and for checking a mechanism before the subsystem exists.
- Install the Cyclone vendordep in the WPILib 2027 project. Java
- In
robotInit(), apply stator and supply from the starting-point table. - Enable with the shaft clear. Command duty every loop.
- After practice, raise stator only if the mechanism cannot complete the move and the motor is not hot.
Java — WPILib 2027
Place SwyftCycloneV4.json in vendordeps/ and rebuild.
Year token: 2027. Class: com.swyftrobotics.cyclone.v4.SwyftCyclone,
constructed with CAN ID 1–62.
apply blocks. Call it from robotInit() or a one-shot command, not from
periodic.
Vendor library API names can change.
import com.swyftrobotics.cyclone.v4.CurrentLimitsConfigs;
import com.swyftrobotics.cyclone.v4.SwyftCyclone;
import org.wpilib.framework.TimedRobot;
public class Robot extends TimedRobot {
private final SwyftCyclone intake = new SwyftCyclone(5);
@Override
public void robotInit() {
var cfg = new CurrentLimitsConfigs();
cfg.StatorCurrentLimit = 20; // A — intake starting point
cfg.SupplyCurrentLimit = 20; // A
intake.getConfigurator().apply(cfg);
}
@Override
public void teleopPeriodic() {
// Every loop. A stale setpoint coasts.
intake.setDutyCycle(0.25);
}
@Override
public void disabledInit() {
intake.disable();
}
}
Set only StatorCurrentLimit and SupplyCurrentLimit. Leave other fields
unset (NaN) so the device keeps its stored values. There is no enable bit for
the stator limit — you cannot turn the protection off from robot code.
SupplyCurrentLowerLimit and SupplyCurrentLowerTime throw
UnsupportedOperationException. If that throw leaves robotInit(), the
robot program never registers and the Driver Station reports no robot code.
setDutyCycle and set are the same quantity: a fraction of bus voltage,
−1 to 1. 0.25 is a quarter of the bus, not a quarter of free speed. Call it
every loop. A stale setpoint coasts.
Starting points
Tune after a practice match.
| Mechanism | Supply | Stator |
|---|---|---|
| Drivetrain module | 60 A | 80 A |
| Swerve azimuth / light mechanism | 40 A | 40 A |
| Elevator / arm | 40 A | 60 A |
| Intake | No extra supply cap if draw stays under ~20 A | 20 A |
Do not leave an unconfigured robot at the stator ceiling. Start from the table. Raise stator only if the mechanism cannot complete the move and the motor is not hot.
NEXT Status lights