@blueyerobotics/protocol-definitions 3.2.0-153cd3ce → 3.2.0-3e0ba702
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/README.md +40 -0
- package/dist/aquatroll.d.ts +2 -8
- package/dist/control.d.ts +2 -8
- package/dist/google/protobuf/any.d.ts +2 -8
- package/dist/google/protobuf/duration.d.ts +2 -8
- package/dist/google/protobuf/timestamp.d.ts +2 -8
- package/dist/message_formats.d.ts +2 -8
- package/dist/mission_planning.d.ts +2 -8
- package/dist/req_rep.d.ts +2 -8
- package/dist/telemetry.d.ts +2 -8
- package/package.json +7 -1
package/README.md
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# @blueyerobotics/protocol-definitions
|
|
2
|
+
|
|
3
|
+
TypeScript protobuf definitions for Blueye Robotics protocols generated using [ts-proto](https://github.com/stephenh/ts-proto).
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @blueyerobotics/protocol-definitions
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
```ts
|
|
14
|
+
import { blueye } from "@blueyerobotics/protocol-definitions";
|
|
15
|
+
|
|
16
|
+
// Create a new GetBatteryReq message
|
|
17
|
+
const request = blueye.protocol.GetBatteryReq.create();
|
|
18
|
+
|
|
19
|
+
// Serialize the message to a Uint8Array (binary)
|
|
20
|
+
const binary = blueye.protocol.GetBatteryReq.encode(request).finish();
|
|
21
|
+
|
|
22
|
+
// ...
|
|
23
|
+
|
|
24
|
+
// For demonstration, we will simulate a response from the device
|
|
25
|
+
const response = blueye.protocol.GetBatteryRep.create({
|
|
26
|
+
battery: {
|
|
27
|
+
level: 85,
|
|
28
|
+
voltage: 12.5,
|
|
29
|
+
temperature: 25,
|
|
30
|
+
},
|
|
31
|
+
});
|
|
32
|
+
|
|
33
|
+
const binaryResponse = blueye.protocol.GetBatteryRep.encode(response).finish();
|
|
34
|
+
|
|
35
|
+
// Decode a binary response back into a message
|
|
36
|
+
const decoded = blueye.protocol.GetBatteryRep.decode(binaryResponse);
|
|
37
|
+
|
|
38
|
+
// Access fields
|
|
39
|
+
console.log(decoded.battery?.level);
|
|
40
|
+
```
|
package/dist/aquatroll.d.ts
CHANGED
|
@@ -424,18 +424,12 @@ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefi
|
|
|
424
424
|
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 {} ? {
|
|
425
425
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
426
426
|
} : Partial<T>;
|
|
427
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
428
|
-
type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
429
|
-
[K in keyof P]: Exact<P[K], I[K]>;
|
|
430
|
-
} & {
|
|
431
|
-
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
432
|
-
};
|
|
433
427
|
interface MessageFns<T> {
|
|
434
428
|
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
435
429
|
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
436
430
|
fromJSON(object: any): T;
|
|
437
431
|
toJSON(message: T): unknown;
|
|
438
|
-
create
|
|
439
|
-
fromPartial
|
|
432
|
+
create(base?: DeepPartial<T>): T;
|
|
433
|
+
fromPartial(object: DeepPartial<T>): T;
|
|
440
434
|
}
|
|
441
435
|
export {};
|
package/dist/control.d.ts
CHANGED
|
@@ -251,18 +251,12 @@ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefi
|
|
|
251
251
|
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 {} ? {
|
|
252
252
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
253
253
|
} : Partial<T>;
|
|
254
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
255
|
-
type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
256
|
-
[K in keyof P]: Exact<P[K], I[K]>;
|
|
257
|
-
} & {
|
|
258
|
-
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
259
|
-
};
|
|
260
254
|
interface MessageFns<T> {
|
|
261
255
|
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
262
256
|
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
263
257
|
fromJSON(object: any): T;
|
|
264
258
|
toJSON(message: T): unknown;
|
|
265
|
-
create
|
|
266
|
-
fromPartial
|
|
259
|
+
create(base?: DeepPartial<T>): T;
|
|
260
|
+
fromPartial(object: DeepPartial<T>): T;
|
|
267
261
|
}
|
|
268
262
|
export {};
|
|
@@ -121,18 +121,12 @@ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefi
|
|
|
121
121
|
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 {} ? {
|
|
122
122
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
123
123
|
} : Partial<T>;
|
|
124
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
125
|
-
type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
126
|
-
[K in keyof P]: Exact<P[K], I[K]>;
|
|
127
|
-
} & {
|
|
128
|
-
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
129
|
-
};
|
|
130
124
|
interface MessageFns<T> {
|
|
131
125
|
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
132
126
|
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
133
127
|
fromJSON(object: any): T;
|
|
134
128
|
toJSON(message: T): unknown;
|
|
135
|
-
create
|
|
136
|
-
fromPartial
|
|
129
|
+
create(base?: DeepPartial<T>): T;
|
|
130
|
+
fromPartial(object: DeepPartial<T>): T;
|
|
137
131
|
}
|
|
138
132
|
export {};
|
|
@@ -81,18 +81,12 @@ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefi
|
|
|
81
81
|
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 {} ? {
|
|
82
82
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
83
83
|
} : Partial<T>;
|
|
84
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
85
|
-
type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
86
|
-
[K in keyof P]: Exact<P[K], I[K]>;
|
|
87
|
-
} & {
|
|
88
|
-
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
89
|
-
};
|
|
90
84
|
interface MessageFns<T> {
|
|
91
85
|
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
92
86
|
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
93
87
|
fromJSON(object: any): T;
|
|
94
88
|
toJSON(message: T): unknown;
|
|
95
|
-
create
|
|
96
|
-
fromPartial
|
|
89
|
+
create(base?: DeepPartial<T>): T;
|
|
90
|
+
fromPartial(object: DeepPartial<T>): T;
|
|
97
91
|
}
|
|
98
92
|
export {};
|
|
@@ -110,18 +110,12 @@ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefi
|
|
|
110
110
|
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 {} ? {
|
|
111
111
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
112
112
|
} : Partial<T>;
|
|
113
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
114
|
-
type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
115
|
-
[K in keyof P]: Exact<P[K], I[K]>;
|
|
116
|
-
} & {
|
|
117
|
-
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
118
|
-
};
|
|
119
113
|
interface MessageFns<T> {
|
|
120
114
|
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
121
115
|
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
122
116
|
fromJSON(object: any): T;
|
|
123
117
|
toJSON(message: T): unknown;
|
|
124
|
-
create
|
|
125
|
-
fromPartial
|
|
118
|
+
create(base?: DeepPartial<T>): T;
|
|
119
|
+
fromPartial(object: DeepPartial<T>): T;
|
|
126
120
|
}
|
|
127
121
|
export {};
|
|
@@ -1835,18 +1835,12 @@ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefi
|
|
|
1835
1835
|
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 {} ? {
|
|
1836
1836
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
1837
1837
|
} : Partial<T>;
|
|
1838
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
1839
|
-
type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
1840
|
-
[K in keyof P]: Exact<P[K], I[K]>;
|
|
1841
|
-
} & {
|
|
1842
|
-
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
1843
|
-
};
|
|
1844
1838
|
interface MessageFns<T> {
|
|
1845
1839
|
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
1846
1840
|
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
1847
1841
|
fromJSON(object: any): T;
|
|
1848
1842
|
toJSON(message: T): unknown;
|
|
1849
|
-
create
|
|
1850
|
-
fromPartial
|
|
1843
|
+
create(base?: DeepPartial<T>): T;
|
|
1844
|
+
fromPartial(object: DeepPartial<T>): T;
|
|
1851
1845
|
}
|
|
1852
1846
|
export {};
|
|
@@ -335,18 +335,12 @@ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefi
|
|
|
335
335
|
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 {} ? {
|
|
336
336
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
337
337
|
} : Partial<T>;
|
|
338
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
339
|
-
type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
340
|
-
[K in keyof P]: Exact<P[K], I[K]>;
|
|
341
|
-
} & {
|
|
342
|
-
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
343
|
-
};
|
|
344
338
|
interface MessageFns<T> {
|
|
345
339
|
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
346
340
|
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
347
341
|
fromJSON(object: any): T;
|
|
348
342
|
toJSON(message: T): unknown;
|
|
349
|
-
create
|
|
350
|
-
fromPartial
|
|
343
|
+
create(base?: DeepPartial<T>): T;
|
|
344
|
+
fromPartial(object: DeepPartial<T>): T;
|
|
351
345
|
}
|
|
352
346
|
export {};
|
package/dist/req_rep.d.ts
CHANGED
|
@@ -251,18 +251,12 @@ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefi
|
|
|
251
251
|
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 {} ? {
|
|
252
252
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
253
253
|
} : Partial<T>;
|
|
254
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
255
|
-
type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
256
|
-
[K in keyof P]: Exact<P[K], I[K]>;
|
|
257
|
-
} & {
|
|
258
|
-
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
259
|
-
};
|
|
260
254
|
interface MessageFns<T> {
|
|
261
255
|
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
262
256
|
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
263
257
|
fromJSON(object: any): T;
|
|
264
258
|
toJSON(message: T): unknown;
|
|
265
|
-
create
|
|
266
|
-
fromPartial
|
|
259
|
+
create(base?: DeepPartial<T>): T;
|
|
260
|
+
fromPartial(object: DeepPartial<T>): T;
|
|
267
261
|
}
|
|
268
262
|
export {};
|
package/dist/telemetry.d.ts
CHANGED
|
@@ -342,18 +342,12 @@ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefi
|
|
|
342
342
|
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 {} ? {
|
|
343
343
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
344
344
|
} : Partial<T>;
|
|
345
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
346
|
-
type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
347
|
-
[K in keyof P]: Exact<P[K], I[K]>;
|
|
348
|
-
} & {
|
|
349
|
-
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
350
|
-
};
|
|
351
345
|
interface MessageFns<T> {
|
|
352
346
|
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
353
347
|
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
354
348
|
fromJSON(object: any): T;
|
|
355
349
|
toJSON(message: T): unknown;
|
|
356
|
-
create
|
|
357
|
-
fromPartial
|
|
350
|
+
create(base?: DeepPartial<T>): T;
|
|
351
|
+
fromPartial(object: DeepPartial<T>): T;
|
|
358
352
|
}
|
|
359
353
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@blueyerobotics/protocol-definitions",
|
|
3
|
-
"version": "3.2.0-
|
|
3
|
+
"version": "3.2.0-3e0ba702",
|
|
4
|
+
"license": "LGPL-3.0-only",
|
|
5
|
+
"description": "TypeScript definitions for Blueye Robotics protocols",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "https://github.com/BluEye-Robotics/ProtocolDefinitions.git"
|
|
9
|
+
},
|
|
4
10
|
"main": "dist/index.js",
|
|
5
11
|
"types": "dist/index.d.ts",
|
|
6
12
|
"files": ["dist"],
|