From 015202aead5f6807d63537c58f4cb6525f19e56f Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sat, 2 Nov 2024 05:46:54 -0500 Subject: [PATCH 01/41] Update mesh.proto --- meshtastic/mesh.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index f53ef96..ca3f6c6 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -17,7 +17,7 @@ option java_package = "com.geeksville.mesh"; option swift_prefix = ""; /* - * a gps position + * A GPS Position */ message Position { /* From 8a38aa93cb21940505eb6716d8037a29f6d89e0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Sun, 3 Nov 2024 23:00:40 +0100 Subject: [PATCH 02/41] add hardware environment --- meshtastic/mesh.proto | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index ca3f6c6..14363ea 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1870,6 +1870,11 @@ message DeviceMetadata { * Has PKC capabilities */ bool hasPKC = 11; + + /* + * Device firmware environment string + */ + string hw_env = 12; } /* From 9f45c61bb7520ea13513035262848b7c1cc4b4b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Sun, 3 Nov 2024 23:02:24 +0100 Subject: [PATCH 03/41] current max size is 35 --- meshtastic/mesh.options | 1 + 1 file changed, 1 insertion(+) diff --git a/meshtastic/mesh.options b/meshtastic/mesh.options index 4e335d2..76c4a40 100644 --- a/meshtastic/mesh.options +++ b/meshtastic/mesh.options @@ -67,6 +67,7 @@ *NeighborInfo.neighbors max_count:10 *DeviceMetadata.firmware_version max_size:18 +*DeviceMetadata.hw_env max_size:40 *MqttClientProxyMessage.topic max_size:60 *MqttClientProxyMessage.data max_size:435 From b227a1ca72688d318cc6daef42ea642d7283b8ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Sun, 3 Nov 2024 23:07:25 +0100 Subject: [PATCH 04/41] rename to pio_env --- meshtastic/mesh.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 14363ea..9560593 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1874,7 +1874,7 @@ message DeviceMetadata { /* * Device firmware environment string */ - string hw_env = 12; + string pio_env = 12; } /* From 254fbdac6acb7796bbee19fd5b84f5f1e216a9b7 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sun, 3 Nov 2024 16:17:03 -0600 Subject: [PATCH 05/41] pio --- meshtastic/mesh.options | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshtastic/mesh.options b/meshtastic/mesh.options index 76c4a40..424d8c4 100644 --- a/meshtastic/mesh.options +++ b/meshtastic/mesh.options @@ -67,7 +67,7 @@ *NeighborInfo.neighbors max_count:10 *DeviceMetadata.firmware_version max_size:18 -*DeviceMetadata.hw_env max_size:40 +*DeviceMetadata.pio_env max_size:40 *MqttClientProxyMessage.topic max_size:60 *MqttClientProxyMessage.data max_size:435 From e505f6051e350dadcc2220131b01a56c98848e5a Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sun, 3 Nov 2024 19:45:10 -0600 Subject: [PATCH 06/41] Move PIO env to mynodeinfo --- meshtastic/mesh.options | 2 +- meshtastic/mesh.proto | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/meshtastic/mesh.options b/meshtastic/mesh.options index 424d8c4..f474988 100644 --- a/meshtastic/mesh.options +++ b/meshtastic/mesh.options @@ -26,6 +26,7 @@ # Big enough for 1.2.28.568032c-d *MyNodeInfo.firmware_version max_size:18 *MyNodeInfo.device_id max_size:16 +*MyNodeInfo.pio_env max_size:40 *MyNodeInfo.air_period_tx max_count:8 *MyNodeInfo.air_period_rx max_count:8 @@ -67,7 +68,6 @@ *NeighborInfo.neighbors max_count:10 *DeviceMetadata.firmware_version max_size:18 -*DeviceMetadata.pio_env max_size:40 *MqttClientProxyMessage.topic max_size:60 *MqttClientProxyMessage.data max_size:435 diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 9560593..348be8d 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1462,6 +1462,11 @@ message MyNodeInfo { * Unique hardware identifier for this device */ bytes device_id = 12; + + /* + * The PlatformIO environment used to build this firmware + */ + string pio_env = 13; } /* @@ -1870,11 +1875,6 @@ message DeviceMetadata { * Has PKC capabilities */ bool hasPKC = 11; - - /* - * Device firmware environment string - */ - string pio_env = 12; } /* From b399bf0f6aacc70dd5aa8df961ef4abdefb6bc4a Mon Sep 17 00:00:00 2001 From: andrekir Date: Sun, 3 Nov 2024 08:43:16 -0300 Subject: [PATCH 07/41] add bit field to `DeviceMetadata` for excluded modules --- meshtastic/mesh.proto | 83 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index ca3f6c6..e07a711 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1870,6 +1870,89 @@ message DeviceMetadata { * Has PKC capabilities */ bool hasPKC = 11; + + /* + * Bit field of boolean for excluded modules + * (bitwise OR of ExcludedModules) + */ + uint32 excluded_modules = 12; +} + +/* + * Enum for modules excluded from a device's configuration. + * Each value represents a ModuleConfigType that can be toggled as excluded + * by setting its corresponding bit in the `excluded_modules` bitmask field. + */ +enum ExcludedModules { + /* + * Default value of 0 indicates no modules are excluded. + */ + EXCLUDED_NONE = 0x0000; + + /* + * MQTT module + */ + MQTT_CONFIG = 0x0001; + + /* + * Serial module + */ + SERIAL_CONFIG = 0x0002; + + /* + * External Notification module + */ + EXTNOTIF_CONFIG = 0x0004; + + /* + * Store and Forward module + */ + STOREFORWARD_CONFIG = 0x0008; + + /* + * Range Test module + */ + RANGETEST_CONFIG = 0x0010; + + /* + * Telemetry module + */ + TELEMETRY_CONFIG = 0x0020; + + /* + * Canned Message module + */ + CANNEDMSG_CONFIG = 0x0040; + + /* + * Audio module + */ + AUDIO_CONFIG = 0x0080; + + /* + * Remote Hardware module + */ + REMOTEHARDWARE_CONFIG = 0x0100; + + /* + * Neighbor Info module + */ + NEIGHBORINFO_CONFIG = 0x0200; + + /* + * Ambient Lighting module + */ + AMBIENTLIGHTING_CONFIG = 0x0400; + + /* + * Detection Sensor module + */ + DETECTIONSENSOR_CONFIG = 0x0800; + + /* + * Paxcounter module + */ + PAXCOUNTER_CONFIG = 0x1000; } /* From 034a18143632d4cf17e0acfff66915646f217c27 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Thu, 7 Nov 2024 06:17:39 -0600 Subject: [PATCH 08/41] Direct neighbor for clarity --- meshtastic/device_only/deviceonly.proto | 235 ++++++++++++++++++++++++ meshtastic/deviceonly.proto | 2 +- meshtastic/mesh.proto | 6 +- 3 files changed, 239 insertions(+), 4 deletions(-) create mode 100644 meshtastic/device_only/deviceonly.proto diff --git a/meshtastic/device_only/deviceonly.proto b/meshtastic/device_only/deviceonly.proto new file mode 100644 index 0000000..b199bc3 --- /dev/null +++ b/meshtastic/device_only/deviceonly.proto @@ -0,0 +1,235 @@ +syntax = "proto3"; + +package meshtastic; + +import "channel.proto"; +import "localonly.proto"; +import "mesh.proto"; +import "telemetry.proto"; +import "config.proto"; +import "nanopb.proto"; + +option csharp_namespace = "Meshtastic.Protobufs"; +option go_package = "github.com/meshtastic/go/generated"; +option java_outer_classname = "DeviceOnly"; +option java_package = "com.geeksville.mesh"; +option swift_prefix = ""; +option (nanopb_fileopt).include = ""; + + +/* + * Position with static location information only for NodeDBLite + */ +message PositionLite { + /* + * The new preferred location encoding, multiply by 1e-7 to get degrees + * in floating point + */ + sfixed32 latitude_i = 1; + + /* + * TODO: REPLACE + */ + sfixed32 longitude_i = 2; + + /* + * In meters above MSL (but see issue #359) + */ + int32 altitude = 3; + + /* + * This is usually not sent over the mesh (to save space), but it is sent + * from the phone so that the local device can set its RTC If it is sent over + * the mesh (because there are devices on the mesh without GPS), it will only + * be sent by devices which has a hardware GPS clock. + * seconds since 1970 + */ + fixed32 time = 4; + + /* + * TODO: REPLACE + */ + Position.LocSource location_source = 5; +} + +message UserLite { + /* + * This is the addr of the radio. + */ + bytes macaddr = 1 [deprecated = true]; + + /* + * A full name for this user, i.e. "Kevin Hester" + */ + string long_name = 2; + + /* + * A VERY short name, ideally two characters. + * Suitable for a tiny OLED screen + */ + string short_name = 3; + + /* + * TBEAM, HELTEC, etc... + * Starting in 1.2.11 moved to hw_model enum in the NodeInfo object. + * Apps will still need the string here for older builds + * (so OTA update can find the right image), but if the enum is available it will be used instead. + */ + HardwareModel hw_model = 4; + + /* + * In some regions Ham radio operators have different bandwidth limitations than others. + * If this user is a licensed operator, set this flag. + * Also, "long_name" should be their licence number. + */ + bool is_licensed = 5; + + /* + * Indicates that the user's role in the mesh + */ + Config.DeviceConfig.Role role = 6; + + /* + * The public key of the user's device. + * This is sent out to other nodes on the mesh to allow them to compute a shared secret key. + */ + bytes public_key = 7; +} + +message NodeInfoLite { + /* + * The node number + */ + uint32 num = 1; + + /* + * The user info for this node + */ + UserLite user = 2; + + /* + * This position data. Note: before 1.2.14 we would also store the last time we've heard from this node in position.time, that is no longer true. + * Position.time now indicates the last time we received a POSITION from that node. + */ + PositionLite position = 3; + + /* + * Returns the Signal-to-noise ratio (SNR) of the last received message, + * as measured by the receiver. Return SNR of the last received message in dB + */ + float snr = 4; + + /* + * Set to indicate the last time we received a packet from this node + */ + fixed32 last_heard = 5; + /* + * The latest device metrics for the node. + */ + DeviceMetrics device_metrics = 6; + + /* + * local channel index we heard that node on. Only populated if its not the default channel. + */ + uint32 channel = 7; + + /* + * True if we witnessed the node over MQTT instead of LoRA transport + */ + bool via_mqtt = 8; + + /* + * Number of hops away from us this node is (0 if direct neighbor) + */ + optional uint32 hops_away = 9; + + /* + * True if node is in our favorites list + * Persists between NodeDB internal clean ups + */ + bool is_favorite = 10; +} + +/* + * This message is never sent over the wire, but it is used for serializing DB + * state to flash in the device code + * FIXME, since we write this each time we enter deep sleep (and have infinite + * flash) it would be better to use some sort of append only data structure for + * the receive queue and use the preferences store for the other stuff + */ +message DeviceState { + /* + * Read only settings/info about this node + */ + MyNodeInfo my_node = 2; + + /* + * My owner info + */ + User owner = 3; + + /* + * Received packets saved for delivery to the phone + */ + repeated MeshPacket receive_queue = 5; + + /* + * A version integer used to invalidate old save files when we make + * incompatible changes This integer is set at build time and is private to + * NodeDB.cpp in the device code. + */ + uint32 version = 8; + + /* + * We keep the last received text message (only) stored in the device flash, + * so we can show it on the screen. + * Might be null + */ + MeshPacket rx_text_message = 7; + + /* + * Used only during development. + * Indicates developer is testing and changes should never be saved to flash. + * Deprecated in 2.3.1 + */ + bool no_save = 9 [deprecated = true]; + + /* + * Some GPS receivers seem to have bogus settings from the factory, so we always do one factory reset. + */ + bool did_gps_reset = 11; + + /* + * We keep the last received waypoint stored in the device flash, + * so we can show it on the screen. + * Might be null + */ + MeshPacket rx_waypoint = 12; + + /* + * The mesh's nodes with their available gpio pins for RemoteHardware module + */ + repeated NodeRemoteHardwarePin node_remote_hardware_pins = 13; + + /* + * New lite version of NodeDB to decrease memory footprint + */ + repeated NodeInfoLite node_db_lite = 14 [(nanopb).callback_datatype = "std::vector"]; +} + +/* + * The on-disk saved channels + */ +message ChannelFile { + /* + * The channels our node knows about + */ + repeated Channel channels = 1; + + /* + * A version integer used to invalidate old save files when we make + * incompatible changes This integer is set at build time and is private to + * NodeDB.cpp in the device code. + */ + uint32 version = 2; +} diff --git a/meshtastic/deviceonly.proto b/meshtastic/deviceonly.proto index 76bdfa8..d08c605 100644 --- a/meshtastic/deviceonly.proto +++ b/meshtastic/deviceonly.proto @@ -138,7 +138,7 @@ message NodeInfoLite { bool via_mqtt = 8; /* - * Number of hops away from us this node is (0 if adjacent) + * Number of hops away from us this node is (0 if direct neighbor) */ optional uint32 hops_away = 9; diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 8fa16aa..1fca39f 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1177,7 +1177,7 @@ message MeshPacket { float rx_snr = 8; /* - * If unset treated as zero (no forwarding, send to adjacent nodes only) + * If unset treated as zero (no forwarding, send to direct neighbor nodes only) * if 1, allow hopping through one node, etc... * For our usecase real world topologies probably have a max of about 3. * This field is normally placed into a few of bits in the header. @@ -1317,7 +1317,7 @@ message NodeInfo { /* * TODO: REMOVE/INTEGRATE * Not currently used (till full DSR deployment?) Our current preferred node node for routing - might be the same as num if - * we are adjacent Or zero if we don't yet know a route to this node. + * we are direct neighbor or zero if we don't yet know a route to this node. * fixed32 next_hop = 5; */ @@ -1341,7 +1341,7 @@ message NodeInfo { bool via_mqtt = 8; /* - * Number of hops away from us this node is (0 if adjacent) + * Number of hops away from us this node is (0 if direct neighbor) */ optional uint32 hops_away = 9; From c2a3834e2400e419a1665c7395d2172bb9ccc7f9 Mon Sep 17 00:00:00 2001 From: GUVWAF Date: Thu, 7 Nov 2024 18:44:15 +0100 Subject: [PATCH 09/41] Add bool to enable LoRa transport for NeighborInfo --- meshtastic/module_config.proto | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/meshtastic/module_config.proto b/meshtastic/module_config.proto index 933d142..f208d42 100644 --- a/meshtastic/module_config.proto +++ b/meshtastic/module_config.proto @@ -128,9 +128,14 @@ message ModuleConfig { /* * Interval in seconds of how often we should try to send our - * Neighbor Info to the mesh + * Neighbor Info (minimum is 14400, i.e., 4 hours) */ uint32 update_interval = 2; + + /* + * Whether in addition to sending it to MQTT and the PhoneAPI, our NeighborInfo should be transmitted over LoRa. + */ + bool transmit_over_lora = 3; } /* From 2978b625879b6c5b4d43ab8290e1cea85b59c347 Mon Sep 17 00:00:00 2001 From: GUVWAF Date: Thu, 7 Nov 2024 19:11:14 +0100 Subject: [PATCH 10/41] LoRa transport not available on the default channel --- meshtastic/module_config.proto | 1 + 1 file changed, 1 insertion(+) diff --git a/meshtastic/module_config.proto b/meshtastic/module_config.proto index f208d42..040b604 100644 --- a/meshtastic/module_config.proto +++ b/meshtastic/module_config.proto @@ -134,6 +134,7 @@ message ModuleConfig { /* * Whether in addition to sending it to MQTT and the PhoneAPI, our NeighborInfo should be transmitted over LoRa. + * Note that this is not available on a channel with default key and name. */ bool transmit_over_lora = 3; } From 04f21f5c7238b8e02f794d9282c4786752634b3c Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sat, 9 Nov 2024 05:21:30 -0600 Subject: [PATCH 11/41] Remove duplicate file --- meshtastic/device_only/deviceonly.proto | 235 ------------------------ 1 file changed, 235 deletions(-) delete mode 100644 meshtastic/device_only/deviceonly.proto diff --git a/meshtastic/device_only/deviceonly.proto b/meshtastic/device_only/deviceonly.proto deleted file mode 100644 index b199bc3..0000000 --- a/meshtastic/device_only/deviceonly.proto +++ /dev/null @@ -1,235 +0,0 @@ -syntax = "proto3"; - -package meshtastic; - -import "channel.proto"; -import "localonly.proto"; -import "mesh.proto"; -import "telemetry.proto"; -import "config.proto"; -import "nanopb.proto"; - -option csharp_namespace = "Meshtastic.Protobufs"; -option go_package = "github.com/meshtastic/go/generated"; -option java_outer_classname = "DeviceOnly"; -option java_package = "com.geeksville.mesh"; -option swift_prefix = ""; -option (nanopb_fileopt).include = ""; - - -/* - * Position with static location information only for NodeDBLite - */ -message PositionLite { - /* - * The new preferred location encoding, multiply by 1e-7 to get degrees - * in floating point - */ - sfixed32 latitude_i = 1; - - /* - * TODO: REPLACE - */ - sfixed32 longitude_i = 2; - - /* - * In meters above MSL (but see issue #359) - */ - int32 altitude = 3; - - /* - * This is usually not sent over the mesh (to save space), but it is sent - * from the phone so that the local device can set its RTC If it is sent over - * the mesh (because there are devices on the mesh without GPS), it will only - * be sent by devices which has a hardware GPS clock. - * seconds since 1970 - */ - fixed32 time = 4; - - /* - * TODO: REPLACE - */ - Position.LocSource location_source = 5; -} - -message UserLite { - /* - * This is the addr of the radio. - */ - bytes macaddr = 1 [deprecated = true]; - - /* - * A full name for this user, i.e. "Kevin Hester" - */ - string long_name = 2; - - /* - * A VERY short name, ideally two characters. - * Suitable for a tiny OLED screen - */ - string short_name = 3; - - /* - * TBEAM, HELTEC, etc... - * Starting in 1.2.11 moved to hw_model enum in the NodeInfo object. - * Apps will still need the string here for older builds - * (so OTA update can find the right image), but if the enum is available it will be used instead. - */ - HardwareModel hw_model = 4; - - /* - * In some regions Ham radio operators have different bandwidth limitations than others. - * If this user is a licensed operator, set this flag. - * Also, "long_name" should be their licence number. - */ - bool is_licensed = 5; - - /* - * Indicates that the user's role in the mesh - */ - Config.DeviceConfig.Role role = 6; - - /* - * The public key of the user's device. - * This is sent out to other nodes on the mesh to allow them to compute a shared secret key. - */ - bytes public_key = 7; -} - -message NodeInfoLite { - /* - * The node number - */ - uint32 num = 1; - - /* - * The user info for this node - */ - UserLite user = 2; - - /* - * This position data. Note: before 1.2.14 we would also store the last time we've heard from this node in position.time, that is no longer true. - * Position.time now indicates the last time we received a POSITION from that node. - */ - PositionLite position = 3; - - /* - * Returns the Signal-to-noise ratio (SNR) of the last received message, - * as measured by the receiver. Return SNR of the last received message in dB - */ - float snr = 4; - - /* - * Set to indicate the last time we received a packet from this node - */ - fixed32 last_heard = 5; - /* - * The latest device metrics for the node. - */ - DeviceMetrics device_metrics = 6; - - /* - * local channel index we heard that node on. Only populated if its not the default channel. - */ - uint32 channel = 7; - - /* - * True if we witnessed the node over MQTT instead of LoRA transport - */ - bool via_mqtt = 8; - - /* - * Number of hops away from us this node is (0 if direct neighbor) - */ - optional uint32 hops_away = 9; - - /* - * True if node is in our favorites list - * Persists between NodeDB internal clean ups - */ - bool is_favorite = 10; -} - -/* - * This message is never sent over the wire, but it is used for serializing DB - * state to flash in the device code - * FIXME, since we write this each time we enter deep sleep (and have infinite - * flash) it would be better to use some sort of append only data structure for - * the receive queue and use the preferences store for the other stuff - */ -message DeviceState { - /* - * Read only settings/info about this node - */ - MyNodeInfo my_node = 2; - - /* - * My owner info - */ - User owner = 3; - - /* - * Received packets saved for delivery to the phone - */ - repeated MeshPacket receive_queue = 5; - - /* - * A version integer used to invalidate old save files when we make - * incompatible changes This integer is set at build time and is private to - * NodeDB.cpp in the device code. - */ - uint32 version = 8; - - /* - * We keep the last received text message (only) stored in the device flash, - * so we can show it on the screen. - * Might be null - */ - MeshPacket rx_text_message = 7; - - /* - * Used only during development. - * Indicates developer is testing and changes should never be saved to flash. - * Deprecated in 2.3.1 - */ - bool no_save = 9 [deprecated = true]; - - /* - * Some GPS receivers seem to have bogus settings from the factory, so we always do one factory reset. - */ - bool did_gps_reset = 11; - - /* - * We keep the last received waypoint stored in the device flash, - * so we can show it on the screen. - * Might be null - */ - MeshPacket rx_waypoint = 12; - - /* - * The mesh's nodes with their available gpio pins for RemoteHardware module - */ - repeated NodeRemoteHardwarePin node_remote_hardware_pins = 13; - - /* - * New lite version of NodeDB to decrease memory footprint - */ - repeated NodeInfoLite node_db_lite = 14 [(nanopb).callback_datatype = "std::vector"]; -} - -/* - * The on-disk saved channels - */ -message ChannelFile { - /* - * The channels our node knows about - */ - repeated Channel channels = 1; - - /* - * A version integer used to invalidate old save files when we make - * incompatible changes This integer is set at build time and is private to - * NodeDB.cpp in the device code. - */ - uint32 version = 2; -} From 04ea4b5b152bd05f70de0ba15a0268d0a3e080a5 Mon Sep 17 00:00:00 2001 From: Matthijs De Smedt Date: Mon, 11 Nov 2024 16:11:41 -0800 Subject: [PATCH 12/41] Add is_ignored bool to NodeInfo --- meshtastic/admin.proto | 10 ++++++++++ meshtastic/deviceonly.proto | 6 ++++++ meshtastic/mesh.proto | 6 ++++++ 3 files changed, 22 insertions(+) diff --git a/meshtastic/admin.proto b/meshtastic/admin.proto index 0f665e7..809d7c6 100644 --- a/meshtastic/admin.proto +++ b/meshtastic/admin.proto @@ -350,6 +350,16 @@ message AdminMessage { */ DeviceUIConfig store_ui_config = 46; + /* + * Set specified node-num to be ignored on the NodeDB on the device + */ + uint32 set_ignored_node = 47; + + /* + * Set specified node-num to be un-ignored on the NodeDB on the device + */ + uint32 remove_ignored_node = 48; + /* * Begins an edit transaction for config, module config, owner, and channel settings changes * This will delay the standard *implicit* save to the file system and subsequent reboot behavior until committed (commit_edit_settings) diff --git a/meshtastic/deviceonly.proto b/meshtastic/deviceonly.proto index d08c605..55aa9a7 100644 --- a/meshtastic/deviceonly.proto +++ b/meshtastic/deviceonly.proto @@ -147,6 +147,12 @@ message NodeInfoLite { * Persists between NodeDB internal clean ups */ bool is_favorite = 10; + + /* + * True if node is in our ignored list + * Persists between NodeDB internal clean ups + */ + bool is_ignored = 11; } /* diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 1fca39f..27915a2 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1350,6 +1350,12 @@ message NodeInfo { * Persists between NodeDB internal clean ups */ bool is_favorite = 10; + + /* + * True if node is in our ignored list + * Persists between NodeDB internal clean ups + */ + bool is_ignored = 11; } /* From 6de64e11989132bdb3f60e6c6d32580d3e70ce60 Mon Sep 17 00:00:00 2001 From: mverch67 Date: Mon, 18 Nov 2024 00:01:47 +0100 Subject: [PATCH 13/41] store calibration, Norwegian language --- meshtastic/device_ui.options | 1 + meshtastic/device_ui.proto | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/meshtastic/device_ui.options b/meshtastic/device_ui.options index 65be467..55edcae 100644 --- a/meshtastic/device_ui.options +++ b/meshtastic/device_ui.options @@ -1,6 +1,7 @@ *DeviceUIConfig.screen_brightness int_size:8 *DeviceUIConfig.screen_timeout int_size:16 *DeviceUIConfig.ring_tone_id int_size:8 +*DeviceUIConfig.calibration_data max_size:16 *NodeFilter.node_name max_size:16 *NodeFilter.hops_away int_size:8 *NodeHighlight.node_name max_size:16 diff --git a/meshtastic/device_ui.proto b/meshtastic/device_ui.proto index 38481d2..b586fed 100644 --- a/meshtastic/device_ui.proto +++ b/meshtastic/device_ui.proto @@ -61,6 +61,11 @@ message DeviceUIConfig { * Node list highlightening */ NodeHighlight node_highlight = 13; + + /* + * 8 integers for screen calibration data + */ + bytes calibration_data = 14; } @@ -215,6 +220,11 @@ enum Language { GREEK = 13; /* + * Norwegian + */ + NORWEGIAN = 14; + + /* * Simplified Chinese (experimental) */ SIMPLIFIED_CHINESE = 30; From 739a6d4af0c68b7266a42336a77f9910d7368171 Mon Sep 17 00:00:00 2001 From: GUVWAF Date: Mon, 18 Nov 2024 18:41:09 +0100 Subject: [PATCH 14/41] Add `next_hop` and `relay_node` to MeshPacket --- meshtastic/mesh.options | 4 +++- meshtastic/mesh.proto | 14 +++++++++++++- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/meshtastic/mesh.options b/meshtastic/mesh.options index f474988..26182a2 100644 --- a/meshtastic/mesh.options +++ b/meshtastic/mesh.options @@ -38,6 +38,8 @@ *MeshPacket.hop_limit int_size:8 *MeshPacket.hop_start int_size:8 *MeshPacket.channel int_size:8 +*MeshPacket.next_hop int_size:8 +*MeshPacket.relay_node int_size:8 *QueueStatus.res int_size:8 *QueueStatus.free int_size:8 @@ -75,4 +77,4 @@ *ChunkedPayload.chunk_count int_size:16 *ChunkedPayload.chunk_index int_size:16 -*ChunkedPayload.payload_chunk max_size:228 +*ChunkedPayload.payload_chunk max_size:228 \ No newline at end of file diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 27915a2..181f27e 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1233,6 +1233,18 @@ message MeshPacket { * Indicates whether the packet was en/decrypted using PKI */ bool pki_encrypted = 17; + + /* + * Last byte of the node number of the node that should be used as the next hop in routing. + * Set by the firmware internally, clients are not supposed to set this. + */ + uint32 next_hop = 18; + + /* + * Last byte of the node number of the node that will relay/relayed this packet. + * Set by the firmware internally, clients are not supposed to set this. + */ + uint32 relay_node = 19; } /* @@ -2040,4 +2052,4 @@ message ChunkedPayloadResponse { */ resend_chunks resend_chunks = 4; } -} +} \ No newline at end of file From 40497bf8d4cf43b2b3e579f868328c87e5e628da Mon Sep 17 00:00:00 2001 From: GUVWAF Date: Mon, 18 Nov 2024 18:41:27 +0100 Subject: [PATCH 15/41] Add `next_hop` to NodeInfoLite --- meshtastic/deviceonly.options | 3 ++- meshtastic/deviceonly.proto | 7 ++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/meshtastic/deviceonly.options b/meshtastic/deviceonly.options index 82dffcf..d6aae0c 100644 --- a/meshtastic/deviceonly.options +++ b/meshtastic/deviceonly.options @@ -10,8 +10,9 @@ *NodeInfoLite.channel int_size:8 *NodeInfoLite.hops_away int_size:8 +*NodeInfoLite.next_hop int_size:8 *UserLite.long_name max_size:40 *UserLite.short_name max_size:5 *UserLite.public_key max_size:32 # public key -*UserLite.macaddr max_size:6 fixed_length:true +*UserLite.macaddr max_size:6 fixed_length:true \ No newline at end of file diff --git a/meshtastic/deviceonly.proto b/meshtastic/deviceonly.proto index 55aa9a7..c506137 100644 --- a/meshtastic/deviceonly.proto +++ b/meshtastic/deviceonly.proto @@ -153,6 +153,11 @@ message NodeInfoLite { * Persists between NodeDB internal clean ups */ bool is_ignored = 11; + + /* + * Last byte of the node number of the node that should be used as the next hop to reach this node. + */ + uint32 next_hop = 12; } /* @@ -237,4 +242,4 @@ message ChannelFile { * NodeDB.cpp in the device code. */ uint32 version = 2; -} +} \ No newline at end of file From c38692bd11b41e369e79510f7ddd07fc8ef0f91e Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Tue, 19 Nov 2024 12:50:44 -0600 Subject: [PATCH 16/41] Add wismesh tap --- meshtastic/mesh.proto | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 181f27e..24b8474 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -650,6 +650,12 @@ enum HardwareModel { */ TLORA_C6 = 83; + /* + * WisMesh Tap + * RAK-4631 w/ TFT in injection modled case + */ + WISMESH_TAP = 84; + /* * ------------------------------------------------------------------------------------------------------------------------------------------ * Reserved ID For developing private Ports. These will show up in live traffic sparsely, so we can use a high number. Keep it within 8 bits. From c952f8a4c1c30f724743ee322dd3ec3ec2f934c4 Mon Sep 17 00:00:00 2001 From: jake-b <1012393+jake-b@users.noreply.github.com> Date: Sat, 23 Nov 2024 09:10:43 -0500 Subject: [PATCH 17/41] Support for the ClimateGuard RadSens Geiger-Muller tube (#626) Co-authored-by: Jake-B --- meshtastic/telemetry.proto | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/meshtastic/telemetry.proto b/meshtastic/telemetry.proto index 5dd810b..69a06f7 100644 --- a/meshtastic/telemetry.proto +++ b/meshtastic/telemetry.proto @@ -128,6 +128,12 @@ message EnvironmentMetrics { * Wind lull in m/s */ optional float wind_lull = 17; + + /* + * Radiation in µR/h + */ + optional float radiation = 18; + } /* @@ -525,6 +531,12 @@ enum TelemetrySensorType { * SCD40/SCD41 CO2, humidity, temperature sensor */ SCD4X = 32; + + /* + * ClimateGuard RadSens, radiation, Geiger-Muller Tube + */ + RADSENS = 33; + } /* From 5ea20fc1f774f3d5d4de301c74cd491fb30f4fb0 Mon Sep 17 00:00:00 2001 From: andrekir Date: Mon, 25 Nov 2024 12:52:24 -0300 Subject: [PATCH 18/41] update payload max length --- meshtastic/mesh.options | 4 ++-- meshtastic/mesh.proto | 2 +- meshtastic/storeforward.options | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/meshtastic/mesh.options b/meshtastic/mesh.options index 26182a2..e2c905d 100644 --- a/meshtastic/mesh.options +++ b/meshtastic/mesh.options @@ -17,7 +17,7 @@ # note: this payload length is ONLY the bytes that are sent inside of the Data protobuf (excluding protobuf overhead). The 16 byte header is # outside of this envelope -*Data.payload max_size:237 +*Data.payload max_size:233 *Data.bitfield int_size:8 *NodeInfo.channel int_size:8 @@ -62,7 +62,7 @@ # or fixed_length or fixed_count, or max_count #This value may want to be a few bytes smaller to compensate for the parent fields. -*Compressed.data max_size:237 +*Compressed.data max_size:233 *Waypoint.name max_size:30 *Waypoint.description max_size:100 diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 24b8474..b1bdd59 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1268,7 +1268,7 @@ enum Constants { * note: this payload length is ONLY the bytes that are sent inside of the Data protobuf (excluding protobuf overhead). The 16 byte header is * outside of this envelope */ - DATA_PAYLOAD_LEN = 237; + DATA_PAYLOAD_LEN = 233; } /* diff --git a/meshtastic/storeforward.options b/meshtastic/storeforward.options index 8580aab..57a122c 100644 --- a/meshtastic/storeforward.options +++ b/meshtastic/storeforward.options @@ -1 +1 @@ -*StoreAndForward.text max_size:237 \ No newline at end of file +*StoreAndForward.text max_size:233 \ No newline at end of file From 66e7582f85cd819008db00dbcffbb4070fe14102 Mon Sep 17 00:00:00 2001 From: Jorropo Date: Mon, 25 Nov 2024 22:57:37 +0100 Subject: [PATCH 19/41] add Routastic hardware model --- meshtastic/mesh.proto | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index b1bdd59..c806f60 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -656,6 +656,14 @@ enum HardwareModel { */ WISMESH_TAP = 84; + /* + * Similar to PORTDUINO but used by Routastic devices, this is not any + * particular device and does not run Meshtastic's code but supports + * the same frame format. + * Runs on linux, see https://github.com/Jorropo/routastic + */ + ROUTASTIC = 85; + /* * ------------------------------------------------------------------------------------------------------------------------------------------ * Reserved ID For developing private Ports. These will show up in live traffic sparsely, so we can use a high number. Keep it within 8 bits. From 55a5c9c139f8e78912b5d8748de3b0abe4ebf4fd Mon Sep 17 00:00:00 2001 From: Iris <52419539+valzzu@users.noreply.github.com> Date: Mon, 9 Dec 2024 23:51:43 +0200 Subject: [PATCH 20/41] Update mesh.proto --- meshtastic/mesh.proto | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index c806f60..f4f9bef 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -664,6 +664,14 @@ enum HardwareModel { */ ROUTASTIC = 85; + /* + * Mesh-Tab esp32 based + * https://github.com/valzzu/Mesh-Tab + */ + MESH_TAB = 86; + + + /* * ------------------------------------------------------------------------------------------------------------------------------------------ * Reserved ID For developing private Ports. These will show up in live traffic sparsely, so we can use a high number. Keep it within 8 bits. @@ -2066,4 +2074,4 @@ message ChunkedPayloadResponse { */ resend_chunks resend_chunks = 4; } -} \ No newline at end of file +} From d2cedee0a075f18111341d43a3012b32c413461e Mon Sep 17 00:00:00 2001 From: Iris <52419539+valzzu@users.noreply.github.com> Date: Mon, 9 Dec 2024 23:53:09 +0200 Subject: [PATCH 21/41] added Mesh-Tab --- meshtastic/mesh.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index f4f9bef..fc0b580 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -665,7 +665,7 @@ enum HardwareModel { ROUTASTIC = 85; /* - * Mesh-Tab esp32 based + * Mesh-Tab, esp32 based * https://github.com/valzzu/Mesh-Tab */ MESH_TAB = 86; From ae684384731b6d02b4ff4bb450ddbbb4a7ee0671 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sat, 14 Dec 2024 05:18:08 -0600 Subject: [PATCH 22/41] Add priority for new critical alert feature --- meshtastic/mesh.proto | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index fc0b580..99c267a 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1095,6 +1095,11 @@ message MeshPacket { */ HIGH = 100; + /* + * Higher priority alert message used for critical messages which take priority over other reliable packets. + */ + ALERT = 110; + /* * Ack/naks are sent with very high priority to ensure that retransmission * stops as soon as possible From 611e3994929011b254b694f80bcb54ce4c3ec084 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sat, 14 Dec 2024 05:19:25 -0600 Subject: [PATCH 23/41] Update mesh.proto --- meshtastic/mesh.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 99c267a..d03dbea 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1096,7 +1096,7 @@ message MeshPacket { HIGH = 100; /* - * Higher priority alert message used for critical messages which take priority over other reliable packets. + * Higher priority alert message used for critical alerts which take priority over other reliable packets. */ ALERT = 110; From 0c8cdc0efaada407565a80e3693851cf1339c254 Mon Sep 17 00:00:00 2001 From: Tom Fifield Date: Sun, 15 Dec 2024 11:17:53 +1100 Subject: [PATCH 24/41] Add INA226 A high accuracy current and voltage sensor --- meshtastic/telemetry.proto | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/meshtastic/telemetry.proto b/meshtastic/telemetry.proto index 69a06f7..688abf7 100644 --- a/meshtastic/telemetry.proto +++ b/meshtastic/telemetry.proto @@ -536,6 +536,11 @@ enum TelemetrySensorType { * ClimateGuard RadSens, radiation, Geiger-Muller Tube */ RADSENS = 33; + + /* + * High accuracy current and voltage + */ + INA226 = 34; } From 0f7e5625693e4f4cfafcc9d661fa584b6e8e4352 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Tue, 17 Dec 2024 06:27:43 -0600 Subject: [PATCH 25/41] Add alert app portnum --- meshtastic/portnums.proto | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/meshtastic/portnums.proto b/meshtastic/portnums.proto index 1f8cdb9..a4b55e5 100644 --- a/meshtastic/portnums.proto +++ b/meshtastic/portnums.proto @@ -105,6 +105,11 @@ enum PortNum { */ DETECTION_SENSOR_APP = 10; + /* + * Same as Text Message but used for critical alerts. + */ + ALERT_APP = 11; + /* * Provides a 'ping' service that replies to any packet it receives. * Also serves as a small example module. From c55f120a9c1ce90c85e4826907a0b9bcb2d5f5a2 Mon Sep 17 00:00:00 2001 From: Erayd Date: Mon, 23 Dec 2024 00:14:48 +1300 Subject: [PATCH 26/41] Add the ROUTER_LATE role & supporting fields (#632) Will always rebroadcast packets, but will do so after all other modes. Intended for router nodes that are there to provide additional coverage in areas not already covered by other routers, or to bridge around problematic terrain, but should not be given priority over other routers in order to avoid unnecessarily consuming hops. --- meshtastic/config.proto | 9 +++++++++ meshtastic/mesh.proto | 7 +++++++ 2 files changed, 16 insertions(+) diff --git a/meshtastic/config.proto b/meshtastic/config.proto index aaf340b..e308529 100644 --- a/meshtastic/config.proto +++ b/meshtastic/config.proto @@ -99,6 +99,15 @@ message Config { * Uses position module configuration to determine TAK PLI broadcast interval. */ TAK_TRACKER = 10; + + /* + * Description: Will always rebroadcast packets, but will do so after all other modes. + * Technical Details: Used for router nodes that are intended to provide additional coverage + * in areas not already covered by other routers, or to bridge around problematic terrain, + * but should not be given priority over other routers in order to avoid unnecessaraily + * consuming hops. + */ + ROUTER_LATE = 11; } /* diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index d03dbea..556295f 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -1272,6 +1272,13 @@ message MeshPacket { * Set by the firmware internally, clients are not supposed to set this. */ uint32 relay_node = 19; + + /* + * *Never* sent over the radio links. + * Timestamp after which this packet may be sent. + * Set by the firmware internally, clients are not supposed to set this. + */ + uint32 tx_after = 20; } /* From fe59011ba51c11638a28d24e532d3906b46f5cac Mon Sep 17 00:00:00 2001 From: mverch67 Date: Wed, 1 Jan 2025 01:28:44 +0100 Subject: [PATCH 27/41] device-ui: add channel filter, add slovenian --- meshtastic/device_ui.options | 1 + meshtastic/device_ui.proto | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/meshtastic/device_ui.options b/meshtastic/device_ui.options index 55edcae..56b684b 100644 --- a/meshtastic/device_ui.options +++ b/meshtastic/device_ui.options @@ -4,4 +4,5 @@ *DeviceUIConfig.calibration_data max_size:16 *NodeFilter.node_name max_size:16 *NodeFilter.hops_away int_size:8 +*NodeFilter.channel int_size:8 *NodeHighlight.node_name max_size:16 diff --git a/meshtastic/device_ui.proto b/meshtastic/device_ui.proto index b586fed..b704e47 100644 --- a/meshtastic/device_ui.proto +++ b/meshtastic/device_ui.proto @@ -100,6 +100,11 @@ message NodeFilter { */ string node_name = 6; + /* + * Filter based on channel + */ + int32 channel = 7; + } message NodeHighlight { @@ -224,6 +229,11 @@ enum Language { */ NORWEGIAN = 14; + /* + * Slovenian + */ + SLOVENIAN = 15; + /* * Simplified Chinese (experimental) */ From b77d1a3bb744e741b73225bb7e4d1b68851b730d Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sun, 5 Jan 2025 12:57:01 -0600 Subject: [PATCH 28/41] Add protocol flags to enable UDP broadcasts and other future local networking transports --- meshtastic/config.proto | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/meshtastic/config.proto b/meshtastic/config.proto index e308529..20334a9 100644 --- a/meshtastic/config.proto +++ b/meshtastic/config.proto @@ -515,6 +515,26 @@ message Config { * rsyslog Server and Port */ string rsyslog_server = 9; + + /* + * Flags for enabling/disabling network protocols + */ + uint32 enabled_protocols = 10; + + /* + * Available flags auxiliary network protocols + */ + enum ProtocolFlags { + /* + * Do not broadcast packets over any network protocol + */ + NO_BROADCAST = 0x0000; + + /* + * Enable broadcasting packets via UDP over the local network + */ + UDP_BROADCAST = 0x0001; + } } /* @@ -1113,4 +1133,4 @@ message Config { SessionkeyConfig sessionkey = 9; DeviceUIConfig device_ui = 10; } -} +} \ No newline at end of file From 9c1bf5b384cf6a4bc34b019a468f59fb779bf35d Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Tue, 7 Jan 2025 19:29:16 -0600 Subject: [PATCH 29/41] Move nodedb to it's own message (and file) --- meshtastic/deviceonly.proto | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/meshtastic/deviceonly.proto b/meshtastic/deviceonly.proto index c506137..8bb4603 100644 --- a/meshtastic/deviceonly.proto +++ b/meshtastic/deviceonly.proto @@ -220,11 +220,20 @@ message DeviceState { * The mesh's nodes with their available gpio pins for RemoteHardware module */ repeated NodeRemoteHardwarePin node_remote_hardware_pins = 13; +} + +message NodeDatabase { + /* + * A version integer used to invalidate old save files when we make + * incompatible changes This integer is set at build time and is private to + * NodeDB.cpp in the device code. + */ + uint32 version = 1; /* * New lite version of NodeDB to decrease memory footprint */ - repeated NodeInfoLite node_db_lite = 14 [(nanopb).callback_datatype = "std::vector"]; + repeated NodeInfoLite nodes = 2 [(nanopb).callback_datatype = "std::vector"]; } /* From fde27e4ef0fcee967063ba353422ed5f9a1c4790 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Sat, 18 Jan 2025 13:30:43 +0100 Subject: [PATCH 30/41] add dfrobot gravity rain gauge (#646) --- meshtastic/telemetry.proto | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/meshtastic/telemetry.proto b/meshtastic/telemetry.proto index 688abf7..4b5b3f2 100644 --- a/meshtastic/telemetry.proto +++ b/meshtastic/telemetry.proto @@ -134,6 +134,16 @@ message EnvironmentMetrics { */ optional float radiation = 18; + /* + * Rainfall in the last hour in mm + */ + optional float rainfall_1h = 19; + + /* + * Rainfall in the last 24 hours in mm + */ + optional float rainfall_24h = 20; + } /* @@ -542,6 +552,11 @@ enum TelemetrySensorType { */ INA226 = 34; + /* + * DFRobot Gravity tipping bucket rain gauge + */ + DFROBOT_RAIN = 35; + } /* From 7f13df0e5f7cbb07f0e6f3a57c0d86ad448738db Mon Sep 17 00:00:00 2001 From: A_Ponzano Date: Sun, 19 Jan 2025 15:07:06 +0100 Subject: [PATCH 31/41] Update mesh.proto with meshlink (#644) --- meshtastic/mesh.proto | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 556295f..502e65a 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -670,6 +670,11 @@ enum HardwareModel { */ MESH_TAB = 86; + /* + * MeshLink board developed by LoraItalia. NRF52840, eByte E22900M22S (Will also come with other frequencies), 25w MPPT solar charger (5v,12v,18v selectable), support for gps, buzzer, oled or e-ink display, 10 gpios, hardware watchdog + * https://www.loraitalia.it + */ + MESHLINK = 87; /* From edc3a7bab55bcad7c32d5a6fc71a76053ef2a00a Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Fri, 31 Jan 2025 20:09:19 -0600 Subject: [PATCH 32/41] Add 12 hour clock device display config --- meshtastic/config.proto | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/meshtastic/config.proto b/meshtastic/config.proto index 20334a9..95eb13e 100644 --- a/meshtastic/config.proto +++ b/meshtastic/config.proto @@ -743,6 +743,12 @@ message Config { * Indicates how to rotate or invert the compass output to accurate display on the display. */ CompassOrientation compass_orientation = 11; + + /* + * If false (default), the device will display the time in 24-hour format on screen. + * If true, the device will display the time in 12-hour format on screen. + */ + bool use_12h_clock = 12; } /* From 068646653e8375fc145988026ad242a3cf70f7ab Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Mon, 10 Feb 2025 14:28:21 -0600 Subject: [PATCH 33/41] Comment --- meshtastic/module_config.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshtastic/module_config.proto b/meshtastic/module_config.proto index 040b604..aa30abc 100644 --- a/meshtastic/module_config.proto +++ b/meshtastic/module_config.proto @@ -603,7 +603,7 @@ message ModuleConfig { } /* - * TODO: REPLACE + * Canned Messages Module Config */ message CannedMessageConfig { /* From 7f45a7e8d925ca24b6462ee292dbef61090f3019 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Tue, 11 Feb 2025 06:01:02 -0600 Subject: [PATCH 34/41] Decrease MQTT password size --- meshtastic/module_config.options | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshtastic/module_config.options b/meshtastic/module_config.options index fdde1b3..bf2a5f4 100644 --- a/meshtastic/module_config.options +++ b/meshtastic/module_config.options @@ -2,7 +2,7 @@ *MQTTConfig.address max_size:64 *MQTTConfig.username max_size:64 -*MQTTConfig.password max_size:64 +*MQTTConfig.password max_size:32 *MQTTConfig.root max_size:32 *AudioConfig.ptt_pin int_size:8 From ff6fce923a24c4a26164143c236e237435fe6c76 Mon Sep 17 00:00:00 2001 From: Tom Fifield Date: Sat, 22 Feb 2025 18:05:58 +0800 Subject: [PATCH 35/41] Deprecate did_gps_reset Removed in: https://github.com/meshtastic/firmware/pull/6116 --- meshtastic/deviceonly.proto | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/meshtastic/deviceonly.proto b/meshtastic/deviceonly.proto index c506137..65d4f95 100644 --- a/meshtastic/deviceonly.proto +++ b/meshtastic/deviceonly.proto @@ -205,9 +205,10 @@ message DeviceState { bool no_save = 9 [deprecated = true]; /* - * Some GPS receivers seem to have bogus settings from the factory, so we always do one factory reset. + * Previously used to manage GPS factory resets. + * Deprecated in 2.5.23 */ - bool did_gps_reset = 11; + bool did_gps_reset = 11 [deprecated = true]; /* * We keep the last received waypoint stored in the device flash, @@ -242,4 +243,4 @@ message ChannelFile { * NodeDB.cpp in the device code. */ uint32 version = 2; -} \ No newline at end of file +} From 91f73d032691008cae84965a6b3e733d0da2ed4f Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sun, 23 Feb 2025 06:25:35 -0600 Subject: [PATCH 36/41] Add container messages for backup prefs --- meshtastic/deviceonly.proto | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/meshtastic/deviceonly.proto b/meshtastic/deviceonly.proto index 8bb4603..43ecb0e 100644 --- a/meshtastic/deviceonly.proto +++ b/meshtastic/deviceonly.proto @@ -6,6 +6,7 @@ import "meshtastic/channel.proto"; import "meshtastic/mesh.proto"; import "meshtastic/telemetry.proto"; import "meshtastic/config.proto"; +import "meshtastic/localonly.proto"; import "nanopb.proto"; option csharp_namespace = "Meshtastic.Protobufs"; @@ -251,4 +252,34 @@ message ChannelFile { * NodeDB.cpp in the device code. */ uint32 version = 2; +} + +/* + * The on-disk backup of the node's preferences + */ + message BackupPrefs { + /* + * The version of the backup + */ + uint32 version = 1; + + /* + * The node's configuration + */ + LocalConfig config = 2; + + /* + * The node's module configuration + */ + LocalModuleConfig module_config = 3; + + /* + * The node's channels + */ + ChannelFile channels = 4; + + /* + * The node's user (owner) information + */ + User owner = 5; } \ No newline at end of file From 8b87eac4db0899d54eb11501b2a1ac76cefad6ec Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sun, 23 Feb 2025 06:52:34 -0600 Subject: [PATCH 37/41] Name --- meshtastic/deviceonly.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshtastic/deviceonly.proto b/meshtastic/deviceonly.proto index 43ecb0e..bb57843 100644 --- a/meshtastic/deviceonly.proto +++ b/meshtastic/deviceonly.proto @@ -257,7 +257,7 @@ message ChannelFile { /* * The on-disk backup of the node's preferences */ - message BackupPrefs { + message BackupPreferences { /* * The version of the backup */ From 2a1386b151fb379f718d51ead179960e7ab8394a Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sun, 23 Feb 2025 08:42:31 -0600 Subject: [PATCH 38/41] Admin messages --- meshtastic/admin.proto | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/meshtastic/admin.proto b/meshtastic/admin.proto index 809d7c6..6cfe6dc 100644 --- a/meshtastic/admin.proto +++ b/meshtastic/admin.proto @@ -154,6 +154,18 @@ message AdminMessage { PAXCOUNTER_CONFIG = 12; } + enum BackupLocation { + /* + * Backup to the internal flash + */ + FLASH = 0; + + /* + * Backup to the SD card + */ + SD = 1; + } + /* * TODO: REPLACE */ @@ -270,6 +282,16 @@ message AdminMessage { */ uint32 set_scale = 23; + /* + * Backup the node's preferences + */ + BackupLocation backup_preferences = 24; + + /* + * Restore the node's preferences + */ + BackupLocation restore_preferences = 25; + /* * Set the owner for this node */ From f3a57add1ae4be78af0b74fa97f4bf03cc34890d Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sun, 23 Feb 2025 13:06:21 -0600 Subject: [PATCH 39/41] Timestamp --- meshtastic/deviceonly.proto | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/meshtastic/deviceonly.proto b/meshtastic/deviceonly.proto index 16ab020..481bfba 100644 --- a/meshtastic/deviceonly.proto +++ b/meshtastic/deviceonly.proto @@ -264,23 +264,28 @@ message ChannelFile { */ uint32 version = 1; + /* + * The timestamp of the backup (if node has time) + */ + fixed32 timestamp = 2; + /* * The node's configuration */ - LocalConfig config = 2; + LocalConfig config = 3; /* * The node's module configuration */ - LocalModuleConfig module_config = 3; + LocalModuleConfig module_config = 4; /* * The node's channels */ - ChannelFile channels = 4; + ChannelFile channels = 5; /* * The node's user (owner) information */ - User owner = 5; + User owner = 6; } \ No newline at end of file From 2f6a133037310b0c8549b3f63dd76880a2b81fab Mon Sep 17 00:00:00 2001 From: mverch67 Date: Tue, 25 Feb 2025 00:20:33 +0100 Subject: [PATCH 40/41] map persistent UI data --- meshtastic/device_ui.options | 2 ++ meshtastic/device_ui.proto | 39 ++++++++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+) diff --git a/meshtastic/device_ui.options b/meshtastic/device_ui.options index 56b684b..5aa61d0 100644 --- a/meshtastic/device_ui.options +++ b/meshtastic/device_ui.options @@ -6,3 +6,5 @@ *NodeFilter.hops_away int_size:8 *NodeFilter.channel int_size:8 *NodeHighlight.node_name max_size:16 +*GeoPoint.zoom int_size:8 +*Map.style max_size:20 diff --git a/meshtastic/device_ui.proto b/meshtastic/device_ui.proto index b704e47..9ac40a3 100644 --- a/meshtastic/device_ui.proto +++ b/meshtastic/device_ui.proto @@ -66,6 +66,11 @@ message DeviceUIConfig { * 8 integers for screen calibration data */ bytes calibration_data = 14; + + /* + * Map related data + */ + Map map_data = 15; } @@ -135,6 +140,40 @@ message NodeHighlight { } +message GeoPoint { + /* + * Zoom level + */ + int32 zoom = 1; + + /* + * Coordinate: latitude + */ + int32 latitude = 2; + + /* + * Coordinate: longitude + */ + int32 longitude = 3; +} + +message Map { + /* + * Home coordinates + */ + GeoPoint home = 1; + + /* + * Map tile style + */ + string style = 2; + + /* + * Map scroll follows GPS + */ + bool follow_gps = 3; +} + enum Theme { /* * Dark From 79298fcdf04c1e680f5abd875233394f44ddaf7a Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Tue, 25 Feb 2025 07:26:25 -0600 Subject: [PATCH 41/41] Add remove_backup_preferences --- meshtastic/admin.proto | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/meshtastic/admin.proto b/meshtastic/admin.proto index 6cfe6dc..e9691ed 100644 --- a/meshtastic/admin.proto +++ b/meshtastic/admin.proto @@ -292,6 +292,10 @@ message AdminMessage { */ BackupLocation restore_preferences = 25; + /* + * Remove backups of the node's preferences + */ + BackupLocation remove_backup_preferences = 26; /* * Set the owner for this node */