Preparation for upcoming new pages

This commit is contained in:
Thomas Hooge 2025-08-05 15:31:41 +02:00
parent cbc0c09d65
commit 0dd6b7c9cf
6 changed files with 601 additions and 235 deletions

199
lib/obp60task/PageAIS.cpp Normal file
View File

@ -0,0 +1,199 @@
// SPDX-License-Identifier: GPL-2.0-or-later
#if defined BOARD_OBP60S3 || defined BOARD_OBP40S3
#include "Pagedata.h"
#include "OBP60Extensions.h"
#include "ConfigMenu.h"
/*
AIS Overview
- circle with certain range, e.g. 5nm
- AIS-Targets in range with speed and heading
- perhaps collision alarm
Data: LAT LON SOG HDT
*/
class PageAIS : public Page
{
private:
GwConfigHandler *config;
GwLog *logger;
bool simulation = false;
bool holdvalues = false;
String flashLED;
String backlightMode;
int scale = 5; // Radius of display circle in nautical miles
bool alarm = false;
bool alarm_enabled = false;
int alarm_range = 3;
char mode = 'N'; // (N)ormal, (C)onfig
int8_t editmode = -1; // marker for menu/edit/set function
ConfigMenu *menu;
void displayModeNormal(PageData &pageData) {
// TBD Boatvalues: ...
LOG_DEBUG(GwLog::DEBUG,"Drawing at PageAIS");
Point c = {200, 150}; // center = current boat position
uint16_t r = 125;
const std::vector<Point> pts_boat = { // polygon lines
{c.x - 5, c.y},
{c.x - 5, c.y - 10},
{c.x, c.y - 16},
{c.x + 5, c.y - 10},
{c.x + 5, c.y}
};
drawPoly(pts_boat, commonData->fgcolor);
// Title and corner value headings
epd->setTextColor(commonData->fgcolor);
epd->setFont(&Ubuntu_Bold12pt8b);
epd->setCursor(8, 48);
epd->print("AIS");
// zoom scale
epd->drawLine(c.x + 10, c.y, c.x + r - 4, c.y, commonData->fgcolor);
// arrow left
epd->drawLine(c.x + 10, c.y, c.x + 16, c.y - 4, commonData->fgcolor);
epd->drawLine(c.x + 10, c.y, c.x + 16, c.y + 4, commonData->fgcolor);
// arrow right
epd->drawLine(c.x + r - 4, c.y, c.x + r - 10, c.y - 4, commonData->fgcolor);
epd->drawLine(c.x + r - 4, c.y, c.x + r - 10, c.y + 4, commonData->fgcolor);
epd->setFont(&Ubuntu_Bold8pt8b);
drawTextCenter(c.x + r / 2, c.y + 8, String(scale) + "nm");
}
void displayModeConfig() {
epd->setTextColor(commonData->fgcolor);
epd->setFont(&Ubuntu_Bold12pt8b);
epd->setCursor(8, 48);
epd->print("AIS configuration");
epd->setFont(&Ubuntu_Bold8pt8b);
// TODO menu
}
public:
PageAIS(CommonData &common)
{
commonData = &common;
config = commonData->config;
logger = commonData->logger;
logger->logDebug(GwLog::LOG,"Instantiate PageAIS");
// preload configuration data
simulation = config->getBool(config->useSimuData);
holdvalues = config->getBool(config->holdvalues);
flashLED = config->getString(config->flashLED);
backlightMode = config->getString(config->backlight);
alarm_range = 30;
// Initialize config menu
/* menu = new ConfigMenu("Options", 40, 80);
menu->setItemDimension(150, 20);
ConfigMenuItem *newitem;
newitem = menu->addItem("range", "Range", "int", 4, "nm");
if (! newitem) {
// Demo: in case of failure exit here, should never be happen
logger->logDebug(GwLog::ERROR,"Menu item creation failed");
return;
}
newitem->setRange(0, 20, {1, 5});
menu->setItemActive("range"); */
}
void setupKeys(){
Page::setupKeys();
commonData->keydata[0].label = "MODE";
commonData->keydata[1].label = "ALARM";
}
#ifdef BOARD_OBP60S3
int handleKey(int key){
if (key == 1) { // Switch between normal and config mode
if (mode == 'N') {
mode = 'C';
} else {
mode = 'N';
}
return 0;
}
if (key == 11) { // Code for keylock
commonData->keylock = !commonData->keylock;
return 0;
}
return key;
}
#endif
#ifdef BOARD_OBP40S3
int handleKey(int key) {
if (key == 1) { // Switch between normal and config mode
if (mode == 'N') {
mode = 'C';
} else {
mode = 'N';
}
return 0;
}
if (key == 11) { // Code for keylock
commonData->keylock = !commonData->keylock;
return 0;
}
return key;
}
#endif
void displayNew(PageData &pageData){
};
int displayPage(PageData &pageData){
// Logging boat values
LOG_DEBUG(GwLog::LOG,"Drawing at PageAIS; Mode=%c", mode);
// Set display in partial refresh mode
epd->setPartialWindow(0, 0, epd->width(), epd->height());
if (mode == 'N') {
displayModeNormal(pageData);
} else if (mode == 'C') {
displayModeConfig();
}
return PAGE_UPDATE;
};
};
static Page *createPage(CommonData &common){
return new PageAIS(common);
}
/**
* with the code below we make this page known to the PageTask
* we give it a type (name) that can be selected in the config
* we define which function is to be called
* and we provide the number of user parameters we expect
* this will be number of BoatValue pointers in pageData.values
*/
PageDescription registerPageAIS(
"AIS", // Page name
createPage, // Action
0, // Number of bus values depends on selection in Web configuration
{"LAT", "LON", "SOG", "HDT"}, // Names of bus values undepends on selection in Web configuration (refer GwBoatData.h)
true // Show display header on/off
);
#endif

