Un-refactored property-list module to lower resource requirements on small devices.
This commit is contained in:
@@ -50,7 +50,19 @@
|
||||
ANALOG_INPUT_DESCR AI_Descr[MAX_ANALOG_INPUTS];
|
||||
|
||||
/* These arrays are used by the ReadPropertyMultiple handler */
|
||||
static const int Properties_Optional[] = {
|
||||
static const int Analog_Input_Properties_Required[] = {
|
||||
PROP_OBJECT_IDENTIFIER,
|
||||
PROP_OBJECT_NAME,
|
||||
PROP_OBJECT_TYPE,
|
||||
PROP_PRESENT_VALUE,
|
||||
PROP_STATUS_FLAGS,
|
||||
PROP_EVENT_STATE,
|
||||
PROP_OUT_OF_SERVICE,
|
||||
PROP_UNITS,
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Analog_Input_Properties_Optional[] = {
|
||||
PROP_DESCRIPTION,
|
||||
PROP_RELIABILITY,
|
||||
PROP_COV_INCREMENT,
|
||||
@@ -69,7 +81,7 @@ static const int Properties_Optional[] = {
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Properties_Proprietary[] = {
|
||||
static const int Analog_Input_Properties_Proprietary[] = {
|
||||
9997,
|
||||
9998,
|
||||
9999,
|
||||
@@ -82,11 +94,11 @@ void Analog_Input_Property_Lists(
|
||||
const int **pProprietary)
|
||||
{
|
||||
if (pRequired)
|
||||
*pRequired = property_list_required(OBJECT_ANALOG_INPUT);
|
||||
*pRequired = Analog_Input_Properties_Required;
|
||||
if (pOptional)
|
||||
*pOptional = Properties_Optional;
|
||||
*pOptional = Analog_Input_Properties_Optional;
|
||||
if (pProprietary)
|
||||
*pProprietary = Properties_Proprietary;
|
||||
*pProprietary = Analog_Input_Properties_Proprietary;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -77,11 +77,26 @@ struct bacnet_channel_object Channel[BACNET_CHANNELS_MAX];
|
||||
|
||||
/* These arrays are used by the ReadPropertyMultiple handler
|
||||
property-list property (as of protocol-revision 14) */
|
||||
static const int Properties_Optional[] = {
|
||||
static const int Channel_Properties_Required[] = {
|
||||
PROP_OBJECT_IDENTIFIER,
|
||||
PROP_OBJECT_NAME,
|
||||
PROP_OBJECT_TYPE,
|
||||
PROP_PRESENT_VALUE,
|
||||
PROP_LAST_PRIORITY,
|
||||
PROP_WRITE_STATUS,
|
||||
PROP_STATUS_FLAGS,
|
||||
PROP_OUT_OF_SERVICE,
|
||||
PROP_LIST_OF_OBJECT_PROPERTY_REFERENCES,
|
||||
PROP_CHANNEL_NUMBER,
|
||||
PROP_CONTROL_GROUPS,
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Properties_Proprietary[] = {
|
||||
static const int Channel_Properties_Optional[] = {
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Channel_Properties_Proprietary[] = {
|
||||
-1
|
||||
};
|
||||
|
||||
@@ -101,11 +116,11 @@ void Channel_Property_Lists(const int **pRequired,
|
||||
const int **pProprietary)
|
||||
{
|
||||
if (pRequired)
|
||||
*pRequired = property_list_required(OBJECT_CHANNEL);
|
||||
*pRequired = Channel_Properties_Required;
|
||||
if (pOptional)
|
||||
*pOptional = Properties_Optional;
|
||||
*pOptional = Channel_Properties_Optional;
|
||||
if (pProprietary)
|
||||
*pProprietary = Properties_Proprietary;
|
||||
*pProprietary = Channel_Properties_Proprietary;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -306,12 +306,23 @@ int cl_decode_apdu(
|
||||
COMMAND_DESCR Command_Descr[MAX_COMMANDS];
|
||||
|
||||
/* These arrays are used by the ReadPropertyMultiple handler */
|
||||
static const int Properties_Optional[] = {
|
||||
static const int Command_Properties_Required[] = {
|
||||
PROP_OBJECT_IDENTIFIER,
|
||||
PROP_OBJECT_NAME,
|
||||
PROP_OBJECT_TYPE,
|
||||
PROP_PRESENT_VALUE,
|
||||
PROP_IN_PROCESS,
|
||||
PROP_ALL_WRITES_SUCCESSFUL,
|
||||
PROP_ACTION,
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Command_Properties_Optional[] = {
|
||||
PROP_DESCRIPTION,
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Properties_Proprietary[] = {
|
||||
static const int Command_Properties_Proprietary[] = {
|
||||
-1
|
||||
};
|
||||
|
||||
@@ -332,11 +343,11 @@ void Command_Property_Lists(
|
||||
const int **pProprietary)
|
||||
{
|
||||
if (pRequired)
|
||||
*pRequired = property_list_required(OBJECT_COMMAND);
|
||||
*pRequired = Command_Properties_Required;
|
||||
if (pOptional)
|
||||
*pOptional = Properties_Optional;
|
||||
*pOptional = Command_Properties_Optional;
|
||||
if (pProprietary)
|
||||
*pProprietary = Properties_Proprietary;
|
||||
*pProprietary = Command_Properties_Proprietary;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -75,11 +75,32 @@ struct lighting_output_object Lighting_Output[MAX_LIGHTING_OUTPUTS];
|
||||
|
||||
/* These arrays are used by the ReadPropertyMultiple handler and
|
||||
property-list property (as of protocol-revision 14) */
|
||||
static const int Properties_Optional[] = {
|
||||
static const int Lighting_Output_Properties_Required[] = {
|
||||
PROP_OBJECT_IDENTIFIER,
|
||||
PROP_OBJECT_NAME,
|
||||
PROP_OBJECT_TYPE,
|
||||
PROP_PRESENT_VALUE,
|
||||
PROP_TRACKING_VALUE,
|
||||
PROP_LIGHTING_COMMAND,
|
||||
PROP_IN_PROGRESS,
|
||||
PROP_STATUS_FLAGS,
|
||||
PROP_OUT_OF_SERVICE,
|
||||
PROP_BLINK_WARN_ENABLE,
|
||||
PROP_EGRESS_TIME,
|
||||
PROP_EGRESS_ACTIVE,
|
||||
PROP_DEFAULT_FADE_TIME,
|
||||
PROP_DEFAULT_RAMP_RATE,
|
||||
PROP_DEFAULT_STEP_INCREMENT,
|
||||
PROP_PRIORITY_ARRAY,
|
||||
PROP_RELINQUISH_DEFAULT,
|
||||
PROP_LIGHTING_COMMAND_DEFAULT_PRIORITY,
|
||||
-1
|
||||
};
|
||||
static const int Lighting_Output_Properties_Optional[] = {
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Properties_Proprietary[] = {
|
||||
static const int Lighting_Output_Properties_Proprietary[] = {
|
||||
-1
|
||||
};
|
||||
|
||||
@@ -100,11 +121,11 @@ void Lighting_Output_Property_Lists(
|
||||
const int **pProprietary)
|
||||
{
|
||||
if (pRequired)
|
||||
*pRequired = property_list_required(OBJECT_LIGHTING_OUTPUT);
|
||||
*pRequired = Lighting_Output_Properties_Required;
|
||||
if (pOptional)
|
||||
*pOptional = Properties_Optional;
|
||||
*pOptional = Lighting_Output_Properties_Optional;
|
||||
if (pProprietary)
|
||||
*pProprietary = Properties_Proprietary;
|
||||
*pProprietary = Lighting_Output_Properties_Proprietary;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -56,12 +56,29 @@ static BACNET_LIFE_SAFETY_OPERATION
|
||||
static bool Life_Safety_Point_Out_Of_Service[MAX_LIFE_SAFETY_POINTS];
|
||||
/* These arrays are used by the ReadPropertyMultiple handler and
|
||||
property-list property (as of protocol-revision 14) */
|
||||
static const int Properties_Optional[] = {
|
||||
static const int Life_Safety_Point_Properties_Required[] = {
|
||||
PROP_OBJECT_IDENTIFIER,
|
||||
PROP_OBJECT_NAME,
|
||||
PROP_OBJECT_TYPE,
|
||||
PROP_PRESENT_VALUE,
|
||||
PROP_TRACKING_VALUE,
|
||||
PROP_STATUS_FLAGS,
|
||||
PROP_EVENT_STATE,
|
||||
PROP_OUT_OF_SERVICE,
|
||||
PROP_RELIABILITY,
|
||||
PROP_MODE,
|
||||
PROP_ACCEPTED_MODES,
|
||||
PROP_SILENCED,
|
||||
PROP_OPERATION_EXPECTED,
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Life_Safety_Point_Properties_Optional[] = {
|
||||
PROP_DESCRIPTION,
|
||||
-1
|
||||
};
|
||||
|
||||
static const int Properties_Proprietary[] = {
|
||||
static const int Life_Safety_Point_Properties_Proprietary[] = {
|
||||
-1
|
||||
};
|
||||
|
||||
@@ -82,13 +99,13 @@ void Life_Safety_Point_Property_Lists(
|
||||
const int **pProprietary)
|
||||
{
|
||||
if (pRequired) {
|
||||
*pRequired = property_list_required(OBJECT_LIFE_SAFETY_POINT);
|
||||
*pRequired = Life_Safety_Point_Properties_Required;
|
||||
}
|
||||
if (pOptional) {
|
||||
*pOptional = Properties_Optional;
|
||||
*pOptional = Life_Safety_Point_Properties_Optional;
|
||||
}
|
||||
if (pProprietary) {
|
||||
*pProprietary = Properties_Proprietary;
|
||||
*pProprietary = Life_Safety_Point_Properties_Proprietary;
|
||||
}
|
||||
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user