BLE_OTAPS_SetEncrytionInfo

C

uint16_t BLE_OTAPS_SetEncrytionInfo(uint8_t * p_iv, uint8_t * p_key);

Description

Sets the Initialization Vector (IV) and encryption key for AES-CBC decryption of the new OTA DFU image.

Note

This function must be called before starting the BLE OTA procedure if the image is encrypted.

Parameters

ParameterDescription
[in] p_ivPointer to the 16-byte IV.
[in] p_keyPointer to the 16-byte encryption key.

Return values

Return valueDescription
MBA_RES_SUCCESSIV and key set successfully.
MBA_RES_BAD_STATEOperation failed because OTA is in progress.