TB2026-YDS Firmware
Loading...
Searching...
No Matches
app.c File Reference
#include "app.h"
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "esp_err.h"
#include "settings.h"
#include "spi_bus.h"
#include "i2c_bus.h"
#include "gpio_expander.h"
#include "display_oled.h"
#include "input.h"
#include "power.h"
#include "fuel_gauge.h"
#include "maintenance.h"
#include "autonomy.h"
#include "storage.h"
#include "playlist.h"
#include "audio_dac.h"
#include "sink_i2s_dac.h"
#include "volume.h"
#include "pipeline.h"
#include "player.h"
#include "navigator.h"
#include "status_bar.h"
#include "root_menu.h"
#include "screen_settings.h"
#include "gfx.h"
#include "esp_log.h"
#include "esp_pm.h"
#include "esp_task_wdt.h"
#include "diag.h"
#include <stdio.h>
#include <string.h>

Macros

#define UI_TASK_STACK   8192
#define UI_TASK_PRIO   5
#define UI_TASK_CORE   1
#define LOCK_SHIFT_MS   30000
#define TEST_POLL_MS   1000

Functions

void app_init (void)
 Bring up the whole board: self-hold power, NVS, drivers and services.
void app_run (void)
 Start the UI on its own task and return.

Detailed Description

Note
Développé avec l'assistance de Claude Opus 4.8 (Anthropic), sous la direction de Y. Dos Santos : spécification, revue et validation sur cible par l'auteur.

Macro Definition Documentation

◆ LOCK_SHIFT_MS

#define LOCK_SHIFT_MS   30000

◆ TEST_POLL_MS

#define TEST_POLL_MS   1000

◆ UI_TASK_CORE

#define UI_TASK_CORE   1

◆ UI_TASK_PRIO

#define UI_TASK_PRIO   5

◆ UI_TASK_STACK

#define UI_TASK_STACK   8192

Function Documentation

◆ app_init()

void app_init ( void )

Bring up the whole board: self-hold power, NVS, drivers and services.

Runs the full boot sequence (EnableReg self-hold, PM config, NVS, then the bsp/driver/service init chain) so the system is ready before the UI starts. Called once from app_main().

◆ app_run()

void app_run ( void )

Start the UI on its own task and return.

Spawns the pinned UI task so app_main() can exit (its undersized stack would otherwise overflow running the UI loop). Call once, after app_init().