Class WsDigitalInput
java.lang.Object
org.wildstang.framework.io.inputs.Input
org.wildstang.framework.io.inputs.DigitalInput
org.wildstang.hardware.roborio.inputs.WsDigitalInput
Reads a digital input.
-
Constructor Summary
ConstructorsConstructorDescriptionWsDigitalInput(String p_name, int channel, boolean p_pullup) Construct the digital input. -
Method Summary
Methods inherited from class org.wildstang.framework.io.inputs.DigitalInput
getValue, readDataFromInput, setValueMethods inherited from class org.wildstang.framework.io.inputs.Input
addInputListener, disable, enable, getInputListeners, getName, hasValueChanged, isEnabled, notifyListeners, removeAllListeners, removeInputListener, setValueChanged, update
-
Constructor Details
-
WsDigitalInput
Construct the digital input.- Parameters:
p_name- Descriptive name for the input.channel- Hardware channel used for input.p_pullup- Whether pull up more should be used.
-
-
Method Details
-
readRawValue
public boolean readRawValue()Reads the value from the digital input. Note: if pull up mode is enabled input is reversed.- Specified by:
readRawValuein classDigitalInput- Returns:
- Raw value from input.
-