public abstract class HiTechnicNxtController extends I2cControllerPortDeviceImpl implements Engagable, HardwareDevice
HardwareDevice.Manufacturer
Modifier and Type | Field and Description |
---|---|
protected Context |
context |
protected I2cDevice |
i2cDevice |
protected I2cDeviceSynch |
i2cDeviceSynch |
protected boolean |
isEngaged |
protected boolean |
isHardwareInitialized |
protected boolean |
isHooked |
controller, physicalPort
Constructor and Description |
---|
HiTechnicNxtController(Context context,
I2cController module,
int physicalPort,
I2cAddr i2cAddr) |
Modifier and Type | Method and Description |
---|---|
protected void |
adjustHookingToMatchEngagement() |
void |
close()
Closes this device
|
protected void |
controllerNowDisarmed()
intended as a subclass hook
|
void |
disengage()
Disengage the object from underlying services it uses to render its function.
|
protected void |
doHook() |
protected void |
doUnhook() |
void |
engage()
(Re)enage the object with its underlying services.
|
protected abstract void |
floatHardware() |
HardwareDevice.Manufacturer |
getManufacturer()
Returns an indication of the manufacturer of this device.
|
protected void |
hook() |
protected abstract void |
initializeHardware() |
protected boolean |
isArmed() |
boolean |
isEngaged()
Returns whether the object is currently in the engaged state.
|
protected byte |
read8(int ireg) |
protected void |
unhook() |
protected void |
write(int ireg,
byte[] data) |
protected void |
write8(int ireg,
byte data) |
controllerNowArmedOrPretending, finishConstruction, getI2cController, getPort, onModuleStateChange
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getConnectionInfo, getDeviceName, getVersion, resetDeviceConfigurationForOpMode
protected Context context
protected boolean isEngaged
protected boolean isHooked
protected I2cDevice i2cDevice
protected I2cDeviceSynch i2cDeviceSynch
protected boolean isHardwareInitialized
public HiTechnicNxtController(Context context, I2cController module, int physicalPort, I2cAddr i2cAddr)
public HardwareDevice.Manufacturer getManufacturer()
HardwareDevice
getManufacturer
in interface HardwareDevice
public void close()
HardwareDevice
close
in interface HardwareDevice
protected abstract void initializeHardware()
protected abstract void floatHardware()
public void engage()
Engagable
public void disengage()
Engagable
public boolean isEngaged()
Engagable
protected void controllerNowDisarmed()
I2cControllerPortDeviceImpl
controllerNowDisarmed
in class I2cControllerPortDeviceImpl
protected void adjustHookingToMatchEngagement()
protected void hook()
protected void unhook()
protected void doHook()
protected void doUnhook()
protected boolean isArmed()
protected void write8(int ireg, byte data)
protected void write(int ireg, byte[] data)
protected byte read8(int ireg)