View File

@ -0,0 +1,152 @@
// SPDX-License-Identifier: GPL-2.0-or-later
#if defined BOARD_OBP60S3 || defined BOARD_OBP40S3
#include "Pagedata.h"
#include "OBP60Extensions.h"
#include "ConfigMenu.h"
/*
Autopilot
*/
class PageAutopilot : public Page
{
private:
GwConfigHandler *config;
GwLog *logger;
bool simulation = false;
bool holdvalues = false;
String flashLED;
String backlightMode;
char mode = 'N'; // (N)ormal, (C)onfig
int8_t editmode = -1; // marker for menu/edit/set function
ConfigMenu *menu;
void displayModeNormal(PageData &pageData) {
// TBD Boatvalues: ...
LOG_DEBUG(GwLog::DEBUG,"Drawing at PageAutopilot");
// Title and corner value headings
epd->setTextColor(commonData->fgcolor);
epd->setFont(&Ubuntu_Bold12pt8b);
epd->setCursor(8, 48);
epd->print("Autopilot");
}
void displayModeConfig() {
epd->setTextColor(commonData->fgcolor);
epd->setFont(&Ubuntu_Bold12pt8b);
epd->setCursor(8, 48);
epd->print("Autopilot configuration");
epd->setFont(&Ubuntu_Bold8pt8b);
// TODO menu
}
public:
PageAutopilot(CommonData &common)
{
commonData = &common;
config = commonData->config;
logger = commonData->logger;
logger->logDebug(GwLog::LOG,"Instantiate PageAutopilot");
// preload configuration data
simulation = config->getBool(config->useSimuData);
holdvalues = config->getBool(config->holdvalues);
flashLED = config->getString(config->flashLED);
backlightMode = config->getString(config->backlight);
}
void setupKeys(){
Page::setupKeys();
commonData->keydata[0].label = "MODE";
}
#ifdef BOARD_OBP60S3
int handleKey(int key){
if (key == 1) { // Switch between normal and config mode
if (mode == 'N') {
mode = 'C';
} else {
mode = 'N';
}
return 0;
}
if (key == 11) { // Code for keylock
commonData->keylock = !commonData->keylock;
return 0;
}
return key;
}
#endif
#ifdef BOARD_OBP40S3
int handleKey(int key){
if (key == 1) { // Switch between normal and config mode
if (mode == 'N') {
mode = 'C';
commonData->keydata[1].label = "EDIT";
} else {
mode = 'N';
commonData->keydata[1].label = "ALARM";
}
return 0;
}
if (key == 11) { // Code for keylock
commonData->keylock = !commonData->keylock;
return 0;
}
return key;
}
#endif
void displayNew(PageData &pageData){
};
int displayPage(PageData &pageData){
// Logging boat values
LOG_DEBUG(GwLog::LOG,"Drawing at PageAutopilot; Mode=%c", mode);
// Set display in partial refresh mode
epd->setPartialWindow(0, 0, epd->width(), epd->height());
if (mode == 'N') {
displayModeNormal(pageData);
} else if (mode == 'C') {
displayModeConfig();
}
return PAGE_UPDATE;
};
};
static Page *createPage(CommonData &common){
return new PageAutopilot(common);
}
/**
* with the code below we make this page known to the PageTask
* we give it a type (name) that can be selected in the config
* we define which function is to be called
* and we provide the number of user parameters we expect
* this will be number of BoatValue pointers in pageData.values
*/
PageDescription registerPageAutopilot(
"Autopilot", // Page name
createPage, // Action
0, // Number of bus values depends on selection in Web configuration
{}, // Names of bus values undepends on selection in Web configuration (refer GwBoatData.h)
true // Show display header on/off
);
#endif

