public class ContactClosureSensor extends ActivityHubSensor implements Iso11073ContactClosureSensor
driver
MY_DEVICE_CATEGORY
CLASS, MANUFACTURER, MATCH_CLASS, MATCH_MAKE, MATCH_MODEL, MATCH_SERIAL, MATCH_VERSION, MODEL, REVISION, SERIAL
Constructor and Description |
---|
ContactClosureSensor(ActivityHubDeviceCategoryUtil.ActivityHubDeviceCategory deviceCategory,
ActivityHubLocationUtil.ActivityHubLocation deviceLocation,
String deviceId,
org.osgi.service.log.LogService logger) |
Modifier and Type | Method and Description |
---|---|
int |
getSensorEventValue() |
void |
incomingSensorEvent(int event)
The specific drivers have to implement this method to receive messages
from devices
|
void |
setSensorEventOff()
set sensor event to off (e.g.
|
void |
setSensorEventOn()
set sensor event to on (e.g.
|
addDriver, getDeviceCategory, getDeviceId, getDeviceLocation, noDriverFound, removeDriver, sendEvent
public ContactClosureSensor(ActivityHubDeviceCategoryUtil.ActivityHubDeviceCategory deviceCategory, ActivityHubLocationUtil.ActivityHubLocation deviceLocation, String deviceId, org.osgi.service.log.LogService logger)
public int getSensorEventValue()
getSensorEventValue
in class ActivityHubSensor
public void setSensorEventOff()
ActivityHubSensor
setSensorEventOff
in class ActivityHubSensor
public void setSensorEventOn()
ActivityHubSensor
setSensorEventOn
in class ActivityHubSensor
public void incomingSensorEvent(int event)
ActivityHubBaseDeviceCategory
incomingSensorEvent
in interface ActivityHubBaseDeviceCategory
event
- Integer representation of a specific ActivityHubSensorEvent.
example MotionSensor: motion-detected = 0;
no-condition-detected = 3Copyright © 2018 universAAL Consortium. All rights reserved.