AWS IoT Over-the-air Update  v2.0.0 (Release Candidate)
Client library for AWS IoT OTA
Constants

Defined constants of the OTA library.

Libraries may #define constants in their headers with special meanings. This page describes the meanings and uses of any constants defined by the OTA library. Related constants are shown in a single section on this page.

OTA Error Code Helper constants

OTA PAL Error code helper for extracting the error code from the OTA PAL.

#define OTA_PAL_ERR_MASK 0xffffffUL
#define OTA_PAL_SUB_BITS 24U
#define OTA_PAL_MAIN_ERR( err ) ( ( OtaPalMainStatus_t ) ( uint32_t ) ( ( uint32_t ) ( err ) >> ( uint32_t ) OTA_PAL_SUB_BITS ) )
#define OTA_PAL_SUB_ERR( err ) ( ( uint32_t ) ( err ) & ( uint32_t ) OTA_PAL_ERR_MASK )
#define OTA_PAL_COMBINE_ERR( main, sub ) ( ( uint32_t ) ( main ) << ( uint32_t ) OTA_PAL_SUB_BITS | ( uint32_t ) ( sub ) )

OTA pal error codes consist of an main code in the upper 8 bits of a 32 bit word and sometimes merged with a platform specific code in the lower 24 bits. You must refer to the platform PAL layer in use to determine the meaning of the lower 24 bits.