Added enumerations and text for notification class object support.
This commit is contained in:
@@ -1426,7 +1426,15 @@ typedef enum BACnetDaysOfWeek {
|
|||||||
BACNET_DAYS_OF_WEEK_THURSDAY = 3,
|
BACNET_DAYS_OF_WEEK_THURSDAY = 3,
|
||||||
BACNET_DAYS_OF_WEEK_FRIDAY = 4,
|
BACNET_DAYS_OF_WEEK_FRIDAY = 4,
|
||||||
BACNET_DAYS_OF_WEEK_SATURDAY = 5,
|
BACNET_DAYS_OF_WEEK_SATURDAY = 5,
|
||||||
BACNET_DAYS_OF_WEEK_SUNDAY = 6
|
BACNET_DAYS_OF_WEEK_SUNDAY = 6,
|
||||||
|
MAX_BACNET_DAYS_OF_WEEK = 7
|
||||||
} BACNET_DAYS_OF_WEEK;
|
} BACNET_DAYS_OF_WEEK;
|
||||||
|
|
||||||
|
typedef enum BACnetEventTransitionBits {
|
||||||
|
TRANSITION_TO_OFFNORMAL = 0,
|
||||||
|
TRANSITION_TO_FAULT = 1,
|
||||||
|
TRANSITION_TO_NORMAL = 2,
|
||||||
|
MAX_BACNET_EVENT_TRANSITION = 3
|
||||||
|
} BACNET_EVENT_TRANSITION_BITS;
|
||||||
|
|
||||||
#endif /* end of BACENUM_H */
|
#endif /* end of BACENUM_H */
|
||||||
|
|||||||
@@ -98,6 +98,17 @@ extern "C" {
|
|||||||
const char *bactext_segmentation_name(
|
const char *bactext_segmentation_name(
|
||||||
unsigned index);
|
unsigned index);
|
||||||
|
|
||||||
|
const char *bactext_event_transition_name(
|
||||||
|
unsigned index);
|
||||||
|
bool bactext_event_transition_index(
|
||||||
|
const char *search_name,
|
||||||
|
unsigned *found_index);
|
||||||
|
|
||||||
|
const char *bactext_days_of_week_name(
|
||||||
|
unsigned index);
|
||||||
|
bool bactext_days_of_week_index(
|
||||||
|
const char *search_name,
|
||||||
|
unsigned *found_index);
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1717,6 +1717,62 @@ const char *bactext_day_of_week_name(
|
|||||||
ASHRAE_Reserved_String);
|
ASHRAE_Reserved_String);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* note: different than DayOfWeek bit string where 1=monday */
|
||||||
|
INDTEXT_DATA bacnet_days_of_week_names[] = {
|
||||||
|
{BACNET_DAYS_OF_WEEK_MONDAY, "Monday"},
|
||||||
|
{BACNET_DAYS_OF_WEEK_TUESDAY, "Tuesday"},
|
||||||
|
{BACNET_DAYS_OF_WEEK_WEDNESDAY, "Wednesday"},
|
||||||
|
{BACNET_DAYS_OF_WEEK_THURSDAY, "Thursday"},
|
||||||
|
{BACNET_DAYS_OF_WEEK_FRIDAY, "Friday"},
|
||||||
|
{BACNET_DAYS_OF_WEEK_SATURDAY, "Saturday"},
|
||||||
|
{BACNET_DAYS_OF_WEEK_SUNDAY, "Sunday"},
|
||||||
|
{0, NULL}
|
||||||
|
};
|
||||||
|
|
||||||
|
const char *bactext_days_of_week_name(
|
||||||
|
unsigned index)
|
||||||
|
{
|
||||||
|
return indtext_by_index_default(bacnet_days_of_week_names, index,
|
||||||
|
ASHRAE_Reserved_String);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool bactext_days_of_week_index(
|
||||||
|
const char *search_name,
|
||||||
|
unsigned *found_index)
|
||||||
|
{
|
||||||
|
return indtext_by_istring(
|
||||||
|
bacnet_days_of_week_names,
|
||||||
|
search_name,
|
||||||
|
found_index);
|
||||||
|
}
|
||||||
|
|
||||||
|
INDTEXT_DATA bacnet_event_transition_names[] = {
|
||||||
|
{TRANSITION_TO_OFFNORMAL, "offnormal"}
|
||||||
|
,
|
||||||
|
{TRANSITION_TO_NORMAL, "normal"}
|
||||||
|
,
|
||||||
|
{TRANSITION_TO_FAULT, "fault"}
|
||||||
|
,
|
||||||
|
{0, NULL}
|
||||||
|
};
|
||||||
|
|
||||||
|
const char *bactext_event_transition_name(
|
||||||
|
unsigned index)
|
||||||
|
{
|
||||||
|
return indtext_by_index_default(bacnet_event_transition_names, index,
|
||||||
|
ASHRAE_Reserved_String);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool bactext_event_transition_index(
|
||||||
|
const char *search_name,
|
||||||
|
unsigned *found_index)
|
||||||
|
{
|
||||||
|
return indtext_by_istring(
|
||||||
|
bacnet_event_transition_names,
|
||||||
|
search_name,
|
||||||
|
found_index);
|
||||||
|
}
|
||||||
|
|
||||||
INDTEXT_DATA bacnet_event_state_names[] = {
|
INDTEXT_DATA bacnet_event_state_names[] = {
|
||||||
{EVENT_STATE_NORMAL, "normal"}
|
{EVENT_STATE_NORMAL, "normal"}
|
||||||
,
|
,
|
||||||
|
|||||||
Reference in New Issue
Block a user