The REV PDH (REV-11-1850) has one special switchable low-current channel (15A continuous) that you can turn on and off from code. This is perfect for things that should not always be live: addressable LED strips for signaling, a cooling fan, or a Limelight/camera that you want to power-cycle without re-deploying. (The CTRE PDP does not expose a software-switchable channel; on a PDP you would use a separate relay/switch.)
Wiring: Run the load's positive lead from the PDH's switchable channel output (clearly silk-screened on the board) and the negative to any PD negative WAGO. Use 18 AWG for a sub-5A load like an LED strip and respect the 15A channel ceiling. As a low-current channel it must be protected per R620 with an ATM/APM-style mini blade fuse rated 15A or lower (the PDH's low-current and switchable channels use ATM/APM fuses, not ATC/ATO — ATC/ATO at 10A or lower is the PDP 2.0 requirement).
Code it (WPILib):
PowerDistribution pdh = new PowerDistribution(1, ModuleType.kRev);
// Turn the channel on (e.g. when a game piece is acquired)
pdh.setSwitchableChannel(true);
// Turn it off (e.g. when empty)
pdh.setSwitchableChannel(false);
A real example: a status light tied to robot state.
@Override public void robotPeriodic() {
boolean haveGamePiece = intakeSensor.get();
pdh.setSwitchableChannel(haveGamePiece);
}
Now an LED strip on the switchable channel lights up the instant the intake sensor sees a game piece, giving the driver and human player a clear visual cue from across the field, with zero extra relays.
A power-cycle helper for a flaky camera:
public void rebootCamera() {
pdh.setSwitchableChannel(false);
// re-enable 2 seconds later via a Command
new edu.wpi.first.wpilibj2.command.WaitCommand(2.0)
.andThen(() -> pdh.setSwitchableChannel(true))
.schedule();
}
Gotchas:
- Treat the switchable channel as OFF until your code drives it true. If your light or camera never comes on, you probably never called
setSwitchableChannel(true). - Do not put anything safety-critical (radio, roboRIO, RSL) on a switchable channel. The radio and roboRIO should be powered through the PD's dedicated fused outputs, never through a switched path.
- Confirm the channel actually toggles by watching the load and by reading current draw on the dashboard from Mini-Project 3.
This tiny project teaches a powerful pattern: hardware behavior driven directly by robot state, with no extra wiring beyond a single switched lead.
Key takeaways
- The PDH has exactly one software-controllable switchable channel (15A continuous); the PDP has no software-switchable channel.
- pdh.setSwitchableChannel(true/false) toggles it from code.
- Never put the radio, roboRIO, or RSL on a switchable channel; reserve it for LEDs, fans, or cameras you want to power-cycle.
Go deeper
Lesson quiz
RequiredAnswer all 3 questions correctly to complete this lesson.
01.How many independently switchable output channels does the REV Power Distribution Hub (PDH) provide for software control of devices like lights or a vision camera?
02.Which WPILib PowerDistribution method turns the PDH's switchable channel on or off?
03.What is the maximum continuous current rating of the PDH's switchable channel, which constrains what loads (lights, a vision coprocessor) you can put on it?
Answer every question to submit.
All 35 lessons in Electrical & Wiring
- Not started:Mini-Project 1: A Single-Motor Test Stand from Battery to Spin
- Not started:Mini-Project 2: Current-Limited Drivetrain (CTRE and REV)
- Not started:Mini-Project 3: A Live Power-Monitoring Dashboard
- Not started:Mini-Project 4: A Switchable Channel for Lights and Vision
- Not started:Mini-Project 5: CAN Device Bring-Up with Tuner X and the Hardware Client