add apploader example
This commit is contained in:
parent
3c453a2a20
commit
566ba378ff
18
applications/app-loader/app-loader.c
Normal file
18
applications/app-loader/app-loader.c
Normal file
@ -0,0 +1,18 @@
|
||||
#include "flipper.h"
|
||||
|
||||
/*
|
||||
render_loader
|
||||
|
||||
handle_input
|
||||
|
||||
handle_menu
|
||||
*/
|
||||
|
||||
void app_loader(void* p) {
|
||||
osThreadId_t self_id = osThreadGetId();
|
||||
assert(self_id);
|
||||
|
||||
printf("[app loader] start\n");
|
||||
|
||||
osThreadSuspend(self_id);
|
||||
}
|
@ -16,6 +16,7 @@ APP_INPUT = 1
|
||||
APP_GUI = 1
|
||||
CFLAGS += -DAPP_MENU
|
||||
C_SOURCES += $(wildcard $(APP_DIR)/menu/*.c)
|
||||
C_SOURCES += $(wildcard $(APP_DIR)/app-loader/*.c)
|
||||
endif
|
||||
|
||||
APP_TEST ?= 0
|
||||
|
@ -27,6 +27,7 @@ void u8g2_qrcode(void* p);
|
||||
void fatfs_list(void* p);
|
||||
void gui_task(void* p);
|
||||
void backlight_control(void* p);
|
||||
void app_loader(void* p);
|
||||
|
||||
const FlipperStartupApp FLIPPER_STARTUP[] = {
|
||||
#ifdef APP_DISPLAY
|
||||
@ -44,6 +45,7 @@ const FlipperStartupApp FLIPPER_STARTUP[] = {
|
||||
|
||||
#ifdef APP_MENU
|
||||
{.app = menu_task, .name = "menu_task", .libs = {1, FURI_LIB{"gui_task"}}},
|
||||
{.app = app_loader, .name = "app_loader", .libs = {1, FURI_LIB{"menu_task"}}},
|
||||
#endif
|
||||
|
||||
// {.app = coreglitch_demo_0, .name = "coreglitch_demo_0", .libs = ""},
|
||||
|
@ -16,6 +16,8 @@ extern "C" {
|
||||
}
|
||||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
// Arduino defines
|
||||
|
||||
#define pinMode app_gpio_init
|
||||
|
@ -1,5 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "flipper.h"
|
||||
|
||||
#include "api-basic/furi.h"
|
||||
//#include "api-basic/flapp.h"
|
||||
#include "cmsis_os2.h"
|
||||
|
Loading…
Reference in New Issue
Block a user