Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/ClusterM/flipperzero-firmware.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSkorpionm <85568270+Skorpionm@users.noreply.github.com>2021-11-11 15:49:19 +0300
committerGitHub <noreply@github.com>2021-11-11 15:49:19 +0300
commitac8b1457f27412ddd0aac065a7babc7818d5bb78 (patch)
tree96fbd8da8b0aed4690257b57c3c462afa0a3a619 /applications/subghz/subghz_i.h
parent5209701add1fd6b9aaea387beb5b99fcb3b8afe5 (diff)
[FL-1931, FL-2005] SubGhz: migration in flipper file format (#807)
* SubGhz: add save key in flipper file format * [FL-2005] SubGhz: fix stored signals cannot be deleted * SubGhz: add load key in flipper file format * SubGhz: fix syntax * SubGhz: fix bad file upload * Storage: add function to get the next free filename * SubGhz: add save RAW in flipper file format * SubGhz: add load RAW in flipper file format * SubGhz: refactoring protocol * SubGhz: refactoring scene * SubGhz: fix SubGhzNotificationState define * Makefile: proper comapre for FORCE Co-authored-by: あく <alleteam@gmail.com>
Diffstat (limited to 'applications/subghz/subghz_i.h')
-rw-r--r--applications/subghz/subghz_i.h20
1 files changed, 14 insertions, 6 deletions
diff --git a/applications/subghz/subghz_i.h b/applications/subghz/subghz_i.h
index 70a39f23..ef27721d 100644
--- a/applications/subghz/subghz_i.h
+++ b/applications/subghz/subghz_i.h
@@ -13,6 +13,7 @@
#include <furi.h>
#include <furi-hal.h>
#include <gui/gui.h>
+#include <dialogs/dialogs.h>
#include <gui/scene_manager.h>
#include <notification/notification-messages.h>
#include <gui/view_dispatcher.h>
@@ -33,11 +34,6 @@
#define SUBGHZ_TEXT_STORE_SIZE 40
-#define NOTIFICATION_STARTING_STATE 0u
-#define NOTIFICATION_IDLE_STATE 1u
-#define NOTIFICATION_TX_STATE 2u
-#define NOTIFICATION_RX_STATE 3u
-
extern const char* const subghz_frequencies_text[];
extern const uint32_t subghz_frequencies[];
extern const uint32_t subghz_hopper_frequencies[];
@@ -45,6 +41,14 @@ extern const uint32_t subghz_frequencies_count;
extern const uint32_t subghz_hopper_frequencies_count;
extern const uint32_t subghz_frequencies_433_92;
+/** SubGhzNotification state */
+typedef enum {
+ SubGhzNotificationStateStarting,
+ SubGhzNotificationStateIDLE,
+ SubGhzNotificationStateTX,
+ SubGhzNotificationStateRX,
+} SubGhzNotificationState;
+
/** SubGhzTxRx state */
typedef enum {
SubGhzTxRxStateIDLE,
@@ -101,9 +105,10 @@ struct SubGhz {
Popup* popup;
TextInput* text_input;
Widget* widget;
+ DialogsApp* dialogs;
char file_name[SUBGHZ_TEXT_STORE_SIZE + 1];
char file_name_tmp[SUBGHZ_TEXT_STORE_SIZE + 1];
- uint8_t state_notifications;
+ SubGhzNotificationState state_notifications;
SubghzReceiver* subghz_receiver;
SubghzTransmitter* subghz_transmitter;
@@ -133,6 +138,9 @@ typedef enum {
SubGhzViewTestPacket,
} SubGhzView;
+bool subghz_set_pteset(SubGhz* subghz, const char* preset);
+bool subghz_get_preset_name(SubGhz* subghz, string_t preset);
+void subghz_get_frequency_modulation(SubGhz* subghz, string_t frequency, string_t modulation);
void subghz_begin(SubGhz* subghz, FuriHalSubGhzPreset preset);
uint32_t subghz_rx(SubGhz* subghz, uint32_t frequency);
void subghz_rx_end(SubGhz* subghz);