@openrobops/iso21423 0.0.0-stage → 0.1.1
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 +358 -2
- package/dist/ccs-CU8XD5sl.d.cts +69 -0
- package/dist/ccs-CU8XD5sl.d.ts +69 -0
- package/dist/chunk-3JNSIJSX.js +31 -0
- package/dist/chunk-3JNSIJSX.js.map +1 -0
- package/dist/chunk-5ZIUSUHF.js +55 -0
- package/dist/chunk-5ZIUSUHF.js.map +1 -0
- package/dist/chunk-DMJ6T3RX.js +445 -0
- package/dist/chunk-DMJ6T3RX.js.map +1 -0
- package/dist/chunk-GPNR37CI.js +1915 -0
- package/dist/chunk-GPNR37CI.js.map +1 -0
- package/dist/chunk-JDO725KR.js +210 -0
- package/dist/chunk-JDO725KR.js.map +1 -0
- package/dist/chunk-JIYCTQXR.js +1 -0
- package/dist/chunk-JIYCTQXR.js.map +1 -0
- package/dist/chunk-JLUENXGS.js +48 -0
- package/dist/chunk-JLUENXGS.js.map +1 -0
- package/dist/chunk-JQAMNFAF.js +1 -0
- package/dist/chunk-JQAMNFAF.js.map +1 -0
- package/dist/chunk-LTPOAVGF.js +44 -0
- package/dist/chunk-LTPOAVGF.js.map +1 -0
- package/dist/chunk-ODBIFZN3.js +65 -0
- package/dist/chunk-ODBIFZN3.js.map +1 -0
- package/dist/chunk-OH2DOPKJ.js +107 -0
- package/dist/chunk-OH2DOPKJ.js.map +1 -0
- package/dist/chunk-QAA44UNO.js +1 -0
- package/dist/chunk-QAA44UNO.js.map +1 -0
- package/dist/chunk-RD7PYTIT.js +107 -0
- package/dist/chunk-RD7PYTIT.js.map +1 -0
- package/dist/chunk-UJC46NTA.js +13 -0
- package/dist/chunk-UJC46NTA.js.map +1 -0
- package/dist/chunk-UW6WTEPT.js +293 -0
- package/dist/chunk-UW6WTEPT.js.map +1 -0
- package/dist/chunk-W7DIDPTG.js +1 -0
- package/dist/chunk-W7DIDPTG.js.map +1 -0
- package/dist/core.cjs +2874 -0
- package/dist/core.cjs.map +1 -0
- package/dist/core.d.cts +996 -0
- package/dist/core.d.ts +996 -0
- package/dist/core.js +59 -0
- package/dist/core.js.map +1 -0
- package/dist/gateway.cjs +2937 -0
- package/dist/gateway.cjs.map +1 -0
- package/dist/gateway.d.cts +165 -0
- package/dist/gateway.d.ts +165 -0
- package/dist/gateway.js +21 -0
- package/dist/gateway.js.map +1 -0
- package/dist/geometry.cjs +98 -0
- package/dist/geometry.cjs.map +1 -0
- package/dist/geometry.d.cts +38 -0
- package/dist/geometry.d.ts +38 -0
- package/dist/geometry.js +14 -0
- package/dist/geometry.js.map +1 -0
- package/dist/identity-BGr2FJmC.d.cts +258 -0
- package/dist/identity-Bw8Dik5S.d.ts +258 -0
- package/dist/index.cjs +3327 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +118 -0
- package/dist/index.d.ts +118 -0
- package/dist/index.js +193 -0
- package/dist/index.js.map +1 -0
- package/dist/schema.cjs +375 -0
- package/dist/schema.cjs.map +1 -0
- package/dist/schema.d.cts +28 -0
- package/dist/schema.d.ts +28 -0
- package/dist/schema.js +14 -0
- package/dist/schema.js.map +1 -0
- package/dist/session-RV32MFpV.d.cts +139 -0
- package/dist/session-ueiESY7Y.d.ts +139 -0
- package/dist/session.cjs +855 -0
- package/dist/session.cjs.map +1 -0
- package/dist/session.d.cts +94 -0
- package/dist/session.d.ts +94 -0
- package/dist/session.js +20 -0
- package/dist/session.js.map +1 -0
- package/dist/testing.cjs +205 -0
- package/dist/testing.cjs.map +1 -0
- package/dist/testing.d.cts +94 -0
- package/dist/testing.d.ts +94 -0
- package/dist/testing.js +169 -0
- package/dist/testing.js.map +1 -0
- package/dist/topics-BiVeZyTW.d.cts +43 -0
- package/dist/topics-BiVeZyTW.d.ts +43 -0
- package/dist/topics.cjs +134 -0
- package/dist/topics.cjs.map +1 -0
- package/dist/topics.d.cts +41 -0
- package/dist/topics.d.ts +41 -0
- package/dist/topics.js +30 -0
- package/dist/topics.js.map +1 -0
- package/dist/transport-BT4AjTn9.d.cts +61 -0
- package/dist/transport-BT4AjTn9.d.ts +61 -0
- package/dist/types.cjs +186 -0
- package/dist/types.cjs.map +1 -0
- package/dist/types.d.cts +83 -0
- package/dist/types.d.ts +83 -0
- package/dist/types.js +50 -0
- package/dist/types.js.map +1 -0
- package/dist/validators-Be0ce1b8.d.cts +29 -0
- package/dist/validators-Be0ce1b8.d.ts +29 -0
- package/package.json +48 -4
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
export { E as EntityRef, P as ParsedTopic, d as disconnectionTopic, i as identityWildcard, p as parseTopic, r as requestStatusTopic, a as requestTopic, t as topicFilterMatches, b as topicFor } from './topics-BiVeZyTW.cjs';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Copyright 2026 InOrbit, Inc.
|
|
5
|
+
*
|
|
6
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
+
* you may not use this file except in compliance with the License.
|
|
8
|
+
* You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
/** Normative publish settings for a resource; `minHz`/`maxHz` bound the allowed publish rate where the spec constrains it. */
|
|
19
|
+
interface ResourceConfig {
|
|
20
|
+
qos: 0 | 1 | 2;
|
|
21
|
+
retain: boolean;
|
|
22
|
+
minHz?: number;
|
|
23
|
+
maxHz?: number;
|
|
24
|
+
}
|
|
25
|
+
/** Table B.1 — resources and their normative QoS / retain / rate configuration. */
|
|
26
|
+
declare const RESOURCE_CONFIG: Record<string, ResourceConfig>;
|
|
27
|
+
/** True for the resources Table B.1 defines; false for deployment-defined extension resources. */
|
|
28
|
+
declare function isStandardResource(name: string): boolean;
|
|
29
|
+
/**
|
|
30
|
+
* Registers a deployment-defined resource (ISO 21423 leaves the resource catalog open — see the
|
|
31
|
+
* standard's extension clause) so entities can publish it via `EntityHandle.publishExtension` and
|
|
32
|
+
* clients can `subscribeResource` to it. Extension resources carry no schema: subscribers receive
|
|
33
|
+
* the raw payload text, exactly like `footprint`.
|
|
34
|
+
*
|
|
35
|
+
* Process-wide (the resource table is a module singleton): both ends of a deployment must
|
|
36
|
+
* register the same name with the same config. Re-registering with an identical config is a
|
|
37
|
+
* no-op; a different config throws, as does a name that collides with a standard resource.
|
|
38
|
+
*/
|
|
39
|
+
declare function registerExtensionResource(name: string, config: ResourceConfig): void;
|
|
40
|
+
|
|
41
|
+
export { RESOURCE_CONFIG, type ResourceConfig, isStandardResource, registerExtensionResource };
|
package/dist/topics.d.ts
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
export { E as EntityRef, P as ParsedTopic, d as disconnectionTopic, i as identityWildcard, p as parseTopic, r as requestStatusTopic, a as requestTopic, t as topicFilterMatches, b as topicFor } from './topics-BiVeZyTW.js';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Copyright 2026 InOrbit, Inc.
|
|
5
|
+
*
|
|
6
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
+
* you may not use this file except in compliance with the License.
|
|
8
|
+
* You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
/** Normative publish settings for a resource; `minHz`/`maxHz` bound the allowed publish rate where the spec constrains it. */
|
|
19
|
+
interface ResourceConfig {
|
|
20
|
+
qos: 0 | 1 | 2;
|
|
21
|
+
retain: boolean;
|
|
22
|
+
minHz?: number;
|
|
23
|
+
maxHz?: number;
|
|
24
|
+
}
|
|
25
|
+
/** Table B.1 — resources and their normative QoS / retain / rate configuration. */
|
|
26
|
+
declare const RESOURCE_CONFIG: Record<string, ResourceConfig>;
|
|
27
|
+
/** True for the resources Table B.1 defines; false for deployment-defined extension resources. */
|
|
28
|
+
declare function isStandardResource(name: string): boolean;
|
|
29
|
+
/**
|
|
30
|
+
* Registers a deployment-defined resource (ISO 21423 leaves the resource catalog open — see the
|
|
31
|
+
* standard's extension clause) so entities can publish it via `EntityHandle.publishExtension` and
|
|
32
|
+
* clients can `subscribeResource` to it. Extension resources carry no schema: subscribers receive
|
|
33
|
+
* the raw payload text, exactly like `footprint`.
|
|
34
|
+
*
|
|
35
|
+
* Process-wide (the resource table is a module singleton): both ends of a deployment must
|
|
36
|
+
* register the same name with the same config. Re-registering with an identical config is a
|
|
37
|
+
* no-op; a different config throws, as does a name that collides with a standard resource.
|
|
38
|
+
*/
|
|
39
|
+
declare function registerExtensionResource(name: string, config: ResourceConfig): void;
|
|
40
|
+
|
|
41
|
+
export { RESOURCE_CONFIG, type ResourceConfig, isStandardResource, registerExtensionResource };
|
package/dist/topics.js
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import "./chunk-QAA44UNO.js";
|
|
2
|
+
import {
|
|
3
|
+
RESOURCE_CONFIG,
|
|
4
|
+
isStandardResource,
|
|
5
|
+
registerExtensionResource
|
|
6
|
+
} from "./chunk-LTPOAVGF.js";
|
|
7
|
+
import {
|
|
8
|
+
disconnectionTopic,
|
|
9
|
+
identityWildcard,
|
|
10
|
+
parseTopic,
|
|
11
|
+
requestStatusTopic,
|
|
12
|
+
requestTopic,
|
|
13
|
+
topicFilterMatches,
|
|
14
|
+
topicFor
|
|
15
|
+
} from "./chunk-5ZIUSUHF.js";
|
|
16
|
+
import "./chunk-RD7PYTIT.js";
|
|
17
|
+
import "./chunk-JLUENXGS.js";
|
|
18
|
+
export {
|
|
19
|
+
RESOURCE_CONFIG,
|
|
20
|
+
disconnectionTopic,
|
|
21
|
+
identityWildcard,
|
|
22
|
+
isStandardResource,
|
|
23
|
+
parseTopic,
|
|
24
|
+
registerExtensionResource,
|
|
25
|
+
requestStatusTopic,
|
|
26
|
+
requestTopic,
|
|
27
|
+
topicFilterMatches,
|
|
28
|
+
topicFor
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=topics.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright 2026 InOrbit, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
/** An inbound message as delivered by the transport. */
|
|
17
|
+
interface TransportMessage {
|
|
18
|
+
topic: string;
|
|
19
|
+
payload: Buffer;
|
|
20
|
+
qos: 0 | 1 | 2;
|
|
21
|
+
retain: boolean;
|
|
22
|
+
}
|
|
23
|
+
/** MQTT Last Will and Testament to arm at connect time (see B.4). */
|
|
24
|
+
interface WillOptions {
|
|
25
|
+
topic: string;
|
|
26
|
+
payload: string;
|
|
27
|
+
qos: 0 | 1 | 2;
|
|
28
|
+
retain: boolean;
|
|
29
|
+
}
|
|
30
|
+
interface TransportConnectOptions {
|
|
31
|
+
clientId: string;
|
|
32
|
+
cleanSession: boolean;
|
|
33
|
+
keepalive: number;
|
|
34
|
+
will?: WillOptions;
|
|
35
|
+
username?: string;
|
|
36
|
+
password?: string;
|
|
37
|
+
}
|
|
38
|
+
type ConnectionState = 'connected' | 'reconnecting' | 'offline' | 'closed';
|
|
39
|
+
/**
|
|
40
|
+
* Broker-agnostic MQTT transport contract the SDK is built against. `session/mqttTransport.ts`
|
|
41
|
+
* implements it over the `mqtt` npm package; `testing/memoryTransport.ts` implements it in-memory
|
|
42
|
+
* for tests. Handlers registered via `onMessage`/`onConnectionState` are additive, not replacing.
|
|
43
|
+
*/
|
|
44
|
+
interface MqttTransport {
|
|
45
|
+
connect(opts: TransportConnectOptions): Promise<void>;
|
|
46
|
+
publish(topic: string, payload: string | Buffer, opts: {
|
|
47
|
+
qos: 0 | 1 | 2;
|
|
48
|
+
retain: boolean;
|
|
49
|
+
}): Promise<void>;
|
|
50
|
+
subscribe(filter: string, opts: {
|
|
51
|
+
qos: 0 | 1 | 2;
|
|
52
|
+
}): Promise<{
|
|
53
|
+
granted: boolean;
|
|
54
|
+
}>;
|
|
55
|
+
unsubscribe(filter: string): Promise<void>;
|
|
56
|
+
onMessage(cb: (msg: TransportMessage) => void): void;
|
|
57
|
+
onConnectionState(cb: (s: ConnectionState) => void): void;
|
|
58
|
+
end(): Promise<void>;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export type { ConnectionState as C, MqttTransport as M, TransportConnectOptions as T, WillOptions as W, TransportMessage as a };
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright 2026 InOrbit, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
/** An inbound message as delivered by the transport. */
|
|
17
|
+
interface TransportMessage {
|
|
18
|
+
topic: string;
|
|
19
|
+
payload: Buffer;
|
|
20
|
+
qos: 0 | 1 | 2;
|
|
21
|
+
retain: boolean;
|
|
22
|
+
}
|
|
23
|
+
/** MQTT Last Will and Testament to arm at connect time (see B.4). */
|
|
24
|
+
interface WillOptions {
|
|
25
|
+
topic: string;
|
|
26
|
+
payload: string;
|
|
27
|
+
qos: 0 | 1 | 2;
|
|
28
|
+
retain: boolean;
|
|
29
|
+
}
|
|
30
|
+
interface TransportConnectOptions {
|
|
31
|
+
clientId: string;
|
|
32
|
+
cleanSession: boolean;
|
|
33
|
+
keepalive: number;
|
|
34
|
+
will?: WillOptions;
|
|
35
|
+
username?: string;
|
|
36
|
+
password?: string;
|
|
37
|
+
}
|
|
38
|
+
type ConnectionState = 'connected' | 'reconnecting' | 'offline' | 'closed';
|
|
39
|
+
/**
|
|
40
|
+
* Broker-agnostic MQTT transport contract the SDK is built against. `session/mqttTransport.ts`
|
|
41
|
+
* implements it over the `mqtt` npm package; `testing/memoryTransport.ts` implements it in-memory
|
|
42
|
+
* for tests. Handlers registered via `onMessage`/`onConnectionState` are additive, not replacing.
|
|
43
|
+
*/
|
|
44
|
+
interface MqttTransport {
|
|
45
|
+
connect(opts: TransportConnectOptions): Promise<void>;
|
|
46
|
+
publish(topic: string, payload: string | Buffer, opts: {
|
|
47
|
+
qos: 0 | 1 | 2;
|
|
48
|
+
retain: boolean;
|
|
49
|
+
}): Promise<void>;
|
|
50
|
+
subscribe(filter: string, opts: {
|
|
51
|
+
qos: 0 | 1 | 2;
|
|
52
|
+
}): Promise<{
|
|
53
|
+
granted: boolean;
|
|
54
|
+
}>;
|
|
55
|
+
unsubscribe(filter: string): Promise<void>;
|
|
56
|
+
onMessage(cb: (msg: TransportMessage) => void): void;
|
|
57
|
+
onConnectionState(cb: (s: ConnectionState) => void): void;
|
|
58
|
+
end(): Promise<void>;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export type { ConnectionState as C, MqttTransport as M, TransportConnectOptions as T, WillOptions as W, TransportMessage as a };
|
package/dist/types.cjs
ADDED
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/types/index.ts
|
|
21
|
+
var types_exports = {};
|
|
22
|
+
__export(types_exports, {
|
|
23
|
+
BATTERY_HEALTH: () => BATTERY_HEALTH,
|
|
24
|
+
CHARGING_STATES: () => CHARGING_STATES,
|
|
25
|
+
DETAIL_STATES: () => DETAIL_STATES,
|
|
26
|
+
DOCK_ACTIONS: () => DOCK_ACTIONS,
|
|
27
|
+
ENTITY_TYPES: () => ENTITY_TYPES,
|
|
28
|
+
KNOWN_OPERATING_STATES: () => KNOWN_OPERATING_STATES,
|
|
29
|
+
KNOWN_REASON_CODES: () => KNOWN_REASON_CODES,
|
|
30
|
+
LOST_CONNECTION_STATE: () => LOST_CONNECTION_STATE,
|
|
31
|
+
OPERATING_MODES: () => OPERATING_MODES,
|
|
32
|
+
PROTOCOL_VERSION: () => PROTOCOL_VERSION,
|
|
33
|
+
REQUEST_STATES: () => REQUEST_STATES,
|
|
34
|
+
ROOT_NAMESPACE: () => ROOT_NAMESPACE,
|
|
35
|
+
cancelRequest: () => cancelRequest,
|
|
36
|
+
dock: () => dock,
|
|
37
|
+
move: () => move,
|
|
38
|
+
nowTimestamp: () => nowTimestamp,
|
|
39
|
+
parseTimestamp: () => parseTimestamp,
|
|
40
|
+
pauseImr: () => pauseImr,
|
|
41
|
+
resumeImr: () => resumeImr,
|
|
42
|
+
undock: () => undock
|
|
43
|
+
});
|
|
44
|
+
module.exports = __toCommonJS(types_exports);
|
|
45
|
+
|
|
46
|
+
// src/types/common.ts
|
|
47
|
+
function nowTimestamp(date = /* @__PURE__ */ new Date()) {
|
|
48
|
+
return date.toISOString();
|
|
49
|
+
}
|
|
50
|
+
function parseTimestamp(ts) {
|
|
51
|
+
return new Date(ts.replace(",", "."));
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
// src/types/constants.ts
|
|
55
|
+
var ROOT_NAMESPACE = "/ISO_21423/v1";
|
|
56
|
+
var PROTOCOL_VERSION = "1.0";
|
|
57
|
+
var ENTITY_TYPES = ["IMR", "IMRFM"];
|
|
58
|
+
var KNOWN_OPERATING_STATES = [
|
|
59
|
+
"STOP_CATEGORY_0",
|
|
60
|
+
"STOP_CATEGORY_1",
|
|
61
|
+
"STOP_CATEGORY_2",
|
|
62
|
+
"PAUSED",
|
|
63
|
+
"WAIT_FOR_RESET",
|
|
64
|
+
"MAPPING",
|
|
65
|
+
"LOST",
|
|
66
|
+
"WAIT_FOR_ATTACHMENT",
|
|
67
|
+
"WAIT_FOR_EVENT",
|
|
68
|
+
"BLOCKED",
|
|
69
|
+
"ATTACHMENT_ACTIVE",
|
|
70
|
+
"STOPPED",
|
|
71
|
+
"DOCKING",
|
|
72
|
+
"SLOWING",
|
|
73
|
+
"ACCELERATING",
|
|
74
|
+
"LEFT_TURN",
|
|
75
|
+
"RIGHT_TURN",
|
|
76
|
+
"REVERSE",
|
|
77
|
+
"FORWARD",
|
|
78
|
+
"LINE_FOLLOWING",
|
|
79
|
+
"CHARGING",
|
|
80
|
+
"LOW_BATTERY",
|
|
81
|
+
"IDLE",
|
|
82
|
+
"PARKED",
|
|
83
|
+
"OFFLINE",
|
|
84
|
+
"READY",
|
|
85
|
+
"NOT_READY",
|
|
86
|
+
"MODE_AUTO",
|
|
87
|
+
"MODE_SEMIAUTO",
|
|
88
|
+
"MODE_TELEOP",
|
|
89
|
+
"MODE_MANUAL",
|
|
90
|
+
"MODE_MAINTENANCE"
|
|
91
|
+
];
|
|
92
|
+
var OPERATING_MODES = [
|
|
93
|
+
"MODE_AUTO",
|
|
94
|
+
"MODE_SEMIAUTO",
|
|
95
|
+
"MODE_TELEOP",
|
|
96
|
+
"MODE_MANUAL",
|
|
97
|
+
"MODE_MAINTENANCE"
|
|
98
|
+
];
|
|
99
|
+
var LOST_CONNECTION_STATE = "LOST_CONNECTION";
|
|
100
|
+
var REQUEST_STATES = [
|
|
101
|
+
"RECEIVED",
|
|
102
|
+
"ACCEPTED",
|
|
103
|
+
"EXECUTING",
|
|
104
|
+
"CANCELED",
|
|
105
|
+
"SUCCEEDED",
|
|
106
|
+
"ABORTED",
|
|
107
|
+
"RECOVERY"
|
|
108
|
+
];
|
|
109
|
+
var DETAIL_STATES = [
|
|
110
|
+
"RECEIVED",
|
|
111
|
+
"ACCEPTED",
|
|
112
|
+
"EXECUTING",
|
|
113
|
+
"CANCELED",
|
|
114
|
+
"SUCCEEDED",
|
|
115
|
+
"ABORTED"
|
|
116
|
+
];
|
|
117
|
+
var KNOWN_REASON_CODES = [
|
|
118
|
+
"OK",
|
|
119
|
+
"GENERAL_FAILURE",
|
|
120
|
+
"TIMEOUT",
|
|
121
|
+
"VERSION_NOT_SUPPORTED",
|
|
122
|
+
"FORMAT_NOT_SUPPORTED",
|
|
123
|
+
"ACTION_NOT_IMPLEMENTED",
|
|
124
|
+
"REJECTED",
|
|
125
|
+
"MALFORMED_REQUEST",
|
|
126
|
+
"INVALID_IMR_STATE_FOR_ACTION"
|
|
127
|
+
];
|
|
128
|
+
var BATTERY_HEALTH = [
|
|
129
|
+
"UNKNOWN",
|
|
130
|
+
"HEALTHY",
|
|
131
|
+
"OVERHEAT",
|
|
132
|
+
"DEAD",
|
|
133
|
+
"OVERVOLTAGE",
|
|
134
|
+
"FAILURE",
|
|
135
|
+
"COLD"
|
|
136
|
+
];
|
|
137
|
+
var CHARGING_STATES = [
|
|
138
|
+
"UNKNOWN",
|
|
139
|
+
"CHARGING",
|
|
140
|
+
"DISCHARGING",
|
|
141
|
+
"NOT_CHARGING",
|
|
142
|
+
"FULL"
|
|
143
|
+
];
|
|
144
|
+
var DOCK_ACTIONS = ["CHARGE", "DUMP", "FILL", "LOAD", "UNLOAD", "PICK", "DROP"];
|
|
145
|
+
|
|
146
|
+
// src/types/actions.ts
|
|
147
|
+
function detail(type, properties, opts = {}) {
|
|
148
|
+
return {
|
|
149
|
+
type,
|
|
150
|
+
version: opts.version ?? PROTOCOL_VERSION,
|
|
151
|
+
format: "ISO-21423",
|
|
152
|
+
blocking: opts.blocking ?? true,
|
|
153
|
+
atomic: opts.atomic ?? false,
|
|
154
|
+
properties
|
|
155
|
+
};
|
|
156
|
+
}
|
|
157
|
+
var move = (props, opts) => detail("move", { ...props }, opts);
|
|
158
|
+
var pauseImr = (opts) => detail("pauseImr", {}, opts);
|
|
159
|
+
var resumeImr = (opts) => detail("resumeImr", {}, opts);
|
|
160
|
+
var cancelRequest = (props, opts) => detail("cancelRequest", { ...props }, opts);
|
|
161
|
+
var dock = (props, opts) => detail("dock", { ...props }, opts);
|
|
162
|
+
var undock = (opts) => detail("undock", {}, opts);
|
|
163
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
164
|
+
0 && (module.exports = {
|
|
165
|
+
BATTERY_HEALTH,
|
|
166
|
+
CHARGING_STATES,
|
|
167
|
+
DETAIL_STATES,
|
|
168
|
+
DOCK_ACTIONS,
|
|
169
|
+
ENTITY_TYPES,
|
|
170
|
+
KNOWN_OPERATING_STATES,
|
|
171
|
+
KNOWN_REASON_CODES,
|
|
172
|
+
LOST_CONNECTION_STATE,
|
|
173
|
+
OPERATING_MODES,
|
|
174
|
+
PROTOCOL_VERSION,
|
|
175
|
+
REQUEST_STATES,
|
|
176
|
+
ROOT_NAMESPACE,
|
|
177
|
+
cancelRequest,
|
|
178
|
+
dock,
|
|
179
|
+
move,
|
|
180
|
+
nowTimestamp,
|
|
181
|
+
parseTimestamp,
|
|
182
|
+
pauseImr,
|
|
183
|
+
resumeImr,
|
|
184
|
+
undock
|
|
185
|
+
});
|
|
186
|
+
//# sourceMappingURL=types.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/types/index.ts","../src/types/common.ts","../src/types/constants.ts","../src/types/actions.ts"],"sourcesContent":["/**\n * Copyright 2026 InOrbit, Inc.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport * from './common.js';\nexport * from './constants.js';\nexport * from './ccs.js';\nexport * from './identity.js';\nexport * from './status.js';\nexport * from './telemetry.js';\nexport * from './requests.js';\nexport * from './actions.js';\n","/**\n * Copyright 2026 InOrbit, Inc.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport type Uuid = string;\n/** ISO 8601-1 timestamp string, dot-decimal milliseconds, UTC. */\nexport type IsoTimestamp = string;\n\nexport function nowTimestamp(date: Date = new Date()): IsoTimestamp {\n return date.toISOString();\n}\n\n/** Accepts both dot and comma decimal separators (spec §3.1). */\nexport function parseTimestamp(ts: string): Date {\n return new Date(ts.replace(',', '.'));\n}\n","/**\n * Copyright 2026 InOrbit, Inc.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport const ROOT_NAMESPACE = '/ISO_21423/v1';\nexport const PROTOCOL_VERSION = '1.0';\n\nexport const ENTITY_TYPES = ['IMR', 'IMRFM'] as const;\nexport type KnownEntityType = (typeof ENTITY_TYPES)[number];\n/** Widened to allow vendor-defined entity types beyond the two the spec names, while still autocompleting the known ones. */\nexport type EntityType = KnownEntityType | (string & {});\n\n/** All operating states the spec defines: stop categories, motion states, and MODE_* (mutually-exclusive mode markers) mixed together. */\nexport const KNOWN_OPERATING_STATES = [\n 'STOP_CATEGORY_0', 'STOP_CATEGORY_1', 'STOP_CATEGORY_2',\n 'PAUSED', 'WAIT_FOR_RESET', 'MAPPING', 'LOST',\n 'WAIT_FOR_ATTACHMENT', 'WAIT_FOR_EVENT', 'BLOCKED', 'ATTACHMENT_ACTIVE',\n 'STOPPED', 'DOCKING', 'SLOWING', 'ACCELERATING',\n 'LEFT_TURN', 'RIGHT_TURN', 'REVERSE', 'FORWARD', 'LINE_FOLLOWING',\n 'CHARGING', 'LOW_BATTERY', 'IDLE', 'PARKED', 'OFFLINE',\n 'READY', 'NOT_READY',\n 'MODE_AUTO', 'MODE_SEMIAUTO', 'MODE_TELEOP', 'MODE_MANUAL', 'MODE_MAINTENANCE',\n] as const;\nexport type KnownOperatingState = (typeof KNOWN_OPERATING_STATES)[number];\nexport type OperatingState = KnownOperatingState | (string & {});\n\n/** Subset of {@link KNOWN_OPERATING_STATES} that are the mutually-exclusive MODE_* markers. */\nexport const OPERATING_MODES = [\n 'MODE_AUTO', 'MODE_SEMIAUTO', 'MODE_TELEOP', 'MODE_MANUAL', 'MODE_MAINTENANCE',\n] as const;\n\n/** LWT state published by the broker on ungraceful disconnect (B.4). */\nexport const LOST_CONNECTION_STATE = 'LOST_CONNECTION';\n\n/** Overall lifecycle states for a whole {@link Request} (its `RECOVERY` state has no per-detail equivalent — see {@link DetailState}). */\nexport const REQUEST_STATES = [\n 'RECEIVED', 'ACCEPTED', 'EXECUTING', 'CANCELED', 'SUCCEEDED', 'ABORTED', 'RECOVERY',\n] as const;\nexport type RequestState = (typeof REQUEST_STATES)[number];\n\n/** Lifecycle states for a single detail/action within a request. */\nexport const DETAIL_STATES = [\n 'RECEIVED', 'ACCEPTED', 'EXECUTING', 'CANCELED', 'SUCCEEDED', 'ABORTED',\n] as const;\nexport type DetailState = (typeof DETAIL_STATES)[number];\n\nexport const KNOWN_REASON_CODES = [\n 'OK', 'GENERAL_FAILURE', 'TIMEOUT', 'VERSION_NOT_SUPPORTED', 'FORMAT_NOT_SUPPORTED',\n 'ACTION_NOT_IMPLEMENTED', 'REJECTED', 'MALFORMED_REQUEST', 'INVALID_IMR_STATE_FOR_ACTION',\n] as const;\nexport type ReasonCode = (typeof KNOWN_REASON_CODES)[number] | (string & {});\n\nexport const BATTERY_HEALTH = [\n 'UNKNOWN', 'HEALTHY', 'OVERHEAT', 'DEAD', 'OVERVOLTAGE', 'FAILURE', 'COLD',\n] as const;\nexport type BatteryHealth = (typeof BATTERY_HEALTH)[number] | (string & {});\n\n/** Charging state as distinct from {@link BatteryHealth} — this is about current/direction of charge flow, not battery condition. */\nexport const CHARGING_STATES = [\n 'UNKNOWN', 'CHARGING', 'DISCHARGING', 'NOT_CHARGING', 'FULL',\n] as const;\nexport type ChargingState = (typeof CHARGING_STATES)[number] | (string & {});\n\nexport const DOCK_ACTIONS = ['CHARGE', 'DUMP', 'FILL', 'LOAD', 'UNLOAD', 'PICK', 'DROP'] as const;\nexport type DockAction = (typeof DOCK_ACTIONS)[number] | (string & {});\n","/**\n * Copyright 2026 InOrbit, Inc.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { PROTOCOL_VERSION, type DockAction } from './constants.js';\nimport type { Uuid } from './common.js';\nimport type { LocationPoint, Orientation } from './ccs.js';\nimport type { RequestDetail } from './requests.js';\n\nexport interface OrientationTolerance { yaw: number; pitch: number; roll: number }\n\nexport interface MoveProps {\n location: LocationPoint;\n orientation?: Orientation; // in examples but not Table C.3 (spec §3.1)\n toleranceRadius?: number;\n orientationTolerance?: OrientationTolerance;\n arrivalTime?: string;\n}\n\nexport interface CancelProps { source: Uuid; requestId: number; actionId?: number }\n\nexport interface DockProps {\n dockLocation: LocationPoint;\n dockId?: Uuid;\n dockActions?: DockAction[];\n toleranceRadius?: number;\n orientationTolerance?: OrientationTolerance;\n}\n\ninterface BuilderOpts { blocking?: boolean; atomic?: boolean; version?: string }\n\n/** Assembles a {@link RequestDetail}, filling in `format`/`version`/`blocking`/`atomic` defaults. */\nfunction detail(type: string, properties: Record<string, unknown>, opts: BuilderOpts = {}): RequestDetail {\n return {\n type,\n version: opts.version ?? PROTOCOL_VERSION,\n format: 'ISO-21423',\n blocking: opts.blocking ?? true,\n atomic: opts.atomic ?? false,\n properties,\n };\n}\n\nexport const move = (props: MoveProps, opts?: BuilderOpts): RequestDetail =>\n detail('move', { ...props }, opts);\nexport const pauseImr = (opts?: BuilderOpts): RequestDetail => detail('pauseImr', {}, opts);\nexport const resumeImr = (opts?: BuilderOpts): RequestDetail => detail('resumeImr', {}, opts);\n/** Builds a `cancelRequest` action detail targeting a previously-sent request/action by id. */\nexport const cancelRequest = (props: CancelProps, opts?: BuilderOpts): RequestDetail =>\n detail('cancelRequest', { ...props }, opts);\nexport const dock = (props: DockProps, opts?: BuilderOpts): RequestDetail =>\n detail('dock', { ...props }, opts);\nexport const undock = (opts?: BuilderOpts): RequestDetail => detail('undock', {}, opts);\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACoBO,SAAS,aAAa,OAAa,oBAAI,KAAK,GAAiB;AAClE,SAAO,KAAK,YAAY;AAC1B;AAGO,SAAS,eAAe,IAAkB;AAC/C,SAAO,IAAI,KAAK,GAAG,QAAQ,KAAK,GAAG,CAAC;AACtC;;;ACXO,IAAM,iBAAiB;AACvB,IAAM,mBAAmB;AAEzB,IAAM,eAAe,CAAC,OAAO,OAAO;AAMpC,IAAM,yBAAyB;AAAA,EACpC;AAAA,EAAmB;AAAA,EAAmB;AAAA,EACtC;AAAA,EAAU;AAAA,EAAkB;AAAA,EAAW;AAAA,EACvC;AAAA,EAAuB;AAAA,EAAkB;AAAA,EAAW;AAAA,EACpD;AAAA,EAAW;AAAA,EAAW;AAAA,EAAW;AAAA,EACjC;AAAA,EAAa;AAAA,EAAc;AAAA,EAAW;AAAA,EAAW;AAAA,EACjD;AAAA,EAAY;AAAA,EAAe;AAAA,EAAQ;AAAA,EAAU;AAAA,EAC7C;AAAA,EAAS;AAAA,EACT;AAAA,EAAa;AAAA,EAAiB;AAAA,EAAe;AAAA,EAAe;AAC9D;AAKO,IAAM,kBAAkB;AAAA,EAC7B;AAAA,EAAa;AAAA,EAAiB;AAAA,EAAe;AAAA,EAAe;AAC9D;AAGO,IAAM,wBAAwB;AAG9B,IAAM,iBAAiB;AAAA,EAC5B;AAAA,EAAY;AAAA,EAAY;AAAA,EAAa;AAAA,EAAY;AAAA,EAAa;AAAA,EAAW;AAC3E;AAIO,IAAM,gBAAgB;AAAA,EAC3B;AAAA,EAAY;AAAA,EAAY;AAAA,EAAa;AAAA,EAAY;AAAA,EAAa;AAChE;AAGO,IAAM,qBAAqB;AAAA,EAChC;AAAA,EAAM;AAAA,EAAmB;AAAA,EAAW;AAAA,EAAyB;AAAA,EAC7D;AAAA,EAA0B;AAAA,EAAY;AAAA,EAAqB;AAC7D;AAGO,IAAM,iBAAiB;AAAA,EAC5B;AAAA,EAAW;AAAA,EAAW;AAAA,EAAY;AAAA,EAAQ;AAAA,EAAe;AAAA,EAAW;AACtE;AAIO,IAAM,kBAAkB;AAAA,EAC7B;AAAA,EAAW;AAAA,EAAY;AAAA,EAAe;AAAA,EAAgB;AACxD;AAGO,IAAM,eAAe,CAAC,UAAU,QAAQ,QAAQ,QAAQ,UAAU,QAAQ,MAAM;;;AC/BvF,SAAS,OAAO,MAAc,YAAqC,OAAoB,CAAC,GAAkB;AACxG,SAAO;AAAA,IACL;AAAA,IACA,SAAS,KAAK,WAAW;AAAA,IACzB,QAAQ;AAAA,IACR,UAAU,KAAK,YAAY;AAAA,IAC3B,QAAQ,KAAK,UAAU;AAAA,IACvB;AAAA,EACF;AACF;AAEO,IAAM,OAAO,CAAC,OAAkB,SACrC,OAAO,QAAQ,EAAE,GAAG,MAAM,GAAG,IAAI;AAC5B,IAAM,WAAW,CAAC,SAAsC,OAAO,YAAY,CAAC,GAAG,IAAI;AACnF,IAAM,YAAY,CAAC,SAAsC,OAAO,aAAa,CAAC,GAAG,IAAI;AAErF,IAAM,gBAAgB,CAAC,OAAoB,SAChD,OAAO,iBAAiB,EAAE,GAAG,MAAM,GAAG,IAAI;AACrC,IAAM,OAAO,CAAC,OAAkB,SACrC,OAAO,QAAQ,EAAE,GAAG,MAAM,GAAG,IAAI;AAC5B,IAAM,SAAS,CAAC,SAAsC,OAAO,UAAU,CAAC,GAAG,IAAI;","names":[]}
|
package/dist/types.d.cts
ADDED
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { U as Uuid, I as IsoTimestamp, L as LocationPoint, O as Orientation } from './ccs-CU8XD5sl.cjs';
|
|
2
|
+
export { C as Ccs, P as Point, R as ReferencePoint, n as nowTimestamp, p as parseTimestamp } from './ccs-CU8XD5sl.cjs';
|
|
3
|
+
import { t as OperatingState, c as Capabilities, h as DockAction, y as RequestDetail } from './identity-BGr2FJmC.cjs';
|
|
4
|
+
export { A as AdditionalProperty, B as BATTERY_HEALTH, a as BatteryHealth, b as BatteryStatus, C as CHARGING_STATES, d as ChargingState, e as DETAIL_STATES, f as DOCK_ACTIONS, D as DetailState, g as DetailStatusBody, E as ENTITY_TYPES, i as EntityIdentity, j as EntityType, G as GlobalPath, k as GlobalPlan, I as ImrDetails, l as ImrfmDetails, K as KNOWN_OPERATING_STATES, m as KNOWN_REASON_CODES, n as KnownEntityType, o as KnownOperatingState, L as LOST_CONNECTION_STATE, p as LocalTrajectory, q as LocationPointStamped, N as NurbsControlPoint, r as NurbsCurve, O as OPERATING_MODES, s as Odometry, P as PROTOCOL_VERSION, u as REQUEST_STATES, v as ROOT_NAMESPACE, w as ReasonCode, x as Request, z as RequestDetailStatus, R as RequestState, F as RequestStatus, S as SoftwareVersion, H as SupportVendorContactInformation } from './identity-BGr2FJmC.cjs';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Copyright 2026 InOrbit, Inc.
|
|
8
|
+
*
|
|
9
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
10
|
+
* you may not use this file except in compliance with the License.
|
|
11
|
+
* You may obtain a copy of the License at
|
|
12
|
+
*
|
|
13
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
14
|
+
*
|
|
15
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
16
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
17
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
18
|
+
* See the License for the specific language governing permissions and
|
|
19
|
+
* limitations under the License.
|
|
20
|
+
*/
|
|
21
|
+
|
|
22
|
+
/** Periodic status snapshot published by an entity (IMR or IMRFM). */
|
|
23
|
+
interface EntityStatus {
|
|
24
|
+
entityId: Uuid;
|
|
25
|
+
timestamp: IsoTimestamp;
|
|
26
|
+
states: OperatingState[];
|
|
27
|
+
disabledCapabilities?: Capabilities;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Copyright 2026 InOrbit, Inc.
|
|
32
|
+
*
|
|
33
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
34
|
+
* you may not use this file except in compliance with the License.
|
|
35
|
+
* You may obtain a copy of the License at
|
|
36
|
+
*
|
|
37
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
38
|
+
*
|
|
39
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
40
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
41
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
42
|
+
* See the License for the specific language governing permissions and
|
|
43
|
+
* limitations under the License.
|
|
44
|
+
*/
|
|
45
|
+
|
|
46
|
+
interface OrientationTolerance {
|
|
47
|
+
yaw: number;
|
|
48
|
+
pitch: number;
|
|
49
|
+
roll: number;
|
|
50
|
+
}
|
|
51
|
+
interface MoveProps {
|
|
52
|
+
location: LocationPoint;
|
|
53
|
+
orientation?: Orientation;
|
|
54
|
+
toleranceRadius?: number;
|
|
55
|
+
orientationTolerance?: OrientationTolerance;
|
|
56
|
+
arrivalTime?: string;
|
|
57
|
+
}
|
|
58
|
+
interface CancelProps {
|
|
59
|
+
source: Uuid;
|
|
60
|
+
requestId: number;
|
|
61
|
+
actionId?: number;
|
|
62
|
+
}
|
|
63
|
+
interface DockProps {
|
|
64
|
+
dockLocation: LocationPoint;
|
|
65
|
+
dockId?: Uuid;
|
|
66
|
+
dockActions?: DockAction[];
|
|
67
|
+
toleranceRadius?: number;
|
|
68
|
+
orientationTolerance?: OrientationTolerance;
|
|
69
|
+
}
|
|
70
|
+
interface BuilderOpts {
|
|
71
|
+
blocking?: boolean;
|
|
72
|
+
atomic?: boolean;
|
|
73
|
+
version?: string;
|
|
74
|
+
}
|
|
75
|
+
declare const move: (props: MoveProps, opts?: BuilderOpts) => RequestDetail;
|
|
76
|
+
declare const pauseImr: (opts?: BuilderOpts) => RequestDetail;
|
|
77
|
+
declare const resumeImr: (opts?: BuilderOpts) => RequestDetail;
|
|
78
|
+
/** Builds a `cancelRequest` action detail targeting a previously-sent request/action by id. */
|
|
79
|
+
declare const cancelRequest: (props: CancelProps, opts?: BuilderOpts) => RequestDetail;
|
|
80
|
+
declare const dock: (props: DockProps, opts?: BuilderOpts) => RequestDetail;
|
|
81
|
+
declare const undock: (opts?: BuilderOpts) => RequestDetail;
|
|
82
|
+
|
|
83
|
+
export { type CancelProps, Capabilities, DockAction, type DockProps, type EntityStatus, IsoTimestamp, LocationPoint, type MoveProps, OperatingState, Orientation, type OrientationTolerance, RequestDetail, Uuid, cancelRequest, dock, move, pauseImr, resumeImr, undock };
|
package/dist/types.d.ts
ADDED
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { U as Uuid, I as IsoTimestamp, L as LocationPoint, O as Orientation } from './ccs-CU8XD5sl.js';
|
|
2
|
+
export { C as Ccs, P as Point, R as ReferencePoint, n as nowTimestamp, p as parseTimestamp } from './ccs-CU8XD5sl.js';
|
|
3
|
+
import { t as OperatingState, c as Capabilities, h as DockAction, y as RequestDetail } from './identity-Bw8Dik5S.js';
|
|
4
|
+
export { A as AdditionalProperty, B as BATTERY_HEALTH, a as BatteryHealth, b as BatteryStatus, C as CHARGING_STATES, d as ChargingState, e as DETAIL_STATES, f as DOCK_ACTIONS, D as DetailState, g as DetailStatusBody, E as ENTITY_TYPES, i as EntityIdentity, j as EntityType, G as GlobalPath, k as GlobalPlan, I as ImrDetails, l as ImrfmDetails, K as KNOWN_OPERATING_STATES, m as KNOWN_REASON_CODES, n as KnownEntityType, o as KnownOperatingState, L as LOST_CONNECTION_STATE, p as LocalTrajectory, q as LocationPointStamped, N as NurbsControlPoint, r as NurbsCurve, O as OPERATING_MODES, s as Odometry, P as PROTOCOL_VERSION, u as REQUEST_STATES, v as ROOT_NAMESPACE, w as ReasonCode, x as Request, z as RequestDetailStatus, R as RequestState, F as RequestStatus, S as SoftwareVersion, H as SupportVendorContactInformation } from './identity-Bw8Dik5S.js';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Copyright 2026 InOrbit, Inc.
|
|
8
|
+
*
|
|
9
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
10
|
+
* you may not use this file except in compliance with the License.
|
|
11
|
+
* You may obtain a copy of the License at
|
|
12
|
+
*
|
|
13
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
14
|
+
*
|
|
15
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
16
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
17
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
18
|
+
* See the License for the specific language governing permissions and
|
|
19
|
+
* limitations under the License.
|
|
20
|
+
*/
|
|
21
|
+
|
|
22
|
+
/** Periodic status snapshot published by an entity (IMR or IMRFM). */
|
|
23
|
+
interface EntityStatus {
|
|
24
|
+
entityId: Uuid;
|
|
25
|
+
timestamp: IsoTimestamp;
|
|
26
|
+
states: OperatingState[];
|
|
27
|
+
disabledCapabilities?: Capabilities;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Copyright 2026 InOrbit, Inc.
|
|
32
|
+
*
|
|
33
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
34
|
+
* you may not use this file except in compliance with the License.
|
|
35
|
+
* You may obtain a copy of the License at
|
|
36
|
+
*
|
|
37
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
38
|
+
*
|
|
39
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
40
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
41
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
42
|
+
* See the License for the specific language governing permissions and
|
|
43
|
+
* limitations under the License.
|
|
44
|
+
*/
|
|
45
|
+
|
|
46
|
+
interface OrientationTolerance {
|
|
47
|
+
yaw: number;
|
|
48
|
+
pitch: number;
|
|
49
|
+
roll: number;
|
|
50
|
+
}
|
|
51
|
+
interface MoveProps {
|
|
52
|
+
location: LocationPoint;
|
|
53
|
+
orientation?: Orientation;
|
|
54
|
+
toleranceRadius?: number;
|
|
55
|
+
orientationTolerance?: OrientationTolerance;
|
|
56
|
+
arrivalTime?: string;
|
|
57
|
+
}
|
|
58
|
+
interface CancelProps {
|
|
59
|
+
source: Uuid;
|
|
60
|
+
requestId: number;
|
|
61
|
+
actionId?: number;
|
|
62
|
+
}
|
|
63
|
+
interface DockProps {
|
|
64
|
+
dockLocation: LocationPoint;
|
|
65
|
+
dockId?: Uuid;
|
|
66
|
+
dockActions?: DockAction[];
|
|
67
|
+
toleranceRadius?: number;
|
|
68
|
+
orientationTolerance?: OrientationTolerance;
|
|
69
|
+
}
|
|
70
|
+
interface BuilderOpts {
|
|
71
|
+
blocking?: boolean;
|
|
72
|
+
atomic?: boolean;
|
|
73
|
+
version?: string;
|
|
74
|
+
}
|
|
75
|
+
declare const move: (props: MoveProps, opts?: BuilderOpts) => RequestDetail;
|
|
76
|
+
declare const pauseImr: (opts?: BuilderOpts) => RequestDetail;
|
|
77
|
+
declare const resumeImr: (opts?: BuilderOpts) => RequestDetail;
|
|
78
|
+
/** Builds a `cancelRequest` action detail targeting a previously-sent request/action by id. */
|
|
79
|
+
declare const cancelRequest: (props: CancelProps, opts?: BuilderOpts) => RequestDetail;
|
|
80
|
+
declare const dock: (props: DockProps, opts?: BuilderOpts) => RequestDetail;
|
|
81
|
+
declare const undock: (opts?: BuilderOpts) => RequestDetail;
|
|
82
|
+
|
|
83
|
+
export { type CancelProps, Capabilities, DockAction, type DockProps, type EntityStatus, IsoTimestamp, LocationPoint, type MoveProps, OperatingState, Orientation, type OrientationTolerance, RequestDetail, Uuid, cancelRequest, dock, move, pauseImr, resumeImr, undock };
|
package/dist/types.js
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import "./chunk-W7DIDPTG.js";
|
|
2
|
+
import {
|
|
3
|
+
cancelRequest,
|
|
4
|
+
dock,
|
|
5
|
+
move,
|
|
6
|
+
pauseImr,
|
|
7
|
+
resumeImr,
|
|
8
|
+
undock
|
|
9
|
+
} from "./chunk-3JNSIJSX.js";
|
|
10
|
+
import {
|
|
11
|
+
nowTimestamp,
|
|
12
|
+
parseTimestamp
|
|
13
|
+
} from "./chunk-UJC46NTA.js";
|
|
14
|
+
import {
|
|
15
|
+
BATTERY_HEALTH,
|
|
16
|
+
CHARGING_STATES,
|
|
17
|
+
DETAIL_STATES,
|
|
18
|
+
DOCK_ACTIONS,
|
|
19
|
+
ENTITY_TYPES,
|
|
20
|
+
KNOWN_OPERATING_STATES,
|
|
21
|
+
KNOWN_REASON_CODES,
|
|
22
|
+
LOST_CONNECTION_STATE,
|
|
23
|
+
OPERATING_MODES,
|
|
24
|
+
PROTOCOL_VERSION,
|
|
25
|
+
REQUEST_STATES,
|
|
26
|
+
ROOT_NAMESPACE
|
|
27
|
+
} from "./chunk-RD7PYTIT.js";
|
|
28
|
+
export {
|
|
29
|
+
BATTERY_HEALTH,
|
|
30
|
+
CHARGING_STATES,
|
|
31
|
+
DETAIL_STATES,
|
|
32
|
+
DOCK_ACTIONS,
|
|
33
|
+
ENTITY_TYPES,
|
|
34
|
+
KNOWN_OPERATING_STATES,
|
|
35
|
+
KNOWN_REASON_CODES,
|
|
36
|
+
LOST_CONNECTION_STATE,
|
|
37
|
+
OPERATING_MODES,
|
|
38
|
+
PROTOCOL_VERSION,
|
|
39
|
+
REQUEST_STATES,
|
|
40
|
+
ROOT_NAMESPACE,
|
|
41
|
+
cancelRequest,
|
|
42
|
+
dock,
|
|
43
|
+
move,
|
|
44
|
+
nowTimestamp,
|
|
45
|
+
parseTimestamp,
|
|
46
|
+
pauseImr,
|
|
47
|
+
resumeImr,
|
|
48
|
+
undock
|
|
49
|
+
};
|
|
50
|
+
//# sourceMappingURL=types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|