This commit is contained in:
skarg
2007-10-19 04:11:20 +00:00
parent 1f8a8b6f84
commit 740bb873be
3 changed files with 16 additions and 25 deletions
+9 -7
View File
@@ -36,9 +36,9 @@
#include "version.h"
/* objects */
#include "device.h"
#include "ai.h"
#if 0
#include "av.h"
#if 0
#include "ai.h"
#include "bi.h"
#include "bv.h"
#include "wp.h"
@@ -105,12 +105,12 @@ unsigned Device_Object_List_Count(void)
unsigned count = 1; /* at least 1 for device object */
/* FIXME: add objects as needed */
count += Analog_Input_Count();
#if 0
count += Analog_Input_Count();
count += Binary_Input_Count();
count += Binary_Value_Count();
count += Analog_Value_Count();
#endif
count += Analog_Value_Count();
return count;
}
@@ -136,6 +136,7 @@ bool Device_Object_List_Identifier(unsigned array_index,
object_count = 1;
/* FIXME: add objects as needed */
/* analog input objects */
#if 0
if (!status) {
/* array index starts at 1, and 1 for the device object */
object_index -= object_count;
@@ -146,7 +147,6 @@ bool Device_Object_List_Identifier(unsigned array_index,
status = true;
}
}
#if 0
/* binary value objects */
if (!status) {
object_index -= object_count;
@@ -158,6 +158,7 @@ bool Device_Object_List_Identifier(unsigned array_index,
status = true;
}
}
#endif
/* analog value objects */
if (!status) {
/* array index starts at 1, and 1 for the device object */
@@ -169,6 +170,7 @@ bool Device_Object_List_Identifier(unsigned array_index,
status = true;
}
}
#if 0
/* binary input objects */
if (!status) {
/* normalize the index since
@@ -267,9 +269,9 @@ int Device_Encode_Property_APDU(uint8_t * apdu,
}
/* FIXME: indicate the objects that YOU support */
bitstring_set_bit(&bit_string, OBJECT_DEVICE, true);
bitstring_set_bit(&bit_string, OBJECT_ANALOG_INPUT, true);
#if 0
bitstring_set_bit(&bit_string, OBJECT_ANALOG_VALUE, true);
#if 0
bitstring_set_bit(&bit_string, OBJECT_ANALOG_INPUT, true);
bitstring_set_bit(&bit_string, OBJECT_BINARY_VALUE, true);
bitstring_set_bit(&bit_string, OBJECT_BINARY_INPUT, true);
#endif