@blueyerobotics/protocol-definitions 3.4.0-8187f91a → 3.4.0-efe27311

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/control.d.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
2
2
  import { SetAquaTrollConnectionStatus, SetAquaTrollParameterUnit } from "./aquatroll.js";
3
3
  import { Annotation, AutoAltitudeState, AutoDepthState, AutoHeadingState, AutoPilotHeaveState, AutoPilotSurgeYawState, BoundingBox, CameraPanTiltZoom, CartesianManipulatorInput, ConnectionDuration, CylindricalManipulatorInput, FilterMessage, GenericServo, GripperVelocities, GuestPortRestartInfo, KnownPoseManipulatorInput, Laser, LatLongPosition, Lights, MarineSnowFilterFrames, MotionInput, MultibeamConfig, MultibeamServo, OperatorInfo, PingerConfiguration, RecordOn, ResetPositionSettings, StationKeepingState, StorageLocation, SystemTime, TiltStabilizationState, TiltVelocity, VisionTrackingState, WaterDensity, WeatherVaningState } from "./message_formats.js";
4
+ import { Instruction } from "./mission_planning.js";
4
5
  /**
5
6
  * Control
6
7
  *
@@ -126,6 +127,30 @@ export interface PauseMissionCtrl {
126
127
  /** Clear the loaded mission. */
127
128
  export interface ClearMissionCtrl {
128
129
  }
130
+ /** Clears the mission rules. */
131
+ export interface ClearMissionRulesCtrl {
132
+ }
133
+ /**
134
+ * Run a single instruction right away, outside any mission.
135
+ *
136
+ * Instructions that do not move the drone (camera, tilt, lights, laser, multibeam, tilt
137
+ * stabilization, CV model, annotation, cruise speed) run in any mission state, alongside a running
138
+ * mission. Instructions that move the drone (waypoint, go to home, transect, survey, depth set
139
+ * point, relative depth, go to surface or seabed, control mode, heading) run only while no
140
+ * mission is running, one at a time, and are rejected otherwise. A wait is rejected. The outcome
141
+ * is reported in InstructionResultTel with the same request_id.
142
+ */
143
+ export interface RunInstructionCtrl {
144
+ /** Instruction to execute. */
145
+ instruction: Instruction | undefined;
146
+ /** Client-chosen id, echoed in InstructionResultTel. */
147
+ requestId: number;
148
+ }
149
+ /** Cancel an instruction started with RunInstructionCtrl. */
150
+ export interface CancelInstructionCtrl {
151
+ /** The request_id given to RunInstructionCtrl. */
152
+ requestId: number;
153
+ }
129
154
  /** Issue a command to reset the position estimate. */
130
155
  export interface ResetPositionCtrl {
131
156
  /** Reset settings. */
@@ -357,6 +382,9 @@ export declare const VisionTrackingCtrl: MessageFns<VisionTrackingCtrl>;
357
382
  export declare const RunMissionCtrl: MessageFns<RunMissionCtrl>;
358
383
  export declare const PauseMissionCtrl: MessageFns<PauseMissionCtrl>;
359
384
  export declare const ClearMissionCtrl: MessageFns<ClearMissionCtrl>;
385
+ export declare const ClearMissionRulesCtrl: MessageFns<ClearMissionRulesCtrl>;
386
+ export declare const RunInstructionCtrl: MessageFns<RunInstructionCtrl>;
387
+ export declare const CancelInstructionCtrl: MessageFns<CancelInstructionCtrl>;
360
388
  export declare const ResetPositionCtrl: MessageFns<ResetPositionCtrl>;
361
389
  export declare const ResetOdometerCtrl: MessageFns<ResetOdometerCtrl>;
362
390
  export declare const CalibrateDvlGyroCtrl: MessageFns<CalibrateDvlGyroCtrl>;
package/dist/control.js CHANGED
@@ -7,6 +7,7 @@
7
7
  import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
8
8
  import { SetAquaTrollConnectionStatus, SetAquaTrollParameterUnit } from "./aquatroll.js";
9
9
  import { Annotation, AutoAltitudeState, AutoDepthState, AutoHeadingState, AutoPilotHeaveState, AutoPilotSurgeYawState, BoundingBox, CameraPanTiltZoom, CartesianManipulatorInput, ConnectionDuration, CylindricalManipulatorInput, FilterMessage, GenericServo, GripperVelocities, GuestPortRestartInfo, KnownPoseManipulatorInput, Laser, LatLongPosition, Lights, MarineSnowFilterFrames, MotionInput, MultibeamConfig, MultibeamServo, OperatorInfo, PingerConfiguration, RecordOn, ResetPositionSettings, StationKeepingState, storageLocationFromJSON, storageLocationToJSON, SystemTime, TiltStabilizationState, TiltVelocity, VisionTrackingState, WaterDensity, WeatherVaningState, } from "./message_formats.js";
10
+ import { Instruction } from "./mission_planning.js";
10
11
  function createBaseMotionInputCtrl() {
11
12
  return { motionInput: undefined };
12
13
  }
@@ -1162,6 +1163,164 @@ export const ClearMissionCtrl = {
1162
1163
  return message;
1163
1164
  },
1164
1165
  };
