use of org.openhab.binding.tinkerforge.internal.types.DecimalValue in project openhab1-addons by openhab.
the class MBrickletAnalogOutV2Impl method setSensorValue.
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated
*/
@Override
public void setSensorValue(DecimalValue newSensorValue) {
DecimalValue oldSensorValue = sensorValue;
sensorValue = newSensorValue;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ModelPackage.MBRICKLET_ANALOG_OUT_V2__SENSOR_VALUE, oldSensorValue, sensorValue));
}
use of org.openhab.binding.tinkerforge.internal.types.DecimalValue in project openhab1-addons by openhab.
the class MBrickletAmbientLightImpl method setSensorValue.
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated
*/
@Override
public void setSensorValue(DecimalValue newSensorValue) {
DecimalValue oldSensorValue = sensorValue;
sensorValue = newSensorValue;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ModelPackage.MBRICKLET_AMBIENT_LIGHT__SENSOR_VALUE, oldSensorValue, sensorValue));
}
use of org.openhab.binding.tinkerforge.internal.types.DecimalValue in project openhab1-addons by openhab.
the class MBrickletAmbientLightV2Impl method setSensorValue.
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated
*/
@Override
public void setSensorValue(DecimalValue newSensorValue) {
DecimalValue oldSensorValue = sensorValue;
sensorValue = newSensorValue;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ModelPackage.MBRICKLET_AMBIENT_LIGHT_V2__SENSOR_VALUE, oldSensorValue, sensorValue));
}
use of org.openhab.binding.tinkerforge.internal.types.DecimalValue in project openhab1-addons by openhab.
the class MBrickletAmbientLightV2Impl method fetchSensorValue.
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
*
* @generated NOT
*/
@Override
public void fetchSensorValue() {
try {
long illuminance = tinkerforgeDevice.getIlluminance();
DecimalValue value = Tools.calculate100(illuminance);
setSensorValue(value);
} catch (TimeoutException e) {
TinkerforgeErrorHandler.handleError(this, TinkerforgeErrorHandler.TF_TIMEOUT_EXCEPTION, e);
} catch (NotConnectedException e) {
TinkerforgeErrorHandler.handleError(this, TinkerforgeErrorHandler.TF_NOT_CONNECTION_EXCEPTION, e);
}
}
use of org.openhab.binding.tinkerforge.internal.types.DecimalValue in project openhab1-addons by openhab.
the class MBrickdImpl method setConnectedCounter.
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated
*/
@Override
public void setConnectedCounter(DecimalValue newConnectedCounter) {
DecimalValue oldConnectedCounter = connectedCounter;
connectedCounter = newConnectedCounter;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ModelPackage.MBRICKD__CONNECTED_COUNTER, oldConnectedCounter, connectedCounter));
}
Aggregations