Skip navigation links
A B C D E G I L N O P R S T V 

A

accept(byte) - Method in interface org.chabala.brick.controllab.ByteConsumer
Performs this operation on the given argument.
addListener(SensorListener) - Method in class org.chabala.brick.controllab.Input
Attach a listener for SensorEvents.
addListener(StopButtonListener) - Method in class org.chabala.brick.controllab.StopButton
Attach a listener for StopButtonEvents.
ALL - Static variable in enum org.chabala.brick.controllab.OutputId
Convenience constant for specifying all output ports.

B

ByteConsumer - Interface in org.chabala.brick.controllab
Like IntConsumer, but for Bytes.

C

close() - Method in interface org.chabala.brick.controllab.ControlLab
Disconnects from the control lab and releases any resources.
ControlLab - Interface in org.chabala.brick.controllab
This is the main interface for interacting with the LEGO® control lab, instances of which can be created with ControlLab.newControlLab().

D

decodeByteToSet(byte) - Static method in enum org.chabala.brick.controllab.OutputId
Decodes a byte into a Set of OutputIds.
Direction - Enum in org.chabala.brick.controllab
Identifiers for the direction of output ports on the control lab.

E

encodeSetToByte(Set<T>) - Static method in enum org.chabala.brick.controllab.OutputId
Encodes values from a Set of Enums to a byte.

G

getAnalogValue() - Method in class org.chabala.brick.controllab.sensor.LightSensor
 
getAnalogValue() - Method in interface org.chabala.brick.controllab.sensor.SensorValue
Analog value returned by sensor, in the range of 0 to 1023.
getAnalogValue() - Method in class org.chabala.brick.controllab.sensor.TemperatureSensor
 
getAnalogValue() - Method in class org.chabala.brick.controllab.sensor.TouchSensor
 
getAvailablePorts() - Method in interface org.chabala.brick.controllab.ControlLab
List available serial ports on this machine.
getCode() - Method in enum org.chabala.brick.controllab.Direction
The byte expected by the control lab for the change direction command.
getCode() - Method in enum org.chabala.brick.controllab.PowerLevel
The byte expected by the control lab for the change power level command.
getConnectedPortName() - Method in interface org.chabala.brick.controllab.ControlLab
Returns the system specific serial port identifier the control lab is connected to, or empty string if not connected.
getInput(InputId) - Method in interface org.chabala.brick.controllab.ControlLab
Return a handle for the input specified on this control lab instance.
getInput() - Method in class org.chabala.brick.controllab.sensor.SensorEvent
The input port that triggered this event.
getInputType() - Method in enum org.chabala.brick.controllab.InputId
Returns an InputType to indicate if this InputId is active or passive.
getNewValue() - Method in class org.chabala.brick.controllab.sensor.SensorEvent
The new value from this input, as a two byte array.
getOldValue() - Method in class org.chabala.brick.controllab.sensor.SensorEvent
The last known value from this input, prior to the event, as a two byte array.
getOutput(OutputId) - Method in interface org.chabala.brick.controllab.ControlLab
Return a handle for the output specified on this control lab instance.
getOutput(Set<OutputId>) - Method in interface org.chabala.brick.controllab.ControlLab
Return a handle for multiple outputs on this control lab instance.
getOutputIdSet() - Method in class org.chabala.brick.controllab.Output
Returns set of OutputIds this Output relates to.
getRawValue() - Method in class org.chabala.brick.controllab.StopButtonEvent
The raw data that signaled this event.
getStatusCode() - Method in class org.chabala.brick.controllab.sensor.LightSensor
 
getStatusCode() - Method in interface org.chabala.brick.controllab.sensor.SensorValue
Six bit status code from the sensor, as a value from 0 to 63.
getStatusCode() - Method in class org.chabala.brick.controllab.sensor.TemperatureSensor
 
getStatusCode() - Method in class org.chabala.brick.controllab.sensor.TouchSensor
 
getStopButton() - Method in interface org.chabala.brick.controllab.ControlLab
Return a handle for the stop button on this control lab instance.
getValue() - Method in class org.chabala.brick.controllab.sensor.SensorEvent
The new value from this input wrapped in the SensorValue class, or sensor specific subclass.

I

