Integrated ReadPropertyMultiple with the demo/server application. Compiles, but untested.

This commit is contained in:
skarg
2007-07-19 00:21:38 +00:00
parent a8555ef196
commit 5b07b5b920
30 changed files with 1047 additions and 431 deletions
+41 -3
View File
@@ -47,6 +47,47 @@ static BACNET_BINARY_PV
/* without changing the physical output */
static bool Binary_Value_Out_Of_Service[MAX_BINARY_VALUES];
/* These three arrays are used by the ReadPropertyMultiple handler */
static const int Binary_Value_Properties_Required[] =
{
PROP_OBJECT_IDENTIFIER,
PROP_OBJECT_NAME,
PROP_OBJECT_TYPE,
PROP_PRESENT_VALUE,
PROP_STATUS_FLAGS,
PROP_EVENT_STATE,
PROP_OUT_OF_SERVICE,
-1
};
static const int Binary_Value_Properties_Optional[] =
{
PROP_DESCRIPTION,
PROP_PRIORITY_ARRAY,
PROP_RELINQUISH_DEFAULT,
-1
};
static const int Binary_Value_Properties_Proprietary[] =
{
-1
};
void Binary_Value_Property_Lists(
const int **pRequired,
const int **pOptional,
const int **pProprietary)
{
if (*pRequired)
*pRequired = Binary_Value_Properties_Required;
if (*pOptional)
*pOptional = Binary_Value_Properties_Optional;
if (*pProprietary)
*pProprietary = Binary_Value_Properties_Proprietary;
return;
}
void Binary_Value_Init(void)
{
unsigned i, j;
@@ -195,9 +236,6 @@ int Binary_Value_Encode_Property_APDU(uint8_t * apdu,
state = Binary_Value_Out_Of_Service[object_index];
apdu_len = encode_tagged_boolean(&apdu[0], state);
break;
case PROP_POLARITY:
apdu_len = encode_tagged_enumerated(&apdu[0], polarity);
break;
case PROP_PRIORITY_ARRAY:
/* Array element zero is the number of elements in the array */
if (array_index == 0)