Goby v2
benthos_atm900.proto
1 
2 import "goby/common/protobuf/option_extensions.proto";
3 import "goby/acomms/protobuf/driver_base.proto";
4 import "goby/acomms/protobuf/modem_message.proto";
5 import "dccl/option_extensions.proto";
6 
7 package benthos.protobuf;
8 
9 message BenthosATM900DriverConfig
10 {
11  // 1441-1460
12  extend goby.acomms.protobuf.DriverConfig
13  {
14  optional bool factory_reset = 1441 [
15  default = false,
16  (goby.field).description =
17  "Reset modem to factory defaults prior to applying "
18  "configuration "
19  "values specified in 'config' (i.e. load values from "
20  "ffs/factcfg.ini)"
21  ];
22  optional string config_load = 1442
23  [(goby.field).description =
24  "Path to config file to load on the modem, e.g. "
25  "'ffs/standard.ini'"];
26  repeated string config = 1443
27  [(goby.field).description =
28  "Strings of configuration values to set in CLAM format, for "
29  "example \"@AcRspTmOut=10.0\""];
30  optional int32 start_timeout = 1445 [
31  default = 20,
32  (goby.field).description =
33  "Number of seconds to initialize the modem before giving up"
34  ];
35  optional uint32 max_frame_size = 1446 [
36  default = 64,
37  (goby.field).description =
38  "Enforce maximum packet size for all rates (also used if "
39  "max_frame_bytes not set in ModemTransmission)"
40  ];
41  }
42 }
43 
44 // subset of goby.acomms.protobuf.ModemTransmission
45 message BenthosHeader
46 {
47  option (dccl.msg).id = 0;
48  option (dccl.msg).max_bytes = 5;
49  option (dccl.msg).codec_version = 3;
50 
51  required goby.acomms.protobuf.ModemTransmission.TransmissionType type = 1;
52 
53  optional bool ack_requested = 3;
54  repeated int32 acked_frame = 4 [
55  (dccl.field).min = 0,
56  (dccl.field).max = 0x7,
57  (dccl.field).max_repeat = 8
58  ];
59 }
60 
61 enum TransmissionType
62 {
63  BASE_TYPE = 0;
64  BENTHOS_TWO_WAY_PING = 1; // modem 1 interrogates modem 2; modem 2 replies
65  // and modem 1 computes one way travel time
66 }
67 
68 message ReceiveStatistics
69 {
70  option (dccl.msg).unit_system = "si";
71 
72  enum CRCState
73  {
74  CRC_PASS = 1;
75  CRC_FAIL = 2;
76  }
77 
78  required CRCState crc = 1;
79  optional float multipath_delay = 2
80  [(dccl.field).units.base_dimensions = "T"];
81  optional float snr = 3;
82  optional float relative_speed = 4
83  [(dccl.field).units.base_dimensions = "LT^-1"];
84  optional float auto_gain_control = 5;
85  optional int32 corrected_channel_error = 6;
86 }
87 
88 message RangingReply
89 {
90  required double one_way_travel_time = 1
91  [(dccl.field).units.unit = "si::second"];
92 }
93 
94 extend goby.acomms.protobuf.ModemTransmission
95 {
96  optional TransmissionType type = 1401 [
97  (goby.field).description =
98  "Type of transmission if base `type` == DRIVER_SPECIFIC",
99  default = BASE_TYPE
100  ];
101  optional ReceiveStatistics receive_stat = 1402;
102  optional RangingReply ranging_reply = 1403;
103 }