Input - Class in org.chabala.brick.controllab
Handle for an input port on a specific control lab instance.
InputId - Enum in org.chabala.brick.controllab
Identifiers for the input ports on the control lab.
InputType - Enum in org.chabala.brick.controllab
Identifiers for the type of sensor allowed on a particular input port.
isEngaged() - Method in interface org.chabala.brick.controllab.sensor.SensorValue
bit 4 looks like 0 for engaged, 1 for released.
isPassive() - Method in interface org.chabala.brick.controllab.sensor.SensorValue
bit 3 looks like 0 for passive, 1 for active sensors.
isStopDepressed() - Method in class org.chabala.brick.controllab.StopButton
Returns current status of stop button.

L

LightSensor - Class in org.chabala.brick.controllab.sensor
Light sensor.
LightSensor(SensorValue) - Constructor for class org.chabala.brick.controllab.sensor.LightSensor
 
LightSensorEvent - Class in org.chabala.brick.controllab.sensor
The event triggered by receiving a SensorValue from an InputId that is known to be a LightSensor.
LightSensorEvent(SensorEvent<SensorValue>) - Constructor for class org.chabala.brick.controllab.sensor.LightSensorEvent
Creates a LightSensorEvent from a generic SensorEvent, and wraps the SensorValue in the appropriate subclass.
lightSensorEventReceived(LightSensorEvent) - Method in interface org.chabala.brick.controllab.sensor.LightSensorListener
Callback for handling light sensor input events.
LightSensorListener - Interface in org.chabala.brick.controllab.sensor
The listener interface for receiving sensor input events from light sensors.
lightValue() - Method in class org.chabala.brick.controllab.sensor.LightSensor
 

N

newControlLab() - Static method in interface org.chabala.brick.controllab.ControlLab
Returns a new ControlLab instance.
newSensorValue(byte, byte) - Static method in interface org.chabala.brick.controllab.sensor.SensorValue
 

O

open(String) - Method in interface org.chabala.brick.controllab.ControlLab
Opens a connection to the control lab on the specified port.
org.chabala.brick.controllab - package org.chabala.brick.controllab
Library for controlling the LEGO® control lab interface.
org.chabala.brick.controllab.sensor - package org.chabala.brick.controllab.sensor
Contains listeners, events, and event values for the input ports and sensor specific subclasses to interpret the values.
Output - Class in org.chabala.brick.controllab
Handle for an output port (or group of ports) on a specific control lab instance.
OutputId - Enum in org.chabala.brick.controllab
Identifiers for the output ports on the control lab.

P

PowerLevel - Enum in org.chabala.brick.controllab
Identifiers for the power level of output ports on the control lab.

R

removeListener(SensorListener) - Method in class org.chabala.brick.controllab.Input
Remove a listener for SensorEvents.
removeListener(StopButtonListener) - Method in class org.chabala.brick.controllab.StopButton
Remove a listener for StopButtonEvents.
reverseDirection() - Method in class org.chabala.brick.controllab.Output
Reverses the Direction of this output.

S

SensorEvent<T extends SensorValue> - Class in org.chabala.brick.controllab.sensor
The event triggered by receiving a SensorValue from an InputId.
SensorEvent(InputId, byte[], byte[], T) - Constructor for class org.chabala.brick.controllab.sensor.SensorEvent
Constructs a SensorEvent.
SensorEvent(SensorEvent<SensorValue>, Function<SensorValue, T>) - Constructor for class org.chabala.brick.controllab.sensor.SensorEvent
A copy constructor for subclasses, to easily wrap the SensorValue in a more specific subclass.
sensorEventReceived(SensorEvent<SensorValue>) - Method in interface org.chabala.brick.controllab.sensor.LightSensorListener
This is the entrypoint for raw sensor data events.
sensorEventReceived(SensorEvent<SensorValue>) - Method in interface org.chabala.brick.controllab.sensor.SensorListener
This is the entrypoint for raw sensor data events.
sensorEventReceived(SensorEvent<SensorValue>) - Method in interface org.chabala.brick.controllab.sensor.TouchSensorListener
This is the entrypoint for raw sensor data events.
SensorListener - Interface in org.chabala.brick.controllab.sensor
The listener interface for receiving sensor input events.
SensorValue - Interface in org.chabala.brick.controllab.sensor
The values obtained from reading an InputId.
setDirection(Direction) - Method in class org.chabala.brick.controllab.Output
Sets the Direction of this output.
setOutputDirection(Direction, Set<OutputId>) - Method in interface org.chabala.brick.controllab.ControlLab
Sets the Direction of the specified outputs.
setOutputPowerLevel(PowerLevel, Set<OutputId>) - Method in interface org.chabala.brick.controllab.ControlLab
Sets the PowerLevel of the specified outputs.
setPowerLevel(PowerLevel) - Method in class org.chabala.brick.controllab.Output
Sets the PowerLevel of this output.
StopButton - Class in org.chabala.brick.controllab
Handle for stop button on a specific control lab instance.
StopButtonEvent - Class in org.chabala.brick.controllab
The event triggered by interacting with the red stop button on the control lab.
StopButtonEvent(Object, byte) - Constructor for class org.chabala.brick.controllab.StopButtonEvent
Constructs a StopButtonEvent.
StopButtonListener - Interface in org.chabala.brick.controllab
The listener interface for receiving stop button events.
stopButtonPressed(StopButtonEvent) - Method in interface org.chabala.brick.controllab.StopButtonListener
Invoked when the stop button is first pressed.
stopButtonReleased(StopButtonEvent) - Method in interface org.chabala.brick.controllab.StopButtonListener
Invoked when the stop button is disengaged.