1166
+ function createBaseClearMissionRulesCtrl() {
1167
+ return {};
1168
+ }
1169
+ export const ClearMissionRulesCtrl = {
1170
+ encode(_, writer = new BinaryWriter()) {
1171
+ return writer;
1172
+ },
1173
+ decode(input, length) {
1174
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1175
+ const end = length === undefined ? reader.len : reader.pos + length;
1176
+ const message = createBaseClearMissionRulesCtrl();
1177
+ while (reader.pos < end) {
1178
+ const tag = reader.uint32();
1179
+ switch (tag >>> 3) {
1180
+ }
1181
+ if ((tag & 7) === 4 || tag === 0) {
1182
+ break;
1183
+ }
1184
+ reader.skip(tag & 7);
1185
+ }
1186
+ return message;
1187
+ },
1188
+ fromJSON(_) {
1189
+ return {};
1190
+ },
1191
+ toJSON(_) {
1192
+ const obj = {};
1193
+ return obj;
1194
+ },
1195
+ create(base) {
1196
+ return ClearMissionRulesCtrl.fromPartial(base ?? {});
1197
+ },
1198
+ fromPartial(_) {
1199
+ const message = createBaseClearMissionRulesCtrl();
1200
+ return message;
1201
+ },
1202
+ };
1203
+ function createBaseRunInstructionCtrl() {
1204
+ return { instruction: undefined, requestId: 0 };
1205
+ }
1206
+ export const RunInstructionCtrl = {
1207
+ encode(message, writer = new BinaryWriter()) {
1208
+ if (message.instruction !== undefined) {
1209
+ Instruction.encode(message.instruction, writer.uint32(10).fork()).join();
1210
+ }
1211
+ if (message.requestId !== 0) {
1212
+ writer.uint32(16).uint32(message.requestId);
1213
+ }
1214
+ return writer;
1215
+ },
1216
+ decode(input, length) {
1217
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1218
+ const end = length === undefined ? reader.len : reader.pos + length;
1219
+ const message = createBaseRunInstructionCtrl();
1220
+ while (reader.pos < end) {
1221
+ const tag = reader.uint32();
1222
+ switch (tag >>> 3) {
1223
+ case 1: {
1224
+ if (tag !== 10) {
1225
+ break;
1226
+ }
1227
+ message.instruction = Instruction.decode(reader, reader.uint32());
1228
+ continue;
1229
+ }
1230
+ case 2: {
1231
+ if (tag !== 16) {
1232
+ break;
1233
+ }
1234
+ message.requestId = reader.uint32();
1235
+ continue;
1236
+ }
1237
+ }
1238
+ if ((tag & 7) === 4 || tag === 0) {
1239
+ break;
1240
+ }
1241
+ reader.skip(tag & 7);
1242
+ }
1243
+ return message;
1244
+ },
1245
+ fromJSON(object) {
1246
+ return {
1247
+ instruction: isSet(object.instruction) ? Instruction.fromJSON(object.instruction) : undefined,
1248
+ requestId: isSet(object.requestId) ? gt.Number(object.requestId) : 0,
1249
+ };
1250
+ },
1251
+ toJSON(message) {
1252
+ const obj = {};
1253
+ if (message.instruction !== undefined) {
1254
+ obj.instruction = Instruction.toJSON(message.instruction);
1255
+ }
1256
+ if (message.requestId !== 0) {
1257
+ obj.requestId = Math.round(message.requestId);
1258
+ }
1259
+ return obj;
1260
+ },
1261
+ create(base) {
1262
+ return RunInstructionCtrl.fromPartial(base ?? {});
1263
+ },
1264
+ fromPartial(object) {
1265
+ const message = createBaseRunInstructionCtrl();
1266
+ message.instruction = (object.instruction !== undefined && object.instruction !== null)
1267
+ ? Instruction.fromPartial(object.instruction)
1268
+ : undefined;
1269
+ message.requestId = object.requestId ?? 0;
1270
+ return message;
1271
+ },
1272
+ };
1273
+ function createBaseCancelInstructionCtrl() {
1274
+ return { requestId: 0 };
1275
+ }
1276
+ export const CancelInstructionCtrl = {
1277
+ encode(message, writer = new BinaryWriter()) {
1278
+ if (message.requestId !== 0) {
1279
+ writer.uint32(8).uint32(message.requestId);
1280
+ }
1281
+ return writer;
1282
+ },
1283
+ decode(input, length) {
1284
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1285
+ const end = length === undefined ? reader.len : reader.pos + length;
1286
+ const message = createBaseCancelInstructionCtrl();
1287
+ while (reader.pos < end) {
1288
+ const tag = reader.uint32();
1289
+ switch (tag >>> 3) {
1290
+ case 1: {
1291
+ if (tag !== 8) {
1292
+ break;
1293
+ }
1294
+ message.requestId = reader.uint32();
1295
+ continue;
1296
+ }
1297
+ }
1298
+ if ((tag & 7) === 4 || tag === 0) {
1299
+ break;
1300
+ }
1301
+ reader.skip(tag & 7);
1302
+ }
1303
+ return message;
1304
+ },
1305
+ fromJSON(object) {
1306
+ return { requestId: isSet(object.requestId) ? gt.Number(object.requestId) : 0 };
1307
+ },
1308
+ toJSON(message) {
1309
+ const obj = {};
1310
+ if (message.requestId !== 0) {
1311
+ obj.requestId = Math.round(message.requestId);
1312
+ }
1313
+ return obj;
1314
+ },
1315
+ create(base) {
1316
+ return CancelInstructionCtrl.fromPartial(base ?? {});
1317
+ },
1318
+ fromPartial(object) {
1319
+ const message = createBaseCancelInstructionCtrl();
1320
+ message.requestId = object.requestId ?? 0;
1321
+ return message;
1322
+ },
1323
+ };
1165
1324
  function createBaseResetPositionCtrl() {
1166
1325
  return { settings: undefined };
1167
1326
  }
