Finish config transition

This commit is contained in:
Sacha Weatherstone
2022-05-07 20:31:21 +10:00
parent c07976438b
commit 6b0ce6b729
55 changed files with 1417 additions and 2027 deletions

View File

@@ -6,7 +6,7 @@
#error Regenerate this file with the current version of nanopb generator.
#endif
PB_BIND(AdminMessage, AdminMessage, 2)
PB_BIND(AdminMessage, AdminMessage, AUTO)

View File

@@ -8,7 +8,6 @@
#include "config.pb.h"
#include "mesh.pb.h"
#include "module_config.pb.h"
#include "radioconfig.pb.h"
#if PB_PROTO_HEADER_VERSION != 40
#error Regenerate this file with the current version of nanopb generator.
@@ -17,7 +16,7 @@
/* Enum definitions */
typedef enum _AdminMessage_ConfigType {
AdminMessage_ConfigType_DEVICE_CONFIG = 0,
AdminMessage_ConfigType_GPS_CONFIG = 1,
AdminMessage_ConfigType_POSITION_CONFIG = 1,
AdminMessage_ConfigType_POWER_CONFIG = 2,
AdminMessage_ConfigType_WIFI_CONFIG = 3,
AdminMessage_ConfigType_DISPLAY_CONFIG = 4,
@@ -39,14 +38,11 @@ typedef enum _AdminMessage_ModuleConfigType {
This message is used to do settings operations to both remote AND local nodes.
(Prior to 1.2 these operations were done via special ToRadio operations) */
typedef struct _AdminMessage {
/* Set the radio provisioning for this node */
/* Set the owner for this node */
pb_size_t which_variant;
union {
RadioConfig set_radio;
User set_owner;
Channel set_channel;
bool get_radio_request;
RadioConfig get_radio_response;
uint32_t get_channel_request;
Channel get_channel_response;
bool get_owner_request;
@@ -95,15 +91,12 @@ extern "C" {
#endif
/* Initializer values for message structs */
#define AdminMessage_init_default {0, {RadioConfig_init_default}}
#define AdminMessage_init_zero {0, {RadioConfig_init_zero}}
#define AdminMessage_init_default {0, {User_init_default}}
#define AdminMessage_init_zero {0, {User_init_zero}}
/* Field tags (for use in manual encoding/decoding) */
#define AdminMessage_set_radio_tag 1
#define AdminMessage_set_owner_tag 2
#define AdminMessage_set_channel_tag 3
#define AdminMessage_get_radio_request_tag 4
#define AdminMessage_get_radio_response_tag 5
#define AdminMessage_get_channel_request_tag 6
#define AdminMessage_get_channel_response_tag 7
#define AdminMessage_get_owner_request_tag 8
@@ -136,11 +129,8 @@ extern "C" {
/* Struct field encoding specification for nanopb */
#define AdminMessage_FIELDLIST(X, a) \
X(a, STATIC, ONEOF, MESSAGE, (variant,set_radio,set_radio), 1) \
X(a, STATIC, ONEOF, MESSAGE, (variant,set_owner,set_owner), 2) \
X(a, STATIC, ONEOF, MESSAGE, (variant,set_channel,set_channel), 3) \
X(a, STATIC, ONEOF, BOOL, (variant,get_radio_request,get_radio_request), 4) \
X(a, STATIC, ONEOF, MESSAGE, (variant,get_radio_response,get_radio_response), 5) \
X(a, STATIC, ONEOF, UINT32, (variant,get_channel_request,get_channel_request), 6) \
X(a, STATIC, ONEOF, MESSAGE, (variant,get_channel_response,get_channel_response), 7) \
X(a, STATIC, ONEOF, BOOL, (variant,get_owner_request,get_owner_request), 8) \
@@ -172,10 +162,8 @@ X(a, STATIC, ONEOF, STRING, (variant,set_canned_message_module_part4,set_
X(a, STATIC, ONEOF, INT32, (variant,shutdown_seconds,shutdown_seconds), 51)
#define AdminMessage_CALLBACK NULL
#define AdminMessage_DEFAULT NULL
#define AdminMessage_variant_set_radio_MSGTYPE RadioConfig
#define AdminMessage_variant_set_owner_MSGTYPE User
#define AdminMessage_variant_set_channel_MSGTYPE Channel
#define AdminMessage_variant_get_radio_response_MSGTYPE RadioConfig
#define AdminMessage_variant_get_channel_response_MSGTYPE Channel
#define AdminMessage_variant_get_owner_response_MSGTYPE User
#define AdminMessage_variant_get_config_response_MSGTYPE Config
@@ -189,10 +177,7 @@ extern const pb_msgdesc_t AdminMessage_msg;
#define AdminMessage_fields &AdminMessage_msg
/* Maximum encoded size of messages (where known) */
#if defined(Config_size) && defined(Config_size)
#define AdminMessage_size (0 + sizeof(union AdminMessage_variant_size_union))
union AdminMessage_variant_size_union {char f0[551]; char f11[(6 + Config_size)]; char f12[(6 + Config_size)];};
#endif
#define AdminMessage_size 204
#ifdef __cplusplus
} /* extern "C" */

View File

@@ -75,7 +75,7 @@ typedef struct _ChannelSettings {
is the special (minimally secure) "Default"channel.
In user interfaces it should be rendered as a local language translation of "X".
For channel_num hashing empty string will be treated as "X".
Where "X" is selected based on the English words listed above for ModemConfig */
Where "X" is selected based on the English words listed above for ModemPreset */
uint8_t channel_num;
/* Used to construct a globally unique channel ID.
The full globally unique ID will be: "name.id" where ID is shown as base36.

View File

@@ -12,7 +12,7 @@ PB_BIND(Config, Config, AUTO)
PB_BIND(Config_DeviceConfig, Config_DeviceConfig, AUTO)
PB_BIND(Config_GpsConfig, Config_GpsConfig, AUTO)
PB_BIND(Config_PositionConfig, Config_PositionConfig, AUTO)
PB_BIND(Config_PowerConfig, Config_PowerConfig, AUTO)
@@ -24,31 +24,12 @@ PB_BIND(Config_WiFiConfig, Config_WiFiConfig, AUTO)
PB_BIND(Config_DisplayConfig, Config_DisplayConfig, AUTO)
PB_BIND(Config_LoRaConfig, Config_LoRaConfig, AUTO)
PB_BIND(Config_ModuleConfig, Config_ModuleConfig, AUTO)
PB_BIND(Config_ModuleConfig_MQTTConfig, Config_ModuleConfig_MQTTConfig, AUTO)
PB_BIND(Config_ModuleConfig_SerialConfig, Config_ModuleConfig_SerialConfig, AUTO)
PB_BIND(Config_ModuleConfig_ExternalNotificationConfig, Config_ModuleConfig_ExternalNotificationConfig, AUTO)
PB_BIND(Config_ModuleConfig_StoreForwardConfig, Config_ModuleConfig_StoreForwardConfig, AUTO)
PB_BIND(Config_ModuleConfig_RangeTestConfig, Config_ModuleConfig_RangeTestConfig, AUTO)
PB_BIND(Config_ModuleConfig_TelemetryConfig, Config_ModuleConfig_TelemetryConfig, AUTO)
PB_BIND(Config_ModuleConfig_CannedMessageConfig, Config_ModuleConfig_CannedMessageConfig, AUTO)
PB_BIND(Config_LoRaConfig, Config_LoRaConfig, 2)

View File

@@ -11,115 +11,181 @@
#endif
/* Enum definitions */
typedef enum _Config_LoRaConfig_ModemConfig {
Config_LoRaConfig_ModemConfig_VLongSlow = 0,
Config_LoRaConfig_ModemConfig_LongSlow = 1,
Config_LoRaConfig_ModemConfig_LongFast = 2,
Config_LoRaConfig_ModemConfig_MidSlow = 3,
Config_LoRaConfig_ModemConfig_MidFast = 4,
Config_LoRaConfig_ModemConfig_ShortSlow = 5,
Config_LoRaConfig_ModemConfig_ShortFast = 6
} Config_LoRaConfig_ModemConfig;
typedef enum _Config_DeviceConfig_Role {
Config_DeviceConfig_Role_Client = 0,
Config_DeviceConfig_Role_ClientMute = 1,
Config_DeviceConfig_Role_Router = 2,
Config_DeviceConfig_Role_RouterClient = 3
} Config_DeviceConfig_Role;
typedef enum _Config_PositionConfig_PositionFlags {
Config_PositionConfig_PositionFlags_POS_UNDEFINED = 0,
Config_PositionConfig_PositionFlags_POS_ALTITUDE = 1,
Config_PositionConfig_PositionFlags_POS_ALT_MSL = 2,
Config_PositionConfig_PositionFlags_POS_GEO_SEP = 4,
Config_PositionConfig_PositionFlags_POS_DOP = 8,
Config_PositionConfig_PositionFlags_POS_HVDOP = 16,
Config_PositionConfig_PositionFlags_POS_BATTERY = 32,
Config_PositionConfig_PositionFlags_POS_SATINVIEW = 64,
Config_PositionConfig_PositionFlags_POS_SEQ_NOS = 128,
Config_PositionConfig_PositionFlags_POS_TIMESTAMP = 256
} Config_PositionConfig_PositionFlags;
typedef enum _Config_PowerConfig_ChargeCurrent {
Config_PowerConfig_ChargeCurrent_MAUnset = 0,
Config_PowerConfig_ChargeCurrent_MA100 = 1,
Config_PowerConfig_ChargeCurrent_MA190 = 2,
Config_PowerConfig_ChargeCurrent_MA280 = 3,
Config_PowerConfig_ChargeCurrent_MA360 = 4,
Config_PowerConfig_ChargeCurrent_MA450 = 5,
Config_PowerConfig_ChargeCurrent_MA550 = 6,
Config_PowerConfig_ChargeCurrent_MA630 = 7,
Config_PowerConfig_ChargeCurrent_MA700 = 8,
Config_PowerConfig_ChargeCurrent_MA780 = 9,
Config_PowerConfig_ChargeCurrent_MA880 = 10,
Config_PowerConfig_ChargeCurrent_MA960 = 11,
Config_PowerConfig_ChargeCurrent_MA1000 = 12,
Config_PowerConfig_ChargeCurrent_MA1080 = 13,
Config_PowerConfig_ChargeCurrent_MA1160 = 14,
Config_PowerConfig_ChargeCurrent_MA1240 = 15,
Config_PowerConfig_ChargeCurrent_MA1320 = 16
} Config_PowerConfig_ChargeCurrent;
typedef enum _Config_DisplayConfig_GpsCoordinateFormat {
Config_DisplayConfig_GpsCoordinateFormat_GpsFormatDec = 0,
Config_DisplayConfig_GpsCoordinateFormat_GpsFormatDMS = 1,
Config_DisplayConfig_GpsCoordinateFormat_GpsFormatUTM = 2,
Config_DisplayConfig_GpsCoordinateFormat_GpsFormatMGRS = 3,
Config_DisplayConfig_GpsCoordinateFormat_GpsFormatOLC = 4,
Config_DisplayConfig_GpsCoordinateFormat_GpsFormatOSGR = 5
} Config_DisplayConfig_GpsCoordinateFormat;
typedef enum _Config_LoRaConfig_RegionCode {
Config_LoRaConfig_RegionCode_Unset = 0,
Config_LoRaConfig_RegionCode_US = 1,
Config_LoRaConfig_RegionCode_EU433 = 2,
Config_LoRaConfig_RegionCode_EU868 = 3,
Config_LoRaConfig_RegionCode_CN = 4,
Config_LoRaConfig_RegionCode_JP = 5,
Config_LoRaConfig_RegionCode_ANZ = 6,
Config_LoRaConfig_RegionCode_KR = 7,
Config_LoRaConfig_RegionCode_TW = 8,
Config_LoRaConfig_RegionCode_RU = 9,
Config_LoRaConfig_RegionCode_IN = 10,
Config_LoRaConfig_RegionCode_NZ865 = 11,
Config_LoRaConfig_RegionCode_TH = 12
} Config_LoRaConfig_RegionCode;
typedef enum _Config_LoRaConfig_ModemPreset {
Config_LoRaConfig_ModemPreset_VLongSlow = 0,
Config_LoRaConfig_ModemPreset_LongSlow = 1,
Config_LoRaConfig_ModemPreset_LongFast = 2,
Config_LoRaConfig_ModemPreset_MidSlow = 3,
Config_LoRaConfig_ModemPreset_MidFast = 4,
Config_LoRaConfig_ModemPreset_ShortSlow = 5,
Config_LoRaConfig_ModemPreset_ShortFast = 6
} Config_LoRaConfig_ModemPreset;
/* Struct definitions */
typedef struct _Config_DeviceConfig {
char dummy_field;
Config_DeviceConfig_Role role;
bool serial_disabled;
bool factory_reset;
bool debug_log_enabled;
} Config_DeviceConfig;
typedef struct _Config_DisplayConfig {
char dummy_field;
uint32_t screen_on_secs;
Config_DisplayConfig_GpsCoordinateFormat gps_format;
uint32_t auto_screen_carousel_secs;
} Config_DisplayConfig;
typedef struct _Config_GpsConfig {
char dummy_field;
} Config_GpsConfig;
typedef struct _Config_ModuleConfig_CannedMessageConfig {
char dummy_field;
} Config_ModuleConfig_CannedMessageConfig;
typedef struct _Config_ModuleConfig_ExternalNotificationConfig {
char dummy_field;
} Config_ModuleConfig_ExternalNotificationConfig;
typedef struct _Config_ModuleConfig_MQTTConfig {
char dummy_field;
} Config_ModuleConfig_MQTTConfig;
typedef struct _Config_ModuleConfig_RangeTestConfig {
char dummy_field;
} Config_ModuleConfig_RangeTestConfig;
typedef struct _Config_ModuleConfig_SerialConfig {
char dummy_field;
} Config_ModuleConfig_SerialConfig;
typedef struct _Config_ModuleConfig_StoreForwardConfig {
char dummy_field;
} Config_ModuleConfig_StoreForwardConfig;
typedef struct _Config_PowerConfig {
char dummy_field;
} Config_PowerConfig;
typedef struct _Config_LoRaConfig {
int32_t tx_power;
Config_LoRaConfig_ModemConfig modem_config;
Config_LoRaConfig_ModemPreset modem_preset;
uint32_t bandwidth;
uint32_t spread_factor;
uint32_t coding_rate;
float frequency_offset;
Config_LoRaConfig_RegionCode region;
uint32_t hop_limit;
bool tx_disabled;
pb_size_t ignore_incoming_count;
uint32_t ignore_incoming[3];
} Config_LoRaConfig;
typedef struct _Config_ModuleConfig_TelemetryConfig {
uint32_t device_update_interval;
uint32_t environment_update_interval;
bool environment_measurement_enabled;
bool environment_screen_enabled;
uint32_t environment_read_error_count_threshold;
uint32_t environment_recovery_interval;
bool environment_display_fahrenheit;
TelemetrySensorType environment_sensor_type;
uint32_t environment_sensor_pin;
} Config_ModuleConfig_TelemetryConfig;
typedef struct _Config_PositionConfig {
uint32_t position_broadcast_secs;
bool position_broadcast_smart_disabled;
bool fixed_position;
bool location_share_disabled;
bool gps_disabled;
uint32_t gps_update_interval;
uint32_t gps_attempt_time;
bool gps_accept_2d;
uint32_t gps_max_dop;
uint32_t position_flags;
} Config_PositionConfig;
typedef struct _Config_PowerConfig {
Config_PowerConfig_ChargeCurrent charge_current;
bool is_low_power;
bool is_always_powered;
uint32_t on_battery_shutdown_after_secs;
bool is_power_saving;
float adc_multiplier_override;
uint32_t wait_bluetooth_secs;
uint32_t phone_timeout_secs;
uint32_t mesh_sds_timeout_secs;
uint32_t sds_secs;
uint32_t ls_secs;
uint32_t min_wake_secs;
} Config_PowerConfig;
typedef struct _Config_WiFiConfig {
pb_callback_t wifi_ssid;
pb_callback_t wifi_password;
bool wifi_ap_mode;
char ssid[33];
char psk[64];
bool ap_mode;
} Config_WiFiConfig;
typedef struct _Config_ModuleConfig {
pb_size_t which_payloadVariant;
union {
Config_ModuleConfig_MQTTConfig mqtt_config;
Config_ModuleConfig_SerialConfig serial_config;
Config_ModuleConfig_ExternalNotificationConfig external_notification_config;
Config_ModuleConfig_StoreForwardConfig store_forward_config;
Config_ModuleConfig_RangeTestConfig range_test_config;
Config_ModuleConfig_TelemetryConfig telemetry_config;
Config_ModuleConfig_CannedMessageConfig canned_message_config;
} payloadVariant;
} Config_ModuleConfig;
typedef struct _Config {
/* TODO: REPLACE */
pb_size_t which_payloadVariant;
union {
Config_DeviceConfig device_config;
Config_GpsConfig gps_config;
Config_PowerConfig power_config;
Config_WiFiConfig wifi_config;
Config_DisplayConfig display_config;
Config_LoRaConfig lora_config;
Config_ModuleConfig module_config;
Config_DeviceConfig device;
Config_PositionConfig position;
Config_PowerConfig power;
Config_WiFiConfig wifi;
Config_DisplayConfig display;
Config_LoRaConfig lora;
} payloadVariant;
} Config;
/* Helper constants for enums */
#define _Config_LoRaConfig_ModemConfig_MIN Config_LoRaConfig_ModemConfig_VLongSlow
#define _Config_LoRaConfig_ModemConfig_MAX Config_LoRaConfig_ModemConfig_ShortFast
#define _Config_LoRaConfig_ModemConfig_ARRAYSIZE ((Config_LoRaConfig_ModemConfig)(Config_LoRaConfig_ModemConfig_ShortFast+1))
#define _Config_DeviceConfig_Role_MIN Config_DeviceConfig_Role_Client
#define _Config_DeviceConfig_Role_MAX Config_DeviceConfig_Role_RouterClient
#define _Config_DeviceConfig_Role_ARRAYSIZE ((Config_DeviceConfig_Role)(Config_DeviceConfig_Role_RouterClient+1))
#define _Config_PositionConfig_PositionFlags_MIN Config_PositionConfig_PositionFlags_POS_UNDEFINED
#define _Config_PositionConfig_PositionFlags_MAX Config_PositionConfig_PositionFlags_POS_TIMESTAMP
#define _Config_PositionConfig_PositionFlags_ARRAYSIZE ((Config_PositionConfig_PositionFlags)(Config_PositionConfig_PositionFlags_POS_TIMESTAMP+1))
#define _Config_PowerConfig_ChargeCurrent_MIN Config_PowerConfig_ChargeCurrent_MAUnset
#define _Config_PowerConfig_ChargeCurrent_MAX Config_PowerConfig_ChargeCurrent_MA1320
#define _Config_PowerConfig_ChargeCurrent_ARRAYSIZE ((Config_PowerConfig_ChargeCurrent)(Config_PowerConfig_ChargeCurrent_MA1320+1))
#define _Config_DisplayConfig_GpsCoordinateFormat_MIN Config_DisplayConfig_GpsCoordinateFormat_GpsFormatDec
#define _Config_DisplayConfig_GpsCoordinateFormat_MAX Config_DisplayConfig_GpsCoordinateFormat_GpsFormatOSGR
#define _Config_DisplayConfig_GpsCoordinateFormat_ARRAYSIZE ((Config_DisplayConfig_GpsCoordinateFormat)(Config_DisplayConfig_GpsCoordinateFormat_GpsFormatOSGR+1))
#define _Config_LoRaConfig_RegionCode_MIN Config_LoRaConfig_RegionCode_Unset
#define _Config_LoRaConfig_RegionCode_MAX Config_LoRaConfig_RegionCode_TH
#define _Config_LoRaConfig_RegionCode_ARRAYSIZE ((Config_LoRaConfig_RegionCode)(Config_LoRaConfig_RegionCode_TH+1))
#define _Config_LoRaConfig_ModemPreset_MIN Config_LoRaConfig_ModemPreset_VLongSlow
#define _Config_LoRaConfig_ModemPreset_MAX Config_LoRaConfig_ModemPreset_ShortFast
#define _Config_LoRaConfig_ModemPreset_ARRAYSIZE ((Config_LoRaConfig_ModemPreset)(Config_LoRaConfig_ModemPreset_ShortFast+1))
#ifdef __cplusplus
@@ -128,234 +194,178 @@ extern "C" {
/* Initializer values for message structs */
#define Config_init_default {0, {Config_DeviceConfig_init_default}}
#define Config_DeviceConfig_init_default {0}
#define Config_GpsConfig_init_default {0}
#define Config_PowerConfig_init_default {0}
#define Config_WiFiConfig_init_default {{{NULL}, NULL}, {{NULL}, NULL}, 0}
#define Config_DisplayConfig_init_default {0}
#define Config_LoRaConfig_init_default {0, _Config_LoRaConfig_ModemConfig_MIN, 0, 0, 0}
#define Config_ModuleConfig_init_default {0, {Config_ModuleConfig_MQTTConfig_init_default}}
#define Config_ModuleConfig_MQTTConfig_init_default {0}
#define Config_ModuleConfig_SerialConfig_init_default {0}
#define Config_ModuleConfig_ExternalNotificationConfig_init_default {0}
#define Config_ModuleConfig_StoreForwardConfig_init_default {0}
#define Config_ModuleConfig_RangeTestConfig_init_default {0}
#define Config_ModuleConfig_TelemetryConfig_init_default {0, 0, 0, 0, 0, 0, 0, _TelemetrySensorType_MIN, 0}
#define Config_ModuleConfig_CannedMessageConfig_init_default {0}
#define Config_DeviceConfig_init_default {_Config_DeviceConfig_Role_MIN, 0, 0, 0}
#define Config_PositionConfig_init_default {0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
#define Config_PowerConfig_init_default {_Config_PowerConfig_ChargeCurrent_MIN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
#define Config_WiFiConfig_init_default {"", "", 0}
#define Config_DisplayConfig_init_default {0, _Config_DisplayConfig_GpsCoordinateFormat_MIN, 0}
#define Config_LoRaConfig_init_default {0, _Config_LoRaConfig_ModemPreset_MIN, 0, 0, 0, 0, _Config_LoRaConfig_RegionCode_MIN, 0, 0, 0, {0, 0, 0}}
#define Config_init_zero {0, {Config_DeviceConfig_init_zero}}
#define Config_DeviceConfig_init_zero {0}
#define Config_GpsConfig_init_zero {0}
#define Config_PowerConfig_init_zero {0}
#define Config_WiFiConfig_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, 0}
#define Config_DisplayConfig_init_zero {0}
#define Config_LoRaConfig_init_zero {0, _Config_LoRaConfig_ModemConfig_MIN, 0, 0, 0}
#define Config_ModuleConfig_init_zero {0, {Config_ModuleConfig_MQTTConfig_init_zero}}
#define Config_ModuleConfig_MQTTConfig_init_zero {0}
#define Config_ModuleConfig_SerialConfig_init_zero {0}
#define Config_ModuleConfig_ExternalNotificationConfig_init_zero {0}
#define Config_ModuleConfig_StoreForwardConfig_init_zero {0}
#define Config_ModuleConfig_RangeTestConfig_init_zero {0}
#define Config_ModuleConfig_TelemetryConfig_init_zero {0, 0, 0, 0, 0, 0, 0, _TelemetrySensorType_MIN, 0}
#define Config_ModuleConfig_CannedMessageConfig_init_zero {0}
#define Config_DeviceConfig_init_zero {_Config_DeviceConfig_Role_MIN, 0, 0, 0}
#define Config_PositionConfig_init_zero {0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
#define Config_PowerConfig_init_zero {_Config_PowerConfig_ChargeCurrent_MIN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
#define Config_WiFiConfig_init_zero {"", "", 0}
#define Config_DisplayConfig_init_zero {0, _Config_DisplayConfig_GpsCoordinateFormat_MIN, 0}
#define Config_LoRaConfig_init_zero {0, _Config_LoRaConfig_ModemPreset_MIN, 0, 0, 0, 0, _Config_LoRaConfig_RegionCode_MIN, 0, 0, 0, {0, 0, 0}}
/* Field tags (for use in manual encoding/decoding) */
#define Config_DeviceConfig_role_tag 1
#define Config_DeviceConfig_serial_disabled_tag 2
#define Config_DeviceConfig_factory_reset_tag 3
#define Config_DeviceConfig_debug_log_enabled_tag 4
#define Config_DisplayConfig_screen_on_secs_tag 1
#define Config_DisplayConfig_gps_format_tag 2
#define Config_DisplayConfig_auto_screen_carousel_secs_tag 3
#define Config_LoRaConfig_tx_power_tag 1
#define Config_LoRaConfig_modem_config_tag 3
#define Config_LoRaConfig_bandwidth_tag 6
#define Config_LoRaConfig_spread_factor_tag 7
#define Config_LoRaConfig_coding_rate_tag 8
#define Config_ModuleConfig_TelemetryConfig_device_update_interval_tag 1
#define Config_ModuleConfig_TelemetryConfig_environment_update_interval_tag 2
#define Config_ModuleConfig_TelemetryConfig_environment_measurement_enabled_tag 3
#define Config_ModuleConfig_TelemetryConfig_environment_screen_enabled_tag 4
#define Config_ModuleConfig_TelemetryConfig_environment_read_error_count_threshold_tag 5
#define Config_ModuleConfig_TelemetryConfig_environment_recovery_interval_tag 6
#define Config_ModuleConfig_TelemetryConfig_environment_display_fahrenheit_tag 7
#define Config_ModuleConfig_TelemetryConfig_environment_sensor_type_tag 8
#define Config_ModuleConfig_TelemetryConfig_environment_sensor_pin_tag 9
#define Config_WiFiConfig_wifi_ssid_tag 1
#define Config_WiFiConfig_wifi_password_tag 2
#define Config_WiFiConfig_wifi_ap_mode_tag 3
#define Config_ModuleConfig_mqtt_config_tag 1
#define Config_ModuleConfig_serial_config_tag 2
#define Config_ModuleConfig_external_notification_config_tag 3
#define Config_ModuleConfig_store_forward_config_tag 4
#define Config_ModuleConfig_range_test_config_tag 5
#define Config_ModuleConfig_telemetry_config_tag 6
#define Config_ModuleConfig_canned_message_config_tag 7
#define Config_device_config_tag 1
#define Config_gps_config_tag 2
#define Config_power_config_tag 3
#define Config_wifi_config_tag 4
#define Config_display_config_tag 5
#define Config_lora_config_tag 6
#define Config_module_config_tag 7
#define Config_LoRaConfig_modem_preset_tag 2
#define Config_LoRaConfig_bandwidth_tag 3
#define Config_LoRaConfig_spread_factor_tag 4
#define Config_LoRaConfig_coding_rate_tag 5
#define Config_LoRaConfig_frequency_offset_tag 6
#define Config_LoRaConfig_region_tag 7
#define Config_LoRaConfig_hop_limit_tag 8
#define Config_LoRaConfig_tx_disabled_tag 9
#define Config_LoRaConfig_ignore_incoming_tag 103
#define Config_PositionConfig_position_broadcast_secs_tag 1
#define Config_PositionConfig_position_broadcast_smart_disabled_tag 2
#define Config_PositionConfig_fixed_position_tag 3
#define Config_PositionConfig_location_share_disabled_tag 4
#define Config_PositionConfig_gps_disabled_tag 5
#define Config_PositionConfig_gps_update_interval_tag 6
#define Config_PositionConfig_gps_attempt_time_tag 7
#define Config_PositionConfig_gps_accept_2d_tag 8
#define Config_PositionConfig_gps_max_dop_tag 9
#define Config_PositionConfig_position_flags_tag 10
#define Config_PowerConfig_charge_current_tag 1
#define Config_PowerConfig_is_low_power_tag 2
#define Config_PowerConfig_is_always_powered_tag 3
#define Config_PowerConfig_on_battery_shutdown_after_secs_tag 4
#define Config_PowerConfig_is_power_saving_tag 5
#define Config_PowerConfig_adc_multiplier_override_tag 6
#define Config_PowerConfig_wait_bluetooth_secs_tag 7
#define Config_PowerConfig_phone_timeout_secs_tag 8
#define Config_PowerConfig_mesh_sds_timeout_secs_tag 9
#define Config_PowerConfig_sds_secs_tag 10
#define Config_PowerConfig_ls_secs_tag 11
#define Config_PowerConfig_min_wake_secs_tag 12
#define Config_WiFiConfig_ssid_tag 1
#define Config_WiFiConfig_psk_tag 2
#define Config_WiFiConfig_ap_mode_tag 3
#define Config_device_tag 1
#define Config_position_tag 2
#define Config_power_tag 3
#define Config_wifi_tag 4
#define Config_display_tag 5
#define Config_lora_tag 6
/* Struct field encoding specification for nanopb */
#define Config_FIELDLIST(X, a) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,device_config,payloadVariant.device_config), 1) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,gps_config,payloadVariant.gps_config), 2) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,power_config,payloadVariant.power_config), 3) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,wifi_config,payloadVariant.wifi_config), 4) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,display_config,payloadVariant.display_config), 5) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,lora_config,payloadVariant.lora_config), 6) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,module_config,payloadVariant.module_config), 7)
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,device,payloadVariant.device), 1) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,position,payloadVariant.position), 2) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,power,payloadVariant.power), 3) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,wifi,payloadVariant.wifi), 4) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,display,payloadVariant.display), 5) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,lora,payloadVariant.lora), 6)
#define Config_CALLBACK NULL
#define Config_DEFAULT NULL
#define Config_payloadVariant_device_config_MSGTYPE Config_DeviceConfig
#define Config_payloadVariant_gps_config_MSGTYPE Config_GpsConfig
#define Config_payloadVariant_power_config_MSGTYPE Config_PowerConfig
#define Config_payloadVariant_wifi_config_MSGTYPE Config_WiFiConfig
#define Config_payloadVariant_display_config_MSGTYPE Config_DisplayConfig
#define Config_payloadVariant_lora_config_MSGTYPE Config_LoRaConfig
#define Config_payloadVariant_module_config_MSGTYPE Config_ModuleConfig
#define Config_payloadVariant_device_MSGTYPE Config_DeviceConfig
#define Config_payloadVariant_position_MSGTYPE Config_PositionConfig
#define Config_payloadVariant_power_MSGTYPE Config_PowerConfig
#define Config_payloadVariant_wifi_MSGTYPE Config_WiFiConfig
#define Config_payloadVariant_display_MSGTYPE Config_DisplayConfig
#define Config_payloadVariant_lora_MSGTYPE Config_LoRaConfig
#define Config_DeviceConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, UENUM, role, 1) \
X(a, STATIC, SINGULAR, BOOL, serial_disabled, 2) \
X(a, STATIC, SINGULAR, BOOL, factory_reset, 3) \
X(a, STATIC, SINGULAR, BOOL, debug_log_enabled, 4)
#define Config_DeviceConfig_CALLBACK NULL
#define Config_DeviceConfig_DEFAULT NULL
#define Config_GpsConfig_FIELDLIST(X, a) \
#define Config_GpsConfig_CALLBACK NULL
#define Config_GpsConfig_DEFAULT NULL
#define Config_PositionConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, UINT32, position_broadcast_secs, 1) \
X(a, STATIC, SINGULAR, BOOL, position_broadcast_smart_disabled, 2) \
X(a, STATIC, SINGULAR, BOOL, fixed_position, 3) \
X(a, STATIC, SINGULAR, BOOL, location_share_disabled, 4) \
X(a, STATIC, SINGULAR, BOOL, gps_disabled, 5) \
X(a, STATIC, SINGULAR, UINT32, gps_update_interval, 6) \
X(a, STATIC, SINGULAR, UINT32, gps_attempt_time, 7) \
X(a, STATIC, SINGULAR, BOOL, gps_accept_2d, 8) \
X(a, STATIC, SINGULAR, UINT32, gps_max_dop, 9) \
X(a, STATIC, SINGULAR, UINT32, position_flags, 10)
#define Config_PositionConfig_CALLBACK NULL
#define Config_PositionConfig_DEFAULT NULL
#define Config_PowerConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, UENUM, charge_current, 1) \
X(a, STATIC, SINGULAR, BOOL, is_low_power, 2) \
X(a, STATIC, SINGULAR, BOOL, is_always_powered, 3) \
X(a, STATIC, SINGULAR, UINT32, on_battery_shutdown_after_secs, 4) \
X(a, STATIC, SINGULAR, BOOL, is_power_saving, 5) \
X(a, STATIC, SINGULAR, FLOAT, adc_multiplier_override, 6) \
X(a, STATIC, SINGULAR, UINT32, wait_bluetooth_secs, 7) \
X(a, STATIC, SINGULAR, UINT32, phone_timeout_secs, 8) \
X(a, STATIC, SINGULAR, UINT32, mesh_sds_timeout_secs, 9) \
X(a, STATIC, SINGULAR, UINT32, sds_secs, 10) \
X(a, STATIC, SINGULAR, UINT32, ls_secs, 11) \
X(a, STATIC, SINGULAR, UINT32, min_wake_secs, 12)
#define Config_PowerConfig_CALLBACK NULL
#define Config_PowerConfig_DEFAULT NULL
#define Config_WiFiConfig_FIELDLIST(X, a) \
X(a, CALLBACK, SINGULAR, STRING, wifi_ssid, 1) \
X(a, CALLBACK, SINGULAR, STRING, wifi_password, 2) \
X(a, STATIC, SINGULAR, BOOL, wifi_ap_mode, 3)
#define Config_WiFiConfig_CALLBACK pb_default_field_callback
X(a, STATIC, SINGULAR, STRING, ssid, 1) \
X(a, STATIC, SINGULAR, STRING, psk, 2) \
X(a, STATIC, SINGULAR, BOOL, ap_mode, 3)
#define Config_WiFiConfig_CALLBACK NULL
#define Config_WiFiConfig_DEFAULT NULL
#define Config_DisplayConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, UINT32, screen_on_secs, 1) \
X(a, STATIC, SINGULAR, UENUM, gps_format, 2) \
X(a, STATIC, SINGULAR, UINT32, auto_screen_carousel_secs, 3)
#define Config_DisplayConfig_CALLBACK NULL
#define Config_DisplayConfig_DEFAULT NULL
#define Config_LoRaConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, INT32, tx_power, 1) \
X(a, STATIC, SINGULAR, UENUM, modem_config, 3) \
X(a, STATIC, SINGULAR, UINT32, bandwidth, 6) \
X(a, STATIC, SINGULAR, UINT32, spread_factor, 7) \
X(a, STATIC, SINGULAR, UINT32, coding_rate, 8)
X(a, STATIC, SINGULAR, UENUM, modem_preset, 2) \
X(a, STATIC, SINGULAR, UINT32, bandwidth, 3) \
X(a, STATIC, SINGULAR, UINT32, spread_factor, 4) \
X(a, STATIC, SINGULAR, UINT32, coding_rate, 5) \
X(a, STATIC, SINGULAR, FLOAT, frequency_offset, 6) \
X(a, STATIC, SINGULAR, UENUM, region, 7) \
X(a, STATIC, SINGULAR, UINT32, hop_limit, 8) \
X(a, STATIC, SINGULAR, BOOL, tx_disabled, 9) \
X(a, STATIC, REPEATED, UINT32, ignore_incoming, 103)
#define Config_LoRaConfig_CALLBACK NULL
#define Config_LoRaConfig_DEFAULT NULL
#define Config_ModuleConfig_FIELDLIST(X, a) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,mqtt_config,payloadVariant.mqtt_config), 1) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,serial_config,payloadVariant.serial_config), 2) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,external_notification_config,payloadVariant.external_notification_config), 3) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,store_forward_config,payloadVariant.store_forward_config), 4) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,range_test_config,payloadVariant.range_test_config), 5) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,telemetry_config,payloadVariant.telemetry_config), 6) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,canned_message_config,payloadVariant.canned_message_config), 7)
#define Config_ModuleConfig_CALLBACK NULL
#define Config_ModuleConfig_DEFAULT NULL
#define Config_ModuleConfig_payloadVariant_mqtt_config_MSGTYPE Config_ModuleConfig_MQTTConfig
#define Config_ModuleConfig_payloadVariant_serial_config_MSGTYPE Config_ModuleConfig_SerialConfig
#define Config_ModuleConfig_payloadVariant_external_notification_config_MSGTYPE Config_ModuleConfig_ExternalNotificationConfig
#define Config_ModuleConfig_payloadVariant_store_forward_config_MSGTYPE Config_ModuleConfig_StoreForwardConfig
#define Config_ModuleConfig_payloadVariant_range_test_config_MSGTYPE Config_ModuleConfig_RangeTestConfig
#define Config_ModuleConfig_payloadVariant_telemetry_config_MSGTYPE Config_ModuleConfig_TelemetryConfig
#define Config_ModuleConfig_payloadVariant_canned_message_config_MSGTYPE Config_ModuleConfig_CannedMessageConfig
#define Config_ModuleConfig_MQTTConfig_FIELDLIST(X, a) \
#define Config_ModuleConfig_MQTTConfig_CALLBACK NULL
#define Config_ModuleConfig_MQTTConfig_DEFAULT NULL
#define Config_ModuleConfig_SerialConfig_FIELDLIST(X, a) \
#define Config_ModuleConfig_SerialConfig_CALLBACK NULL
#define Config_ModuleConfig_SerialConfig_DEFAULT NULL
#define Config_ModuleConfig_ExternalNotificationConfig_FIELDLIST(X, a) \
#define Config_ModuleConfig_ExternalNotificationConfig_CALLBACK NULL
#define Config_ModuleConfig_ExternalNotificationConfig_DEFAULT NULL
#define Config_ModuleConfig_StoreForwardConfig_FIELDLIST(X, a) \
#define Config_ModuleConfig_StoreForwardConfig_CALLBACK NULL
#define Config_ModuleConfig_StoreForwardConfig_DEFAULT NULL
#define Config_ModuleConfig_RangeTestConfig_FIELDLIST(X, a) \
#define Config_ModuleConfig_RangeTestConfig_CALLBACK NULL
#define Config_ModuleConfig_RangeTestConfig_DEFAULT NULL
#define Config_ModuleConfig_TelemetryConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, UINT32, device_update_interval, 1) \
X(a, STATIC, SINGULAR, UINT32, environment_update_interval, 2) \
X(a, STATIC, SINGULAR, BOOL, environment_measurement_enabled, 3) \
X(a, STATIC, SINGULAR, BOOL, environment_screen_enabled, 4) \
X(a, STATIC, SINGULAR, UINT32, environment_read_error_count_threshold, 5) \
X(a, STATIC, SINGULAR, UINT32, environment_recovery_interval, 6) \
X(a, STATIC, SINGULAR, BOOL, environment_display_fahrenheit, 7) \
X(a, STATIC, SINGULAR, UENUM, environment_sensor_type, 8) \
X(a, STATIC, SINGULAR, UINT32, environment_sensor_pin, 9)
#define Config_ModuleConfig_TelemetryConfig_CALLBACK NULL
#define Config_ModuleConfig_TelemetryConfig_DEFAULT NULL
#define Config_ModuleConfig_CannedMessageConfig_FIELDLIST(X, a) \
#define Config_ModuleConfig_CannedMessageConfig_CALLBACK NULL
#define Config_ModuleConfig_CannedMessageConfig_DEFAULT NULL
extern const pb_msgdesc_t Config_msg;
extern const pb_msgdesc_t Config_DeviceConfig_msg;
extern const pb_msgdesc_t Config_GpsConfig_msg;
extern const pb_msgdesc_t Config_PositionConfig_msg;
extern const pb_msgdesc_t Config_PowerConfig_msg;
extern const pb_msgdesc_t Config_WiFiConfig_msg;
extern const pb_msgdesc_t Config_DisplayConfig_msg;
extern const pb_msgdesc_t Config_LoRaConfig_msg;
extern const pb_msgdesc_t Config_ModuleConfig_msg;
extern const pb_msgdesc_t Config_ModuleConfig_MQTTConfig_msg;
extern const pb_msgdesc_t Config_ModuleConfig_SerialConfig_msg;
extern const pb_msgdesc_t Config_ModuleConfig_ExternalNotificationConfig_msg;
extern const pb_msgdesc_t Config_ModuleConfig_StoreForwardConfig_msg;
extern const pb_msgdesc_t Config_ModuleConfig_RangeTestConfig_msg;
extern const pb_msgdesc_t Config_ModuleConfig_TelemetryConfig_msg;
extern const pb_msgdesc_t Config_ModuleConfig_CannedMessageConfig_msg;
/* Defines for backwards compatibility with code written before nanopb-0.4.0 */
#define Config_fields &Config_msg
#define Config_DeviceConfig_fields &Config_DeviceConfig_msg
#define Config_GpsConfig_fields &Config_GpsConfig_msg
#define Config_PositionConfig_fields &Config_PositionConfig_msg
#define Config_PowerConfig_fields &Config_PowerConfig_msg
#define Config_WiFiConfig_fields &Config_WiFiConfig_msg
#define Config_DisplayConfig_fields &Config_DisplayConfig_msg
#define Config_LoRaConfig_fields &Config_LoRaConfig_msg
#define Config_ModuleConfig_fields &Config_ModuleConfig_msg
#define Config_ModuleConfig_MQTTConfig_fields &Config_ModuleConfig_MQTTConfig_msg
#define Config_ModuleConfig_SerialConfig_fields &Config_ModuleConfig_SerialConfig_msg
#define Config_ModuleConfig_ExternalNotificationConfig_fields &Config_ModuleConfig_ExternalNotificationConfig_msg
#define Config_ModuleConfig_StoreForwardConfig_fields &Config_ModuleConfig_StoreForwardConfig_msg
#define Config_ModuleConfig_RangeTestConfig_fields &Config_ModuleConfig_RangeTestConfig_msg
#define Config_ModuleConfig_TelemetryConfig_fields &Config_ModuleConfig_TelemetryConfig_msg
#define Config_ModuleConfig_CannedMessageConfig_fields &Config_ModuleConfig_CannedMessageConfig_msg
/* Maximum encoded size of messages (where known) */
/* Config_size depends on runtime parameters */
/* Config_WiFiConfig_size depends on runtime parameters */
#define Config_DeviceConfig_size 0
#define Config_DisplayConfig_size 0
#define Config_GpsConfig_size 0
#define Config_LoRaConfig_size 31
#define Config_ModuleConfig_CannedMessageConfig_size 0
#define Config_ModuleConfig_ExternalNotificationConfig_size 0
#define Config_ModuleConfig_MQTTConfig_size 0
#define Config_ModuleConfig_RangeTestConfig_size 0
#define Config_ModuleConfig_SerialConfig_size 0
#define Config_ModuleConfig_StoreForwardConfig_size 0
#define Config_ModuleConfig_TelemetryConfig_size 38
#define Config_ModuleConfig_size 40
#define Config_PowerConfig_size 0
#define Config_DeviceConfig_size 8
#define Config_DisplayConfig_size 14
#define Config_LoRaConfig_size 67
#define Config_PositionConfig_size 40
#define Config_PowerConfig_size 55
#define Config_WiFiConfig_size 101
#define Config_size 103
#ifdef __cplusplus
} /* extern "C" */

