@deeptrekker/api-domain 1.0.54-x4-updates.3 → 1.0.54-x4-updates.5

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.
@@ -1 +1 @@
1
- export declare const API_VERSION = "1.0.54-x4-updates.3";
1
+ export declare const API_VERSION = "1.0.54-x4-updates.5";
@@ -2,4 +2,4 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.API_VERSION = void 0;
4
4
  /* AUTO GENERATED FILE */
5
- exports.API_VERSION = "1.0.54-x4-updates.3";
5
+ exports.API_VERSION = "1.0.54-x4-updates.5";
@@ -2,7 +2,7 @@ import { Movement } from "../../../core";
2
2
  import { DeviceModel, MotorDiagnostics, SerialDevice, Sonar, Sonar3D, StereoCamera, X4CameraHead } from "../../cameraHeads";
3
3
  import { ImpaqDriver, SensorPod, X4Light } from "../../peripherals";
4
4
  import { LightConfig, ThrusterConfig } from "./deviceAllocation";
5
- import { X4RollbackStatus, X4SystemVersion, X4UpdateFetchRequest, X4UpdateFetchStatus } from "./softwareUpdates";
5
+ import { X4RollbackStatus, X4SoftwareVersion, X4UpdateFetchRequest, X4UpdateFetchStatus } from "./softwareUpdates";
6
6
  export * from "./deviceAllocation";
7
7
  export * from "./softwareUpdates";
8
8
  import { CygnusType } from "../..";