@@ -1,6 +1,7 @@
1
1
  export * from "./aquatroll.js";
2
2
  export * from "./message_formats.js";
3
- export * from "./control.js";
4
3
  export * from "./mission_planning.js";
4
+ export * from "./control.js";
5
+ export * from "./slam.js";
5
6
  export * from "./req_rep.js";
6
7
  export * from "./telemetry.js";
@@ -5,7 +5,8 @@
5
5
  /* eslint-disable */
6
6
  export * from "./aquatroll.js";
7
7
  export * from "./message_formats.js";
8
- export * from "./control.js";
9
8
  export * from "./mission_planning.js";
9
+ export * from "./control.js";
10
+ export * from "./slam.js";
10
11
  export * from "./req_rep.js";
11
12
  export * from "./telemetry.js";
@@ -166,6 +166,22 @@ export declare enum NotificationType {
166
166
  NOTIFICATION_TYPE_VIDEO_PARTITION_NOT_MOUNTED = 33,
167
167
  /** NOTIFICATION_TYPE_DVL_PROTOCOL_UNSUPPORTED - DVL firmware speaks a protocol version Blunux does not support. */
168
168
  NOTIFICATION_TYPE_DVL_PROTOCOL_UNSUPPORTED = 34,
169
+ /** NOTIFICATION_TYPE_INSTRUCTION_STARTED - An instruction started; the value names it or is its target. */
170
+ NOTIFICATION_TYPE_INSTRUCTION_STARTED = 35,
171
+ /** NOTIFICATION_TYPE_MISSION_PAUSED_BY_INSTRUCTION - Paused after the instruction whose id is the value. */
172
+ NOTIFICATION_TYPE_MISSION_PAUSED_BY_INSTRUCTION = 36,
173
+ /** NOTIFICATION_TYPE_MISSION_UPDATED - The loaded mission was changed; the value says what changed. */
174
+ NOTIFICATION_TYPE_MISSION_UPDATED = 37,
175
+ /** NOTIFICATION_TYPE_MISSION_RULE_FIRED - A mission rule fired; the value is its name. */
176
+ NOTIFICATION_TYPE_MISSION_RULE_FIRED = 38,
177
+ /** NOTIFICATION_TYPE_MISSION_RULE_RELEASED - A mission rule released; the value is its name. */
178
+ NOTIFICATION_TYPE_MISSION_RULE_RELEASED = 39,
179
+ /**
180
+ * NOTIFICATION_TYPE_MULTIBEAM_SONAR_MISMATCH - A multibeam instruction was made for a different sonar than the one the multibeam driver
181
+ * reports; the value is the instruction's id. A MultibeamConfigCommand is skipped. An
182
+ * ActivateMultibeamCommand still starts or stops the driver, but without its configuration.
183
+ */
184
+ NOTIFICATION_TYPE_MULTIBEAM_SONAR_MISMATCH = 40,
169
185
  UNRECOGNIZED = -1
170
186
  }
