AllJoyn/Samples/BACnetAdapter/bacnet-stack-0.8.2/demo/object/gw_device.c
bool Routed_Device_Set_Object_Name(
    uint8_t encoding,
    const char *value,
    size_t length)
{
    bool status = false;        /*return value */
    DEVICE_OBJECT_DATA *pDev = &Devices[iCurrent_Device_Idx];

    if ((encoding == CHARACTER_UTF8) && (length < MAX_DEV_NAME_LEN)) {
        /* Make the change and update the database revision */
        memmove(pDev->bacObj.Object_Name, value, length);
        pDev->bacObj.Object_Name[length] = 0;
        Routed_Device_Inc_Database_Revision();
        status = true;
    }

    return status;
}
/** Sets the Object Name for a routed Device (or the gateway).
 * Uses local variable iCurrent_Device_Idx to know which Device
 * is to be updated.
 * @param object_name [in] Character String for the new Object Name.
 * @return True if succeed in updating Object Name, else False.
 */
Sets the Object Name for a routed Device (or the gateway).
Uses local variable iCurrent_Device_Idx to know which Device
is to be updated.
@param object_name [in] Character String for the new Object Name.
@return True if succeed in updating Object Name, else False.
Sets the Object Name for a routed Device ( or the gateway ) . Uses local variable iCurrent_Device_Idx to know which Device is to be updated . @param object_name [ in ] Character String for the new Object Name . @return True if succeed in updating Object Name else False .
bool Routed_Device_Set_Object_Name(
    uint8_t encoding,
    const char *value,
    size_t length)
{
    bool status = false;        
    DEVICE_OBJECT_DATA *pDev = &Devices[iCurrent_Device_Idx];
    if ((encoding == CHARACTER_UTF8) && (length < MAX_DEV_NAME_LEN)) {
        memmove(pDev->bacObj.Object_Name, value, length);
        pDev->bacObj.Object_Name[length] = 0;
        Routed_Device_Inc_Database_Revision();
        status = true;
    }
    return status;
}
bool Routed_Device_Set_Object_Name ( uint8_t encoding , const char * value , size_t length ) { bool status = false ; DEVICE_OBJECT_DATA * pDev = & Devices [ iCurrent_Device_Idx ] ; if ( ( encoding == CHARACTER_UTF8 ) && ( length < MAX_DEV_NAME_LEN ) ) { memmove ( pDev -> bacObj . Object_Name , value , length ) ; pDev -> bacObj . Object_Name [ length ] = 0 ; Routed_Device_Inc_Database_Revision ( ) ; status = true ; } return status ; }
Sets the Object Name for a routed Device (or the gateway).
Sets the Object Name for a routed Device ( or the gateway ) .
/*return value */ /* Make the change and update the database revision */