iap 优化,避免 v8 升级失败

Signed-off-by: a1012112796 <1012112796@qq.com>
This commit is contained in:
2023-12-08 08:42:05 +08:00
parent 1830fad2a7
commit 32d8112577
8 changed files with 171 additions and 64 deletions

View File

@@ -395,11 +395,11 @@ static int _iap_entry(rt_bool_t is_boot)
_response_cmd(IAP_V5_CMD_ONE_REPLY);
rt_thread_mdelay(200);
if (!iap_v5_req_char(console_dev, &_wait, 'c', 1000))
{
err = RT_ENOSYS;
goto _exit;
}
// if (!iap_v5_req_char(console_dev, &_wait, 'c', 1000))
// {
// err = RT_ENOSYS;
// goto _exit;
// }
_response_cmd(IAP_V5_CMD_C_REPLY);
@@ -410,6 +410,7 @@ static int _iap_entry(rt_bool_t is_boot)
rt_kprintf("rt_malloc failed\n");
goto _exit;
}
ctx->parent.v5_iap_adapt = RT_TRUE;
ctx->flash = fal_partition_find(IapAppAddr? IAP_FLASH_BOOT_SEC: IAP_FLASH_APP_SEC);
if (ctx->flash == RT_NULL)