Protobuf bump

This commit is contained in:
Jonathan Bennett
2024-02-22 13:41:43 -06:00
parent 0153daa8ba
commit 790f100620
8 changed files with 50 additions and 24 deletions
+29 -5
View File
@@ -30,6 +30,12 @@ typedef enum _meshtastic_Channel_Role {
} meshtastic_Channel_Role;
/* Struct definitions */
/* This message is specifically for modules to store per-channel configuration data. */
typedef struct _meshtastic_ModuleSettings {
/* Bits of precision for the location sent in position packets. */
uint32_t position_precision;
} meshtastic_ModuleSettings;
typedef PB_BYTES_ARRAY_T(32) meshtastic_ChannelSettings_psk_t;
/* This information can be encoded as a QRcode/url so that other users can configure
their radio to join the same channel.
@@ -85,6 +91,9 @@ typedef struct _meshtastic_ChannelSettings {
bool uplink_enabled;
/* If true, messages seen on the internet will be forwarded to the local mesh. */
bool downlink_enabled;
/* Per-channel module settings. */
bool has_module_settings;
meshtastic_ModuleSettings module_settings;
} meshtastic_ChannelSettings;
/* A pair of a channel number, mode and the (sharable) settings for that channel */
@@ -111,22 +120,27 @@ extern "C" {
#define _meshtastic_Channel_Role_ARRAYSIZE ((meshtastic_Channel_Role)(meshtastic_Channel_Role_SECONDARY+1))
#define meshtastic_Channel_role_ENUMTYPE meshtastic_Channel_Role
/* Initializer values for message structs */
#define meshtastic_ChannelSettings_init_default {0, {0, {0}}, "", 0, 0, 0}
#define meshtastic_ChannelSettings_init_default {0, {0, {0}}, "", 0, 0, 0, false, meshtastic_ModuleSettings_init_default}
#define meshtastic_ModuleSettings_init_default {0}
#define meshtastic_Channel_init_default {0, false, meshtastic_ChannelSettings_init_default, _meshtastic_Channel_Role_MIN}
#define meshtastic_ChannelSettings_init_zero {0, {0, {0}}, "", 0, 0, 0}
#define meshtastic_ChannelSettings_init_zero {0, {0, {0}}, "", 0, 0, 0, false, meshtastic_ModuleSettings_init_zero}
#define meshtastic_ModuleSettings_init_zero {0}
#define meshtastic_Channel_init_zero {0, false, meshtastic_ChannelSettings_init_zero, _meshtastic_Channel_Role_MIN}
/* Field tags (for use in manual encoding/decoding) */
#define meshtastic_ModuleSettings_position_precision_tag 1
#define meshtastic_ChannelSettings_channel_num_tag 1
#define meshtastic_ChannelSettings_psk_tag 2
#define meshtastic_ChannelSettings_name_tag 3
#define meshtastic_ChannelSettings_id_tag 4
#define meshtastic_ChannelSettings_uplink_enabled_tag 5
#define meshtastic_ChannelSettings_downlink_enabled_tag 6
#define meshtastic_ChannelSettings_module_settings_tag 7
#define meshtastic_Channel_index_tag 1
#define meshtastic_Channel_settings_tag 2
#define meshtastic_Channel_role_tag 3
@@ -138,9 +152,16 @@ X(a, STATIC, SINGULAR, BYTES, psk, 2) \
X(a, STATIC, SINGULAR, STRING, name, 3) \
X(a, STATIC, SINGULAR, FIXED32, id, 4) \
X(a, STATIC, SINGULAR, BOOL, uplink_enabled, 5) \
X(a, STATIC, SINGULAR, BOOL, downlink_enabled, 6)
X(a, STATIC, SINGULAR, BOOL, downlink_enabled, 6) \
X(a, STATIC, OPTIONAL, MESSAGE, module_settings, 7)
#define meshtastic_ChannelSettings_CALLBACK NULL
#define meshtastic_ChannelSettings_DEFAULT NULL
#define meshtastic_ChannelSettings_module_settings_MSGTYPE meshtastic_ModuleSettings
#define meshtastic_ModuleSettings_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, UINT32, position_precision, 1)
#define meshtastic_ModuleSettings_CALLBACK NULL
#define meshtastic_ModuleSettings_DEFAULT NULL
#define meshtastic_Channel_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, INT32, index, 1) \
@@ -151,15 +172,18 @@ X(a, STATIC, SINGULAR, UENUM, role, 3)
#define meshtastic_Channel_settings_MSGTYPE meshtastic_ChannelSettings
extern const pb_msgdesc_t meshtastic_ChannelSettings_msg;
extern const pb_msgdesc_t meshtastic_ModuleSettings_msg;
extern const pb_msgdesc_t meshtastic_Channel_msg;
/* Defines for backwards compatibility with code written before nanopb-0.4.0 */
#define meshtastic_ChannelSettings_fields &meshtastic_ChannelSettings_msg
#define meshtastic_ModuleSettings_fields &meshtastic_ModuleSettings_msg
#define meshtastic_Channel_fields &meshtastic_Channel_msg
/* Maximum encoded size of messages (where known) */
#define meshtastic_ChannelSettings_size 62
#define meshtastic_Channel_size 77
#define meshtastic_ChannelSettings_size 70
#define meshtastic_Channel_size 85
#define meshtastic_ModuleSettings_size 6
#ifdef __cplusplus
} /* extern "C" */