T

TemperatureSensor - Class in org.chabala.brick.controllab.sensor
Temperature sensor.
TemperatureSensor(SensorValue) - Constructor for class org.chabala.brick.controllab.sensor.TemperatureSensor
 
temperatureValue() - Method in class org.chabala.brick.controllab.sensor.TemperatureSensor
 
toString() - Method in class org.chabala.brick.controllab.Input
toString() - Method in class org.chabala.brick.controllab.Output
toString() - Method in class org.chabala.brick.controllab.sensor.LightSensor
 
toString() - Method in class org.chabala.brick.controllab.sensor.SensorEvent
 
toString() - Method in class org.chabala.brick.controllab.sensor.TemperatureSensor
 
toString() - Method in class org.chabala.brick.controllab.sensor.TouchSensor
 
toString() - Method in class org.chabala.brick.controllab.StopButtonEvent
TouchSensor - Class in org.chabala.brick.controllab.sensor
Touch sensor.
TouchSensor(SensorValue) - Constructor for class org.chabala.brick.controllab.sensor.TouchSensor
 
TouchSensorEvent - Class in org.chabala.brick.controllab.sensor
The event triggered by receiving a SensorValue from an InputId that is known to be a TouchSensor.
TouchSensorEvent(SensorEvent<SensorValue>) - Constructor for class org.chabala.brick.controllab.sensor.TouchSensorEvent
Creates a TouchSensorEvent from a generic SensorEvent, and wraps the SensorValue in the appropriate subclass.
touchSensorEventReceived(TouchSensorEvent) - Method in interface org.chabala.brick.controllab.sensor.TouchSensorListener
Callback for handling touch sensor input events.
TouchSensorListener - Interface in org.chabala.brick.controllab.sensor
The listener interface for receiving sensor input events from touch sensors.
touchStatus() - Method in class org.chabala.brick.controllab.sensor.TouchSensor
 
turnOff() - Method in class org.chabala.brick.controllab.Output
Stops sending power to this output.
turnOn() - Method in class org.chabala.brick.controllab.Output
Starts sending power to this output.
turnOutputOff(Set<OutputId>) - Method in interface org.chabala.brick.controllab.ControlLab
Stops sending power to the specified outputs.
turnOutputOn(Set<OutputId>) - Method in interface org.chabala.brick.controllab.ControlLab
Starts sending power to the specified outputs.

V

valueOf(String) - Static method in enum org.chabala.brick.controllab.Direction
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.chabala.brick.controllab.InputId
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.chabala.brick.controllab.InputType
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.chabala.brick.controllab.OutputId
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.chabala.brick.controllab.PowerLevel
Returns the enum constant of this type with the specified name.
values() - Static method in enum org.chabala.brick.controllab.Direction
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.chabala.brick.controllab.InputId
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.chabala.brick.controllab.InputType
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.chabala.brick.controllab.OutputId
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.chabala.brick.controllab.PowerLevel
Returns an array containing the constants of this enum type, in the order they are declared.
A B C D E G I L N O P R S T V 
Skip navigation links

Copyright © 2016–2023. All rights reserved.