summaryrefslogtreecommitdiff
path: root/src/system_fsm/running.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/system_fsm/running.cpp')
-rw-r--r--src/system_fsm/running.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/system_fsm/running.cpp b/src/system_fsm/running.cpp
index 3e8b8b76..9116ec9d 100644
--- a/src/system_fsm/running.cpp
+++ b/src/system_fsm/running.cpp
@@ -4,6 +4,7 @@
* SPDX-License-Identifier: GPL-3.0-only
*/
+#include "freertos/projdefs.h"
#include "result.hpp"
#include "audio_fsm.hpp"
@@ -24,6 +25,7 @@ static const char kTag[] = "RUN";
*/
void Running::entry() {
ESP_LOGI(kTag, "mounting sd card");
+ vTaskDelay(pdMS_TO_TICKS(250));
auto storage_res = drivers::SdStorage::Create(sGpioExpander.get());
if (storage_res.has_error()) {
events::Dispatch<StorageError, SystemState, audio::AudioState, ui::UiState>(
@@ -31,6 +33,7 @@ void Running::entry() {
return;
}
sStorage.reset(storage_res.value());
+ vTaskDelay(pdMS_TO_TICKS(250));
ESP_LOGI(kTag, "opening database");
auto database_res = database::Database::Open();