mirror of
https://github.com/MarekZegare4/MeshCore-Solo.git
synced 2026-08-03 10:46:12 +00:00
feat: add periodic auto-advert with GPS position (Auto-Advert tool)
Adds configurable periodic 0-hop self-advert that includes GPS coordinates, making the device's position visible in other nodes' Nearby Nodes screen. Options: off / 1min / 2min / 5min / 10min / 30min / 1h. Accessible via Tools → Auto-Advert. Timer runs in MyMesh::loop(). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 4.6
parent
d59687647f
commit
09ac455806
@@ -1594,6 +1594,7 @@ public:
|
||||
#include "BotScreen.h"
|
||||
#include "NearbyScreen.h"
|
||||
#include "DashboardConfigScreen.h"
|
||||
#include "AutoAdvertScreen.h"
|
||||
#include "ToolsScreen.h"
|
||||
|
||||
// ── HomeScreen ────────────────────────────────────────────────────────────────
|
||||
@@ -2252,6 +2253,7 @@ void UITask::begin(DisplayDriver* display, SensorManager* sensors, NodePrefs* no
|
||||
bot_screen = new BotScreen(this, node_prefs);
|
||||
nearby_screen = new NearbyScreen(this);
|
||||
dashboard_config = new DashboardConfigScreen(this, node_prefs);
|
||||
auto_advert_screen = new AutoAdvertScreen(this, node_prefs);
|
||||
setCurrScreen(splash);
|
||||
|
||||
applyBrightness();
|
||||
@@ -2286,6 +2288,11 @@ void UITask::gotoDashboardConfig() {
|
||||
setCurrScreen(dashboard_config);
|
||||
}
|
||||
|
||||
void UITask::gotoAutoAdvertScreen() {
|
||||
((AutoAdvertScreen*)auto_advert_screen)->enter();
|
||||
setCurrScreen(auto_advert_screen);
|
||||
}
|
||||
|
||||
void UITask::playMelody(const char* melody) {
|
||||
#ifdef PIN_BUZZER
|
||||
buzzer.playForced(melody);
|
||||
|
||||
Reference in New Issue
Block a user