add ota algorithm for device

1. effective "Differential Upgrade" patch algorithm with high compression rate
2. effective recovery algorithm support recovery firmware in blocks which has low memory consumption and wear-leveling strategies, especially suitable for embeded devices with low RAM.
3. add sample ota bootloader project, see:
board\TencentOS_tiny_EVB_MX_Plus\KEIL\ota\ota_bootloader_recovery
4. add sample application project for download firmware through http, see:
board\TencentOS_tiny_EVB_MX_Plus\KEIL\ota\ota_application_download_through_http
5. add sample application project for download firmware through qcloud explorer console, see:
board\TencentOS_tiny_EVB_MX_Plus\KEIL\ota\ota_application_download_through_qcloud_iot_explorer
6. an OTA markdown document is pending
This commit is contained in:
daishengdong
2020-06-02 15:03:42 +08:00
parent 84faf16765
commit 5b51d50ade
177 changed files with 42367 additions and 1233 deletions

View File

@@ -255,7 +255,7 @@ __API__ k_err_t tos_task_create_dyn(k_task_t **task,
return K_ERR_TASK_OUT_OF_MEMORY;
}
stk_base = tos_mmheap_aligned_alloc(stk_size, sizeof(cpu_addr_t));
stk_base = tos_mmheap_alloc(stk_size);
if (!stk_base) {
tos_mmheap_free(the_task);
return K_ERR_TASK_OUT_OF_MEMORY;
@@ -349,9 +349,9 @@ __API__ k_err_t tos_task_prio_change(k_task_t *task, k_prio_t prio_new)
k_prio_t highest_pending_prio;
#endif
TOS_IN_IRQ_CHECK();
TOS_PTR_SANITY_CHECK(task);
TOS_OBJ_VERIFY(task, KNL_OBJ_TYPE_TASK);
TOS_IN_IRQ_CHECK();
if (unlikely(prio_new >= K_TASK_PRIO_IDLE)) {
return K_ERR_TASK_PRIO_INVALID;
@@ -497,9 +497,9 @@ __API__ k_err_t tos_task_delay_abort(k_task_t *task)
{
TOS_CPU_CPSR_ALLOC();
TOS_IN_IRQ_CHECK();
TOS_PTR_SANITY_CHECK(task);
TOS_OBJ_VERIFY(task, KNL_OBJ_TYPE_TASK);
TOS_IN_IRQ_CHECK();
TOS_CPU_INT_DISABLE();