Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to LVGL 9.2.0 #197

Merged
merged 21 commits into from
Sep 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions lib/gps/gps.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@ void initGPS()
// gps->println("$PCAS04,5*1C\r\n");


// WARM START¿?
gps->println("$PCAS10,0*1C\r\n");
gps->flush();
delay(100);
// // WARM START¿?
// gps->println("$PCAS10,0*1C\r\n");
// gps->flush();
// delay(100);

// GPS+BDS+GLONASS
gps->println("$PCAS04,7*1E\r\n");
Expand Down
2 changes: 1 addition & 1 deletion lib/gui/src/buttonBar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ void createButtonBarScr()

menuBtn = lv_img_create(mainScreen);
lv_img_set_src(menuBtn, menuIconFile);
lv_obj_add_flag(menuBtn, LV_OBJ_FLAG_FLOATING | LV_OBJ_FLAG_CLICKABLE);
lv_obj_add_flag(menuBtn, (lv_obj_flag_t)(LV_OBJ_FLAG_FLOATING | LV_OBJ_FLAG_CLICKABLE));
lv_img_set_zoom(menuBtn,buttonScale);
lv_obj_update_layout(menuBtn);
lv_obj_add_event_cb(menuBtn, hideShowEvent, LV_EVENT_ALL, buttonBar);
Expand Down
18 changes: 9 additions & 9 deletions lib/gui/src/buttonBar.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
#include "globalGuiDef.h"
#include "mainScr.hpp"

static const char *waypointIconFile PROGMEM = "F:/wpt.bin"; // Waypoint icon
static const char *trackIconFile PROGMEM = "F:/track.bin"; // Track icon
static const char *settingsIconFile PROGMEM = "F:/settings.bin"; // Settings icon
static const char *saveIconFile PROGMEM = "F:/save.bin"; // Save icon
static const char *loadIconFile PROGMEM = "F:/load.bin"; // Load icon
static const char *editIconFile PROGMEM = "F:/edit.bin"; // Edit icon
static const char *deleteIconFile PROGMEM = "F:/delete.bin"; // Delete icon
static const char *menuIconFile PROGMEM = "F/menu.bin"; // Menu icon
static const char *addWptIconFile PROGMEM = "F:/addwpt.bin"; // Add Waypoint icon
static const char *waypointIconFile PROGMEM = "/wpt.bin"; // Waypoint icon
static const char *trackIconFile PROGMEM = "/track.bin"; // Track icon
static const char *settingsIconFile PROGMEM = "/settings.bin"; // Settings icon
static const char *saveIconFile PROGMEM = "/save.bin"; // Save icon
static const char *loadIconFile PROGMEM = "/load.bin"; // Load icon
static const char *editIconFile PROGMEM = "/edit.bin"; // Edit icon
static const char *deleteIconFile PROGMEM = "/delete.bin"; // Delete icon
static const char *menuIconFile PROGMEM = "/menu.bin"; // Menu icon
static const char *addWptIconFile PROGMEM = "/addwpt.bin"; // Add Waypoint icon

static lv_obj_t *option;

Expand Down
4 changes: 2 additions & 2 deletions lib/gui/src/mainScr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -584,8 +584,8 @@ void createMainScr()
// Main Screen Tiles
tilesScreen = lv_tileview_create(mainScreen);
compassTile = lv_tileview_add_tile(tilesScreen, 0, 0, LV_DIR_RIGHT);
mapTile = lv_tileview_add_tile(tilesScreen, 1, 0, LV_DIR_LEFT | LV_DIR_RIGHT);
navTile = lv_tileview_add_tile(tilesScreen, 2, 0, LV_DIR_LEFT | LV_DIR_RIGHT);
mapTile = lv_tileview_add_tile(tilesScreen, 1, 0, (lv_dir_t)(LV_DIR_LEFT | LV_DIR_RIGHT));
navTile = lv_tileview_add_tile(tilesScreen, 2, 0, (lv_dir_t)(LV_DIR_LEFT | LV_DIR_RIGHT));
lv_obj_add_flag(navTile,LV_OBJ_FLAG_HIDDEN);
satTrackTile = lv_tileview_add_tile(tilesScreen, 3, 0, LV_DIR_LEFT);
lv_obj_set_size(tilesScreen, TFT_WIDTH, TFT_HEIGHT - 25);
Expand Down
8 changes: 4 additions & 4 deletions lib/gui/src/mainScr.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ extern bool isMainScreen; // Flag to indicate main scre
extern bool isReady; // Flag to indicate when tileview scroll was finished
static TFT_eSprite zoomSprite = TFT_eSprite(&tft); // Zoom sprite

static const char *arrowIconFile PROGMEM = "F:/arrow.bin"; // Compass Arrow Icon
static const char *positionIconFile PROGMEM = "F:/pin.bin"; // Position Icon
static const char *altitudeIconFile PROGMEM = "F:/altit.bin"; // Altitude Icon
static const char *speedIconFile PROGMEM = "F:/speed.bin"; // Speed Icon
static const char *arrowIconFile PROGMEM = "/arrow.bin"; // Compass Arrow Icon
static const char *positionIconFile PROGMEM = "/pin.bin"; // Position Icon
static const char *altitudeIconFile PROGMEM = "/altit.bin"; // Altitude Icon
static const char *speedIconFile PROGMEM = "/speed.bin"; // Speed Icon

extern uint8_t activeTile; // Active Tile in TileView control
enum tileName
Expand Down
7 changes: 4 additions & 3 deletions lib/gui/src/satInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,8 @@ void createSNRSprite(TFT_eSprite &spr)
void drawSNRBar(lv_obj_t *bar, lv_chart_series_t *barSer, uint8_t id, uint8_t satNum, uint8_t snr, TFT_eSprite &spr)
{
lv_point_t p;
barSer->y_points[id] = snr;
lv_chart_get_y_array(bar, barSer);
lv_chart_set_value_by_id(bar, barSer, id, snr);
lv_chart_get_point_pos_by_id(bar, barSer, id, &p);
spr.setCursor(p.x - 2, 0);
spr.print(satNum);
Expand Down Expand Up @@ -178,8 +179,8 @@ void fillSatInView(GSV &gsv, int color)

for (int i = 0; i < (MAX_SATELLLITES_IN_VIEW / 2); i++)
{
satelliteBarSerie1->y_points[i] = LV_CHART_POINT_NONE;
satelliteBarSerie2->y_points[i] = LV_CHART_POINT_NONE;
lv_chart_set_value_by_id(satelliteBar1, satelliteBarSerie1, i, LV_CHART_POINT_NONE);
lv_chart_set_value_by_id(satelliteBar2, satelliteBarSerie1, i, LV_CHART_POINT_NONE);
}

uint8_t activeSat = 0;
Expand Down
6 changes: 3 additions & 3 deletions lib/gui/src/searchSatScr.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
extern lv_obj_t *searchSatScreen; // Search Satellite Screen
static lv_timer_t *searchTimer;
static const char* textSearch PROGMEM = "Searching for satellites";
static const char* satIconFile PROGMEM = "F:/sat.bin";
static const char *skipIconFile PROGMEM = "F:/skip.bin"; // Skip icon
static const char *confIconFile PROGMEM = "F:/settings.bin"; // Settings icon
static const char* satIconFile PROGMEM = "/sat.bin";
static const char *skipIconFile PROGMEM = "/skip.bin"; // Skip icon
static const char *confIconFile PROGMEM = "/settings.bin"; // Settings icon

void loadMainScreen();
void searchGPS(lv_timer_t *searchTimer);
Expand Down
Loading
Loading