Package | Description |
---|---|
org.chabala.brick.controllab.sensor |
Contains listeners, events, and event values for the input ports
and sensor specific subclasses to interpret the values.
|
Modifier and Type | Class and Description |
---|---|
class |
SensorEvent<T extends SensorValue>
The event triggered by receiving a
SensorValue from an InputId . |
Modifier and Type | Class and Description |
---|---|
class |
LightSensor
Light sensor.
|
class |
TemperatureSensor
Temperature sensor.
|
class |
TouchSensor
Touch sensor.
|
Modifier and Type | Method and Description |
---|---|
static SensorValue |
SensorValue.newSensorValue(byte high,
byte low) |
Modifier and Type | Method and Description |
---|---|
default void |
TouchSensorListener.sensorEventReceived(SensorEvent<SensorValue> sensorEvent)
This is the entrypoint for raw sensor data events.
|
default void |
LightSensorListener.sensorEventReceived(SensorEvent<SensorValue> sensorEvent)
This is the entrypoint for raw sensor data events.
|
void |
SensorListener.sensorEventReceived(SensorEvent<SensorValue> sensorEvent)
This is the entrypoint for raw sensor data events.
|
Constructor and Description |
---|
LightSensor(SensorValue sensorValue) |
TemperatureSensor(SensorValue sensorValue) |
TouchSensor(SensorValue sensorValue) |
Constructor and Description |
---|
LightSensorEvent(SensorEvent<SensorValue> sensorEvent)
Creates a LightSensorEvent from a generic
SensorEvent , and wraps
the SensorValue in the appropriate subclass. |
SensorEvent(SensorEvent<SensorValue> sensorEvent,
Function<SensorValue,T> sensorWrapper)
A copy constructor for subclasses, to easily wrap the
SensorValue in a
more specific subclass. |
SensorEvent(SensorEvent<SensorValue> sensorEvent,
Function<SensorValue,T> sensorWrapper)
A copy constructor for subclasses, to easily wrap the
SensorValue in a
more specific subclass. |
TouchSensorEvent(SensorEvent<SensorValue> sensorEvent)
Creates a TouchSensorEvent from a generic
SensorEvent , and wraps
the SensorValue in the appropriate subclass. |
Copyright © 2016–2023. All rights reserved.