OTA library header file.
More...
Go to the source code of this file.
|
enum | flashOtaStatus_et {
OTA_STATUS_READY
, OTA_STATUS_SUCCESS
, OTA_STATUS_GET_PARTITION_FAILED
, OTA_STATUS_BEGIN_FAILED
,
OTA_STATUS_WRITE_FAILED
, OTA_STATUS_END_FAILED
, OTA_STATUS_SET_PARTITION_FAILED
, OTA_STATUS_TIMEDOUT
,
OTA_STATUS_DOWNLOAD_FAILED
, OTA_STATUS_FAILED_UNKOWN_REASON
, OTA_STATUS_MAX
} |
|
enum | firmUpdateType_et { OTA_UPDATE_TYPE_NONE
, OTA_UPDATE_TYPE_LOCAL
, OTA_UPDATE_TYPE_WEB
, OTA_UPDATE_TYPE_MAX
} |
|
◆ firmUpdateType_et
Types of supported firmware updates.
Enumerator |
---|
OTA_UPDATE_TYPE_NONE | None
|
OTA_UPDATE_TYPE_LOCAL | Perform local update
|
OTA_UPDATE_TYPE_WEB | Perform web update
|
OTA_UPDATE_TYPE_MAX | Total number of firmware update types
|
◆ flashOtaStatus_et
An enum to represent OTA status.
Enumerator |
---|
OTA_STATUS_READY | Ready status
|
OTA_STATUS_SUCCESS | OTA was successful
|
OTA_STATUS_GET_PARTITION_FAILED | Failed to get partition
|
OTA_STATUS_BEGIN_FAILED | Failed to start OTA
|
OTA_STATUS_WRITE_FAILED | Failed to write OTA packets
|
OTA_STATUS_END_FAILED | Failed to end OTA process
|
OTA_STATUS_SET_PARTITION_FAILED | Failed to set boot parition after OTA
|
OTA_STATUS_TIMEDOUT | OTA process timedout
|
OTA_STATUS_DOWNLOAD_FAILED | OTA file download failed
|
OTA_STATUS_FAILED_UNKOWN_REASON | OTA failed with unknown error
|
OTA_STATUS_MAX | Total number of OTA status
|
◆ OTA_getProgressPercentage()
uint8_t OTA_getProgressPercentage |
( |
| ) |
|
Get OTA progress in percentage.
- Parameters
-
- Returns
- Progress value in percentage.
◆ OTA_inProgress()
Check if OTA is in progress.
- Parameters
-
- Returns
- Status to indicate if OTA is in progress
- Return values
-
true | if in progress |
false | if not in progress |
◆ OTA_printStatus()
Prints the status of OTA.
- Parameters
-
- Returns
- none
◆ OTA_start()
Start OTA firmware update process.
- Parameters
-
[in] | updateType_e | type of update |
- Returns
- status of OTA start request
- Return values
-
true | on success |
false | on failure |