@kuriousdesign/machine-sdk 1.0.36 → 1.0.37
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,4 +1,12 @@
|
|
|
1
1
|
import { PartStateDeprecated as PartStateDeprecated } from "../enums";
|
|
2
|
+
export declare enum PartLocationIds {
|
|
3
|
+
None = 0,
|
|
4
|
+
RobotGripper = 1,
|
|
5
|
+
LeftFixture_P1 = 2,
|
|
6
|
+
RightFixture_P1,
|
|
7
|
+
Lost
|
|
8
|
+
}
|
|
9
|
+
export declare function partLocationIdToString(locationId: PartLocationIds): string;
|
|
2
10
|
export declare enum PartStates {
|
|
3
11
|
Empty = 0,//no part present
|
|
4
12
|
UnvalidatedRaw = 10,//used if registered by sensor, but not approved by operator
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.initialPartDataStatus = exports.initialPartData = exports.initialPartValidationData = exports.PartStates = void 0;
|
|
3
|
+
exports.initialPartDataStatus = exports.initialPartData = exports.initialPartValidationData = exports.PartStates = exports.PartLocationIds = void 0;
|
|
4
|
+
exports.partLocationIdToString = partLocationIdToString;
|
|
4
5
|
exports.partStateToString = partStateToString;
|
|
5
6
|
const GlobalConstants_1 = require("./GlobalConstants");
|
|
6
7
|
// TYPE PartValidationData :
|
|
@@ -44,6 +45,36 @@ const GlobalConstants_1 = require("./GlobalConstants");
|
|
|
44
45
|
// Passed:=1000 //ProessingDone, back in fixture and waiting to be unloaded
|
|
45
46
|
// );
|
|
46
47
|
// END_TYPE
|
|
48
|
+
// {attribute 'qualified_only'}
|
|
49
|
+
// //{attribute 'strict'}
|
|
50
|
+
// TYPE PartLocationIds :
|
|
51
|
+
// (
|
|
52
|
+
// None:=0,
|
|
53
|
+
// RobotGripper:=1,
|
|
54
|
+
// LeftFixture_P1 :=2,
|
|
55
|
+
// RightFixture_P1:=LeftFixture_P1 + GCs.NUM_PARTS_PER_FIXTURE,
|
|
56
|
+
// Lost:=RightFixture_P1 + GCs.NUM_PARTS_PER_FIXTURE
|
|
57
|
+
// );
|
|
58
|
+
// END_TYPE
|
|
59
|
+
var PartLocationIds;
|
|
60
|
+
(function (PartLocationIds) {
|
|
61
|
+
PartLocationIds[PartLocationIds["None"] = 0] = "None";
|
|
62
|
+
PartLocationIds[PartLocationIds["RobotGripper"] = 1] = "RobotGripper";
|
|
63
|
+
PartLocationIds[PartLocationIds["LeftFixture_P1"] = 2] = "LeftFixture_P1";
|
|
64
|
+
PartLocationIds[PartLocationIds["RightFixture_P1"] = PartLocationIds.LeftFixture_P1 + GlobalConstants_1.GCs.NUM_PARTS_PER_FIXTURE] = "RightFixture_P1";
|
|
65
|
+
PartLocationIds[PartLocationIds["Lost"] = PartLocationIds.RightFixture_P1 + GlobalConstants_1.GCs.NUM_PARTS_PER_FIXTURE] = "Lost";
|
|
66
|
+
})(PartLocationIds || (exports.PartLocationIds = PartLocationIds = {}));
|
|
67
|
+
;
|
|
68
|
+
function partLocationIdToString(locationId) {
|
|
69
|
+
switch (locationId) {
|
|
70
|
+
case PartLocationIds.None: return "None";
|
|
71
|
+
case PartLocationIds.RobotGripper: return "Robot Gripper";
|
|
72
|
+
case PartLocationIds.LeftFixture_P1: return "Left Fixture P1";
|
|
73
|
+
case PartLocationIds.RightFixture_P1: return "Right Fixture P1";
|
|
74
|
+
case PartLocationIds.Lost: return "Lost";
|
|
75
|
+
default: return "Unknown";
|
|
76
|
+
}
|
|
77
|
+
}
|
|
47
78
|
var PartStates;
|
|
48
79
|
(function (PartStates) {
|
|
49
80
|
PartStates[PartStates["Empty"] = 0] = "Empty";
|
package/package.json
CHANGED
package/src/custom-types/Part.ts
CHANGED
|
@@ -58,6 +58,38 @@ import { GCs } from "./GlobalConstants";
|
|
|
58
58
|
// );
|
|
59
59
|
// END_TYPE
|
|
60
60
|
|
|
61
|
+
|
|
62
|
+
// {attribute 'qualified_only'}
|
|
63
|
+
// //{attribute 'strict'}
|
|
64
|
+
// TYPE PartLocationIds :
|
|
65
|
+
// (
|
|
66
|
+
// None:=0,
|
|
67
|
+
// RobotGripper:=1,
|
|
68
|
+
// LeftFixture_P1 :=2,
|
|
69
|
+
// RightFixture_P1:=LeftFixture_P1 + GCs.NUM_PARTS_PER_FIXTURE,
|
|
70
|
+
// Lost:=RightFixture_P1 + GCs.NUM_PARTS_PER_FIXTURE
|
|
71
|
+
// );
|
|
72
|
+
// END_TYPE
|
|
73
|
+
|
|
74
|
+
export enum PartLocationIds {
|
|
75
|
+
None = 0,
|
|
76
|
+
RobotGripper = 1,
|
|
77
|
+
LeftFixture_P1 = 2,
|
|
78
|
+
RightFixture_P1 = LeftFixture_P1 + GCs.NUM_PARTS_PER_FIXTURE,
|
|
79
|
+
Lost = RightFixture_P1 + GCs.NUM_PARTS_PER_FIXTURE
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
export function partLocationIdToString(locationId: PartLocationIds): string {
|
|
83
|
+
switch (locationId) {
|
|
84
|
+
case PartLocationIds.None: return "None";
|
|
85
|
+
case PartLocationIds.RobotGripper: return "Robot Gripper";
|
|
86
|
+
case PartLocationIds.LeftFixture_P1: return "Left Fixture P1";
|
|
87
|
+
case PartLocationIds.RightFixture_P1: return "Right Fixture P1";
|
|
88
|
+
case PartLocationIds.Lost: return "Lost";
|
|
89
|
+
default: return "Unknown";
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
61
93
|
export enum PartStates {
|
|
62
94
|
Empty = 0,//no part present
|
|
63
95
|
//BadSensorEmpty = 1, //used if sensors give false positive
|