mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2024-11-29 03:43:51 +03:00
d0ed33e710
* GUI: reusable module example
28 lines
527 B
C
28 lines
527 B
C
#pragma once
|
|
|
|
#include <stdint.h>
|
|
#include <stdbool.h>
|
|
#include <furi.h>
|
|
#include <gui/canvas.h>
|
|
#include <gui/view.h>
|
|
|
|
typedef enum { PowerViewInfo, PowerViewDialog } PowerView;
|
|
|
|
typedef struct {
|
|
float current_charger;
|
|
float current_gauge;
|
|
|
|
float voltage_charger;
|
|
float voltage_gauge;
|
|
|
|
uint32_t capacity_remaining;
|
|
uint32_t capacity_full;
|
|
|
|
float temperature_charger;
|
|
float temperature_gauge;
|
|
|
|
uint8_t charge;
|
|
} PowerInfoModel;
|
|
|
|
void power_info_draw_callback(Canvas* canvas, void* context);
|