Added defines for lighting output object present-value special values. (#1137)
This commit is contained in:
@@ -873,38 +873,47 @@ bool Lighting_Output_Present_Value_Set(
|
||||
the corresponding lighting command and is subject to the same
|
||||
restrictions. The special value itself is not written to the
|
||||
priority array. */
|
||||
if (is_float_equal(value, -1.0)) {
|
||||
if (is_float_equal(value, BACNET_LIGHTING_SPECIAL_VALUE_WARN)) {
|
||||
/* Provides the same functionality as the
|
||||
WARN lighting command. */
|
||||
Lighting_Command_Warn(pObject, priority);
|
||||
status = true;
|
||||
} else if (is_float_equal(value, -2.0)) {
|
||||
} else if (is_float_equal(
|
||||
value,
|
||||
BACNET_LIGHTING_SPECIAL_VALUE_WARN_RELINQUISH)) {
|
||||
/* Provides the same functionality as the
|
||||
WARN_RELINQUISH lighting command. */
|
||||
Lighting_Command_Warn_Relinquish(pObject, priority);
|
||||
status = true;
|
||||
} else if (is_float_equal(value, -3.0)) {
|
||||
} else if (is_float_equal(
|
||||
value, BACNET_LIGHTING_SPECIAL_VALUE_WARN_OFF)) {
|
||||
/* Provides the same functionality as the
|
||||
WARN_OFF lighting command. */
|
||||
Lighting_Command_Warn_Off(pObject, priority);
|
||||
status = true;
|
||||
#if (BACNET_PROTOCOL_REVISION >= 28)
|
||||
} else if (is_float_equal(value, -4.0)) {
|
||||
} else if (is_float_equal(
|
||||
value, BACNET_LIGHTING_SPECIAL_VALUE_RESTORE_ON)) {
|
||||
/* Provides the same functionality as the
|
||||
RESTORE_ON lighting command. */
|
||||
Lighting_Command_Restore_On(pObject, priority);
|
||||
status = true;
|
||||
} else if (is_float_equal(value, -5.0)) {
|
||||
} else if (is_float_equal(
|
||||
value, BACNET_LIGHTING_SPECIAL_VALUE_DEFAULT_ON)) {
|
||||
/* Provides the same functionality as the
|
||||
DEFAULT_ON lighting command. */
|
||||
Lighting_Command_Default_On(pObject, priority);
|
||||
status = true;
|
||||
} else if (is_float_equal(value, -6.0)) {
|
||||
} else if (is_float_equal(
|
||||
value,
|
||||
BACNET_LIGHTING_SPECIAL_VALUE_TOGGLE_RESTORE)) {
|
||||
/* Provides the same functionality as the
|
||||
TOGGLE_RESTORE lighting command. */
|
||||
Lighting_Command_Toggle_Restore(pObject, priority);
|
||||
status = true;
|
||||
} else if (is_float_equal(value, -7.0)) {
|
||||
} else if (is_float_equal(
|
||||
value,
|
||||
BACNET_LIGHTING_SPECIAL_VALUE_TOGGLE_DEFAULT)) {
|
||||
/* Provides the same functionality as the
|
||||
TOGGLE_DEFAULT lighting command. */
|
||||
Lighting_Command_Toggle_Default(pObject, priority);
|
||||
|
||||
Reference in New Issue
Block a user