171
187
  export declare function notificationTypeFromJSON(object: any): NotificationType;
@@ -516,6 +532,12 @@ export declare enum GuestPortDeviceID {
516
532
  GUEST_PORT_DEVICE_ID_OUTLAND_TECHNOLOGY_MP200 = 51,
517
533
  /** GUEST_PORT_DEVICE_ID_REACH_ROBOTICS_REACH_ALPHA_5 - Reach Robotics Reach Alpha 5 Manipulator. */
518
534
  GUEST_PORT_DEVICE_ID_REACH_ROBOTICS_REACH_ALPHA_5 = 52,
535
+ /** GUEST_PORT_DEVICE_ID_BLUEYE_MULTIBEAM_SERVO_V3 - Blueye Multibeam Skid Servo V3. */
536
+ GUEST_PORT_DEVICE_ID_BLUEYE_MULTIBEAM_SERVO_V3 = 53,
537
+ /** GUEST_PORT_DEVICE_ID_BLUE_ROBOTICS_DETACHABLE_NEWTON_V2 - Detachable Blue Robotics Newton V2. */
538
+ GUEST_PORT_DEVICE_ID_BLUE_ROBOTICS_DETACHABLE_NEWTON_V2 = 54,
539
+ /** GUEST_PORT_DEVICE_ID_BLUEYE_SCALING_LASER_V2 - Blueye Scaling Laser V2. */
540
+ GUEST_PORT_DEVICE_ID_BLUEYE_SCALING_LASER_V2 = 55,
519
541
  UNRECOGNIZED = -1
520
542
  }
521
543
  export declare function guestPortDeviceIDFromJSON(object: any): GuestPortDeviceID;