View File

@ -0,0 +1,147 @@
// SPDX-License-Identifier: GPL-2.0-or-later
#if defined BOARD_OBP60S3 || defined BOARD_OBP40S3
#include "Pagedata.h"
#include "OBP60Extensions.h"
/*
Electric propulsion
*/
class PageEPropulsion : public Page
{
private:
GwConfigHandler *config;
GwLog *logger;
bool simulation = false;
bool holdvalues = false;
String flashLED;
String backlightMode;
char mode = 'N'; // (N)ormal, (C)onfig
void displayModeNormal(PageData &pageData) {
// TBD Boatvalues: ...
LOG_DEBUG(GwLog::DEBUG,"Drawing at PageEPropulsion");
// Title and corner value headings
epd->setTextColor(commonData->fgcolor);
epd->setFont(&Ubuntu_Bold12pt8b);
epd->setCursor(8, 48);
epd->print("Electric propulsion");
}
void displayModeConfig() {
epd->setTextColor(commonData->fgcolor);
epd->setFont(&Ubuntu_Bold12pt8b);
epd->setCursor(8, 48);
epd->print("EPropulsion configuration");
epd->setFont(&Ubuntu_Bold8pt8b);
// TODO menu
}
public:
PageEPropulsion(CommonData &common)
{
commonData = &common;
config = commonData->config;
logger = commonData->logger;
logger->logDebug(GwLog::LOG,"Instantiate PageEPropulsion");
// preload configuration data
simulation = config->getBool(config->useSimuData);
holdvalues = config->getBool(config->holdvalues);
flashLED = config->getString(config->flashLED);
backlightMode = config->getString(config->backlight);
}
void setupKeys(){
Page::setupKeys();
}
#ifdef BOARD_OBP60S3
int handleKey(int key){
if (key == 1) { // Switch between normal and config mode
if (mode == 'N') {
mode = 'C';
} else {
mode = 'N';
}
return 0;
}
if (key == 11) { // Code for keylock
commonData->keylock = !commonData->keylock;
return 0;
}
return key;
}
#endif
#ifdef BOARD_OBP40S3
int handleKey(int key){
if (key == 1) { // Switch between normal and config mode
if (mode == 'N') {
mode = 'C';
commonData->keydata[1].label = "EDIT";
} else {
mode = 'N';
commonData->keydata[1].label = "ALARM";
}
return 0;
}
if (key == 11) { // Code for keylock
commonData->keylock = !commonData->keylock;
return 0;
}
return key;
}
#endif
void displayNew(PageData &pageData){
};
int displayPage(PageData &pageData){
// Logging boat values
LOG_DEBUG(GwLog::LOG,"Drawing at PageEPropulsion; Mode=%c", mode);
// Set display in partial refresh mode
epd->setPartialWindow(0, 0, epd->width(), epd->height());
if (mode == 'N') {
displayModeNormal(pageData);
} else if (mode == 'C') {
displayModeConfig();
}
return PAGE_UPDATE;
};
};
static Page *createPage(CommonData &common){
return new PageEPropulsion(common);
}
/**
* with the code below we make this page known to the PageTask
* we give it a type (name) that can be selected in the config
* we define which function is to be called
* and we provide the number of user parameters we expect
* this will be number of BoatValue pointers in pageData.values
*/
PageDescription registerPageEPropulsion(
"EPropulsion", // Page name
createPage, // Action
0, // Number of bus values depends on selection in Web configuration
{}, // Names of bus values undepends on selection in Web configuration (refer GwBoatData.h)
true // Show display header on/off
);
#endif

