Add MaxNodes to Native config (#3427)

* Add MaxNodes to Native

* It compiles...

* Convert nodedb to use new

* Closer but still broken.

* Finally working

* Remove unintended lines

* Don't include a pointer

* Capitalization matters.

* avoid rename in protocol regen

* When trimming the nodeDB, start with a cleanup

* Remove extra cleanupMeshDB() call for now

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
This commit is contained in:
Jonathan Bennett
2024-03-21 09:06:37 -05:00
committed by GitHub
parent f4095ce00d
commit dfcd0d14f6
58 changed files with 258 additions and 209 deletions

View File

@@ -1,4 +1,5 @@
#pragma once
#include <vector>
#include "mesh/generated/meshtastic/admin.pb.h"
#include "mesh/generated/meshtastic/deviceonly.pb.h"
@@ -16,7 +17,11 @@
#define MAX_RX_TOPHONE 32
/// max number of nodes allowed in the mesh
#define MAX_NUM_NODES (member_size(meshtastic_DeviceState, node_db_lite) / member_size(meshtastic_DeviceState, node_db_lite[0]))
#if ARCH_PORTDUINO
#define MAX_NUM_NODES settingsMap[maxnodes]
#else
#define MAX_NUM_NODES 100
#endif
/// Max number of channels allowed
#define MAX_NUM_CHANNELS (member_size(meshtastic_ChannelFile, channels) / member_size(meshtastic_ChannelFile, channels[0]))