bl602 boot counter - this breaks other paltforms

This commit is contained in:
openshwprojects
2022-04-17 17:40:00 +02:00
parent 29d3764e13
commit 997c1eeaee
15 changed files with 168 additions and 73 deletions

View File

@ -7,6 +7,7 @@
#include "../jsmn/jsmn_h.h"
#include "../ota/ota.h"
#include "../hal/hal_wifi.h"
#include "../hal/hal_flashVars.h"
#ifdef BK_LITTLEFS
#include "../littlefs/our_lfs.h"
#endif
@ -16,11 +17,8 @@
#elif PLATFORM_BL602
#else
#include "../flash_config/flash_config.h"
#endif
#include "../new_cfg.h"
#include "../flash_config/flash_vars_vars.h"
#include "../flash_config/flash_vars.h"
#include "../new_cfg.h"
// Commands register, execution API and cmd tokenizer
#include "../cmnds/cmd_public.h"
@ -955,10 +953,10 @@ static int http_rest_get_flash_vars_test(http_request_t *request){
p = &data;
} else {
for (i = 0; i < increment; i++){
increment_boot_count();
HAL_FlashVars_IncreaseBootCount();
}
for (i = 0; i < len; i++){
boot_complete();
HAL_FlashVars_SaveBootComplete();
}
}