Package frc.lib5k.components.sensors
Class LimitSwitch
- java.lang.Object
-
- edu.wpi.first.wpilibj.InterruptableSensorBase
-
- edu.wpi.first.wpilibj.DigitalSource
-
- edu.wpi.first.wpilibj.DigitalInput
-
- frc.lib5k.components.sensors.LimitSwitch
-
- All Implemented Interfaces:
edu.wpi.first.wpilibj.Sendable
,IBinarySensor
,java.lang.AutoCloseable
public class LimitSwitch extends edu.wpi.first.wpilibj.DigitalInput implements IBinarySensor
-
-
Constructor Summary
Constructors Constructor Description LimitSwitch(int channel)
Create a digital Limit Switch sensor object
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
get()
Get binary sensor reading-
Methods inherited from class edu.wpi.first.wpilibj.DigitalInput
close, getAnalogTriggerTypeForRouting, getChannel, getPortHandleForRouting, initSendable, isAnalogTrigger, setSimDevice
-
Methods inherited from class edu.wpi.first.wpilibj.InterruptableSensorBase
allocateInterrupts, cancelInterrupts, disableInterrupts, enableInterrupts, readFallingTimestamp, readRisingTimestamp, requestInterrupts, requestInterrupts, requestInterrupts, setUpSourceEdge, waitForInterrupt, waitForInterrupt
-
-
-
-
Method Detail
-
get
public boolean get()
Description copied from interface:IBinarySensor
Get binary sensor reading- Specified by:
get
in interfaceIBinarySensor
- Overrides:
get
in classedu.wpi.first.wpilibj.DigitalInput
- Returns:
- Is sensor on?
-
-