[FL-2589] RPC App control commands (#1350)

* RPC App control commands
* Button release timeout
* SubGhz tx fix

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
This commit is contained in:
Nikolay Minaylov
2022-07-04 16:09:46 +03:00
committed by GitHub
parent 0e78f38404
commit 4a1695ba1c
32 changed files with 768 additions and 45 deletions

View File

@@ -29,10 +29,18 @@
#include <nfc/scenes/nfc_scene.h>
#include <nfc/helpers/nfc_custom_event.h>
#include "rpc/rpc_app.h"
#define NFC_SEND_NOTIFICATION_FALSE (0UL)
#define NFC_SEND_NOTIFICATION_TRUE (1UL)
#define NFC_TEXT_STORE_SIZE 128
typedef enum {
NfcRpcStateIdle,
NfcRpcStateEmulating,
NfcRpcStateEmulated,
} NfcRpcState;
// Forward declaration due to circular dependency
typedef struct NfcGenerator NfcGenerator;
@@ -48,6 +56,9 @@ struct Nfc {
char text_store[NFC_TEXT_STORE_SIZE + 1];
string_t text_box_store;
void* rpc_ctx;
NfcRpcState rpc_state;
// Common Views
Submenu* submenu;
DialogEx* dialog_ex;
@@ -85,3 +96,5 @@ void nfc_text_store_clear(Nfc* nfc);
void nfc_blink_start(Nfc* nfc);
void nfc_blink_stop(Nfc* nfc);
void nfc_rpc_exit_callback(Nfc* nfc);