[FL-2627] Flipper applications: SDK, build and debug system (#1387)
* Added support for running applications from SD card (FAPs - Flipper Application Packages) * Added plugin_dist target for fbt to build FAPs * All apps of type FlipperAppType.EXTERNAL and FlipperAppType.PLUGIN are built as FAPs by default * Updated VSCode configuration for new fbt features - re-deploy stock configuration to use them * Added debugging support for FAPs with fbt debug & VSCode * Added public firmware API with automated versioning Co-authored-by: hedger <hedger@users.noreply.github.com> Co-authored-by: SG <who.just.the.doctor@gmail.com> Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
82
applications/services/storage/storages/sd_notify.c
Normal file
82
applications/services/storage/storages/sd_notify.c
Normal file
@@ -0,0 +1,82 @@
|
||||
#include "sd_notify.h"
|
||||
|
||||
static const NotificationSequence sd_sequence_success = {
|
||||
&message_green_255,
|
||||
&message_delay_50,
|
||||
&message_green_0,
|
||||
&message_delay_50,
|
||||
&message_green_255,
|
||||
&message_delay_50,
|
||||
&message_green_0,
|
||||
&message_delay_50,
|
||||
&message_green_255,
|
||||
&message_delay_50,
|
||||
&message_green_0,
|
||||
&message_delay_50,
|
||||
NULL,
|
||||
};
|
||||
|
||||
static const NotificationSequence sd_sequence_error = {
|
||||
&message_red_255,
|
||||
&message_delay_50,
|
||||
&message_red_0,
|
||||
&message_delay_50,
|
||||
&message_red_255,
|
||||
&message_delay_50,
|
||||
&message_red_0,
|
||||
&message_delay_50,
|
||||
&message_red_255,
|
||||
&message_delay_50,
|
||||
&message_red_0,
|
||||
&message_delay_50,
|
||||
NULL,
|
||||
};
|
||||
|
||||
static const NotificationSequence sd_sequence_eject = {
|
||||
&message_blue_255,
|
||||
&message_delay_50,
|
||||
&message_blue_0,
|
||||
&message_delay_50,
|
||||
&message_blue_255,
|
||||
&message_delay_50,
|
||||
&message_blue_0,
|
||||
&message_delay_50,
|
||||
&message_blue_255,
|
||||
&message_delay_50,
|
||||
&message_blue_0,
|
||||
&message_delay_50,
|
||||
NULL,
|
||||
};
|
||||
|
||||
static const NotificationSequence sd_sequence_wait = {
|
||||
&message_red_255,
|
||||
&message_blue_255,
|
||||
&message_do_not_reset,
|
||||
NULL,
|
||||
};
|
||||
|
||||
static const NotificationSequence sd_sequence_wait_off = {
|
||||
&message_red_0,
|
||||
&message_blue_0,
|
||||
NULL,
|
||||
};
|
||||
|
||||
void sd_notify_wait(NotificationApp* notifications) {
|
||||
notification_message(notifications, &sd_sequence_wait);
|
||||
}
|
||||
|
||||
void sd_notify_wait_off(NotificationApp* notifications) {
|
||||
notification_message(notifications, &sd_sequence_wait_off);
|
||||
}
|
||||
|
||||
void sd_notify_success(NotificationApp* notifications) {
|
||||
notification_message(notifications, &sd_sequence_success);
|
||||
}
|
||||
|
||||
void sd_notify_eject(NotificationApp* notifications) {
|
||||
notification_message(notifications, &sd_sequence_eject);
|
||||
}
|
||||
|
||||
void sd_notify_error(NotificationApp* notifications) {
|
||||
notification_message(notifications, &sd_sequence_error);
|
||||
}
|
Reference in New Issue
Block a user