mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-05-19 04:44:47 -07:00
Update unitemp
This commit is contained in:
@@ -17,7 +17,6 @@
|
|||||||
*/
|
*/
|
||||||
#include "Sensors.h"
|
#include "Sensors.h"
|
||||||
#include <furi_hal_power.h>
|
#include <furi_hal_power.h>
|
||||||
#include <m-string.h>
|
|
||||||
|
|
||||||
//Порты ввода/вывода, которые не были обозначены в общем списке
|
//Порты ввода/вывода, которые не были обозначены в общем списке
|
||||||
const GpioPin SWC_10 = {.pin = LL_GPIO_PIN_14, .port = GPIOA};
|
const GpioPin SWC_10 = {.pin = LL_GPIO_PIN_14, .port = GPIOA};
|
||||||
@@ -344,7 +343,7 @@ bool unitemp_sensors_load(void) {
|
|||||||
//Сколько байт до конца строки
|
//Сколько байт до конца строки
|
||||||
size_t line_end = 0;
|
size_t line_end = 0;
|
||||||
|
|
||||||
while(line_end != STRING_FAILURE && line_end != (size_t)(file_size - 1)) {
|
while(line_end != ((size_t)-1) && line_end != (size_t)(file_size - 1)) {
|
||||||
//Имя датчика
|
//Имя датчика
|
||||||
char name[11] = {0};
|
char name[11] = {0};
|
||||||
//Тип датчика
|
//Тип датчика
|
||||||
|
|||||||
@@ -21,7 +21,6 @@
|
|||||||
#include "./views/UnitempViews.h"
|
#include "./views/UnitempViews.h"
|
||||||
|
|
||||||
#include <furi_hal_power.h>
|
#include <furi_hal_power.h>
|
||||||
#include <m-string.h>
|
|
||||||
|
|
||||||
/* Переменные */
|
/* Переменные */
|
||||||
//Данные приложения
|
//Данные приложения
|
||||||
@@ -147,7 +146,7 @@ bool unitemp_loadSettings(void) {
|
|||||||
//Сколько байт до конца строки
|
//Сколько байт до конца строки
|
||||||
size_t line_end = 0;
|
size_t line_end = 0;
|
||||||
|
|
||||||
while(line_end != STRING_FAILURE && line_end != (size_t)(file_size - 1)) {
|
while(line_end != ((size_t)-1) && line_end != (size_t)(file_size - 1)) {
|
||||||
char buff[20] = {0};
|
char buff[20] = {0};
|
||||||
sscanf(((char*)(file_buf + line_end)), "%s", buff);
|
sscanf(((char*)(file_buf + line_end)), "%s", buff);
|
||||||
|
|
||||||
|
|||||||
@@ -18,7 +18,9 @@
|
|||||||
#include "UnitempViews.h"
|
#include "UnitempViews.h"
|
||||||
#include "unitemp_icons.h"
|
#include "unitemp_icons.h"
|
||||||
|
|
||||||
#include <assets_icons.h>
|
extern const Icon I_ButtonRight_4x7;
|
||||||
|
extern const Icon I_ButtonLeft_4x7;
|
||||||
|
extern const Icon I_Ok_btn_9x9;
|
||||||
|
|
||||||
static View* view;
|
static View* view;
|
||||||
|
|
||||||
|
|||||||
@@ -18,7 +18,6 @@
|
|||||||
#include "UnitempViews.h"
|
#include "UnitempViews.h"
|
||||||
#include <gui/modules/variable_item_list.h>
|
#include <gui/modules/variable_item_list.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <assets_icons.h>
|
|
||||||
|
|
||||||
uint32_t _prev_view_id;
|
uint32_t _prev_view_id;
|
||||||
|
|
||||||
|
|||||||
@@ -18,7 +18,8 @@
|
|||||||
#include "UnitempViews.h"
|
#include "UnitempViews.h"
|
||||||
#include <gui/modules/variable_item_list.h>
|
#include <gui/modules/variable_item_list.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <assets_icons.h>
|
|
||||||
|
extern const Icon I_Cry_dolph_55x52;
|
||||||
|
|
||||||
//Текущий вид
|
//Текущий вид
|
||||||
static View* view;
|
static View* view;
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
#include "UnitempViews.h"
|
#include "UnitempViews.h"
|
||||||
#include "unitemp_icons.h"
|
#include "unitemp_icons.h"
|
||||||
|
|
||||||
#include <assets_icons.h>
|
extern const Icon I_DolphinCommon_56x48;
|
||||||
|
|
||||||
void unitemp_widgets_alloc(void) {
|
void unitemp_widgets_alloc(void) {
|
||||||
app->widget = widget_alloc();
|
app->widget = widget_alloc();
|
||||||
|
|||||||
Reference in New Issue
Block a user