Azure IoT middleware for FreeRTOS
Macros | Typedefs | Functions
azure_iot.h File Reference

Azure IoT FreeRTOS middleware common APIs and structs. More...

#include "azure_iot_config.h"
#include "azure_iot_config_defaults.h"
#include "FreeRTOS.h"
#include "azure_iot_result.h"
#include "azure/core/_az_cfg_prefix.h"
#include "azure/core/_az_cfg_suffix.h"

Go to the source code of this file.

Macros

#define azureiotMILLISECONDS_PER_TICK   ( 1000 / configTICK_RATE_HZ )
 Milliseconds per FreeRTOS tick.
 

Typedefs

typedef uint64_t(* AzureIoTGetCurrentTimeFunc_t) (void)
 The platform get time function to be used by the SDK for MQTT connections. More...
 
typedef uint32_t(* AzureIoTGetHMACFunc_t) (const uint8_t *pucKey, uint32_t ulKeyLength, const uint8_t *pucData, uint32_t ulDataLength, uint8_t *pucOutput, uint32_t ulOutputLength, uint32_t *pulBytesCopied)
 The HMAC256 function used by the SDK to generate SAS keys. More...
 

Functions

AzureIoTResult_t AzureIoT_Init ()
 Initialize Azure IoT middleware. More...
 
void AzureIoT_Deinit ()
 Deinitialize Azure IoT middleware. More...
 

Detailed Description

Azure IoT FreeRTOS middleware common APIs and structs.

Note
You MUST NOT use any symbols (macros, functions, structures, enums, etc.) prefixed with an underscore ('_') directly in your application code. These symbols are part of Azure SDK's internal implementation; we do not document these symbols and they are subject to change in future versions of the SDK which would break your code.

Typedef Documentation

◆ AzureIoTGetCurrentTimeFunc_t

typedef uint64_t( * AzureIoTGetCurrentTimeFunc_t) (void)

The platform get time function to be used by the SDK for MQTT connections.

Returns
The time (in seconds) since Unix epoch.

◆ AzureIoTGetHMACFunc_t

typedef uint32_t( * AzureIoTGetHMACFunc_t) (const uint8_t *pucKey, uint32_t ulKeyLength, const uint8_t *pucData, uint32_t ulDataLength, uint8_t *pucOutput, uint32_t ulOutputLength, uint32_t *pulBytesCopied)

The HMAC256 function used by the SDK to generate SAS keys.

Parameters
[in]pucKeyThe key to use for the HMAC operation.
[in]ulKeyLengthThe length of pucKey.
[in]pucDataThe data on which the operation will take place. In this context, the data will be a certain concatenation of the iot hub name, sas key, and expiration time.
[in]ulDataLengthThe length of pucData.
[in,out]pucOutputThe buffer into which the processed data will be placed.
[in]ulOutputLengthThe size of pucOutput.
[out]pulBytesCopiedThe number of bytes copied into pucOutput.

Function Documentation

◆ AzureIoT_Deinit()

void AzureIoT_Deinit ( )

Deinitialize Azure IoT middleware.

Note
This should be called once per process.

◆ AzureIoT_Init()

AzureIoTResult_t AzureIoT_Init ( )

Initialize Azure IoT middleware.

Note
This should be called once per process.