Goby3  3.1.5a
2024.05.23
pAcommsHandler_config.proto
Go to the documentation of this file.
1 syntax = "proto2";
2 import "goby/moos/protobuf/goby_moos_app.proto";
3 import "goby/acomms/protobuf/driver_base.proto";
4 import "goby/acomms/protobuf/queue.proto";
5 import "goby/acomms/protobuf/amac_config.proto";
6 import "goby/acomms/protobuf/dccl.proto";
7 import "goby/acomms/protobuf/route.proto";
8 import "goby/moos/protobuf/translator.proto";
9 import "goby/protobuf/option_extensions.proto";
10 
11 package goby.apps.moos.protobuf;
12 
13 message pAcommsHandlerConfig
14 {
15  optional goby.moos.protobuf.GobyMOOSAppConfig common = 1 [
16  (goby.field).description =
17  "Configuration common to all Goby MOOS applications"
18  ]; // see goby_moos_app.proto
19 
20  // unique identifying integer (1-31) for this vehicle's modem
21  // setting this will set the modem_id for all the components of goby-acomms
22  required int32 modem_id = 2 [
23  (goby.field).description = "Unique number 1-31 to identify this node",
24  (goby.field).example = "1"
25  ];
26 
27  optional goby.acomms.protobuf.DriverConfig driver_cfg = 4
28  [(goby.field).description =
29  "Configure the primary acoustic modem driver (used for sending "
30  "and receiving)"];
31 
32  repeated goby.acomms.protobuf.DriverConfig listen_driver_cfg = 31
33  [(goby.field).description =
34  "Configuration for the additional drivers."];
35 
36  message DriverFailureApproach
37  {
38  enum DriverFailureTechnique
39  {
40  CONTINUALLY_RESTART_DRIVER = 1;
41  MOVE_LISTEN_DRIVER_TO_PRIMARY = 2;
42  DISABLE_AND_MOVE_LISTEN_DRIVER_TO_PRIMARY = 3;
43  }
44  optional DriverFailureTechnique technique = 1
45  [default = CONTINUALLY_RESTART_DRIVER];
46  optional int32 driver_backoff_sec = 2 [
47  (goby.field).description =
48  "Seconds to wait until restarting a failed driver.",
49  default = 60
50  ];
51  optional int32 new_driver_backoff_sec = 3 [
52  (goby.field).description =
53  "Seconds to wait until starting a listen driver in place of the failed driver.",
54  default = 5
55  ];
56  }
57  optional DriverFailureApproach driver_failure_approach = 32
58  [(goby.field).description = "How to try to deal with a failed driver"];
59 
60  // amac
61  optional goby.acomms.protobuf.MACConfig mac_cfg = 5
62  [(goby.field).description =
63  "Configure the acoustic Medium Access Control"];
64 
65  // for queue
66  optional goby.acomms.protobuf.QueueManagerConfig queue_cfg = 6
67  [(goby.field).description = "Configure the Priority Queuing layer"];
68 
69  // for dccl
70  optional goby.acomms.protobuf.DCCLConfig dccl_cfg = 7
71  [(goby.field).description =
72  "Configure the Dynamic Compact Control Language Encoding/Decoding "
73  "unit"];
74 
75  optional goby.acomms.protobuf.RouteManagerConfig route_cfg = 8
76  [(goby.field).description = "Configure the Goby Routing unit"];
77 
78  message MOOSVariables
79  {
80  optional string prefix = 1 [
81  default = "ACOMMS_",
82  (goby.field).description =
83  "Prefix all MOOS variable names with this string"
84  ];
85 
86  // serial feed
87  optional string driver_raw_in = 10 [default = "NMEA_IN"];
88  optional string driver_raw_out = 11 [default = "NMEA_OUT"];
89 
90  optional string driver_raw_msg_in = 12 [default = "RAW_INCOMING"];
91  optional string driver_raw_msg_out = 13 [default = "RAW_OUTGOING"];
92 
93  optional string driver_receive = 14 [default = "MODEM_RECEIVE"];
94  optional string driver_transmit = 15 [default = "MODEM_TRANSMIT"];
95 
96  optional string driver_cfg_update = 16
97  [default = "DRIVER_CONFIG_UPDATE"];
98 
99  optional string queue_receive = 100 [default = "QUEUE_RECEIVE"];
100  optional string queue_transmit = 101 [default = "QUEUE_TRANSMIT"];
101  // acoustic acknowledgments get written here
102  optional string queue_ack_transmission = 102 [default = "ACK"];
103  optional string queue_ack_original_msg = 103 [default = "ACK_ORIGINAL"];
104  // expired messages (ttl ends)
105  optional string queue_expire = 104 [default = "EXPIRE"];
106  optional string queue_size = 105 [default = "QSIZE"];
107  optional string queue_flush = 106 [default = "FLUSH_QUEUE"];
108 
109  optional string mac_cycle_update = 200 [default = "MAC_CYCLE_UPDATE"];
110  optional string mac_initiate_transmission = 201
111  [default = "MAC_INITIATE_TRANSMISSION"];
112  optional string mac_slot_start = 202 [default = "MAC_SLOT_START"];
113 
114  optional string config_file = 300 [default = "CONFIG"];
115  optional string config_file_request = 301 [default = "CONFIG_REQUEST"];
116 
117  optional string driver_reset = 400 [default = "DRIVER_RESET"];
118 
119  optional string ifrontseat_data_out = 500 [default = "IFS_DATA_OUT"];
120  }
121  optional MOOSVariables moos_var = 10;
122 
123  repeated string load_shared_library = 20 [
124  (goby.field).description =
125  "Path to a shared library containing compiled DCCL protobuf files. "
126  "Preferred over load_dccl_proto_file.",
127  (goby.field).example = "/usr/lib/libmy_dccl_messages.so"
128  ];
129 
130  repeated string load_proto_file = 21 [
131  (goby.field).description =
132  "Path to a DCCL protobuf file. Use load_shared_library when "
133  "possible.",
134  (goby.field).example = "/usr/include/mylib/message.proto"
135  ];
136 
137  repeated goby.moos.protobuf.TranslatorEntry translator_entry = 22
138  [(goby.field).description =
139  "Describes how to trigger (generate) a DCCL message from a MOOS "
140  "event and how to publish the contents of the message upon "
141  "receipt"];
142 
143  repeated string multiplex_create_moos_var = 23 [
144  (goby.field).description =
145  "Used primarily by goby_liaison. Specify a MOOS variable that "
146  "contains one of many TECHNIQUE_PREFIXED_PROTOBUF_TEXT_FORMAT "
147  "encoded protobuf messages. Upon receipt of a message, the "
148  "`create` directives for this type are *published* (inverse of "
149  "normal behavior), which triggers the creation of the message (if "
150  "`trigger` is set to one of the `create` MOOS variables).",
151  (goby.field).example = "LIAISON_COMMANDER_OUT"
152  ];
153 
154  repeated string dccl_frontseat_forward_name = 24
155  [(goby.field).description =
156  "Full name of DCCL Protobuf message to foward to iFrontSeat"];
157 
158  // path to text file with entries:
159  // modem_id,name,type
160  // for example
161  // 3,unicorn,auv
162  optional string modem_id_lookup_path = 101 [
163  (goby.field).description =
164  "Path to file containing mapping between modem_id and vehicle name "
165  "& type",
166  (goby.field).moos_global = "modem_id_lookup_path"
167  ];
168 
169 }