Files
vicliu d320b6511d Unify PlatformIO and ESP-IDF around a shared UI/runtime shellRefactor/repo structure (#11)
* Unify PlatformIO and ESP-IDF around a shared UI/runtime shell
2026-03-12 01:17:46 +08:00

121 lines
4.2 KiB
C

/* Automatically generated nanopb header */
/* Generated by nanopb-0.4.9.1 */
#ifndef PB_MESHTASTIC_MESHTASTIC_INTERDEVICE_PB_H_INCLUDED
#define PB_MESHTASTIC_MESHTASTIC_INTERDEVICE_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 */
typedef enum _meshtastic_MessageType
{
meshtastic_MessageType_ACK = 0,
meshtastic_MessageType_COLLECT_INTERVAL = 160, /* in ms */
meshtastic_MessageType_BEEP_ON = 161, /* duration ms */
meshtastic_MessageType_BEEP_OFF = 162, /* cancel prematurely */
meshtastic_MessageType_SHUTDOWN = 163,
meshtastic_MessageType_POWER_ON = 164,
meshtastic_MessageType_SCD41_TEMP = 176,
meshtastic_MessageType_SCD41_HUMIDITY = 177,
meshtastic_MessageType_SCD41_CO2 = 178,
meshtastic_MessageType_AHT20_TEMP = 179,
meshtastic_MessageType_AHT20_HUMIDITY = 180,
meshtastic_MessageType_TVOC_INDEX = 181
} meshtastic_MessageType;
/* Struct definitions */
typedef struct _meshtastic_SensorData
{
/* The message type */
meshtastic_MessageType type;
pb_size_t which_data;
union
{
float float_value;
uint32_t uint32_value;
} data;
} meshtastic_SensorData;
typedef struct _meshtastic_InterdeviceMessage
{
pb_size_t which_data;
union
{
char nmea[1024];
meshtastic_SensorData sensor;
} data;
} meshtastic_InterdeviceMessage;
#ifdef __cplusplus
extern "C"
{
#endif
/* Helper constants for enums */
#define _meshtastic_MessageType_MIN meshtastic_MessageType_ACK
#define _meshtastic_MessageType_MAX meshtastic_MessageType_TVOC_INDEX
#define _meshtastic_MessageType_ARRAYSIZE ((meshtastic_MessageType)(meshtastic_MessageType_TVOC_INDEX + 1))
#define meshtastic_SensorData_type_ENUMTYPE meshtastic_MessageType
/* Initializer values for message structs */
#define meshtastic_SensorData_init_default \
{ \
_meshtastic_MessageType_MIN, 0, { 0 } \
}
#define meshtastic_InterdeviceMessage_init_default \
{ \
0, { "" } \
}
#define meshtastic_SensorData_init_zero \
{ \
_meshtastic_MessageType_MIN, 0, { 0 } \
}
#define meshtastic_InterdeviceMessage_init_zero \
{ \
0, { "" } \
}
/* Field tags (for use in manual encoding/decoding) */
#define meshtastic_SensorData_type_tag 1
#define meshtastic_SensorData_float_value_tag 2
#define meshtastic_SensorData_uint32_value_tag 3
#define meshtastic_InterdeviceMessage_nmea_tag 1
#define meshtastic_InterdeviceMessage_sensor_tag 2
/* Struct field encoding specification for nanopb */
#define meshtastic_SensorData_FIELDLIST(X, a) \
X(a, STATIC, SINGULAR, UENUM, type, 1) \
X(a, STATIC, ONEOF, FLOAT, (data, float_value, data.float_value), 2) \
X(a, STATIC, ONEOF, UINT32, (data, uint32_value, data.uint32_value), 3)
#define meshtastic_SensorData_CALLBACK NULL
#define meshtastic_SensorData_DEFAULT NULL
#define meshtastic_InterdeviceMessage_FIELDLIST(X, a) \
X(a, STATIC, ONEOF, STRING, (data, nmea, data.nmea), 1) \
X(a, STATIC, ONEOF, MESSAGE, (data, sensor, data.sensor), 2)
#define meshtastic_InterdeviceMessage_CALLBACK NULL
#define meshtastic_InterdeviceMessage_DEFAULT NULL
#define meshtastic_InterdeviceMessage_data_sensor_MSGTYPE meshtastic_SensorData
extern const pb_msgdesc_t meshtastic_SensorData_msg;
extern const pb_msgdesc_t meshtastic_InterdeviceMessage_msg;
/* Defines for backwards compatibility with code written before nanopb-0.4.0 */
#define meshtastic_SensorData_fields &meshtastic_SensorData_msg
#define meshtastic_InterdeviceMessage_fields &meshtastic_InterdeviceMessage_msg
/* Maximum encoded size of messages (where known) */
#define MESHTASTIC_MESHTASTIC_INTERDEVICE_PB_H_MAX_SIZE meshtastic_InterdeviceMessage_size
#define meshtastic_InterdeviceMessage_size 1026
#define meshtastic_SensorData_size 9
#ifdef __cplusplus
} /* extern "C" */
#endif
#endif