Snapdragon® Telematics Application Framework (TelAF) Interface Specification
|
#include "legato.h"
Go to the source code of this file.
Macros | |
#define | IFGEN_TAF_HMS_PROTOCOL_ID "cc3827cbeec19f09ccdab03c0939c367" |
#define | IFGEN_TAF_HMS_MSG_SIZE 48 |
#define | TAF_HMS_MAX_NAME_SIZE 32 |
Typedefs | |
typedef struct taf_hms_UbiDevInfoList * | taf_hms_UbiDevInfoListRef_t |
typedef struct taf_hms_UbiDevInfo * | taf_hms_UbiDevInfoRef_t |
typedef struct taf_hms_UbiVolInfo * | taf_hms_UbiVolInfoRef_t |
typedef struct taf_hms_MtdDevInfoList * | taf_hms_MtdDevInfoListRef_t |
typedef struct taf_hms_MtdDevInfo * | taf_hms_MtdDevInfoRef_t |
#define IFGEN_TAF_HMS_PROTOCOL_ID "cc3827cbeec19f09ccdab03c0939c367" |
#define IFGEN_TAF_HMS_MSG_SIZE 48 |
#define TAF_HMS_MAX_NAME_SIZE 32 |
The maximum size of the String.
typedef struct taf_hms_UbiDevInfoList* taf_hms_UbiDevInfoListRef_t |
The UBI device information list reference.
typedef struct taf_hms_UbiDevInfo* taf_hms_UbiDevInfoRef_t |
Reference type for details of UBI device info.
typedef struct taf_hms_UbiVolInfo* taf_hms_UbiVolInfoRef_t |
Reference type for details of UBI volume info.
typedef struct taf_hms_MtdDevInfoList* taf_hms_MtdDevInfoListRef_t |
The MTD information list reference.
typedef struct taf_hms_MtdDevInfo* taf_hms_MtdDevInfoRef_t |
Reference type for details of MTD info.
LE_SHARED bool ifgen_taf_hms_HasLocalBinding | ( | void | ) |
Get if this client bound locally.
LE_SHARED void ifgen_taf_hms_InitCommonData | ( | void | ) |
Init data that is common across all threads
LE_SHARED void ifgen_taf_hms_CleanupCommonData | ( | le_msg_SessionRef_t | _ifgen_sessionRef | ) |
Cleanup the data of a session
LE_SHARED le_result_t ifgen_taf_hms_OpenSession | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
bool | isBlocking | ||
) |
Perform common initialization and open a session
LE_SHARED le_result_t ifgen_taf_hms_GetCpuLoad | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
double * | cpuCurrentLoadPtr | ||
) |
Gets the total CPU usage from " /proc/stat ".
[out] | cpuCurrentLoadPtr | CPU Total Usage. |
LE_SHARED uint32_t ifgen_taf_hms_GetCpuCoreNum | ( | le_msg_SessionRef_t | _ifgen_sessionRef | ) |
Gets number of CPU core from " /proc/cpuinfo ".
LE_SHARED le_result_t ifgen_taf_hms_GetIndvCoreUsage | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
uint32_t | coreID, | ||
double * | cpuUsagePtr | ||
) |
Gets the CPU usage of each core from " /proc/stat ". The API provides total CPU usage of each core ranging from 0 to 100 %. The coreID range can be 0 - (cpuCoreNum-1), the result value can be LE_OK.
[in] | coreID | Core ID |
[out] | cpuUsagePtr | cpuUsage |
LE_SHARED le_result_t ifgen_taf_hms_GetRamMemInfo | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
uint32_t * | ramTotalMemPtr, | ||
uint32_t * | ramUsedMemPtr, | ||
uint32_t * | ramFreeMemPtr | ||
) |
Gets the meminfo value from " /proc/meminfo ".
[out] | ramTotalMemPtr | Total Memory in kB. |
[out] | ramUsedMemPtr | Used Memory in kB. |
[out] | ramFreeMemPtr | Free memory in kB. |
LE_SHARED taf_hms_UbiDevInfoListRef_t ifgen_taf_hms_GetUbiDevInfoList | ( | le_msg_SessionRef_t | _ifgen_sessionRef | ) |
Gets the list of available UBI device information.
LE_SHARED taf_hms_UbiDevInfoRef_t ifgen_taf_hms_GetFirstUbiDevInfo | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiDevInfoListRef_t | ubiDevInfoListRef | ||
) |
Gets the first UBI device Info object reference in the list of the UbiDevInfoList retrieved with taf_hms_GetUbiDevInfoList().
[in] | ubiDevInfoListRef | UBI device list reference |
LE_SHARED le_result_t ifgen_taf_hms_DeleteUbiDevInfoList | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiDevInfoListRef_t | ubiDevInfoListRef | ||
) |
Deletes the UbiDevInfoList list retrieved with taf_hms_GetUbiDevInfoList().
[in] | ubiDevInfoListRef | UBI device list reference |
LE_SHARED taf_hms_UbiDevInfoRef_t ifgen_taf_hms_GetNextUbiDevInfo | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiDevInfoListRef_t | ubiDevInfoListRef | ||
) |
Gets the next UBI device Info object reference in the list of the UBIInfoList retrieved with taf_hms_GetUBIInfoList().
[in] | ubiDevInfoListRef | UBI device list reference |
LE_SHARED le_result_t ifgen_taf_hms_GetUbiDevId | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiDevInfoRef_t | ubiDevInfoRef, | ||
uint32_t * | ubiDevIdPtr | ||
) |
Gets UBI device ID
[in] | ubiDevInfoRef | UBI device Info reference. |
[out] | ubiDevIdPtr | UBI device ID |
LE_SHARED le_result_t ifgen_taf_hms_GetUbiDevMaxEraseCnt | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiDevInfoRef_t | ubiDevInfoRef, | ||
uint32_t * | ubiEraseCntPtr | ||
) |
Gets UBI information for current maximum erase count from " /sys/class/ubi/ubi%d/ ".
[in] | ubiDevInfoRef | UBI device Info reference. |
[out] | ubiEraseCntPtr | Erase count. |
LE_SHARED le_result_t ifgen_taf_hms_GetUbiDevBadBlkCnt | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiDevInfoRef_t | ubiDevInfoRef, | ||
uint32_t * | ubiBbCntPtr | ||
) |
Gets UBI information for bad block count from " /sys/class/ubi/ubi%d/ ".
[in] | ubiDevInfoRef | UBI device Info reference. |
[out] | ubiBbCntPtr | Bad Block count. |
LE_SHARED taf_hms_UbiVolInfoRef_t ifgen_taf_hms_GetFirstUbiVolInfo | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiDevInfoRef_t | ubiDevInfoRef | ||
) |
Gets the first UBI volume Info object reference in the list of the UbiVolInfoList retrieved with taf_hms_GetUbiDevInfoList().
[in] | ubiDevInfoRef | UBI device Info reference. |
LE_SHARED taf_hms_UbiVolInfoRef_t ifgen_taf_hms_GetNextUbiVolInfo | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiDevInfoRef_t | ubiDevInfoRef | ||
) |
Gets the next UBI volume Info object reference in the list of the UbiVolInfoList retrieved with taf_hms_GetUbiDevInfoList().
[in] | ubiDevInfoRef | UBI device Info reference. |
LE_SHARED le_result_t ifgen_taf_hms_GetUbiVolId | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiVolInfoRef_t | ubiVolInfoRef, | ||
uint32_t * | ubiVolIdPtr | ||
) |
Gets UBI volume ID.
[in] | ubiVolInfoRef | |
[out] | ubiVolIdPtr |
LE_SHARED le_result_t ifgen_taf_hms_GetUbiVolName | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiVolInfoRef_t | ubiVolInfoRef, | ||
char * | ubiVolName, | ||
size_t | ubiVolNameSize | ||
) |
Gets name of UBI volume.
[in] | ubiVolInfoRef | UBI device Info reference. |
[out] | ubiVolName | UBI volume name. |
[in] | ubiVolNameSize |
LE_SHARED le_result_t ifgen_taf_hms_GetUbiVolSize | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_UbiVolInfoRef_t | ubiVolInfoRef, | ||
uint32_t * | ubiVolSizePtr | ||
) |
Gets size of UBI volume in bytes.
[in] | ubiVolInfoRef | UBI device Info reference. |
[out] | ubiVolSizePtr | UBI volume size. |
LE_SHARED taf_hms_MtdDevInfoListRef_t ifgen_taf_hms_GetMtdDevInfoList | ( | le_msg_SessionRef_t | _ifgen_sessionRef | ) |
Gets the list of available MTD Node.
LE_SHARED le_result_t ifgen_taf_hms_DeleteMtdDevInfoList | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_MtdDevInfoListRef_t | mtdDevInfoListRef | ||
) |
Deletes the MtdInfoList list retrieved with taf_hms_GetMtdInfoList().
[in] | mtdDevInfoListRef | MTD device list reference |
LE_SHARED taf_hms_MtdDevInfoRef_t ifgen_taf_hms_GetFirstMtdDevInfo | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_MtdDevInfoListRef_t | mtdDevInfoListRef | ||
) |
Gets the first MtdInfo object reference in the list of the MtdInfoList retrieved with taf_hms_GetMtdInfoList().
[in] | mtdDevInfoListRef | MTD node list reference |
LE_SHARED taf_hms_MtdDevInfoRef_t ifgen_taf_hms_GetNextMtdDevInfo | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_MtdDevInfoListRef_t | mtdDevInfoListRef | ||
) |
Gets the next MtdInfo object reference in the list of the MtdInfoList retrieved with taf_hms_GetMtdInfoList().
[in] | mtdDevInfoListRef | MTD node list reference |
LE_SHARED le_result_t ifgen_taf_hms_GetMtdDevName | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_MtdDevInfoRef_t | mtdDevInfoRef, | ||
char * | mtdName, | ||
size_t | mtdNameSize | ||
) |
Gets MTD information for name from " /sys/class/mtd/mtd%d/ ".
[in] | mtdDevInfoRef | MTD Info reference. |
[out] | mtdName | MTD name. |
[in] | mtdNameSize |
LE_SHARED le_result_t ifgen_taf_hms_GetMtdDevBlkSize | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_MtdDevInfoRef_t | mtdDevInfoRef, | ||
uint32_t * | mtdBlkSizePtr | ||
) |
Gets MTD information for block size in bytes.
[in] | mtdDevInfoRef | MTD Info reference. |
[out] | mtdBlkSizePtr | Bad block size. |
LE_SHARED le_result_t ifgen_taf_hms_GetMtdDevId | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_MtdDevInfoRef_t | mtdDevInfoRef, | ||
uint32_t * | mtdDevIdPtr | ||
) |
Gets MTD information for device ID.
[in] | mtdDevInfoRef | MTD Info reference. |
[out] | mtdDevIdPtr | Device ID. |
LE_SHARED le_result_t ifgen_taf_hms_GetMtdDevBlkCnt | ( | le_msg_SessionRef_t | _ifgen_sessionRef, |
taf_hms_MtdDevInfoRef_t | mtdDevInfoRef, | ||
uint32_t * | mtdBlkCntPtr | ||
) |
Gets MTD information for block count.
[in] | mtdDevInfoRef | MTD Info reference. |
[out] | mtdBlkCntPtr | Block count. |