Skip to content

Commit 2d25ac5

Browse files
committed
Compress NodeInfoLite bools into a bitfield
1 parent b4044f8 commit 2d25ac5

File tree

1 file changed

+8
-15
lines changed

1 file changed

+8
-15
lines changed

meshtastic/deviceonly.proto

Lines changed: 8 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -134,31 +134,24 @@ message NodeInfoLite {
134134
uint32 channel = 7;
135135

136136
/*
137-
* True if we witnessed the node over MQTT instead of LoRA transport
137+
* Bitfield to contain 8 1-bit boolean values.
138+
* 0 - via_mqtt: True if we witnessed the node over MQTT instead of LoRA transport
139+
* 1 - is_favorite: True if node is in our favorites list
140+
* Persists between NodeDB internal clean ups
141+
* 2 - is_ignored: True if node is in our ignored list
142+
* Persists between NodeDB internal clean ups
138143
*/
139-
bool via_mqtt = 8;
144+
uint32 bitfield = 8;
140145

141146
/*
142147
* Number of hops away from us this node is (0 if direct neighbor)
143148
*/
144149
optional uint32 hops_away = 9;
145150

146-
/*
147-
* True if node is in our favorites list
148-
* Persists between NodeDB internal clean ups
149-
*/
150-
bool is_favorite = 10;
151-
152-
/*
153-
* True if node is in our ignored list
154-
* Persists between NodeDB internal clean ups
155-
*/
156-
bool is_ignored = 11;
157-
158151
/*
159152
* Last byte of the node number of the node that should be used as the next hop to reach this node.
160153
*/
161-
uint32 next_hop = 12;
154+
uint32 next_hop = 10;
162155
}
163156

164157
/*

0 commit comments

Comments
 (0)