Parameter

    This module can obtain device information such as device type and manufacturer.

    Since:

    1.0

    Version:

    1.0

    Summary

    Files

    Functions

    Details

    Function Documentation

    GetAbiList()

    Description:

    Obtains the list of application binary interfaces (ABIs) supported on this device.

    The interfaces in the ABI list are separated by commas (,). This function is available only for an OS with an ecosystem accommodating native applications.

    Returns:

    Returns the ABI list if a result is found; returns NULL otherwise. The return result is released by the caller.

    GetBootloaderVersion()

    Description:

    Obtains the bootloader version of this device.

    The bootloader version can have a maximum length of 64 characters.

    Returns:

    Returns the bootloader version if a result is found; returns NULL otherwise. The return result is released by the caller.

    GetBrand()

    1. char* GetBrand (void )

    Description:

    Obtains the device brand.

    The device brand can have a maximum length of 32 characters.

    Returns:

    Returns the device brand if a result is found; returns NULL otherwise. The return result is released by the caller.

    GetBuildHost()

    1. char* GetBuildHost (void )

    Description:

    Obtains the build host name.

    The build host name can have a maximum length of 32 characters.

    Returns:

    Returns the build host name if a result is found; returns NULL otherwise. The return result is released by the caller.

      Description:

      Obtains the buildroot hash value of this version.

      The buildroot hash value is represented by the root hash value in the software version hash tree.

      Returns:

      Returns the buildroot hash value if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetBuildTime()

      1. char* GetBuildTime (void )

      Description:

      Obtains the version build time.

      The version build time is represented by the number of milliseconds elapsed since 1970-01-01 00:00:00 GMT.

      Returns:

      Returns the version build time if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetBuildType()

      1. char* GetBuildType (void )

      Description:

      Obtains the build type.

      Different build types with the same baseline codes will be returned, for example, debug/release and log/nolog. Multiple build types can be separated by semicolons (;).

      Returns:

      Returns the build type if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetBuildUser()

      1. char* GetBuildUser (void )

      Description:

      Obtains the build account user name.

      The build account user name can have a maximum length of 32 characters.

      Returns:

      Returns the build account user name if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetDisplayVersion()

      Description:

      Obtains the software version visible to users.

      The software version visible to users can have a maximum length of 64 characters.

      Returns:

      Returns the software version visible to users if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetFirstApiLevel()

      Description:

      Obtains the first SDK API level of the system software.

      In general, the first SDK API level is an integer. This function is only available for an OS with an ecosystem.

      Returns:

      Returns the first SDK API level if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetHardwareModel()

      1. char* GetHardwareModel (void )

      Description:

      Obtains the device hardware model.

      The device hardware model can have a maximum length of 32 characters.

      Returns:

      Returns the device hardware model if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetHardwareProfile()

      1. char* GetHardwareProfile (void )

      Description:

      Obtains the device hardware profile.

      The device hardware profile is a string in JSON format and has a maximum length of 1000 characters.

      Returns:

      Returns the device hardware profile if a result is found; returns NULL otherwise. The return result is released by the caller. The JSON field in the device hardware profile is defined as follows:

      GetIncrementalVersion()

      1. char* GetIncrementalVersion (void )

      Description:

      Obtains the incremental version.

      The incremental version can be used as the unique software version when the device model is the same.

      Returns:

      Returns the incremental version if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetManufacture()

      1. char* GetManufacture (void )

      Description:

      Obtains the device manufacturer.

      The device manufacturer can have a maximum length of 32 characters.

      Returns:

      Returns the device manufacturer if a result is found; returns NULL otherwise. The return result is released by the caller.

      1. char* GetMarketName (void )

      Description:

      Obtains the device marketing name.

      The device marketing name can have a maximum length of 32 characters.

      Returns:

      Returns the device marketing name if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetOsName()

      1. char* GetOsName (void )

      Description:

      Obtains the operating system (OS) name.

      The device OS name can have a maximum length of 32 characters.

      Returns:

      Returns the device OS name if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetParameter()

      Description:

      Obtains a system parameter matching the specified key.

      If no system parameter is found, the def parameter will be returned.

      Parameters:

      Returns:

      Returns the number of bytes of the system parameter if the operation is successful; returns -9 if a parameter is incorrect; returns -1 in other scenarios.

      GetProductModel()

      Description:

      Obtains the device authentication model.

      The device authentication model can have a maximum length of 32 characters.

      Returns:

      Returns the device authentication model if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetProductSeries()

      1. char* GetProductSeries (void )

      Description:

      Obtains the device series name.

      The device series name can have a maximum length of 32 characters.

      Returns:

      Returns the device series name if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetProductType()

      1. char* GetProductType (void )

      Description:

      Obtains the device type.

      The device type can have a maximum length of 32 characters.

      Returns:

      Returns the device type if a result is found, for example, returns wifiiot if the application is running on a Wi-Fi connected IoT device; returns NULL otherwise. The return result is released by the caller.

      GetSdkApiLevel()

      1. char* GetSdkApiLevel (void )

      Description:

      Obtains the SDK API level that matches the current system software.

      In general, the SDK API level is an integer. This function is only available for an OS with an ecosystem.

      Returns:

      Returns the SDK API level if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetSecurityPatchTag()

      1. char* GetSecurityPatchTag (void )

      Description:

      Obtains the security patch tag.

      Returns:

      Returns the security patch tag if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetSerial()

      1. char* GetSerial (void )

      Description:

      Obtains the device serial number (SN).

      The device SN can have a maximum length of 64 characters.

      Returns:

      Returns the device SN if a result is found; returns NULL otherwise. The return result is released by the caller.

      GetSoftwareModel()

      1. char* GetSoftwareModel (void )

      Description:

      Obtains the device software model.

      The device software model can have a maximum length of 32 characters.

      Returns:

      Returns the device software model if a result is found; returns NULL otherwise. The return result is released by the caller.

      Description:

      Obtains the version ID.

      The version ID can have a maximum length of 127 characters. It is the unique identifier of a device.

      Returns:

      Returns the version ID if a result is found; returns NULL otherwise. The return result is released by the caller.

      SetParameter()

        Description:

        Sets or updates a system parameter.

        You can use this function to set a system parameter that matches key as value.

        Parameters:

        Returns: