mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-04-25 03:29:58 -07:00
68 lines
1.7 KiB
C
68 lines
1.7 KiB
C
#pragma once
|
|
|
|
#include <furi.h>
|
|
#include <gui/gui.h>
|
|
#include <gui/view.h>
|
|
#include <gui/modules/validators.h>
|
|
#include <gui/view_dispatcher.h>
|
|
#include <gui/scene_manager.h>
|
|
#include <assets_icons.h>
|
|
#include <gui/modules/submenu.h>
|
|
#include <gui/modules/text_input.h>
|
|
#include <gui/modules/byte_input.h>
|
|
#include <gui/modules/popup.h>
|
|
#include "scenes/nfc_maker_scene.h"
|
|
#include <lib/flipper_format/flipper_format.h>
|
|
#include <toolbox/name_generator.h>
|
|
#include <applications/main/nfc/nfc_i.h>
|
|
#include <furi_hal_bt.h>
|
|
|
|
#define MAC_INPUT_LEN GAP_MAC_ADDR_SIZE
|
|
#define MAIL_INPUT_LEN 128
|
|
#define PHONE_INPUT_LEN 17
|
|
|
|
#define BIG_INPUT_LEN 248
|
|
#define SMALL_INPUT_LEN 90
|
|
|
|
typedef enum {
|
|
WifiAuthenticationOpen = 0x01,
|
|
WifiAuthenticationWpa2Personal = 0x20,
|
|
WifiAuthenticationWpa2Enterprise = 0x10,
|
|
WifiAuthenticationWpaPersonal = 0x02,
|
|
WifiAuthenticationWpaEnterprise = 0x08,
|
|
WifiAuthenticationShared = 0x04,
|
|
} WifiAuthentication;
|
|
|
|
typedef enum {
|
|
WifiEncryptionAes = 0x08,
|
|
WifiEncryptionWep = 0x02,
|
|
WifiEncryptionTkip = 0x04,
|
|
WifiEncryptionNone = 0x01,
|
|
} WifiEncryption;
|
|
|
|
typedef struct {
|
|
Gui* gui;
|
|
SceneManager* scene_manager;
|
|
ViewDispatcher* view_dispatcher;
|
|
Submenu* submenu;
|
|
TextInput* text_input;
|
|
ByteInput* byte_input;
|
|
Popup* popup;
|
|
|
|
uint8_t mac_buf[MAC_INPUT_LEN];
|
|
char mail_buf[MAIL_INPUT_LEN];
|
|
char phone_buf[PHONE_INPUT_LEN];
|
|
|
|
char big_buf[BIG_INPUT_LEN];
|
|
char small_buf1[SMALL_INPUT_LEN];
|
|
char small_buf2[SMALL_INPUT_LEN];
|
|
char save_buf[BIG_INPUT_LEN];
|
|
} NfcMaker;
|
|
|
|
typedef enum {
|
|
NfcMakerViewSubmenu,
|
|
NfcMakerViewTextInput,
|
|
NfcMakerViewByteInput,
|
|
NfcMakerViewPopup,
|
|
} NfcMakerView;
|