[FL-1149] Dolphin: stage 3 (#422)
* dolphin scenes refactoring & restructuring phase 1 * Passport app: mood and level display, opens from main menu and dolphin scenes. Dolphin scenes: minor refactoring (WIP) * dolphin scene app restruct * use gui defines for screen size * mv passport to dolphin dir Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
@@ -3,38 +3,6 @@
|
||||
#include <api-hal.h>
|
||||
#include <math.h>
|
||||
|
||||
typedef struct {
|
||||
uint8_t magic;
|
||||
uint8_t version;
|
||||
uint8_t checksum;
|
||||
uint8_t flags;
|
||||
uint32_t timestamp;
|
||||
} DolphinDataHeader;
|
||||
|
||||
#define DOLPHIN_DATA_PAGE 0xC0
|
||||
#define DOLPHIN_DATA_HEADER_ADDRESS 0x080C0000U
|
||||
#define DOLPHIN_DATA_DATA_ADDRESS (DOLPHIN_DATA_HEADER_ADDRESS + sizeof(DolphinDataHeader))
|
||||
|
||||
#define DOLPHIN_DATA_HEADER_MAGIC 0xD0
|
||||
#define DOLPHIN_DATA_HEADER_VERSION 0x01
|
||||
|
||||
#define DOLPHIN_LVL_THRESHOLD 20.0f
|
||||
|
||||
typedef struct {
|
||||
uint32_t limit_ibutton;
|
||||
uint32_t limit_nfc;
|
||||
uint32_t limit_ir;
|
||||
uint32_t limit_rfid;
|
||||
|
||||
uint32_t flags;
|
||||
uint32_t icounter;
|
||||
uint32_t butthurt;
|
||||
} DolphinData;
|
||||
|
||||
struct DolphinState {
|
||||
DolphinData data;
|
||||
};
|
||||
|
||||
DolphinState* dolphin_state_alloc() {
|
||||
DolphinState* dolphin_state = furi_alloc(sizeof(DolphinState));
|
||||
return dolphin_state;
|
||||
|
Reference in New Issue
Block a user