View File

@@ -31,3 +31,6 @@ PB_BIND(ModuleConfig_CannedMessageConfig, ModuleConfig_CannedMessageConfig, AUTO

View File

@@ -10,29 +10,97 @@
#error Regenerate this file with the current version of nanopb generator.
#endif
/* Enum definitions */
typedef enum _ModuleConfig_SerialConfig_Serial_Baud {
ModuleConfig_SerialConfig_Serial_Baud_BAUD_Default = 0,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_2400 = 1,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_4800 = 2,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_9600 = 3,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_19200 = 4,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_38400 = 5,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_57600 = 6,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_115200 = 7,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_230400 = 8,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_460800 = 9,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_576000 = 10,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_921600 = 11,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_110 = 12,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_300 = 13,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_600 = 14,
ModuleConfig_SerialConfig_Serial_Baud_BAUD_1200 = 15
} ModuleConfig_SerialConfig_Serial_Baud;
typedef enum _ModuleConfig_SerialConfig_Serial_Mode {
ModuleConfig_SerialConfig_Serial_Mode_MODE_Default = 0,
ModuleConfig_SerialConfig_Serial_Mode_MODE_SIMPLE = 1,
ModuleConfig_SerialConfig_Serial_Mode_MODE_PROTO = 2
} ModuleConfig_SerialConfig_Serial_Mode;
typedef enum _ModuleConfig_CannedMessageConfig_InputEventChar {
ModuleConfig_CannedMessageConfig_InputEventChar_KEY_NONE = 0,
ModuleConfig_CannedMessageConfig_InputEventChar_KEY_UP = 17,
ModuleConfig_CannedMessageConfig_InputEventChar_KEY_DOWN = 18,
ModuleConfig_CannedMessageConfig_InputEventChar_KEY_LEFT = 19,
ModuleConfig_CannedMessageConfig_InputEventChar_KEY_RIGHT = 20,
ModuleConfig_CannedMessageConfig_InputEventChar_KEY_SELECT = 10,
ModuleConfig_CannedMessageConfig_InputEventChar_KEY_BACK = 27,
ModuleConfig_CannedMessageConfig_InputEventChar_KEY_CANCEL = 24
} ModuleConfig_CannedMessageConfig_InputEventChar;
/* Struct definitions */
typedef struct _ModuleConfig_CannedMessageConfig {
char dummy_field;
bool rotary1_enabled;
uint32_t inputbroker_pin_a;
uint32_t inputbroker_pin_b;
uint32_t inputbroker_pin_press;
ModuleConfig_CannedMessageConfig_InputEventChar inputbroker_event_cw;
ModuleConfig_CannedMessageConfig_InputEventChar inputbroker_event_ccw;
ModuleConfig_CannedMessageConfig_InputEventChar inputbroker_event_press;
bool updown1_enabled;
bool enabled;
char allow_input_source[16];
bool send_bell;
} ModuleConfig_CannedMessageConfig;
typedef struct _ModuleConfig_ExternalNotificationConfig {
char dummy_field;
bool enabled;
uint32_t output_ms;
uint32_t output;
bool active;
bool alert_message;
bool alert_bell;
} ModuleConfig_ExternalNotificationConfig;
typedef struct _ModuleConfig_MQTTConfig {
char dummy_field;
bool disabled;
char address[32];
char username[32];
char password[32];
bool encryption_enabled;
} ModuleConfig_MQTTConfig;
typedef struct _ModuleConfig_RangeTestConfig {
char dummy_field;
bool enabled;
uint32_t sender;
bool save;
} ModuleConfig_RangeTestConfig;
typedef struct _ModuleConfig_SerialConfig {
char dummy_field;
bool enabled;
bool echo;
uint32_t rxd;
uint32_t txd;
ModuleConfig_SerialConfig_Serial_Baud baud;
uint32_t timeout;
ModuleConfig_SerialConfig_Serial_Mode mode;
} ModuleConfig_SerialConfig;
typedef struct _ModuleConfig_StoreForwardConfig {
char dummy_field;
bool enabled;
bool heartbeat;
uint32_t records;
uint32_t history_return_max;
uint32_t history_return_window;
} ModuleConfig_StoreForwardConfig;
typedef struct _ModuleConfig_TelemetryConfig {
@@ -52,40 +120,91 @@ typedef struct _ModuleConfig {
/* TODO: REPLACE */
pb_size_t which_payloadVariant;
union {
ModuleConfig_MQTTConfig mqtt_config;
ModuleConfig_SerialConfig serial_config;
ModuleConfig_ExternalNotificationConfig external_notification_config;
ModuleConfig_StoreForwardConfig store_forward_config;
ModuleConfig_RangeTestConfig range_test_config;
ModuleConfig_TelemetryConfig telemetry_config;
ModuleConfig_CannedMessageConfig canned_message_config;
ModuleConfig_MQTTConfig mqtt;
ModuleConfig_SerialConfig serial;
ModuleConfig_ExternalNotificationConfig external_notification;
ModuleConfig_StoreForwardConfig store_forward;
ModuleConfig_RangeTestConfig range_test;
ModuleConfig_TelemetryConfig telemetry;
ModuleConfig_CannedMessageConfig canned_message;
} payloadVariant;
} ModuleConfig;
/* Helper constants for enums */
#define _ModuleConfig_SerialConfig_Serial_Baud_MIN ModuleConfig_SerialConfig_Serial_Baud_BAUD_Default
#define _ModuleConfig_SerialConfig_Serial_Baud_MAX ModuleConfig_SerialConfig_Serial_Baud_BAUD_1200
#define _ModuleConfig_SerialConfig_Serial_Baud_ARRAYSIZE ((ModuleConfig_SerialConfig_Serial_Baud)(ModuleConfig_SerialConfig_Serial_Baud_BAUD_1200+1))
#define _ModuleConfig_SerialConfig_Serial_Mode_MIN ModuleConfig_SerialConfig_Serial_Mode_MODE_Default
#define _ModuleConfig_SerialConfig_Serial_Mode_MAX ModuleConfig_SerialConfig_Serial_Mode_MODE_PROTO
#define _ModuleConfig_SerialConfig_Serial_Mode_ARRAYSIZE ((ModuleConfig_SerialConfig_Serial_Mode)(ModuleConfig_SerialConfig_Serial_Mode_MODE_PROTO+1))
#define _ModuleConfig_CannedMessageConfig_InputEventChar_MIN ModuleConfig_CannedMessageConfig_InputEventChar_KEY_NONE
#define _ModuleConfig_CannedMessageConfig_InputEventChar_MAX ModuleConfig_CannedMessageConfig_InputEventChar_KEY_BACK
#define _ModuleConfig_CannedMessageConfig_InputEventChar_ARRAYSIZE ((ModuleConfig_CannedMessageConfig_InputEventChar)(ModuleConfig_CannedMessageConfig_InputEventChar_KEY_BACK+1))
#ifdef __cplusplus
extern "C" {
#endif
/* Initializer values for message structs */
#define ModuleConfig_init_default {0, {ModuleConfig_MQTTConfig_init_default}}
#define ModuleConfig_MQTTConfig_init_default {0}
#define ModuleConfig_SerialConfig_init_default {0}
#define ModuleConfig_ExternalNotificationConfig_init_default {0}
#define ModuleConfig_StoreForwardConfig_init_default {0}
#define ModuleConfig_RangeTestConfig_init_default {0}
#define ModuleConfig_MQTTConfig_init_default {0, "", "", "", 0}
#define ModuleConfig_SerialConfig_init_default {0, 0, 0, 0, _ModuleConfig_SerialConfig_Serial_Baud_MIN, 0, _ModuleConfig_SerialConfig_Serial_Mode_MIN}
#define ModuleConfig_ExternalNotificationConfig_init_default {0, 0, 0, 0, 0, 0}
#define ModuleConfig_StoreForwardConfig_init_default {0, 0, 0, 0, 0}
#define ModuleConfig_RangeTestConfig_init_default {0, 0, 0}
#define ModuleConfig_TelemetryConfig_init_default {0, 0, 0, 0, 0, 0, 0, _TelemetrySensorType_MIN, 0}
#define ModuleConfig_CannedMessageConfig_init_default {0}
#define ModuleConfig_CannedMessageConfig_init_default {0, 0, 0, 0, _ModuleConfig_CannedMessageConfig_InputEventChar_MIN, _ModuleConfig_CannedMessageConfig_InputEventChar_MIN, _ModuleConfig_CannedMessageConfig_InputEventChar_MIN, 0, 0, "", 0}
#define ModuleConfig_init_zero {0, {ModuleConfig_MQTTConfig_init_zero}}
#define ModuleConfig_MQTTConfig_init_zero {0}
#define ModuleConfig_SerialConfig_init_zero {0}
#define ModuleConfig_ExternalNotificationConfig_init_zero {0}
#define ModuleConfig_StoreForwardConfig_init_zero {0}
#define ModuleConfig_RangeTestConfig_init_zero {0}
#define ModuleConfig_MQTTConfig_init_zero {0, "", "", "", 0}
#define ModuleConfig_SerialConfig_init_zero {0, 0, 0, 0, _ModuleConfig_SerialConfig_Serial_Baud_MIN, 0, _ModuleConfig_SerialConfig_Serial_Mode_MIN}
#define ModuleConfig_ExternalNotificationConfig_init_zero {0, 0, 0, 0, 0, 0}
#define ModuleConfig_StoreForwardConfig_init_zero {0, 0, 0, 0, 0}
#define ModuleConfig_RangeTestConfig_init_zero {0, 0, 0}
#define ModuleConfig_TelemetryConfig_init_zero {0, 0, 0, 0, 0, 0, 0, _TelemetrySensorType_MIN, 0}
#define ModuleConfig_CannedMessageConfig_init_zero {0}
#define ModuleConfig_CannedMessageConfig_init_zero {0, 0, 0, 0, _ModuleConfig_CannedMessageConfig_InputEventChar_MIN, _ModuleConfig_CannedMessageConfig_InputEventChar_MIN, _ModuleConfig_CannedMessageConfig_InputEventChar_MIN, 0, 0, "", 0}
/* Field tags (for use in manual encoding/decoding) */
#define ModuleConfig_CannedMessageConfig_rotary1_enabled_tag 1
#define ModuleConfig_CannedMessageConfig_inputbroker_pin_a_tag 2
#define ModuleConfig_CannedMessageConfig_inputbroker_pin_b_tag 3
#define ModuleConfig_CannedMessageConfig_inputbroker_pin_press_tag 4
#define ModuleConfig_CannedMessageConfig_inputbroker_event_cw_tag 5
#define ModuleConfig_CannedMessageConfig_inputbroker_event_ccw_tag 6
#define ModuleConfig_CannedMessageConfig_inputbroker_event_press_tag 7
#define ModuleConfig_CannedMessageConfig_updown1_enabled_tag 8
#define ModuleConfig_CannedMessageConfig_enabled_tag 9
#define ModuleConfig_CannedMessageConfig_allow_input_source_tag 10
#define ModuleConfig_CannedMessageConfig_send_bell_tag 11
#define ModuleConfig_ExternalNotificationConfig_enabled_tag 1
#define ModuleConfig_ExternalNotificationConfig_output_ms_tag 2
#define ModuleConfig_ExternalNotificationConfig_output_tag 3
#define ModuleConfig_ExternalNotificationConfig_active_tag 4
#define ModuleConfig_ExternalNotificationConfig_alert_message_tag 5
#define ModuleConfig_ExternalNotificationConfig_alert_bell_tag 6
#define ModuleConfig_MQTTConfig_disabled_tag 1
#define ModuleConfig_MQTTConfig_address_tag 2
#define ModuleConfig_MQTTConfig_username_tag 3
#define ModuleConfig_MQTTConfig_password_tag 4
#define ModuleConfig_MQTTConfig_encryption_enabled_tag 5
#define ModuleConfig_RangeTestConfig_enabled_tag 1
#define ModuleConfig_RangeTestConfig_sender_tag 2
#define ModuleConfig_RangeTestConfig_save_tag 3
#define ModuleConfig_SerialConfig_enabled_tag 1
#define ModuleConfig_SerialConfig_echo_tag 2
#define ModuleConfig_SerialConfig_rxd_tag 3
#define ModuleConfig_SerialConfig_txd_tag 4
#define ModuleConfig_SerialConfig_baud_tag 5
#define ModuleConfig_SerialConfig_timeout_tag 6
#define ModuleConfig_SerialConfig_mode_tag 7
#define ModuleConfig_StoreForwardConfig_enabled_tag 1
#define ModuleConfig_StoreForwardConfig_heartbeat_tag 2
#define ModuleConfig_StoreForwardConfig_records_tag 3
#define ModuleConfig_StoreForwardConfig_history_return_max_tag 4
#define ModuleConfig_StoreForwardConfig_history_return_window_tag 5
#define ModuleConfig_TelemetryConfig_device_update_interval_tag 1
#define ModuleConfig_TelemetryConfig_environment_update_interval_tag 2
#define ModuleConfig_TelemetryConfig_environment_measurement_enabled_tag 3
@@ -95,55 +214,76 @@ extern "C" {
#define ModuleConfig_TelemetryConfig_environment_display_fahrenheit_tag 7
#define ModuleConfig_TelemetryConfig_environment_sensor_type_tag 8
#define ModuleConfig_TelemetryConfig_environment_sensor_pin_tag 9
#define ModuleConfig_mqtt_config_tag 1
#define ModuleConfig_serial_config_tag 2
#define ModuleConfig_external_notification_config_tag 3
#define ModuleConfig_store_forward_config_tag 4
#define ModuleConfig_range_test_config_tag 5
#define ModuleConfig_telemetry_config_tag 6
#define ModuleConfig_canned_message_config_tag 7
#define ModuleConfig_mqtt_tag 1
#define ModuleConfig_serial_tag 2
#define ModuleConfig_external_notification_tag 3
#define ModuleConfig_store_forward_tag 4
#define ModuleConfig_range_test_tag 5
#define ModuleConfig_telemetry_tag 6
#define ModuleConfig_canned_message_tag 7
/* Struct field encoding specification for nanopb */
#define ModuleConfig_FIELDLIST(X, a) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,mqtt_config,payloadVariant.mqtt_config), 1) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,serial_config,payloadVariant.serial_config), 2) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,external_notification_config,payloadVariant.external_notification_config), 3) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,store_forward_config,payloadVariant.store_forward_config), 4) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,range_test_config,payloadVariant.range_test_config), 5) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,telemetry_config,payloadVariant.telemetry_config), 6) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,canned_message_config,payloadVariant.canned_message_config), 7)
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,mqtt,payloadVariant.mqtt), 1) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,serial,payloadVariant.serial), 2) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,external_notification,payloadVariant.external_notification), 3) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,store_forward,payloadVariant.store_forward), 4) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,range_test,payloadVariant.range_test), 5) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,telemetry,payloadVariant.telemetry), 6) \
X(a, STATIC, ONEOF, MESSAGE, (payloadVariant,canned_message,payloadVariant.canned_message), 7)
#define ModuleConfig_CALLBACK NULL
#define ModuleConfig_DEFAULT NULL
#define ModuleConfig_payloadVariant_mqtt_config_MSGTYPE ModuleConfig_MQTTConfig
#define ModuleConfig_payloadVariant_serial_config_MSGTYPE ModuleConfig_SerialConfig
#define ModuleConfig_payloadVariant_external_notification_config_MSGTYPE ModuleConfig_ExternalNotificationConfig
#define ModuleConfig_payloadVariant_store_forward_config_MSGTYPE ModuleConfig_StoreForwardConfig
#define ModuleConfig_payloadVariant_range_test_config_MSGTYPE ModuleConfig_RangeTestConfig
#define ModuleConfig_payloadVariant_telemetry_config_MSGTYPE ModuleConfig_TelemetryConfig
#define ModuleConfig_payloadVariant_canned_message_config_MSGTYPE ModuleConfig_CannedMessageConfig
#define ModuleConfig_payloadVariant_mqtt_MSGTYPE ModuleConfig_MQTTConfig
#define ModuleConfig_payloadVariant_serial_MSGTYPE ModuleConfig_SerialConfig
#define ModuleConfig_payloadVariant_external_notification_MSGTYPE ModuleConfig_ExternalNotificationConfig
#define ModuleConfig_payloadVariant_store_forward_MSGTYPE ModuleConfig_StoreForwardConfig
#define ModuleConfig_payloadVariant_range_test_MSGTYPE ModuleConfig_RangeTestConfig
#define ModuleConfig_payloadVariant_telemetry_MSGTYPE ModuleConfig_TelemetryConfig
#define ModuleConfig_payloadVariant_canned_message_MSGTYPE ModuleConfig_CannedMessageConfig
#define ModuleConfig_MQTTConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, BOOL, disabled, 1) \
X(a, STATIC, SINGULAR, STRING, address, 2) \
X(a, STATIC, SINGULAR, STRING, username, 3) \
X(a, STATIC, SINGULAR, STRING, password, 4) \
X(a, STATIC, SINGULAR, BOOL, encryption_enabled, 5)
#define ModuleConfig_MQTTConfig_CALLBACK NULL
#define ModuleConfig_MQTTConfig_DEFAULT NULL
#define ModuleConfig_SerialConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, BOOL, enabled, 1) \
X(a, STATIC, SINGULAR, BOOL, echo, 2) \
X(a, STATIC, SINGULAR, UINT32, rxd, 3) \
X(a, STATIC, SINGULAR, UINT32, txd, 4) \
X(a, STATIC, SINGULAR, UENUM, baud, 5) \
X(a, STATIC, SINGULAR, UINT32, timeout, 6) \
X(a, STATIC, SINGULAR, UENUM, mode, 7)
#define ModuleConfig_SerialConfig_CALLBACK NULL
#define ModuleConfig_SerialConfig_DEFAULT NULL
#define ModuleConfig_ExternalNotificationConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, BOOL, enabled, 1) \
X(a, STATIC, SINGULAR, UINT32, output_ms, 2) \
X(a, STATIC, SINGULAR, UINT32, output, 3) \
X(a, STATIC, SINGULAR, BOOL, active, 4) \
X(a, STATIC, SINGULAR, BOOL, alert_message, 5) \
X(a, STATIC, SINGULAR, BOOL, alert_bell, 6)
#define ModuleConfig_ExternalNotificationConfig_CALLBACK NULL
#define ModuleConfig_ExternalNotificationConfig_DEFAULT NULL
#define ModuleConfig_StoreForwardConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, BOOL, enabled, 1) \
X(a, STATIC, SINGULAR, BOOL, heartbeat, 2) \
X(a, STATIC, SINGULAR, UINT32, records, 3) \
X(a, STATIC, SINGULAR, UINT32, history_return_max, 4) \
X(a, STATIC, SINGULAR, UINT32, history_return_window, 5)
#define ModuleConfig_StoreForwardConfig_CALLBACK NULL
#define ModuleConfig_StoreForwardConfig_DEFAULT NULL
#define ModuleConfig_RangeTestConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, BOOL, enabled, 1) \
X(a, STATIC, SINGULAR, UINT32, sender, 2) \
X(a, STATIC, SINGULAR, BOOL, save, 3)
#define ModuleConfig_RangeTestConfig_CALLBACK NULL
#define ModuleConfig_RangeTestConfig_DEFAULT NULL
@@ -161,7 +301,17 @@ X(a, STATIC, SINGULAR, UINT32, environment_sensor_pin, 9)
#define ModuleConfig_TelemetryConfig_DEFAULT NULL
#define ModuleConfig_CannedMessageConfig_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, BOOL, rotary1_enabled, 1) \
X(a, STATIC, SINGULAR, UINT32, inputbroker_pin_a, 2) \
X(a, STATIC, SINGULAR, UINT32, inputbroker_pin_b, 3) \
X(a, STATIC, SINGULAR, UINT32, inputbroker_pin_press, 4) \
X(a, STATIC, SINGULAR, UENUM, inputbroker_event_cw, 5) \
X(a, STATIC, SINGULAR, UENUM, inputbroker_event_ccw, 6) \
X(a, STATIC, SINGULAR, UENUM, inputbroker_event_press, 7) \
X(a, STATIC, SINGULAR, BOOL, updown1_enabled, 8) \
X(a, STATIC, SINGULAR, BOOL, enabled, 9) \
X(a, STATIC, SINGULAR, STRING, allow_input_source, 10) \
X(a, STATIC, SINGULAR, BOOL, send_bell, 11)
#define ModuleConfig_CannedMessageConfig_CALLBACK NULL
#define ModuleConfig_CannedMessageConfig_DEFAULT NULL
@@ -185,14 +335,14 @@ extern const pb_msgdesc_t ModuleConfig_CannedMessageConfig_msg;
#define ModuleConfig_CannedMessageConfig_fields &ModuleConfig_CannedMessageConfig_msg
/* Maximum encoded size of messages (where known) */
#define ModuleConfig_CannedMessageConfig_size 0
#define ModuleConfig_ExternalNotificationConfig_size 0
#define ModuleConfig_MQTTConfig_size 0
#define ModuleConfig_RangeTestConfig_size 0
#define ModuleConfig_SerialConfig_size 0
#define ModuleConfig_StoreForwardConfig_size 0
#define ModuleConfig_CannedMessageConfig_size 49
#define ModuleConfig_ExternalNotificationConfig_size 20
#define ModuleConfig_MQTTConfig_size 103
#define ModuleConfig_RangeTestConfig_size 10
#define ModuleConfig_SerialConfig_size 26
#define ModuleConfig_StoreForwardConfig_size 22
#define ModuleConfig_TelemetryConfig_size 38
#define ModuleConfig_size 40
#define ModuleConfig_size 105
#ifdef __cplusplus
} /* extern "C" */

