mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-05-19 04:44:47 -07:00
Merge remote-tracking branch 'ofw/dev' into mntm-dev
This commit is contained in:
@@ -23,12 +23,6 @@ App(
|
||||
apptype=FlipperAppType.METAPACKAGE,
|
||||
provides=[
|
||||
"cli",
|
||||
"ibutton_start",
|
||||
"onewire_start",
|
||||
"subghz_start",
|
||||
"subghz_load_extended_settings",
|
||||
"infrared_start",
|
||||
"lfrfid_start",
|
||||
"nfc_start",
|
||||
],
|
||||
)
|
||||
|
||||
@@ -9,6 +9,7 @@ App(
|
||||
icon="A_BadUsb_14",
|
||||
order=70,
|
||||
resources="resources",
|
||||
fap_libs=["assets"],
|
||||
fap_icon="icon.png",
|
||||
fap_category="Tools",
|
||||
)
|
||||
|
||||
@@ -6,6 +6,7 @@ App(
|
||||
stack_size=2 * 1024,
|
||||
icon="A_GPIO_14",
|
||||
order=50,
|
||||
fap_libs=["assets"],
|
||||
fap_icon="icon.png",
|
||||
fap_category="GPIO",
|
||||
)
|
||||
|
||||
@@ -7,24 +7,16 @@ App(
|
||||
icon="A_iButton_14",
|
||||
stack_size=2 * 1024,
|
||||
order=60,
|
||||
fap_libs=["assets"],
|
||||
fap_icon="icon.png",
|
||||
fap_category="iButton",
|
||||
)
|
||||
|
||||
App(
|
||||
appid="ibutton_cli",
|
||||
appid="cli_ikey",
|
||||
targets=["f7"],
|
||||
apptype=FlipperAppType.PLUGIN,
|
||||
entry_point="ibutton_cli_plugin_ep",
|
||||
entry_point="cli_ikey_ep",
|
||||
requires=["cli"],
|
||||
sources=["ibutton_cli.c"],
|
||||
)
|
||||
|
||||
App(
|
||||
appid="ibutton_start",
|
||||
apptype=FlipperAppType.STARTUP,
|
||||
targets=["f7"],
|
||||
entry_point="ibutton_on_system_start",
|
||||
sources=["ibutton_cli.c"],
|
||||
order=60,
|
||||
)
|
||||
|
||||
@@ -204,7 +204,7 @@ void ibutton_cli_emulate(PipeSide* pipe, FuriString* args) {
|
||||
|
||||
while(!cli_is_pipe_broken_or_is_etx_next_char(pipe)) {
|
||||
furi_delay_ms(100);
|
||||
}
|
||||
};
|
||||
|
||||
} while(false);
|
||||
|
||||
@@ -216,8 +216,7 @@ void ibutton_cli_emulate(PipeSide* pipe, FuriString* args) {
|
||||
ibutton_protocols_free(protocols);
|
||||
}
|
||||
|
||||
void ibutton_cli(PipeSide* pipe, FuriString* args, void* context) {
|
||||
UNUSED(pipe);
|
||||
static void execute(PipeSide* pipe, FuriString* args, void* context) {
|
||||
UNUSED(context);
|
||||
FuriString* cmd;
|
||||
cmd = furi_string_alloc();
|
||||
@@ -241,15 +240,4 @@ void ibutton_cli(PipeSide* pipe, FuriString* args, void* context) {
|
||||
furi_string_free(cmd);
|
||||
}
|
||||
|
||||
#include <cli/cli_i.h>
|
||||
CLI_PLUGIN_WRAPPER("ibutton", ibutton_cli)
|
||||
|
||||
void ibutton_on_system_start(void) {
|
||||
#ifdef SRV_CLI
|
||||
Cli* cli = furi_record_open(RECORD_CLI);
|
||||
cli_add_command(cli, "ikey", CliCommandFlagDefault, ibutton_cli_wrapper, cli);
|
||||
furi_record_close(RECORD_CLI);
|
||||
#else
|
||||
UNUSED(ibutton_cli);
|
||||
#endif
|
||||
}
|
||||
CLI_COMMAND_INTERFACE(ikey, execute, CliCommandFlagDefault, 1024);
|
||||
|
||||
@@ -9,15 +9,16 @@ App(
|
||||
order=40,
|
||||
sources=["*.c", "!infrared_cli.c"],
|
||||
resources="resources",
|
||||
fap_libs=["assets"],
|
||||
fap_icon="icon.png",
|
||||
fap_category="Infrared",
|
||||
)
|
||||
|
||||
App(
|
||||
appid="infrared_cli",
|
||||
appid="cli_ir",
|
||||
targets=["f7"],
|
||||
apptype=FlipperAppType.PLUGIN,
|
||||
entry_point="infrared_cli_start_ir_plugin_ep",
|
||||
entry_point="cli_ir_ep",
|
||||
requires=["cli"],
|
||||
sources=[
|
||||
"infrared_cli.c",
|
||||
@@ -25,12 +26,3 @@ App(
|
||||
"infrared_signal.c",
|
||||
],
|
||||
)
|
||||
|
||||
App(
|
||||
appid="infrared_start",
|
||||
apptype=FlipperAppType.STARTUP,
|
||||
targets=["f7"],
|
||||
entry_point="infrared_on_system_start",
|
||||
sources=["infrared_cli.c"],
|
||||
order=20,
|
||||
)
|
||||
|
||||
@@ -526,7 +526,7 @@ static void infrared_cli_process_universal(PipeSide* pipe, FuriString* args) {
|
||||
furi_string_free(arg2);
|
||||
}
|
||||
|
||||
static void infrared_cli_start_ir(PipeSide* pipe, FuriString* args, void* context) {
|
||||
static void execute(PipeSide* pipe, FuriString* args, void* context) {
|
||||
UNUSED(context);
|
||||
if(furi_hal_infrared_is_busy()) {
|
||||
printf("INFRARED is busy. Exiting.");
|
||||
@@ -554,15 +554,4 @@ static void infrared_cli_start_ir(PipeSide* pipe, FuriString* args, void* contex
|
||||
furi_string_free(command);
|
||||
}
|
||||
|
||||
#include <cli/cli_i.h>
|
||||
CLI_PLUGIN_WRAPPER("infrared", infrared_cli_start_ir)
|
||||
|
||||
void infrared_on_system_start(void) {
|
||||
#ifdef SRV_CLI
|
||||
Cli* cli = (Cli*)furi_record_open(RECORD_CLI);
|
||||
cli_add_command(cli, "ir", CliCommandFlagDefault, infrared_cli_start_ir_wrapper, NULL);
|
||||
furi_record_close(RECORD_CLI);
|
||||
#else
|
||||
UNUSED(infrared_cli_start_ir);
|
||||
#endif
|
||||
}
|
||||
CLI_COMMAND_INTERFACE(ir, execute, CliCommandFlagDefault, 2048);
|
||||
|
||||
@@ -7,24 +7,16 @@ App(
|
||||
icon="A_125khz_14",
|
||||
stack_size=2 * 1024,
|
||||
order=20,
|
||||
fap_libs=["assets"],
|
||||
fap_icon="icon.png",
|
||||
fap_category="RFID",
|
||||
)
|
||||
|
||||
App(
|
||||
appid="lfrfid_cli",
|
||||
appid="cli_rfid",
|
||||
targets=["f7"],
|
||||
apptype=FlipperAppType.PLUGIN,
|
||||
entry_point="lfrfid_cli_plugin_ep",
|
||||
entry_point="cli_rfid_ep",
|
||||
requires=["cli"],
|
||||
sources=["lfrfid_cli.c"],
|
||||
)
|
||||
|
||||
App(
|
||||
appid="lfrfid_start",
|
||||
targets=["f7"],
|
||||
apptype=FlipperAppType.STARTUP,
|
||||
entry_point="lfrfid_on_system_start",
|
||||
sources=["lfrfid_cli.c"],
|
||||
order=50,
|
||||
)
|
||||
|
||||
@@ -536,7 +536,7 @@ static void lfrfid_cli_raw_emulate(PipeSide* pipe, FuriString* args) {
|
||||
furi_string_free(filepath);
|
||||
}
|
||||
|
||||
static void lfrfid_cli(PipeSide* pipe, FuriString* args, void* context) {
|
||||
static void execute(PipeSide* pipe, FuriString* args, void* context) {
|
||||
UNUSED(context);
|
||||
FuriString* cmd;
|
||||
cmd = furi_string_alloc();
|
||||
@@ -566,11 +566,4 @@ static void lfrfid_cli(PipeSide* pipe, FuriString* args, void* context) {
|
||||
furi_string_free(cmd);
|
||||
}
|
||||
|
||||
#include <cli/cli_i.h>
|
||||
CLI_PLUGIN_WRAPPER("lfrfid", lfrfid_cli)
|
||||
|
||||
void lfrfid_on_system_start(void) {
|
||||
Cli* cli = furi_record_open(RECORD_CLI);
|
||||
cli_add_command(cli, "rfid", CliCommandFlagDefault, lfrfid_cli_wrapper, NULL);
|
||||
furi_record_close(RECORD_CLI);
|
||||
}
|
||||
CLI_COMMAND_INTERFACE(rfid, execute, CliCommandFlagDefault, 2048);
|
||||
|
||||
@@ -350,19 +350,10 @@ App(
|
||||
)
|
||||
|
||||
App(
|
||||
appid="nfc_cli",
|
||||
appid="cli_nfc",
|
||||
targets=["f7"],
|
||||
apptype=FlipperAppType.PLUGIN,
|
||||
entry_point="nfc_cli_plugin_ep",
|
||||
entry_point="cli_nfc_ep",
|
||||
requires=["cli"],
|
||||
sources=["nfc_cli.c"],
|
||||
)
|
||||
|
||||
App(
|
||||
appid="nfc_start",
|
||||
targets=["f7"],
|
||||
apptype=FlipperAppType.STARTUP,
|
||||
entry_point="nfc_on_system_start",
|
||||
sources=["nfc_cli.c"],
|
||||
order=30,
|
||||
)
|
||||
|
||||
@@ -42,7 +42,7 @@ static void nfc_cli_field(PipeSide* pipe, FuriString* args) {
|
||||
furi_hal_nfc_release();
|
||||
}
|
||||
|
||||
static void nfc_cli(PipeSide* pipe, FuriString* args, void* context) {
|
||||
static void execute(PipeSide* pipe, FuriString* args, void* context) {
|
||||
UNUSED(context);
|
||||
FuriString* cmd;
|
||||
cmd = furi_string_alloc();
|
||||
@@ -65,15 +65,4 @@ static void nfc_cli(PipeSide* pipe, FuriString* args, void* context) {
|
||||
furi_string_free(cmd);
|
||||
}
|
||||
|
||||
#include <cli/cli_i.h>
|
||||
CLI_PLUGIN_WRAPPER("nfc", nfc_cli)
|
||||
|
||||
void nfc_on_system_start(void) {
|
||||
#ifdef SRV_CLI
|
||||
Cli* cli = furi_record_open(RECORD_CLI);
|
||||
cli_add_command(cli, "nfc", CliCommandFlagDefault, nfc_cli_wrapper, NULL);
|
||||
furi_record_close(RECORD_CLI);
|
||||
#else
|
||||
UNUSED(nfc_cli);
|
||||
#endif
|
||||
}
|
||||
CLI_COMMAND_INTERFACE(nfc, execute, CliCommandFlagDefault, 1024);
|
||||
|
||||
@@ -1,16 +1,8 @@
|
||||
App(
|
||||
appid="onewire_cli",
|
||||
appid="cli_onewire",
|
||||
targets=["f7"],
|
||||
apptype=FlipperAppType.PLUGIN,
|
||||
entry_point="onewire_cli_plugin_ep",
|
||||
entry_point="cli_onewire_ep",
|
||||
requires=["cli"],
|
||||
sources=["onewire_cli.c"],
|
||||
)
|
||||
|
||||
App(
|
||||
appid="onewire_start",
|
||||
apptype=FlipperAppType.STARTUP,
|
||||
entry_point="onewire_on_system_start",
|
||||
sources=["onewire_cli.c"],
|
||||
order=60,
|
||||
)
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#include <furi.h>
|
||||
#include <furi_hal.h>
|
||||
|
||||
#include <cli/cli_commands.h>
|
||||
#include <power/power_service/power.h>
|
||||
#include <cli/cli_commands.h>
|
||||
#include <toolbox/args.h>
|
||||
@@ -45,7 +46,7 @@ static void onewire_cli_search(PipeSide* pipe) {
|
||||
furi_record_close(RECORD_POWER);
|
||||
}
|
||||
|
||||
static void onewire_cli(PipeSide* pipe, FuriString* args, void* context) {
|
||||
static void execute(PipeSide* pipe, FuriString* args, void* context) {
|
||||
UNUSED(context);
|
||||
FuriString* cmd;
|
||||
cmd = furi_string_alloc();
|
||||
@@ -63,15 +64,4 @@ static void onewire_cli(PipeSide* pipe, FuriString* args, void* context) {
|
||||
furi_string_free(cmd);
|
||||
}
|
||||
|
||||
#include <cli/cli_i.h>
|
||||
CLI_PLUGIN_WRAPPER("onewire", onewire_cli)
|
||||
|
||||
void onewire_on_system_start(void) {
|
||||
#ifdef SRV_CLI
|
||||
Cli* cli = furi_record_open(RECORD_CLI);
|
||||
cli_add_command(cli, "onewire", CliCommandFlagDefault, onewire_cli_wrapper, cli);
|
||||
furi_record_close(RECORD_CLI);
|
||||
#else
|
||||
UNUSED(onewire_cli);
|
||||
#endif
|
||||
}
|
||||
CLI_COMMAND_INTERFACE(onewire, execute, CliCommandFlagDefault, 1024);
|
||||
|
||||
@@ -18,7 +18,7 @@ App(
|
||||
# ],
|
||||
requires=["region"],
|
||||
resources="resources",
|
||||
fap_libs=["hwdrivers"],
|
||||
fap_libs=["assets", "hwdrivers"],
|
||||
fap_icon="icon.png",
|
||||
fap_category="Sub-GHz",
|
||||
sdk_headers=["subghz_fap.h"],
|
||||
@@ -45,24 +45,14 @@ App(
|
||||
)
|
||||
|
||||
App(
|
||||
appid="subghz_cli",
|
||||
appid="cli_subghz",
|
||||
targets=["f7"],
|
||||
apptype=FlipperAppType.PLUGIN,
|
||||
entry_point="subghz_cli_command_plugin_ep",
|
||||
entry_point="cli_subghz_ep",
|
||||
requires=["cli"],
|
||||
sources=["subghz_cli.c", "helpers/subghz_chat.c"],
|
||||
)
|
||||
|
||||
|
||||
App(
|
||||
appid="subghz_start",
|
||||
targets=["f7"],
|
||||
apptype=FlipperAppType.STARTUP,
|
||||
entry_point="subghz_on_system_start",
|
||||
# sources=["subghz_cli.c"],
|
||||
order=40,
|
||||
)
|
||||
|
||||
App(
|
||||
appid="subghz_load_extended_settings",
|
||||
targets=["f7"],
|
||||
|
||||
@@ -1115,7 +1115,7 @@ static void subghz_cli_command_chat(PipeSide* pipe, FuriString* args) {
|
||||
printf("\r\nExit chat\r\n");
|
||||
}
|
||||
|
||||
static void subghz_cli_command(PipeSide* pipe, FuriString* args, void* context) {
|
||||
static void execute(PipeSide* pipe, FuriString* args, void* context) {
|
||||
FuriString* cmd = furi_string_alloc();
|
||||
|
||||
do {
|
||||
@@ -1182,24 +1182,4 @@ static void subghz_cli_command(PipeSide* pipe, FuriString* args, void* context)
|
||||
furi_string_free(cmd);
|
||||
}
|
||||
|
||||
#include <cli/cli_i.h>
|
||||
CLI_PLUGIN_WRAPPER("subghz", subghz_cli_command)
|
||||
|
||||
static void subghz_cli_command_chat_wrapper(PipeSide* pipe, FuriString* args, void* context) {
|
||||
furi_string_replace_at(args, 0, 0, "chat ");
|
||||
subghz_cli_command_wrapper(pipe, args, context);
|
||||
}
|
||||
|
||||
void subghz_on_system_start(void) {
|
||||
#ifdef SRV_CLI
|
||||
Cli* cli = furi_record_open(RECORD_CLI);
|
||||
|
||||
cli_add_command(cli, "subghz", CliCommandFlagDefault, subghz_cli_command_wrapper, NULL);
|
||||
cli_add_command(cli, "chat", CliCommandFlagDefault, subghz_cli_command_chat_wrapper, NULL);
|
||||
|
||||
furi_record_close(RECORD_CLI);
|
||||
#else
|
||||
UNUSED(subghz_cli_command);
|
||||
UNUSED(subghz_cli_command_chat_wrapper);
|
||||
#endif
|
||||
}
|
||||
CLI_COMMAND_INTERFACE(subghz, execute, CliCommandFlagDefault, 2048);
|
||||
|
||||
@@ -7,7 +7,7 @@ App(
|
||||
icon="A_U2F_14",
|
||||
order=80,
|
||||
resources="resources",
|
||||
fap_libs=["mbedtls"],
|
||||
fap_libs=["assets", "mbedtls"],
|
||||
fap_category="USB",
|
||||
fap_icon="icon.png",
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user