AllJoyn/Samples/BACnetAdapter/bacnet-stack-0.8.2/demo/object/command.c
unsigned Command_Instance_To_Index(
    uint32_t object_instance)
{
    unsigned index = MAX_COMMANDS;

    if (object_instance < MAX_COMMANDS)
        index = object_instance;

    return index;
}
/**
 * For a given object instance-number, determines a 0..N index
 * of this object where N is the total number of this object instances
 *
 * @param object_instance - object-instance number of the object.
 *
 * @return index for the given instance-number, or
 * the total number of this object instances if not valid.
 */
For a given object instance-number, determines a 0..N index
of this object where N is the total number of this object instances

@param object_instance - object-instance number of the object.

@return index for the given instance-number, or
the total number of this object instances if not valid.
For a given object instance - number determines a 0 .. N index of this object where N is the total number of this object instances @param object_instance - object - instance number of the object . @return index for the given instance - number or the total number of this object instances if not valid .
unsigned Command_Instance_To_Index(
    uint32_t object_instance)
{
    unsigned index = MAX_COMMANDS;
    if (object_instance < MAX_COMMANDS)
        index = object_instance;
    return index;
}
unsigned Command_Instance_To_Index ( uint32_t object_instance ) { unsigned index = MAX_COMMANDS ; if ( object_instance < MAX_COMMANDS ) index = object_instance ; return index ; }
For a given object instance-number, determines a 0..N index
 of this object where N is the total number of this object instances
For a given object instance - number determines a 0 .. N index of this object where N is the total number of this object instances