View File

@@ -1,23 +0,0 @@
/* Automatically generated nanopb constant definitions */
/* Generated by nanopb-0.4.5 */
#include "radioconfig.pb.h"
#if PB_PROTO_HEADER_VERSION != 40
#error Regenerate this file with the current version of nanopb generator.
#endif
PB_BIND(RadioConfig, RadioConfig, 2)
PB_BIND(RadioConfig_UserPreferences, RadioConfig_UserPreferences, 2)

View File

@@ -1,550 +0,0 @@
/* Automatically generated nanopb header */
/* Generated by nanopb-0.4.5 */
#ifndef PB_RADIOCONFIG_PB_H_INCLUDED
#define PB_RADIOCONFIG_PB_H_INCLUDED
#include <pb.h>
#if PB_PROTO_HEADER_VERSION != 40
#error Regenerate this file with the current version of nanopb generator.
#endif
/* Enum definitions */
/* The frequency/regulatory region the user has selected.
Note: In 1.0 builds (which must still be supported by the android app for a
long time) this field will be unpopulated.
If firmware is ever upgraded from an old 1.0ish build, the old
MyNodeInfo.region string will be used to set UserPreferences.region and the
old value will be no longer set. */
typedef enum _RegionCode {
/* TODO: REPLACE */
RegionCode_Unset = 0,
/* TODO: REPLACE */
RegionCode_US = 1,
/* TODO: REPLACE */
RegionCode_EU433 = 2,
/* TODO: REPLACE */
RegionCode_EU868 = 3,
/* TODO: REPLACE */
RegionCode_CN = 4,
/* TODO: REPLACE */
RegionCode_JP = 5,
/* TODO: REPLACE */
RegionCode_ANZ = 6,
/* TODO: REPLACE */
RegionCode_KR = 7,
/* TODO: REPLACE */
RegionCode_TW = 8,
/* TODO: REPLACE */
RegionCode_RU = 9,
/* TODO: REPLACE */
RegionCode_IN = 10,
/* TODO: REPLACE */
RegionCode_NZ865 = 11,
/* TODO: REPLACE */
RegionCode_TH = 12
} RegionCode;
/* Defines the device's role on the Mesh network
unset
Behave normally.
Router
Functions as a router */
typedef enum _Role {
/* Client device role */
Role_Client = 0,
/* ClientMute device role
This is like the client but packets will not hop over this node. Would be
useful if you want to save power by not contributing to the mesh. */
Role_ClientMute = 1,
/* Router device role.
Uses an agressive algirithem for the flood networking so packets will
prefer to be routed over this node. Also assume that this will be generally
unattended and so will turn off the wifi/ble radio as well as the oled screen. */
Role_Router = 2,
/* RouterClient device role
Uses an agressive algirithem for the flood networking so packets will
prefer to be routed over this node. Similiar power management as a regular
client, so the RouterClient can be used as both a Router and a Client. Useful
as a well placed base station that you could also use to send messages. */
Role_RouterClient = 3
} Role;
/* Sets the charge control current of devices with a battery charger that can be
configured. This is passed into the axp power management chip like on the tbeam. */
typedef enum _ChargeCurrent {
/* TODO: REPLACE */
ChargeCurrent_MAUnset = 0,
/* TODO: REPLACE */
ChargeCurrent_MA100 = 1,
/* TODO: REPLACE */
ChargeCurrent_MA190 = 2,
/* TODO: REPLACE */
ChargeCurrent_MA280 = 3,
/* TODO: REPLACE */
ChargeCurrent_MA360 = 4,
/* TODO: REPLACE */
ChargeCurrent_MA450 = 5,
/* TODO: REPLACE */
ChargeCurrent_MA550 = 6,
/* TODO: REPLACE */
ChargeCurrent_MA630 = 7,
/* TODO: REPLACE */
ChargeCurrent_MA700 = 8,
/* TODO: REPLACE */
ChargeCurrent_MA780 = 9,
/* TODO: REPLACE */
ChargeCurrent_MA880 = 10,
/* TODO: REPLACE */
ChargeCurrent_MA960 = 11,
/* TODO: REPLACE */
ChargeCurrent_MA1000 = 12,
/* TODO: REPLACE */
ChargeCurrent_MA1080 = 13,
/* TODO: REPLACE */
ChargeCurrent_MA1160 = 14,
/* TODO: REPLACE */
ChargeCurrent_MA1240 = 15,
/* TODO: REPLACE */
ChargeCurrent_MA1320 = 16
} ChargeCurrent;
/* How the GPS coordinates are displayed on the OLED screen. */
typedef enum _GpsCoordinateFormat {
/* GPS coordinates are displayed in the normal decimal degrees format:
DD.DDDDDD DDD.DDDDDD */
GpsCoordinateFormat_GpsFormatDec = 0,
/* GPS coordinates are displayed in the degrees minutes seconds format:
DD°MM'SS"C DDD°MM'SS"C, where C is the compass point representing the locations quadrant */
GpsCoordinateFormat_GpsFormatDMS = 1,
/* GPS coordinates are displayed in Universal Transverse Mercator format:
ZZB EEEEEE NNNNNNN, where Z is zone, B is band, E is easting, N is northing */
GpsCoordinateFormat_GpsFormatUTM = 2,
/* GPS coordinates are displayed in Military Grid Reference System format:
ZZB CD EEEEE NNNNN, where Z is zone, B is band, C is the east 100k square, D is the north 100k square,
E is easting, N is northing */
GpsCoordinateFormat_GpsFormatMGRS = 3,
/* GPS coordinates are displayed in Open Location Code (aka Plus Codes). */
GpsCoordinateFormat_GpsFormatOLC = 4,
/* GPS coordinates are displayed in Ordnance Survey Grid Reference (the National Grid System of the UK).
Format: AB EEEEE NNNNN, where A is the east 100k square, B is the north 100k square, E is the easting,
N is the northing */
GpsCoordinateFormat_GpsFormatOSGR = 5
} GpsCoordinateFormat;
/* Bit field of boolean configuration options, indicating which optional
fields to include when assembling POSITION messages
Longitude and latitude are always included (also time if GPS-synced)
NOTE: the more fields are included, the larger the message will be -
leading to longer airtime and a higher risk of packet loss */
typedef enum _PositionFlags {
/* Required for compilation */
PositionFlags_POS_UNDEFINED = 0,
/* Include an altitude value (if available) */
PositionFlags_POS_ALTITUDE = 1,
/* Altitude value is MSL */
PositionFlags_POS_ALT_MSL = 2,
/* Include geoidal separation */
PositionFlags_POS_GEO_SEP = 4,
/* Include the DOP value ; PDOP used by default, see below */
PositionFlags_POS_DOP = 8,
/* If POS_DOP set, send separate HDOP / VDOP values instead of PDOP */
PositionFlags_POS_HVDOP = 16,
/* Include battery level */
PositionFlags_POS_BATTERY = 32,
/* Include number of "satellites in view" */
PositionFlags_POS_SATINVIEW = 64,
/* Include a sequence number incremented per packet */
PositionFlags_POS_SEQ_NOS = 128,
/* Include positional timestamp (from GPS solution) */
PositionFlags_POS_TIMESTAMP = 256
} PositionFlags;
/* TODO: REPLACE */
typedef enum _InputEventChar {
/* TODO: REPLACE */
InputEventChar_KEY_NONE = 0,
/* TODO: REPLACE */
InputEventChar_KEY_UP = 17,
/* TODO: REPLACE */
InputEventChar_KEY_DOWN = 18,
/* TODO: REPLACE */
InputEventChar_KEY_LEFT = 19,
/* TODO: REPLACE */
InputEventChar_KEY_RIGHT = 20,
/* '\n' */
InputEventChar_KEY_SELECT = 10,
/* TODO: REPLACE */
InputEventChar_KEY_BACK = 27,
/* TODO: REPLACE */
InputEventChar_KEY_CANCEL = 24
} InputEventChar;
/* The frequency/regulatory region the user has selected.
Note: In 1.0 builds (which must still be supported by the android app for a
long time) this field will be unpopulated.
If firmware is ever upgraded from an old 1.0ish build, the old
MyNodeInfo.region string will be used to set UserPreferences.region and the
old value will be no longer set. */
typedef enum _RadioConfig_UserPreferences_Serial_Baud {
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_Default = 0,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_2400 = 1,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_4800 = 2,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_9600 = 3,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_19200 = 4,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_38400 = 5,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_57600 = 6,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_115200 = 7,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_230400 = 8,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_460800 = 9,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_576000 = 10,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_921600 = 11,
/* TODO: REPLACE */
RadioConfig_UserPreferences_Serial_Baud_BAUD_110 = 12,
RadioConfig_UserPreferences_Serial_Baud_BAUD_300 = 13,
RadioConfig_UserPreferences_Serial_Baud_BAUD_600 = 14,
RadioConfig_UserPreferences_Serial_Baud_BAUD_1200 = 15
} RadioConfig_UserPreferences_Serial_Baud;
/* Defines the device's role on the Mesh network
unset
Behave normally.
Router
Functions as a router */
typedef enum _RadioConfig_UserPreferences_Serial_Mode {
/* Client device role */
RadioConfig_UserPreferences_Serial_Mode_MODE_Default = 0,
/* ClientMute device role
This is like the client but packets will not hop over this node. Would be
useful if you want to save power by not contributing to the mesh. */
RadioConfig_UserPreferences_Serial_Mode_MODE_SIMPLE = 1,
/* Router device role.
Uses an agressive algirithem for the flood networking so packets will
prefer to be routed over this node. Also assume that this will be generally
unattended and so will turn off the wifi/ble radio as well as the oled screen. */
RadioConfig_UserPreferences_Serial_Mode_MODE_PROTO = 2
} RadioConfig_UserPreferences_Serial_Mode;
/* Struct definitions */
typedef struct _RadioConfig_UserPreferences {
uint32_t position_broadcast_secs;
uint32_t wait_bluetooth_secs;
uint32_t screen_on_secs;
uint32_t phone_timeout_secs;
uint32_t mesh_sds_timeout_secs;
uint32_t sds_secs;
uint32_t ls_secs;
uint32_t min_wake_secs;
char wifi_ssid[33];
char wifi_password[64];
bool wifi_ap_mode;
RegionCode region;
ChargeCurrent charge_current;
bool position_broadcast_smart_disabled;
Role role;
bool location_share_disabled;
bool gps_disabled;
uint32_t gps_update_interval;
uint32_t gps_attempt_time;
bool is_low_power;
bool fixed_position;
bool serial_disabled;
float frequency_offset;
char mqtt_server[32];
bool mqtt_disabled;
GpsCoordinateFormat gps_format;
bool gps_accept_2d;
uint32_t gps_max_dop;
bool factory_reset;
bool debug_log_enabled;
pb_size_t ignore_incoming_count;
uint32_t ignore_incoming[3];
bool serial_module_enabled;
bool serial_module_echo;
uint32_t serial_module_rxd;
uint32_t serial_module_txd;
uint32_t serial_module_timeout;
RadioConfig_UserPreferences_Serial_Mode serial_module_mode;
bool ext_notification_module_enabled;
uint32_t ext_notification_module_output_ms;
uint32_t ext_notification_module_output;
bool ext_notification_module_active;
bool ext_notification_module_alert_message;
bool ext_notification_module_alert_bell;
bool range_test_module_enabled;
uint32_t range_test_module_sender;
bool range_test_module_save;
uint32_t store_forward_module_records;
uint32_t store_forward_module_history_return_max;
uint32_t store_forward_module_history_return_window;
bool store_forward_module_enabled;
bool store_forward_module_heartbeat;
uint32_t position_flags;
bool is_always_powered;
uint32_t auto_screen_carousel_secs;
uint32_t on_battery_shutdown_after_secs;
uint32_t hop_limit;
char mqtt_username[32];
char mqtt_password[32];
bool is_lora_tx_disabled;
bool is_power_saving;
bool rotary1_enabled;
uint32_t inputbroker_pin_a;
uint32_t inputbroker_pin_b;
uint32_t inputbroker_pin_press;
InputEventChar inputbroker_event_cw;
InputEventChar inputbroker_event_ccw;
InputEventChar inputbroker_event_press;
bool updown1_enabled;
bool canned_message_module_enabled;
char canned_message_module_allow_input_source[16];
bool canned_message_module_send_bell;
bool mqtt_encryption_enabled;
float adc_multiplier_override;
RadioConfig_UserPreferences_Serial_Baud serial_module_baud;
} RadioConfig_UserPreferences;
/* The entire set of user settable/readable settings for our radio device.
Includes both the current channel settings and any preferences the user has
set for behavior of their node */
typedef struct _RadioConfig {
/* TODO: REPLACE */
bool has_preferences;
RadioConfig_UserPreferences preferences;
} RadioConfig;
/* Helper constants for enums */
#define _RegionCode_MIN RegionCode_Unset
#define _RegionCode_MAX RegionCode_TH
#define _RegionCode_ARRAYSIZE ((RegionCode)(RegionCode_TH+1))
#define _Role_MIN Role_Client
#define _Role_MAX Role_RouterClient
#define _Role_ARRAYSIZE ((Role)(Role_RouterClient+1))
#define _ChargeCurrent_MIN ChargeCurrent_MAUnset
#define _ChargeCurrent_MAX ChargeCurrent_MA1320
#define _ChargeCurrent_ARRAYSIZE ((ChargeCurrent)(ChargeCurrent_MA1320+1))
#define _GpsCoordinateFormat_MIN GpsCoordinateFormat_GpsFormatDec
#define _GpsCoordinateFormat_MAX GpsCoordinateFormat_GpsFormatOSGR
#define _GpsCoordinateFormat_ARRAYSIZE ((GpsCoordinateFormat)(GpsCoordinateFormat_GpsFormatOSGR+1))
#define _PositionFlags_MIN PositionFlags_POS_UNDEFINED
#define _PositionFlags_MAX PositionFlags_POS_TIMESTAMP
#define _PositionFlags_ARRAYSIZE ((PositionFlags)(PositionFlags_POS_TIMESTAMP+1))
#define _InputEventChar_MIN InputEventChar_KEY_NONE
#define _InputEventChar_MAX InputEventChar_KEY_BACK
#define _InputEventChar_ARRAYSIZE ((InputEventChar)(InputEventChar_KEY_BACK+1))
#define _RadioConfig_UserPreferences_Serial_Baud_MIN RadioConfig_UserPreferences_Serial_Baud_BAUD_Default
#define _RadioConfig_UserPreferences_Serial_Baud_MAX RadioConfig_UserPreferences_Serial_Baud_BAUD_1200
#define _RadioConfig_UserPreferences_Serial_Baud_ARRAYSIZE ((RadioConfig_UserPreferences_Serial_Baud)(RadioConfig_UserPreferences_Serial_Baud_BAUD_1200+1))
#define _RadioConfig_UserPreferences_Serial_Mode_MIN RadioConfig_UserPreferences_Serial_Mode_MODE_Default
#define _RadioConfig_UserPreferences_Serial_Mode_MAX RadioConfig_UserPreferences_Serial_Mode_MODE_PROTO
#define _RadioConfig_UserPreferences_Serial_Mode_ARRAYSIZE ((RadioConfig_UserPreferences_Serial_Mode)(RadioConfig_UserPreferences_Serial_Mode_MODE_PROTO+1))
#ifdef __cplusplus
extern "C" {
#endif
/* Initializer values for message structs */
#define RadioConfig_init_default {false, RadioConfig_UserPreferences_init_default}
#define RadioConfig_UserPreferences_init_default {0, 0, 0, 0, 0, 0, 0, 0, "", "", 0, _RegionCode_MIN, _ChargeCurrent_MIN, 0, _Role_MIN, 0, 0, 0, 0, 0, 0, 0, 0, "", 0, _GpsCoordinateFormat_MIN, 0, 0, 0, 0, 0, {0, 0, 0}, 0, 0, 0, 0, 0, _RadioConfig_UserPreferences_Serial_Mode_MIN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, "", "", 0, 0, 0, 0, 0, 0, _InputEventChar_MIN, _InputEventChar_MIN, _InputEventChar_MIN, 0, 0, "", 0, 0, 0, _RadioConfig_UserPreferences_Serial_Baud_MIN}
#define RadioConfig_init_zero {false, RadioConfig_UserPreferences_init_zero}
#define RadioConfig_UserPreferences_init_zero {0, 0, 0, 0, 0, 0, 0, 0, "", "", 0, _RegionCode_MIN, _ChargeCurrent_MIN, 0, _Role_MIN, 0, 0, 0, 0, 0, 0, 0, 0, "", 0, _GpsCoordinateFormat_MIN, 0, 0, 0, 0, 0, {0, 0, 0}, 0, 0, 0, 0, 0, _RadioConfig_UserPreferences_Serial_Mode_MIN, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, "", "", 0, 0, 0, 0, 0, 0, _InputEventChar_MIN, _InputEventChar_MIN, _InputEventChar_MIN, 0, 0, "", 0, 0, 0, _RadioConfig_UserPreferences_Serial_Baud_MIN}
/* Field tags (for use in manual encoding/decoding) */
#define RadioConfig_UserPreferences_position_broadcast_secs_tag 1
#define RadioConfig_UserPreferences_wait_bluetooth_secs_tag 4
#define RadioConfig_UserPreferences_screen_on_secs_tag 5
#define RadioConfig_UserPreferences_phone_timeout_secs_tag 6
#define RadioConfig_UserPreferences_mesh_sds_timeout_secs_tag 8
#define RadioConfig_UserPreferences_sds_secs_tag 9
#define RadioConfig_UserPreferences_ls_secs_tag 10
#define RadioConfig_UserPreferences_min_wake_secs_tag 11
#define RadioConfig_UserPreferences_wifi_ssid_tag 12
#define RadioConfig_UserPreferences_wifi_password_tag 13
#define RadioConfig_UserPreferences_wifi_ap_mode_tag 14
#define RadioConfig_UserPreferences_region_tag 15
#define RadioConfig_UserPreferences_charge_current_tag 16
#define RadioConfig_UserPreferences_position_broadcast_smart_disabled_tag 17
#define RadioConfig_UserPreferences_role_tag 18
#define RadioConfig_UserPreferences_location_share_disabled_tag 32
#define RadioConfig_UserPreferences_gps_disabled_tag 33
#define RadioConfig_UserPreferences_gps_update_interval_tag 34
#define RadioConfig_UserPreferences_gps_attempt_time_tag 36
#define RadioConfig_UserPreferences_is_low_power_tag 38
#define RadioConfig_UserPreferences_fixed_position_tag 39
#define RadioConfig_UserPreferences_serial_disabled_tag 40
#define RadioConfig_UserPreferences_frequency_offset_tag 41
#define RadioConfig_UserPreferences_mqtt_server_tag 42
#define RadioConfig_UserPreferences_mqtt_disabled_tag 43
#define RadioConfig_UserPreferences_gps_format_tag 44
#define RadioConfig_UserPreferences_gps_accept_2d_tag 45
#define RadioConfig_UserPreferences_gps_max_dop_tag 46
#define RadioConfig_UserPreferences_factory_reset_tag 100
#define RadioConfig_UserPreferences_debug_log_enabled_tag 101
#define RadioConfig_UserPreferences_ignore_incoming_tag 103
#define RadioConfig_UserPreferences_serial_module_enabled_tag 120
#define RadioConfig_UserPreferences_serial_module_echo_tag 121
#define RadioConfig_UserPreferences_serial_module_rxd_tag 122
#define RadioConfig_UserPreferences_serial_module_txd_tag 123
#define RadioConfig_UserPreferences_serial_module_timeout_tag 124
#define RadioConfig_UserPreferences_serial_module_mode_tag 125
#define RadioConfig_UserPreferences_ext_notification_module_enabled_tag 126
#define RadioConfig_UserPreferences_ext_notification_module_output_ms_tag 127
#define RadioConfig_UserPreferences_ext_notification_module_output_tag 128
#define RadioConfig_UserPreferences_ext_notification_module_active_tag 129
#define RadioConfig_UserPreferences_ext_notification_module_alert_message_tag 130
#define RadioConfig_UserPreferences_ext_notification_module_alert_bell_tag 131
#define RadioConfig_UserPreferences_range_test_module_enabled_tag 132
#define RadioConfig_UserPreferences_range_test_module_sender_tag 133
#define RadioConfig_UserPreferences_range_test_module_save_tag 134
#define RadioConfig_UserPreferences_store_forward_module_records_tag 137
#define RadioConfig_UserPreferences_store_forward_module_history_return_max_tag 138
#define RadioConfig_UserPreferences_store_forward_module_history_return_window_tag 139
#define RadioConfig_UserPreferences_store_forward_module_enabled_tag 148
#define RadioConfig_UserPreferences_store_forward_module_heartbeat_tag 149
#define RadioConfig_UserPreferences_position_flags_tag 150
#define RadioConfig_UserPreferences_is_always_powered_tag 151
#define RadioConfig_UserPreferences_auto_screen_carousel_secs_tag 152
#define RadioConfig_UserPreferences_on_battery_shutdown_after_secs_tag 153
#define RadioConfig_UserPreferences_hop_limit_tag 154
#define RadioConfig_UserPreferences_mqtt_username_tag 155
#define RadioConfig_UserPreferences_mqtt_password_tag 156
#define RadioConfig_UserPreferences_is_lora_tx_disabled_tag 157
#define RadioConfig_UserPreferences_is_power_saving_tag 158
#define RadioConfig_UserPreferences_rotary1_enabled_tag 160
#define RadioConfig_UserPreferences_inputbroker_pin_a_tag 161
#define RadioConfig_UserPreferences_inputbroker_pin_b_tag 162
#define RadioConfig_UserPreferences_inputbroker_pin_press_tag 163
#define RadioConfig_UserPreferences_inputbroker_event_cw_tag 164
#define RadioConfig_UserPreferences_inputbroker_event_ccw_tag 165
#define RadioConfig_UserPreferences_inputbroker_event_press_tag 166
#define RadioConfig_UserPreferences_updown1_enabled_tag 167
#define RadioConfig_UserPreferences_canned_message_module_enabled_tag 170
#define RadioConfig_UserPreferences_canned_message_module_allow_input_source_tag 171
#define RadioConfig_UserPreferences_canned_message_module_send_bell_tag 173
#define RadioConfig_UserPreferences_mqtt_encryption_enabled_tag 174
#define RadioConfig_UserPreferences_adc_multiplier_override_tag 175
#define RadioConfig_UserPreferences_serial_module_baud_tag 176
#define RadioConfig_preferences_tag 1
/* Struct field encoding specification for nanopb */
#define RadioConfig_FIELDLIST(X, a) \
X(a, STATIC, OPTIONAL, MESSAGE, preferences, 1)
#define RadioConfig_CALLBACK NULL
#define RadioConfig_DEFAULT NULL
#define RadioConfig_preferences_MSGTYPE RadioConfig_UserPreferences
#define RadioConfig_UserPreferences_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, UINT32, position_broadcast_secs, 1) \
X(a, STATIC, SINGULAR, UINT32, wait_bluetooth_secs, 4) \
X(a, STATIC, SINGULAR, UINT32, screen_on_secs, 5) \
X(a, STATIC, SINGULAR, UINT32, phone_timeout_secs, 6) \
X(a, STATIC, SINGULAR, UINT32, mesh_sds_timeout_secs, 8) \
X(a, STATIC, SINGULAR, UINT32, sds_secs, 9) \
X(a, STATIC, SINGULAR, UINT32, ls_secs, 10) \
X(a, STATIC, SINGULAR, UINT32, min_wake_secs, 11) \
X(a, STATIC, SINGULAR, STRING, wifi_ssid, 12) \
X(a, STATIC, SINGULAR, STRING, wifi_password, 13) \
X(a, STATIC, SINGULAR, BOOL, wifi_ap_mode, 14) \
X(a, STATIC, SINGULAR, UENUM, region, 15) \
X(a, STATIC, SINGULAR, UENUM, charge_current, 16) \
X(a, STATIC, SINGULAR, BOOL, position_broadcast_smart_disabled, 17) \
X(a, STATIC, SINGULAR, UENUM, role, 18) \
X(a, STATIC, SINGULAR, BOOL, location_share_disabled, 32) \
X(a, STATIC, SINGULAR, BOOL, gps_disabled, 33) \
X(a, STATIC, SINGULAR, UINT32, gps_update_interval, 34) \
X(a, STATIC, SINGULAR, UINT32, gps_attempt_time, 36) \
X(a, STATIC, SINGULAR, BOOL, is_low_power, 38) \
X(a, STATIC, SINGULAR, BOOL, fixed_position, 39) \
X(a, STATIC, SINGULAR, BOOL, serial_disabled, 40) \
X(a, STATIC, SINGULAR, FLOAT, frequency_offset, 41) \
X(a, STATIC, SINGULAR, STRING, mqtt_server, 42) \
X(a, STATIC, SINGULAR, BOOL, mqtt_disabled, 43) \
X(a, STATIC, SINGULAR, UENUM, gps_format, 44) \
X(a, STATIC, SINGULAR, BOOL, gps_accept_2d, 45) \
X(a, STATIC, SINGULAR, UINT32, gps_max_dop, 46) \
X(a, STATIC, SINGULAR, BOOL, factory_reset, 100) \
X(a, STATIC, SINGULAR, BOOL, debug_log_enabled, 101) \
X(a, STATIC, REPEATED, UINT32, ignore_incoming, 103) \
X(a, STATIC, SINGULAR, BOOL, serial_module_enabled, 120) \
X(a, STATIC, SINGULAR, BOOL, serial_module_echo, 121) \
X(a, STATIC, SINGULAR, UINT32, serial_module_rxd, 122) \
X(a, STATIC, SINGULAR, UINT32, serial_module_txd, 123) \
X(a, STATIC, SINGULAR, UINT32, serial_module_timeout, 124) \
X(a, STATIC, SINGULAR, UENUM, serial_module_mode, 125) \
X(a, STATIC, SINGULAR, BOOL, ext_notification_module_enabled, 126) \
X(a, STATIC, SINGULAR, UINT32, ext_notification_module_output_ms, 127) \
X(a, STATIC, SINGULAR, UINT32, ext_notification_module_output, 128) \
X(a, STATIC, SINGULAR, BOOL, ext_notification_module_active, 129) \
X(a, STATIC, SINGULAR, BOOL, ext_notification_module_alert_message, 130) \
X(a, STATIC, SINGULAR, BOOL, ext_notification_module_alert_bell, 131) \
X(a, STATIC, SINGULAR, BOOL, range_test_module_enabled, 132) \
X(a, STATIC, SINGULAR, UINT32, range_test_module_sender, 133) \
X(a, STATIC, SINGULAR, BOOL, range_test_module_save, 134) \
X(a, STATIC, SINGULAR, UINT32, store_forward_module_records, 137) \
X(a, STATIC, SINGULAR, UINT32, store_forward_module_history_return_max, 138) \
X(a, STATIC, SINGULAR, UINT32, store_forward_module_history_return_window, 139) \
X(a, STATIC, SINGULAR, BOOL, store_forward_module_enabled, 148) \
X(a, STATIC, SINGULAR, BOOL, store_forward_module_heartbeat, 149) \
X(a, STATIC, SINGULAR, UINT32, position_flags, 150) \
X(a, STATIC, SINGULAR, BOOL, is_always_powered, 151) \
X(a, STATIC, SINGULAR, UINT32, auto_screen_carousel_secs, 152) \
X(a, STATIC, SINGULAR, UINT32, on_battery_shutdown_after_secs, 153) \
X(a, STATIC, SINGULAR, UINT32, hop_limit, 154) \
X(a, STATIC, SINGULAR, STRING, mqtt_username, 155) \
X(a, STATIC, SINGULAR, STRING, mqtt_password, 156) \
X(a, STATIC, SINGULAR, BOOL, is_lora_tx_disabled, 157) \
X(a, STATIC, SINGULAR, BOOL, is_power_saving, 158) \
X(a, STATIC, SINGULAR, BOOL, rotary1_enabled, 160) \
X(a, STATIC, SINGULAR, UINT32, inputbroker_pin_a, 161) \
X(a, STATIC, SINGULAR, UINT32, inputbroker_pin_b, 162) \
X(a, STATIC, SINGULAR, UINT32, inputbroker_pin_press, 163) \
X(a, STATIC, SINGULAR, UENUM, inputbroker_event_cw, 164) \
X(a, STATIC, SINGULAR, UENUM, inputbroker_event_ccw, 165) \
X(a, STATIC, SINGULAR, UENUM, inputbroker_event_press, 166) \
X(a, STATIC, SINGULAR, BOOL, updown1_enabled, 167) \
X(a, STATIC, SINGULAR, BOOL, canned_message_module_enabled, 170) \
X(a, STATIC, SINGULAR, STRING, canned_message_module_allow_input_source, 171) \
X(a, STATIC, SINGULAR, BOOL, canned_message_module_send_bell, 173) \
X(a, STATIC, SINGULAR, BOOL, mqtt_encryption_enabled, 174) \
X(a, STATIC, SINGULAR, FLOAT, adc_multiplier_override, 175) \
X(a, STATIC, SINGULAR, UENUM, serial_module_baud, 176)
#define RadioConfig_UserPreferences_CALLBACK NULL
#define RadioConfig_UserPreferences_DEFAULT NULL
extern const pb_msgdesc_t RadioConfig_msg;
extern const pb_msgdesc_t RadioConfig_UserPreferences_msg;
/* Defines for backwards compatibility with code written before nanopb-0.4.0 */
#define RadioConfig_fields &RadioConfig_msg
#define RadioConfig_UserPreferences_fields &RadioConfig_UserPreferences_msg
/* Maximum encoded size of messages (where known) */
#define RadioConfig_UserPreferences_size 545
#define RadioConfig_size 548
#ifdef __cplusplus
} /* extern "C" */
#endif
#endif