/* * Copyright (c) CompanyNameMagicTag 2018-2019. All rights reserved. * Description: SOC_NV_UPG. * Author: CompanyName * Create: 2018-10-31 */ #ifndef SOC_UPG_NV_H #define SOC_UPG_NV_H /* * @ingroup upg * Upgrade report parameters configure the NV item ID. */ #define EXT_UPG_REPORT_INFO_NV_ID 0x73 /* * @ingroup upg * Upgrade parameters configure the NV item ID. */ #define EXT_UPG_CFG_NV_ID 0x74 /* * @ingroup upg * Delay waiting configuration: \n * @li The default value for the 3.2M band is: {{1,0}, 2,10,3}. * @li 500K band corresponds to the default value: {{1,0}, 2,10,3}. * @li 150K band corresponds to the default value: {{1,0}, 2,10,3}. */ typedef struct { /* * Upgrade restart or power failure After power-on, * the number of sites is less than the number of sites at the time of initial upgrade, * and whether the delay wait policy is enabled.A value of 0 means that the delay wait policy is not enabled, * and other values indicate that the policy is enabled. */ td_u8 enable : 1; td_u8 pad : 7; td_u8 period; /* < Periodically check whether the station has entered the full timer period, unit: min. */ /* * The number of timer cycles included in one round. * The number of sites did not change during the waiting period. * Then no longer wait for the delay. When set to 0, the default value of 10 is taken. */ td_u8 timer_cnt; /* * delay waiting for the maximum number of rounds. * After reaching the maximum number of rounds, no longer wait. */ td_u8 loop_cnt; } ext_upg_delay_wait_cfg; /* * @ingroup upg * Query site information configuration: \n * @li The default value for the 3.2M band is: {60, 2, 5}. * @li 500K band corresponds to the default value: {60, 2, 5}. * @li 150K band corresponds to the default value: {60, 2, 16}. */ typedef struct { td_u8 loop_max; /*