@@ -563,6 +585,10 @@ export declare enum GuestPortCapability {
563
585
  GUEST_PORT_CAPABILITY_PWM = 6,
564
586
  /** GUEST_PORT_CAPABILITY_ETHERNET_1G - Gigabit Ethernet. */
565
587
  GUEST_PORT_CAPABILITY_ETHERNET_1G = 7,
588
+ /** GUEST_PORT_CAPABILITY_I2C_IO - TCA9536 I/O expander. */
589
+ GUEST_PORT_CAPABILITY_I2C_IO = 8,
590
+ /** GUEST_PORT_CAPABILITY_I2C_IO_V2 - PCA9554A I/O expander. */
591
+ GUEST_PORT_CAPABILITY_I2C_IO_V2 = 9,
566
592
  UNRECOGNIZED = -1
567
593
  }
568
594
  export declare function guestPortCapabilityFromJSON(object: any): GuestPortCapability;
@@ -881,6 +907,11 @@ export interface LaserDetection {
881
907
  correctedPixelDistance: number;
882
908
  /** Estimated subject distance (m). */
883
909
  estimatedDistance: number;
910
+ /**
911
+ * Id of the camera frame the detection was computed from, 0 if unknown. Matches the frame id
912
+ * embedded in recorded video; ModelDetections describes the format.
913
+ */
914
+ frameId: number;
884
915
  }
885
916
  /** Latitude and longitude position in WGS 84 decimal degrees format. */