@@ -925,7 +925,7 @@ export type X4 = {
925
925
  */
926
926
  lowPowerMode?: boolean;
927
927
  /**
928
- * The app sends an {@link X4UpdateFetchRequest | X4UpdateFetchRequest} to start or cancel
928
+ * The app sends an {@link X4UpdateFetchRequest | X4UpdateFetchRequest} to start
929
929
  * a Spectra update, and the vehicle reports an {@link X4UpdateFetchStatus | X4UpdateFetchStatus}.
930
930
  */
931
931
  updateFetch?: X4UpdateFetchRequest | X4UpdateFetchStatus;
@@ -942,5 +942,5 @@ export type X4 = {
942
942
  /**
943
943
  * The OS and application versions installed on the vehicle. Read only.
944
944
  */
945
- systemVersion?: X4SystemVersion;
945
+ softwareVersion?: X4SoftwareVersion;
946
946
  };
@@ -16,49 +16,22 @@ export type X4UpdateTransferSizes = {
16
16
  tools?: number;
17
17
  };
18
18
  /**
19
- * Asks the vehicle to fetch an update from a URL itself.
19
+ * The request the app sends as `updateFetch` to start an update. The app then transfers the
20
+ * files over the `UPDATE_TRANSFER` data channel.
20
21
  * @group X4
21
22
  * @category Software Updates
22
23
  */
23
- export type X4UpdateFetchUrlRequest = {
24
- url: string;
24
+ export type X4UpdateFetchRequest = {
25
25
  type: X4UpdateKind;
26
- transport: "http";
27
- toolsUrl?: string;
28
- manifestUrl?: string;
29
- signatureUrl?: string;
30
- };
31
- /**
32
- * Asks the vehicle to receive an update that the app transfers over the `UPDATE_TRANSFER`
33
- * data channel.
34
- * @group X4
35
- * @category Software Updates
36
- */
37
- export type X4UpdateFetchTransferRequest = {
38
- type: X4UpdateKind;
39
- transport: "datachannel";
40
26
  transfer: X4UpdateTransferSizes;
41
27
  };
42
28
  /**
43
- * Cancels the update fetch in progress.
29
+ * The state of an update or a rollback as the vehicle reports it. `running` covers every step
30
+ * from the transfer to the reboot that a major update ends in.
44
31
  * @group X4
45
32
  * @category Software Updates
46
33
  */
47
- export type X4UpdateFetchCancelRequest = {
48
- cancel: true;
49
- };
50
- /**
51
- * A request the app sends as `updateFetch`.
52
- * @group X4
53
- * @category Software Updates
54
- */
55
- export type X4UpdateFetchRequest = X4UpdateFetchUrlRequest | X4UpdateFetchTransferRequest | X4UpdateFetchCancelRequest;
56
- /**
57
- * The state of an update fetch as the vehicle reports it.
58
- * @group X4
59
- * @category Software Updates
60
- */
61
- export type X4UpdateFetchState = "idle" | "starting" | "transferring" | "verifying" | "applying" | "staging" | "staged" | "applied" | "cancelling" | "cancelled" | "failed" | "unknown";
34
+ export type X4UpdateState = "idle" | "running" | "succeeded" | "failed";
62
35
  /**
63
36
  * The state of the vehicle's peripheral firmware as it reports it.
64
37
  * @group X4
@@ -87,11 +60,10 @@ export type X4FirmwareStatus = {
87
60
  * @category Software Updates
88
61
  */
89
62
  export type X4UpdateFetchStatus = {
90
- state?: X4UpdateFetchState;
63
+ state?: X4UpdateState;
91
64
  detail?: string;
92
65
  run?: string;
93
66
  type?: string;
94
- cancellable?: boolean;
95
67
  percent?: number;
96
68
  bytes?: number;
97
69
  total?: number;
@@ -101,30 +73,24 @@ export type X4UpdateFetchStatus = {
101
73
  firmware?: X4FirmwareStatus;
102
74
  };
103
75
  /**
104
- * The state of a rollback as the vehicle reports it.
105
- * @group X4
106
- * @category Software Updates
107
- */
108
- export type X4RollbackState = "idle" | "running" | "succeeded" | "failed" | "rolled-back-os" | "unknown";
109
- /**
110
- * The status the vehicle reports as `rollback` and `rollbackOs`. An OS rollback ends in
111
- * `rolled-back-os` just before the vehicle reboots onto the other OS.
76
+ * The status the vehicle reports as `rollback` and `rollbackOs`. An OS rollback reports
77
+ * `succeeded` just before the vehicle reboots onto the other OS.
112
78
  * @group X4
113
79
  * @category Software Updates
114
80
  */
115
81
  export type X4RollbackStatus = {
116
- state?: X4RollbackState;
82
+ state?: X4UpdateState;
117
83
  detail?: string;
118
84
  run?: string;
119
85
  finishedAt?: string;
120
86
  };
121
87
  /**
122
- * The OS and application versions the vehicle reports as `systemVersion`,
88
+ * The OS and application versions the vehicle reports as `softwareVersion`,
123
89
  * including the previous application slot that a rollback would return to.
124
90
  * @group X4
125
91
  * @category Software Updates
126
92
  */
127
- export type X4SystemVersion = {
93
+ export type X4SoftwareVersion = {
128
94
  osHash?: string;
129
95
  osVersion?: string;
130
96
  appSlot?: string;
@@ -139,11 +105,11 @@ export type X4SystemVersion = {
139
105
  rollbackAvailable?: boolean;
140
106
  };
141
107
  /**
142
- * Why the vehicle refused a software update, cancel or rollback request.
108
+ * Why the vehicle refused a software update or rollback request.
143
109
  * @group X4
144
110
  * @category Software Updates
145
111
  */
146
- export type X4UpdateRefusalReason = "update-in-progress" | "rollback-in-progress" | "firmware-flashing" | "cancel-refused" | "cancel-failed" | "invalid-request" | "unavailable" | "refused";
112
+ export type X4UpdateRefusalReason = "update-in-progress" | "rollback-in-progress" | "firmware-flashing" | "invalid-request" | "unavailable" | "refused";
147
113
  /**
148
114
  * The API setting a software update error came from.
149
115
  * @group X4
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deeptrekker/api-domain",
3
- "version": "1.0.54-x4-updates.3",
3
+ "version": "1.0.54-x4-updates.5",
4
4
  "description": "A business domain of types and schemas that the Deep Trekker topside communicates with via an API.",
5
5
  "main": "dist/index.js",
6
6
  "engines": {