Itron LCE research protocol on July 12, 2017. The protocol is based on Protocol Buffers developed by Google.

Dependents:   ProtocBufTest Borsch

Committer:
sgnezdov
Date:
Thu Aug 03 00:07:26 2017 +0000
Revision:
2:67db916a7e08
Parent:
0:1139a294684a
updated protocol to use proper data types

Who changed what in which revision?

UserRevisionLine numberNew contents of line
sgnezdov 0:1139a294684a 1 /* Automatically generated nanopb header */
sgnezdov 0:1139a294684a 2 /* Generated by nanopb-0.3.8 at Wed Jul 12 11:04:33 2017. */
sgnezdov 0:1139a294684a 3
sgnezdov 0:1139a294684a 4 #ifndef PB_PROTOCOL_COMMAND_PB_H_INCLUDED
sgnezdov 0:1139a294684a 5 #define PB_PROTOCOL_COMMAND_PB_H_INCLUDED
sgnezdov 0:1139a294684a 6 #include <pb.h>
sgnezdov 0:1139a294684a 7
sgnezdov 0:1139a294684a 8 #include "google/protobuf/timestamp.pb.h"
sgnezdov 0:1139a294684a 9
sgnezdov 0:1139a294684a 10 /* @@protoc_insertion_point(includes) */
sgnezdov 0:1139a294684a 11 #if PB_PROTO_HEADER_VERSION != 30
sgnezdov 0:1139a294684a 12 #error Regenerate this file with the current version of nanopb generator.
sgnezdov 0:1139a294684a 13 #endif
sgnezdov 0:1139a294684a 14
sgnezdov 0:1139a294684a 15 #ifdef __cplusplus
sgnezdov 0:1139a294684a 16 extern "C" {
sgnezdov 0:1139a294684a 17 #endif
sgnezdov 0:1139a294684a 18
sgnezdov 0:1139a294684a 19 /* Enum definitions */
sgnezdov 0:1139a294684a 20 typedef enum _protocol_CommandStatus {
sgnezdov 0:1139a294684a 21 protocol_CommandStatus_Success = 0
sgnezdov 0:1139a294684a 22 } protocol_CommandStatus;
sgnezdov 0:1139a294684a 23 #define _protocol_CommandStatus_MIN protocol_CommandStatus_Success
sgnezdov 0:1139a294684a 24 #define _protocol_CommandStatus_MAX protocol_CommandStatus_Success
sgnezdov 0:1139a294684a 25 #define _protocol_CommandStatus_ARRAYSIZE ((protocol_CommandStatus)(protocol_CommandStatus_Success+1))
sgnezdov 0:1139a294684a 26
sgnezdov 0:1139a294684a 27 /* Struct definitions */
sgnezdov 0:1139a294684a 28 typedef struct _protocol_CommandBatch {
sgnezdov 0:1139a294684a 29 pb_callback_t sn;
sgnezdov 0:1139a294684a 30 pb_callback_t items;
sgnezdov 0:1139a294684a 31 /* @@protoc_insertion_point(struct:protocol_CommandBatch) */
sgnezdov 0:1139a294684a 32 } protocol_CommandBatch;
sgnezdov 0:1139a294684a 33
sgnezdov 0:1139a294684a 34 typedef struct _protocol_CommandResponseBatch {
sgnezdov 0:1139a294684a 35 pb_callback_t sn;
sgnezdov 0:1139a294684a 36 pb_callback_t items;
sgnezdov 0:1139a294684a 37 /* @@protoc_insertion_point(struct:protocol_CommandResponseBatch) */
sgnezdov 0:1139a294684a 38 } protocol_CommandResponseBatch;
sgnezdov 0:1139a294684a 39
sgnezdov 0:1139a294684a 40 typedef struct _protocol_SecureCommandBatch {
sgnezdov 0:1139a294684a 41 pb_callback_t signature;
sgnezdov 0:1139a294684a 42 pb_callback_t content;
sgnezdov 0:1139a294684a 43 /* @@protoc_insertion_point(struct:protocol_SecureCommandBatch) */
sgnezdov 0:1139a294684a 44 } protocol_SecureCommandBatch;
sgnezdov 0:1139a294684a 45
sgnezdov 0:1139a294684a 46 typedef struct _protocol_Command {
sgnezdov 0:1139a294684a 47 google_protobuf_Timestamp issuedDT;
sgnezdov 0:1139a294684a 48 uint32_t commandType;
sgnezdov 0:1139a294684a 49 pb_callback_t payload;
sgnezdov 0:1139a294684a 50 /* @@protoc_insertion_point(struct:protocol_Command) */
sgnezdov 0:1139a294684a 51 } protocol_Command;
sgnezdov 0:1139a294684a 52
sgnezdov 0:1139a294684a 53 typedef struct _protocol_CommandResponse {
sgnezdov 0:1139a294684a 54 google_protobuf_Timestamp issuedDT;
sgnezdov 0:1139a294684a 55 protocol_CommandStatus status;
sgnezdov 0:1139a294684a 56 /* @@protoc_insertion_point(struct:protocol_CommandResponse) */
sgnezdov 0:1139a294684a 57 } protocol_CommandResponse;
sgnezdov 0:1139a294684a 58
sgnezdov 0:1139a294684a 59 /* Default values for struct fields */
sgnezdov 0:1139a294684a 60
sgnezdov 0:1139a294684a 61 /* Initializer values for message structs */
sgnezdov 0:1139a294684a 62 #define protocol_Command_init_default {google_protobuf_Timestamp_init_default, 0, {{NULL}, NULL}}
sgnezdov 0:1139a294684a 63 #define protocol_CommandBatch_init_default {{{NULL}, NULL}, {{NULL}, NULL}}
sgnezdov 0:1139a294684a 64 #define protocol_SecureCommandBatch_init_default {{{NULL}, NULL}, {{NULL}, NULL}}
sgnezdov 0:1139a294684a 65 #define protocol_CommandResponse_init_default {google_protobuf_Timestamp_init_default, (protocol_CommandStatus)0}
sgnezdov 0:1139a294684a 66 #define protocol_CommandResponseBatch_init_default {{{NULL}, NULL}, {{NULL}, NULL}}
sgnezdov 0:1139a294684a 67 #define protocol_Command_init_zero {google_protobuf_Timestamp_init_zero, 0, {{NULL}, NULL}}
sgnezdov 0:1139a294684a 68 #define protocol_CommandBatch_init_zero {{{NULL}, NULL}, {{NULL}, NULL}}
sgnezdov 0:1139a294684a 69 #define protocol_SecureCommandBatch_init_zero {{{NULL}, NULL}, {{NULL}, NULL}}
sgnezdov 0:1139a294684a 70 #define protocol_CommandResponse_init_zero {google_protobuf_Timestamp_init_zero, (protocol_CommandStatus)0}
sgnezdov 0:1139a294684a 71 #define protocol_CommandResponseBatch_init_zero {{{NULL}, NULL}, {{NULL}, NULL}}
sgnezdov 0:1139a294684a 72
sgnezdov 0:1139a294684a 73 /* Field tags (for use in manual encoding/decoding) */
sgnezdov 0:1139a294684a 74 #define protocol_CommandBatch_sn_tag 1
sgnezdov 0:1139a294684a 75 #define protocol_CommandBatch_items_tag 10
sgnezdov 0:1139a294684a 76 #define protocol_CommandResponseBatch_sn_tag 1
sgnezdov 0:1139a294684a 77 #define protocol_CommandResponseBatch_items_tag 2
sgnezdov 0:1139a294684a 78 #define protocol_SecureCommandBatch_signature_tag 1
sgnezdov 0:1139a294684a 79 #define protocol_SecureCommandBatch_content_tag 2
sgnezdov 0:1139a294684a 80 #define protocol_Command_issuedDT_tag 1
sgnezdov 0:1139a294684a 81 #define protocol_Command_commandType_tag 2
sgnezdov 0:1139a294684a 82 #define protocol_Command_payload_tag 10
sgnezdov 0:1139a294684a 83 #define protocol_CommandResponse_issuedDT_tag 1
sgnezdov 0:1139a294684a 84 #define protocol_CommandResponse_status_tag 2
sgnezdov 0:1139a294684a 85
sgnezdov 0:1139a294684a 86 /* Struct field encoding specification for nanopb */
sgnezdov 0:1139a294684a 87 extern const pb_field_t protocol_Command_fields[4];
sgnezdov 0:1139a294684a 88 extern const pb_field_t protocol_CommandBatch_fields[3];
sgnezdov 0:1139a294684a 89 extern const pb_field_t protocol_SecureCommandBatch_fields[3];
sgnezdov 0:1139a294684a 90 extern const pb_field_t protocol_CommandResponse_fields[3];
sgnezdov 0:1139a294684a 91 extern const pb_field_t protocol_CommandResponseBatch_fields[3];
sgnezdov 0:1139a294684a 92
sgnezdov 0:1139a294684a 93 /* Maximum encoded size of messages (where known) */
sgnezdov 0:1139a294684a 94 /* protocol_Command_size depends on runtime parameters */
sgnezdov 0:1139a294684a 95 /* protocol_CommandBatch_size depends on runtime parameters */
sgnezdov 0:1139a294684a 96 /* protocol_SecureCommandBatch_size depends on runtime parameters */
sgnezdov 0:1139a294684a 97 #define protocol_CommandResponse_size 26
sgnezdov 0:1139a294684a 98 /* protocol_CommandResponseBatch_size depends on runtime parameters */
sgnezdov 0:1139a294684a 99
sgnezdov 0:1139a294684a 100 /* Message IDs (where set with "msgid" option) */
sgnezdov 0:1139a294684a 101 #ifdef PB_MSGID
sgnezdov 0:1139a294684a 102
sgnezdov 0:1139a294684a 103 #define COMMAND_MESSAGES \
sgnezdov 0:1139a294684a 104
sgnezdov 0:1139a294684a 105
sgnezdov 0:1139a294684a 106 #endif
sgnezdov 0:1139a294684a 107
sgnezdov 0:1139a294684a 108 #ifdef __cplusplus
sgnezdov 0:1139a294684a 109 } /* extern "C" */
sgnezdov 0:1139a294684a 110 #endif
sgnezdov 0:1139a294684a 111 /* @@protoc_insertion_point(eof) */
sgnezdov 0:1139a294684a 112
sgnezdov 0:1139a294684a 113 #endif