BSB Developer Docs
Loading...
Searching...
No Matches
desktop_i.h
1#pragma once
2
3#include "desktop.h"
4
5#include <furi.h>
6
7#include <input/input.h>
8#include <loader/loader.h>
9
10#include "desktop_overlay.h"
11#include "desktop_start_request.h"
12
13// Time to wait for the rotary switch steady state.
14#define SWITCH_DELAY_MS (100)
15// Maximum and initial counts for synchronisation primitives
16#define INPUT_QUEUE_COUNT (8)
17#define START_QUEUE_COUNT (3)
18#define EXIT_SEMAPH_COUNT (1)
19#define EXIT_SEMAPH_INIT (1)
20
21#define DESKTOP_STARTUP_APP_NAME "Power On"
22
23struct Desktop {
24 FuriEventLoop* event_loop;
25 FuriSemaphore* exit_semaphore;
26 FuriMessageQueue* input_queue;
27 FuriMessageQueue* start_queue;
28 FuriEventLoopTimer* switch_timer;
29 FuriEventLoopTimer* start_timer;
30 FuriString* error_message;
31 Loader* loader;
32 DesktopOverlay* overlay;
33 DesktopStartRequest* current_request;
34 InputSwitchPosition switch_pos;
35 DesktopSwitchDirection switch_direction;
36 bool pin_current_app;
37};
Functions for controlling the currently running application.
DesktopSwitchDirection
Direction of rotary switch movement.
Definition desktop.h:27
Input: main API.
Loader service API.
Definition desktop_i.h:23
Definition desktop_overlay.c:18
Definition desktop_start_request.c:5
Definition loader_i.h:13