SafePWM

class wpilib.SafePWM(channel)[source]

Bases: wpilib.PWM, wpilib.MotorSafety

A raw PWM interface that implements the MotorSafety interface

Constructor for a SafePWM object taking a channel number.

Parameters:channel (int) – The channel number to be used for the underlying PWM object. 0-9 are on-board, 10-19 are on the MXP port.
disable()[source]
getDescription()[source]
stopMotor()[source]

Stop the motor associated with this PWM object. This is called by the MotorSafety object when it has a timeout for this PWM and needs to stop it from running.