From 30eb05a8a97a216d602e50b3c38d6086ba52cd5d Mon Sep 17 00:00:00 2001 From: Jonathan Bennett Date: Wed, 4 Sep 2024 14:30:54 -0500 Subject: [PATCH 1/2] Adds OKToMqtt bool to data --- meshtastic/mesh.proto | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 23d2b9c9..4dfdac03 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -888,6 +888,11 @@ message Data { * a message a heart or poop emoji. */ fixed32 emoji = 8; + + /* + * Defaults to false. Indicates the user approves the packet being uploaded to MQTT. + */ + bool OKToMqtt = 9; } /* @@ -1889,4 +1894,4 @@ message ChunkedPayloadResponse { */ resend_chunks resend_chunks = 4; } -} \ No newline at end of file +} From fce5ab584fecd0113d168e792af894b8b63afb1a Mon Sep 17 00:00:00 2001 From: Jonathan Bennett Date: Fri, 6 Sep 2024 11:57:23 -0500 Subject: [PATCH 2/2] Rename ok_to_mqtt and add config --- meshtastic/config.proto | 7 ++++++- meshtastic/mesh.proto | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/meshtastic/config.proto b/meshtastic/config.proto index 66d149f0..0ad0b26e 100644 --- a/meshtastic/config.proto +++ b/meshtastic/config.proto @@ -973,6 +973,11 @@ message Config { * If true, the device will not process any packets received via LoRa that passed via MQTT anywhere on the path towards it. */ bool ignore_mqtt = 104; + + /* + * Sets the ok_to_mqtt bit on outgoing packets + */ + bool config_ok_to_mqtt = 105; } message BluetoothConfig { @@ -1070,4 +1075,4 @@ message Config { SecurityConfig security = 8; SessionkeyConfig sessionkey = 9; } -} \ No newline at end of file +} diff --git a/meshtastic/mesh.proto b/meshtastic/mesh.proto index 4dfdac03..ed2e3aa6 100644 --- a/meshtastic/mesh.proto +++ b/meshtastic/mesh.proto @@ -892,7 +892,7 @@ message Data { /* * Defaults to false. Indicates the user approves the packet being uploaded to MQTT. */ - bool OKToMqtt = 9; + optional bool ok_to_mqtt = 9; } /*