本文整理匯總了Java中edu.wpi.first.wpilibj.Relay.setDirection方法的典型用法代碼示例。如果您正苦於以下問題:Java Relay.setDirection方法的具體用法?Java Relay.setDirection怎麽用?Java Relay.setDirection使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類edu.wpi.first.wpilibj.Relay
的用法示例。
在下文中一共展示了Relay.setDirection方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: Shooter
import edu.wpi.first.wpilibj.Relay; //導入方法依賴的package包/類
public Shooter(JoystickControl controller) {
this.controller = controller;
WINCH = new Relay(WINCH_RELAY_CHANNEL);
WINCH.setDirection(Relay.Direction.kForward);
shooterSwitch = new DigitalInput(WINCH_DIGITAL_SIDECAR_SLOT,
WINCH_DIGITAL_CHANNEL);
cycleCounts = 0;
}
示例2: Flashlight
import edu.wpi.first.wpilibj.Relay; //導入方法依賴的package包/類
/**
* A private constructor to prevent multiple instances from being created.
*/
private Flashlight() {
lightRelay = new Relay(RobotMap.flashlightRelay.getInt());
lightRelay.setDirection(Relay.Direction.kForward);
}
示例3: Compressor
import edu.wpi.first.wpilibj.Relay; //導入方法依賴的package包/類
private Compressor()
{
compressorRelay = new Relay(1);
compressorRelay.setDirection(Relay.Direction.kForward);
}
示例4: OffBoardCompressor
import edu.wpi.first.wpilibj.Relay; //導入方法依賴的package包/類
private OffBoardCompressor()
{
compressorRelay = new Relay(RobotMap.OFF_BOARD_COMPRESSOR_RELAY);
compressorRelay.setDirection(Relay.Direction.kForward);
}
示例5: Gripper
import edu.wpi.first.wpilibj.Relay; //導入方法依賴的package包/類
public Gripper(){
gripperRelay = new Relay(1);
gripperRelay.setDirection(Relay.Direction.kBoth);
}