Class I2CInput
java.lang.Object
org.wildstang.framework.io.inputs.Input
org.wildstang.framework.io.inputs.I2CInput
- Direct Known Subclasses:
WsI2CInput
First abstraction of Input representing I2C Inputs.
Currently there are no implementations of this type.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbyte[]getValue()Returns the latest stored value from the Input.protected voidProcesses raw value read from Input's hardware.protected abstract byte[]Abstract function to request and return the raw value from hardware.voidsetValue(byte[] p_newValue) Takes a new value stores it and notifys listeners.Methods inherited from class org.wildstang.framework.io.inputs.Input
addInputListener, disable, enable, getInputListeners, getName, hasValueChanged, isEnabled, notifyListeners, removeAllListeners, removeInputListener, setValueChanged, update
-
Constructor Details
-
I2CInput
Constructor simply passes on name.- Parameters:
p_name- Name of the Input.
-
-
Method Details
-
readDataFromInput
protected void readDataFromInput()Processes raw value read from Input's hardware.- Specified by:
readDataFromInputin classInput
-
setValue
public void setValue(byte[] p_newValue) Takes a new value stores it and notifys listeners. This is a public version of setNewValue() for manual value updating.- Parameters:
p_newValue- New value read for the Input.
-
readRawValue
protected abstract byte[] readRawValue()Abstract function to request and return the raw value from hardware.- Returns:
- The latest value read from hardware.
-
getValue
public byte[] getValue()Returns the latest stored value from the Input.- Returns:
- Latest value store in the Input.
-