View File

@ -749,19 +749,8 @@
"obp60":"true"
},
"condition": [
{ "calInstance1": "AWA" },
{ "calInstance1": "AWS" },
{ "calInstance1": "COG" },
{ "calInstance1": "DBT" },
{ "calInstance1": "HDM" },
{ "calInstance1": "PRPOS" },
{ "calInstance1": "RPOS" },
{ "calInstance1": "SOG" },
{ "calInstance1": "STW" },
{ "calInstance1": "TWA" },
{ "calInstance1": "TWS" },
{ "calInstance1": "TWD" },
{ "calInstance1": "WTemp" } ]
{ "calInstance1": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSlope1",
@ -774,19 +763,8 @@
"obp60":"true"
},
"condition": [
{ "calInstance1": "AWA" },
{ "calInstance1": "AWS" },
{ "calInstance1": "COG" },
{ "calInstance1": "DBT" },
{ "calInstance1": "HDM" },
{ "calInstance1": "PRPOS" },
{ "calInstance1": "RPOS" },
{ "calInstance1": "SOG" },
{ "calInstance1": "STW" },
{ "calInstance1": "TWA" },
{ "calInstance1": "TWS" },
{ "calInstance1": "TWD" },
{ "calInstance1": "WTemp" } ]
{ "calInstance1": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSmooth1",
@ -802,19 +780,8 @@
"obp60":"true"
},
"condition": [
{ "calInstance1": "AWA" },
{ "calInstance1": "AWS" },
{ "calInstance1": "COG" },
{ "calInstance1": "DBT" },
{ "calInstance1": "HDM" },
{ "calInstance1": "PRPOS" },
{ "calInstance1": "RPOS" },
{ "calInstance1": "SOG" },
{ "calInstance1": "STW" },
{ "calInstance1": "TWA" },
{ "calInstance1": "TWS" },
{ "calInstance1": "TWD" },
{ "calInstance1": "WTemp" } ]
{ "calInstance1": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calInstance2",
@ -854,19 +821,8 @@
"obp60":"true"
},
"condition": [
{ "calInstance2": "AWA" },
{ "calInstance2": "AWS" },
{ "calInstance2": "COG" },
{ "calInstance2": "DBT" },
{ "calInstance2": "HDM" },
{ "calInstance2": "PRPOS" },
{ "calInstance2": "RPOS" },
{ "calInstance2": "SOG" },
{ "calInstance2": "STW" },
{ "calInstance2": "TWA" },
{ "calInstance2": "TWS" },
{ "calInstance2": "TWD" },
{ "calInstance2": "WTemp" } ]
{ "calInstance2": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSlope2",
@ -879,19 +835,8 @@
"obp60":"true"
},
"condition": [
{ "calInstance2": "AWA" },
{ "calInstance2": "AWS" },
{ "calInstance2": "COG" },
{ "calInstance2": "DBT" },
{ "calInstance2": "HDM" },
{ "calInstance2": "PRPOS" },
{ "calInstance2": "RPOS" },
{ "calInstance2": "SOG" },
{ "calInstance2": "STW" },
{ "calInstance2": "TWA" },
{ "calInstance2": "TWS" },
{ "calInstance2": "TWD" },
{ "calInstance2": "WTemp" } ]
{ "calInstance2": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSmooth2",
@ -907,19 +852,8 @@
"obp60":"true"
},
"condition": [
{ "calInstance2": "AWA" },
{ "calInstance2": "AWS" },
{ "calInstance2": "COG" },
{ "calInstance2": "DBT" },
{ "calInstance2": "HDM" },
{ "calInstance2": "PRPOS" },
{ "calInstance2": "RPOS" },
{ "calInstance2": "SOG" },
{ "calInstance2": "STW" },
{ "calInstance2": "TWA" },
{ "calInstance2": "TWS" },
{ "calInstance2": "TWD" },
{ "calInstance2": "WTemp" } ]
{ "calInstance2": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calInstance3",
@ -959,19 +893,8 @@
"obp60":"true"
},
"condition": [
{ "calInstance3": "AWA" },
{ "calInstance3": "AWS" },
{ "calInstance3": "COG" },
{ "calInstance3": "DBT" },
{ "calInstance3": "HDM" },
{ "calInstance3": "PRPOS" },
{ "calInstance3": "RPOS" },
{ "calInstance3": "SOG" },
{ "calInstance3": "STW" },
{ "calInstance3": "TWA" },
{ "calInstance3": "TWS" },
{ "calInstance3": "TWD" },
{ "calInstance3": "WTemp" } ]
{ "calInstance3": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSlope3",
@ -984,19 +907,8 @@
"obp60":"true"
},
"condition": [
{ "calInstance3": "AWA" },
{ "calInstance3": "AWS" },
{ "calInstance3": "COG" },
{ "calInstance3": "DBT" },
{ "calInstance3": "HDM" },
{ "calInstance3": "PRPOS" },
{ "calInstance3": "RPOS" },
{ "calInstance3": "SOG" },
{ "calInstance3": "STW" },
{ "calInstance3": "TWA" },
{ "calInstance3": "TWS" },
{ "calInstance3": "TWD" },
{ "calInstance3": "WTemp" } ]
{ "calInstance3": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSmooth3",
@ -1012,19 +924,8 @@
"obp60":"true"
},
"condition": [
{ "calInstance3": "AWA" },
{ "calInstance3": "AWS" },
{ "calInstance3": "COG" },
{ "calInstance3": "DBT" },
{ "calInstance3": "HDM" },
{ "calInstance3": "PRPOS" },
{ "calInstance3": "RPOS" },
{ "calInstance3": "SOG" },
{ "calInstance3": "STW" },
{ "calInstance3": "TWA" },
{ "calInstance3": "TWS" },
{ "calInstance3": "TWD" },
{ "calInstance3": "WTemp" } ]
{ "calInstance3": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "display",
@ -1347,13 +1248,16 @@
"default": "Voltage",
"description": "Type of page for page 1",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -1630,13 +1534,16 @@
"default": "WindRose",
"description": "Type of page for page 2",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -1910,13 +1817,16 @@
"default": "OneValue",
"description": "Type of page for page 3",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -2187,13 +2097,16 @@
"default": "TwoValues",
"description": "Type of page for page 4",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -2461,13 +2374,16 @@
"default": "ThreeValues",
"description": "Type of page for page 5",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -2732,13 +2648,16 @@
"default": "FourValues",
"description": "Type of page for page 6",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -3000,13 +2919,16 @@
"default": "FourValues2",
"description": "Type of page for page 7",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -3265,13 +3187,16 @@
"default": "Clock",
"description": "Type of page for page 8",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -3527,13 +3452,16 @@
"default": "RollPitch",
"description": "Type of page for page 9",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -3786,13 +3714,16 @@
"default": "Battery2",
"description": "Type of page for page 10",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",

View File

@ -760,19 +760,8 @@
"obp40":"true"
},
"condition": [
{ "calInstance1": "AWA" },
{ "calInstance1": "AWS" },
{ "calInstance1": "COG" },
{ "calInstance1": "DBT" },
{ "calInstance1": "HDM" },
{ "calInstance1": "PRPOS" },
{ "calInstance1": "RPOS" },
{ "calInstance1": "SOG" },
{ "calInstance1": "STW" },
{ "calInstance1": "TWA" },
{ "calInstance1": "TWS" },
{ "calInstance1": "TWD" },
{ "calInstance1": "WTemp" } ]
{ "calInstance1": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSlope1",
@ -785,19 +774,8 @@
"obp40":"true"
},
"condition": [
{ "calInstance1": "AWA" },
{ "calInstance1": "AWS" },
{ "calInstance1": "COG" },
{ "calInstance1": "DBT" },
{ "calInstance1": "HDM" },
{ "calInstance1": "PRPOS" },
{ "calInstance1": "RPOS" },
{ "calInstance1": "SOG" },
{ "calInstance1": "STW" },
{ "calInstance1": "TWA" },
{ "calInstance1": "TWS" },
{ "calInstance1": "TWD" },
{ "calInstance1": "WTemp" } ]
{ "calInstance1": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSmooth1",
@ -813,19 +791,8 @@
"obp40":"true"
},
"condition": [
{ "calInstance1": "AWA" },
{ "calInstance1": "AWS" },
{ "calInstance1": "COG" },
{ "calInstance1": "DBT" },
{ "calInstance1": "HDM" },
{ "calInstance1": "PRPOS" },
{ "calInstance1": "RPOS" },
{ "calInstance1": "SOG" },
{ "calInstance1": "STW" },
{ "calInstance1": "TWA" },
{ "calInstance1": "TWS" },
{ "calInstance1": "TWD" },
{ "calInstance1": "WTemp" } ]
{ "calInstance1": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calInstance2",
@ -865,19 +832,8 @@
"obp40":"true"
},
"condition": [
{ "calInstance2": "AWA" },
{ "calInstance2": "AWS" },
{ "calInstance2": "COG" },
{ "calInstance2": "DBT" },
{ "calInstance2": "HDM" },
{ "calInstance2": "PRPOS" },
{ "calInstance2": "RPOS" },
{ "calInstance2": "SOG" },
{ "calInstance2": "STW" },
{ "calInstance2": "TWA" },
{ "calInstance2": "TWS" },
{ "calInstance2": "TWD" },
{ "calInstance2": "WTemp" } ]
{ "calInstance2": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSlope2",
@ -890,19 +846,8 @@
"obp40":"true"
},
"condition": [
{ "calInstance2": "AWA" },
{ "calInstance2": "AWS" },
{ "calInstance2": "COG" },
{ "calInstance2": "DBT" },
{ "calInstance2": "HDM" },
{ "calInstance2": "PRPOS" },
{ "calInstance2": "RPOS" },
{ "calInstance2": "SOG" },
{ "calInstance2": "STW" },
{ "calInstance2": "TWA" },
{ "calInstance2": "TWS" },
{ "calInstance2": "TWD" },
{ "calInstance2": "WTemp" } ]
{ "calInstance2": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSmooth2",
@ -918,19 +863,8 @@
"obp40":"true"
},
"condition": [
{ "calInstance2": "AWA" },
{ "calInstance2": "AWS" },
{ "calInstance2": "COG" },
{ "calInstance2": "DBT" },
{ "calInstance2": "HDM" },
{ "calInstance2": "PRPOS" },
{ "calInstance2": "RPOS" },
{ "calInstance2": "SOG" },
{ "calInstance2": "STW" },
{ "calInstance2": "TWA" },
{ "calInstance2": "TWS" },
{ "calInstance2": "TWD" },
{ "calInstance2": "WTemp" } ]
{ "calInstance2": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calInstance3",
@ -970,19 +904,8 @@
"obp40":"true"
},
"condition": [
{ "calInstance3": "AWA" },
{ "calInstance3": "AWS" },
{ "calInstance3": "COG" },
{ "calInstance3": "DBT" },
{ "calInstance3": "HDM" },
{ "calInstance3": "PRPOS" },
{ "calInstance3": "RPOS" },
{ "calInstance3": "SOG" },
{ "calInstance3": "STW" },
{ "calInstance3": "TWA" },
{ "calInstance3": "TWS" },
{ "calInstance3": "TWD" },
{ "calInstance3": "WTemp" } ]
{ "calInstance3": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSlope3",
@ -995,19 +918,8 @@
"obp40":"true"
},
"condition": [
{ "calInstance3": "AWA" },
{ "calInstance3": "AWS" },
{ "calInstance3": "COG" },
{ "calInstance3": "DBT" },
{ "calInstance3": "HDM" },
{ "calInstance3": "PRPOS" },
{ "calInstance3": "RPOS" },
{ "calInstance3": "SOG" },
{ "calInstance3": "STW" },
{ "calInstance3": "TWA" },
{ "calInstance3": "TWS" },
{ "calInstance3": "TWD" },
{ "calInstance3": "WTemp" } ]
{ "calInstance3": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "calSmooth3",
@ -1023,19 +935,8 @@
"obp40":"true"
},
"condition": [
{ "calInstance3": "AWA" },
{ "calInstance3": "AWS" },
{ "calInstance3": "COG" },
{ "calInstance3": "DBT" },
{ "calInstance3": "HDM" },
{ "calInstance3": "PRPOS" },
{ "calInstance3": "RPOS" },
{ "calInstance3": "SOG" },
{ "calInstance3": "STW" },
{ "calInstance3": "TWA" },
{ "calInstance3": "TWS" },
{ "calInstance3": "TWD" },
{ "calInstance3": "WTemp" } ]
{ "calInstance3": ["AWA", "AWS", "COG", "DBT", "HDM", "PRPOS", "RPOS", "SOG", "STW", "TWA", "TWS", "TWD", "WTemp" ] }
]
},
{
"name": "display",
@ -1370,13 +1271,16 @@
"default": "Clock",
"description": "Type of page for page 1",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -1653,13 +1557,16 @@
"default": "Wind",
"description": "Type of page for page 2",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -1933,13 +1840,16 @@
"default": "OneValue",
"description": "Type of page for page 3",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -2210,13 +2120,16 @@
"default": "TwoValues",
"description": "Type of page for page 4",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -2484,13 +2397,16 @@
"default": "ThreeValues",
"description": "Type of page for page 5",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -2755,13 +2671,16 @@
"default": "FourValues",
"description": "Type of page for page 6",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -3023,13 +2942,16 @@
"default": "FourValues2",
"description": "Type of page for page 7",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -3288,13 +3210,16 @@
"default": "Fluid",
"description": "Type of page for page 8",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -3550,13 +3475,16 @@
"default": "RollPitch",
"description": "Type of page for page 9",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",
@ -3809,13 +3737,16 @@
"default": "Battery2",
"description": "Type of page for page 10",
"list": [
"AIS",
"Anchor",
"Autopilot",
"BME280",
"Battery",
"Battery2",
"Clock",
"Compass",
"DST810",
"EPropulsion",
"Fluid",
"FourValues",
"FourValues2",

View File

@ -259,7 +259,7 @@ void registerAllPages(PageList &list){
extern PageDescription registerPageWindRose;
list.add(&registerPageWindRose);
extern PageDescription registerPageWindRoseFlex;
list.add(&registerPageWindRoseFlex); //
list.add(&registerPageWindRoseFlex);
extern PageDescription registerPageVoltage;
list.add(&registerPageVoltage);
extern PageDescription registerPageDST810;
@ -294,6 +294,12 @@ void registerAllPages(PageList &list){
list.add(&registerPageSkyView);
extern PageDescription registerPageAnchor;
list.add(&registerPageAnchor);
/* extern PageDescription registerPageAIS;
list.add(&registerPageAIS);
extern PageDescription registerPageAutopilot;
list.add(&registerPageAutopilot);
extern PageDescription registerPageEPropulsion;
list.add(&registerPageEPropulsion); */
}
// Undervoltage detection for shutdown display