886
917
  export interface LatLongPosition {
@@ -1651,7 +1682,7 @@ export interface DvlVelocity {
1651
1682
  deltaTime: number;
1652
1683
  /** Figure of merit, a measure of the accuracy of the velocities (m/s). */
1653
1684
  fom: number;
1654
- /** Velocity, x forward, y left, z down (m/s). */
1685
+ /** Velocity, x forward, y right, z down (m/s). */
1655
1686
  velocity: Vector3 | undefined;
1656
1687
  /** Water tracking status. */
1657
1688
  isWaterTracking: boolean;
@@ -1981,6 +2012,13 @@ export interface DroneInfo {
1981
2012
  powerSource: PowerSource;
1982
2013
  /** Intrinsic calibration of the main camera. Unset when unknown. */
1983
2014
  mainCameraCalibration: CameraCalibration | undefined;
2015
+ /** Dive number, the counter at the end of the logfile name. 0 when unknown. */
2016
+ diveNumber: number;
2017
+ /**
2018
+ * Name of the dive logfile without extension (e.g. BYEDP070012_ea9ac92e040aa9d4_00231).
2019
+ * Unlike dive_number it stays unique when the counter restarts, e.g. after the storage is replaced.
2020
+ */
2021
+ logName: string;
1984
2022
  }
1985
2023
  /** Known error states for the drone. */
1986
2024
  export interface ErrorFlags {
@@ -3017,7 +3055,26 @@ export interface ObjectDetection {
3017
3055
  /** Instance segmentation mask (absent if model has no segmentation). */
3018
3056
  mask: SegmentationMask | undefined;
3019
3057
  }
3020
- /** A list of object detections from a single model for a single video frame. */
3058
+ /**
3059
+ * A list of object detections from a single model for a single video frame.
3060
+ *
3061
+ * frame_id matches detections to the exact frame of a recording. The video pipeline on the X3 Ultra
3062
+ * assigns an id to each camera frame once, passes it to the computer vision models and the recorder,
3063
+ * and writes it into the recorded video. An id is never reused within one boot of the drone, and stays
3064
+ * below 2^53, so it is exact as a JavaScript number. The models do not process every frame, so the ids
3065
+ * of successive results can skip.
3066
+ *
3067
+ * Recorded video carries the id in a user_data_unregistered SEI message (payload type 5), one per access
3068
+ * unit, placed before the first slice: NAL unit type 6 in H.264 and PREFIX_SEI_NUT (type 39) in H.265.
3069
+ * The payload is 32 bytes, counted after the emulation prevention bytes are removed:
3070
+ *
3071
+ * - Bytes 0-15: UUID 6b1e2f0c-935d-4a8e-b17a-52d40e3c91f6, in the byte order written.
3072
+ * - Bytes 16-23: frame_id, uint64 big-endian.
3073
+ * - Bytes 24-31: capture time of the frame in CLOCK_MONOTONIC on the drone (ns), uint64 big-endian, 0 if unknown.
3074
+ *
3075
+ * A frame that the recorder repeats to keep the frame rate carries the id of the frame it repeats.
3076
+ * Re-encoding the video drops the SEI, so only the original recording carries the ids.
3077
+ */
3021
3078
  export interface ModelDetections {
3022
3079
  /** List of detections in the frame. */
3023
3080
  detections: ObjectDetection[];
@@ -3029,6 +3086,11 @@ export interface ModelDetections {
3029
3086
  imageHeight: number;
3030
3087
  /** Name of the computer vision model that produced the detections. */
3031
3088
  modelName: string;
3089
+ /**
3090
+ * Id of the camera frame the detections were computed from, 0 if unknown. Matches the frame id
3091
+ * embedded in recorded video; the message description gives the format.
3092
+ */
3093
+ frameId: number;
3032
3094
  }
3033
3095
  /** Generic filter settings. */
3034
3096
  export interface FilterMessage {
@@ -3094,6 +3156,11 @@ export interface SotState {
3094
3156
  vs: number;
3095
3157
  /** Kalman rate of change of the bounding box aspect ratio, width / height (1/s). */
3096
3158
  vr: number;
3159
+ /**
3160
+ * Id of the camera frame the state was computed from, 0 if unknown. Matches the frame id embedded
3161
+ * in recorded video; ModelDetections describes the format.
3162
+ */
3163
+ frameId: number;
3097
3164
  }
3098
3165
  /** Current state of the SOT tracker. */
3099
3166
  export declare enum SotState_State {
@@ -3140,6 +3207,39 @@ export interface Annotation {
3140
3207
  /** Origin of the annotation; the app sets APP, the drone sets DRONE for its own. */
3141
3208
  source: AnnotationSource;
3142
3209
  }
3210
+ /**
3211
+ * Unit quaternion describing a rotation (Hamilton convention: w + xi + yj + zk).
3212
+ *
3213
+ * Where it is a body's orientation, it rotates vectors from the body's frame to
3214
+ * the frame the body is placed in.
3215
+ */
3216
+ export interface Quaternion {
3217
+ /** X-component of the vector part. */
3218
+ x: number;
3219
+ /** Y-component of the vector part. */
3220
+ y: number;
3221
+ /** Z-component of the vector part. */
3222
+ z: number;
3223
+ /** Scalar part. */
3224
+ w: number;
3225
+ }
3226
+ /**
3227
+ * Points packed for use as typed arrays without decoding them one by one.
3228
+ *
3229
+ * The frame the positions are in is the one the enclosing message names.
3230
+ *
3231
+ * count says how many points the bytes hold: positions is exactly count * 12 bytes,
3232
+ * and intensities either empty or count bytes. A cloud whose bytes disagree with
3233
+ * count is malformed, and is not used.
3234
+ */
3235
+ export interface PointCloud {
3236
+ /** Number of points. */
3237
+ count: number;
3238
+ /** count x, y, z triplets of little-endian float32 (m): 12 bytes per point. */
3239
+ positions: Uint8Array;
3240
+ /** count signal strengths, one byte each (0 to 255), or empty when unknown. */
3241
+ intensities: Uint8Array;
3242
+ }
3143
3243
  export declare const BinlogRecord: MessageFns<BinlogRecord>;
3144
3244
  export declare const LogEntry: MessageFns<LogEntry>;
3145
3245
  export declare const KernelLogEntry: MessageFns<KernelLogEntry>;
@@ -3270,6 +3370,8 @@ export declare const CameraPanTiltZoom: MessageFns<CameraPanTiltZoom>;
3270
3370
  export declare const OperatorInfo: MessageFns<OperatorInfo>;
3271
3371
  export declare const SotState: MessageFns<SotState>;
3272
3372
  export declare const Annotation: MessageFns<Annotation>;
3373
+ export declare const Quaternion: MessageFns<Quaternion>;
3374
+ export declare const PointCloud: MessageFns<PointCloud>;
3273
3375
  type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
3274
3376
  type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
3275
3377
  [K in keyof T]?: DeepPartial<T[K]>;