mirror of
https://github.com/espressif/ESP8266_RTOS_SDK.git
synced 2025-05-30 06:59:02 +08:00
feat(esp8266): add system version
Bootloader can get the version of application for specific section, and then check if some features are supported. Developers can use the macro "ESP_IDF_VERSION" to limite some function like following: include "esp_idf_version.h" if ESP_IDF_VERSION >= ESP_IDF_VERSION_VAL(3, 4, 0) && ESP_IDF_VERSION < ESP_IDF_VERSION_VAL(4, 0, 0) // 3.4 <= ver < 4.0 do_xxx_process(); endif
This commit is contained in:
@ -52,6 +52,16 @@ struct _rtc_sys_info {
|
||||
if your bootloader is older than v3.2, please don't use this */
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief System information
|
||||
*/
|
||||
typedef struct esp_sys_info {
|
||||
uint32_t version; //!< system version
|
||||
uint32_t reserved[3]; //!< reserved data
|
||||
} esp_sys_info_t;
|
||||
|
||||
_Static_assert(sizeof(esp_sys_info_t) == 16, "esp_sys_info_t should be 16 bytes");
|
||||
|
||||
extern struct _rtc_sys_info rtc_sys_info;
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user