enhancement: new "config" module to access configuration in RAM

This is to allow moving some tasks/stack memory to SPIRAM, saving on
precious IRAM. HTTP server should also be more responsive.
This commit is contained in:
Sebastien
2019-11-06 23:31:13 -05:00
parent 86f0d4c7ea
commit cdbb198d8a
38 changed files with 1219 additions and 510 deletions

View File

@@ -27,6 +27,7 @@
#include "esp_partition.h"
#include "esp_ota_ops.h"
#include "platform_esp32.h"
#include "nvs_utilities.h"
#ifdef CONFIG_FREERTOS_USE_STATS_FORMATTING_FUNCTIONS
#define WITH_TASKS_INFO 1
@@ -126,6 +127,9 @@ esp_err_t guided_boot(esp_partition_subtype_t partition_subtype)
}
esp_partition_iterator_release(it);
if(bFound) {
if(!wait_for_commit()){
ESP_LOGW(TAG,"Unable to commit configuration. ");
}
ESP_LOGI(TAG, "Restarting!.");
esp_restart();
}
@@ -136,6 +140,9 @@ esp_err_t guided_boot(esp_partition_subtype_t partition_subtype)
static int restart(int argc, char **argv)
{
if(!wait_for_commit()){
ESP_LOGW(TAG,"Unable to commit configuration. ");
}
ESP_LOGW(TAG, "Restarting");
esp_restart();
return 0;
@@ -143,6 +150,10 @@ static int restart(int argc, char **argv)
void simple_restart()
{
if(!wait_for_commit()){
ESP_LOGW(TAG,"Unable to commit configuration. ");
}
ESP_LOGW(TAG, "Restarting");
esp_restart();
}

View File

@@ -9,3 +9,4 @@
COMPONENT_ADD_INCLUDEDIRS := .
COMPONENT_EXTRA_INCLUDES += $(PROJECT_PATH)/main/
COMPONENT_EXTRA_INCLUDES += $(PROJECT_PATH)/components/tools/