@duet3d/objectmodel 3.7.0-alpha.14 → 3.7.0-alpha.15

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.
@@ -21,7 +21,7 @@ export declare enum DriverMode {
21
21
  }
22
22
  export declare class DriverConfig extends ModelObject {
23
23
  direction: boolean;
24
- mode: DriverMode;
24
+ mode: DriverMode | null;
25
25
  }
26
26
  export default class Driver extends ModelObject {
27
27
  constructor();
@@ -33,7 +33,7 @@ export class DriverConfig extends ModelObject {
33
33
  constructor() {
34
34
  super(...arguments);
35
35
  this.direction = true;
36
- this.mode = DriverMode.spreadCycle;
36
+ this.mode = null;
37
37
  }
38
38
  }
39
39
  export default class Driver extends ModelObject {
@@ -11,7 +11,7 @@ export class DirectDisplayScreenST7567 extends DirectDisplayScreenBase {
11
11
  return null;
12
12
  }
13
13
  if (typeof jsonElement.controller === "string" && jsonElement.controller !== this.controller) {
14
- return getDirectDisplayScreen(jsonElement.type).update(jsonElement);
14
+ return getDirectDisplayScreen(jsonElement.controller).update(jsonElement);
15
15
  }
16
16
  return super.update(jsonElement);
17
17
  }
@@ -29,7 +29,6 @@ export declare class MinMaxCurrent extends ModelObject {
29
29
  export declare class Board extends ModelObject {
30
30
  constructor();
31
31
  accelerometer: Accelerometer | null;
32
- bootloaderFileName: string | null;
33
32
  canAddress: number | null;
34
33
  closedLoop: BoardClosedLoop | null;
35
34
  directDisplay: DirectDisplay | null;
@@ -40,7 +40,6 @@ export class Board extends ModelObject {
40
40
  constructor() {
41
41
  super();
42
42
  this.accelerometer = null;
43
- this.bootloaderFileName = null;
44
43
  this.canAddress = null;
45
44
  this.closedLoop = null;
46
45
  this.directDisplay = null;
@@ -10,7 +10,6 @@
10
10
  },
11
11
  "boards[].accelerometer.points": "Number of collected data points in the last run or 0 if it failed",
12
12
  "boards[].accelerometer.runs": "Number of completed sampling runs",
13
- "boards[].bootloaderFileName": "Filename of the bootloader binary or null if unknown",
14
13
  "boards[].canAddress": "CAN address of this board or null if not applicable",
15
14
  "boards[].closedLoop": "Closed loop data of this board or null if unknown",
16
15
  "boards[].closedLoop.points": "Number of collected data points in the last run or 0 if it failed",
@@ -168,12 +167,19 @@
168
167
  "heat.heaters[].model.pid": "Details about the PID controller",
169
168
  "heat.heaters[].model.pid.d": "Derivative value of the PID regulator",
170
169
  "heat.heaters[].model.pid.i": "Integral value of the PID regulator",
171
- "heat.heaters[].model.pid.overridden": "Indicates if custom PID values are used",
172
170
  "heat.heaters[].model.pid.p": "Proportional value of the PID regulator",
173
171
  "heat.heaters[].model.pid.used": "Indicates if PID control is being used",
174
172
  "heat.heaters[].model.standardVoltage": "Standard voltage or null if unknown",
175
173
  "heat.heaters[].monitors": "Monitors of this heater",
176
- "heat.heaters[].monitors[].action": "Action to perform when the trigger condition is met",
174
+ "heat.heaters[].monitors[].action": {
175
+ "summary": "Action to perform when the trigger condition is met",
176
+ "values": {
177
+ "0": "Generate a heater fault",
178
+ "1": "Permanently switch off the heater",
179
+ "2": "Temporarily switch off the heater until the condition is no longer met",
180
+ "3": "Shut down the printer"
181
+ }
182
+ },
177
183
  "heat.heaters[].monitors[].condition": {
178
184
  "summary": "Condition to meet to perform an action",
179
185
  "values": {
@@ -624,11 +630,25 @@
624
630
  "network.interfaces[].firmwareVersion": "Version of the network interface or null if unknown. This is only reported by ESP-based boards in standalone mode",
625
631
  "network.interfaces[].gateway": "IPv4 gateway of the network adapter or null if unknown",
626
632
  "network.interfaces[].mac": "Physical address of the network adapter or null if unknown",
627
- "network.interfaces[].numReconnects": "Number of reconnect attempts or null if unknown. This is only reported by ESP-based boards in standalone mode",
628
633
  "network.interfaces[].rssi": "Received signal strength indicator of the WiFi adapter (only WiFi, in dBm, or null if unknown)",
629
634
  "network.interfaces[].speed": "Speed of the network interface (in MBit, null if unknown, 0 if not connected)",
630
635
  "network.interfaces[].ssid": "SSID of the WiFi network or null if not applicable",
631
- "network.interfaces[].state": "State of this network interface or null if unknown",
636
+ "network.interfaces[].state": {
637
+ "summary": "State of this network interface or null if unknown",
638
+ "values": {
639
+ "disabled": null,
640
+ "enabled": null,
641
+ "initFailed": null,
642
+ "starting1": null,
643
+ "starting2": null,
644
+ "changingMode": null,
645
+ "establishingLink": null,
646
+ "obtainingIP": null,
647
+ "connected": null,
648
+ "active": null,
649
+ "idle": null
650
+ }
651
+ },
632
652
  "network.interfaces[].subnet": "Subnet of the network adapter or null if unknown",
633
653
  "network.interfaces[].type": {
634
654
  "summary": "Type of this network interface",
@@ -801,6 +821,10 @@
801
821
  "overOrUnderVoltage": "Sensor exceeded min/max voltage",
802
822
  "badVref": "Bad VREF detected",
803
823
  "badVssa": "Bad VSSA detected",
824
+ "readingTooLow": null,
825
+ "readingTooHigh": null,
826
+ "ambientReadingTooLow": null,
827
+ "ambientReadingTooHigh": null,
804
828
  "unknownError": "Unknown error"
805
829
  }
806
830
  },
@@ -819,8 +843,13 @@
819
843
  "bme280": "BME280 sensor",
820
844
  "bmepressure": "BME280 pressure sensor",
821
845
  "bmehumidity": "BME280 humidity sensor",
822
- "currentloooppyro": "Current loop sensor",
823
- "ads131.chan0": "ADS131 channel 0",
846
+ "bme68x": null,
847
+ "bme68xpressure": null,
848
+ "bme68xhumidity": null,
849
+ "bme68xgas": null,
850
+ "currentloop": "Current loop sensor",
851
+ "ads131.chan0.u": null,
852
+ "ads131.chan0.b": null,
824
853
  "ads131.chan1": "ADS131 channel 1",
825
854
  "mcutemp": "MCU temperature",
826
855
  "drivers": "On-board stepper driver sensors",
@@ -877,8 +906,6 @@
877
906
  "sensors.gpIn": "List of general-purpose input ports",
878
907
  "sensors.gpIn[].value": "Value of this port (0..1)",
879
908
  "sensors.probes": "List of configured probes",
880
- "sensors.probes[].calibA": "Linear coefficient for scanning probes",
881
- "sensors.probes[].calibB": "Quadratic coefficient for scanning probes",
882
909
  "sensors.probes[].calibrationTemperature": "Calibration temperature (in C)",
883
910
  "sensors.probes[].deployedByUser": "Indicates if the user has deployed the probe",
884
911
  "sensors.probes[].disablesHeaters": "Whether probing disables the heater(s)",
@@ -939,7 +966,13 @@
939
966
  "reverse": "Spindle is going in reverse"
940
967
  }
941
968
  },
942
- "spindles[].type": "Spindle type",
969
+ "spindles[].type": {
970
+ "summary": "Spindle type",
971
+ "values": {
972
+ "enaDir": "Enable and direction",
973
+ "fwdRev": "Forward and reverse"
974
+ }
975
+ },
943
976
  "state": "Information about the machine state",
944
977
  "state.atxPower": "State of the ATX power pin (if controlled)",
945
978
  "state.atxPowerPort": "Port of the ATX power pin or null if not assigned",
package/dist/enums.json CHANGED
@@ -20,6 +20,12 @@
20
20
  "running",
21
21
  "timedOut"
22
22
  ],
23
+ "heat.heaters[].monitors[].action": [
24
+ "0",
25
+ "1",
26
+ "2",
27
+ "3"
28
+ ],
23
29
  "heat.heaters[].monitors[].condition": [
24
30
  "disabled",
25
31
  "tooHigh",
@@ -139,6 +145,19 @@
139
145
  "ei3",
140
146
  "custom"
141
147
  ],
148
+ "network.interfaces[].state": [
149
+ "disabled",
150
+ "enabled",
151
+ "initFailed",
152
+ "starting1",
153
+ "starting2",
154
+ "changingMode",
155
+ "establishingLink",
156
+ "obtainingIP",
157
+ "connected",
158
+ "active",
159
+ "idle"
160
+ ],
142
161
  "network.interfaces[].type": [
143
162
  "ethernet",
144
163
  "wifi"
@@ -185,6 +204,10 @@
185
204
  "overOrUnderVoltage",
186
205
  "badVref",
187
206
  "badVssa",
207
+ "readingTooLow",
208
+ "readingTooHigh",
209
+ "ambientReadingTooLow",
210
+ "ambientReadingTooHigh",
188
211
  "unknownError"
189
212
  ],
190
213
  "sensors.analog[].type": [
@@ -200,8 +223,13 @@
200
223
  "bme280",
201
224
  "bmepressure",
202
225
  "bmehumidity",
203
- "currentloooppyro",
204
- "ads131.chan0",
226
+ "bme68x",
227
+ "bme68xpressure",
228
+ "bme68xhumidity",
229
+ "bme68xgas",
230
+ "currentloop",
231
+ "ads131.chan0.u",
232
+ "ads131.chan0.b",
205
233
  "ads131.chan1",
206
234
  "mcutemp",
207
235
  "drivers",
@@ -256,6 +284,10 @@
256
284
  "forward",
257
285
  "reverse"
258
286
  ],
287
+ "spindles[].type": [
288
+ "enaDir",
289
+ "fwdRev"
290
+ ],
259
291
  "state.logLevel": [
260
292
  "debug",
261
293
  "info",
@@ -2,7 +2,6 @@ import ModelObject from "../ModelObject";
2
2
  export declare class HeaterModelPID extends ModelObject {
3
3
  d: number;
4
4
  i: number;
5
- overridden: boolean;
6
5
  p: number;
7
6
  used: boolean;
8
7
  }
@@ -4,7 +4,6 @@ export class HeaterModelPID extends ModelObject {
4
4
  super(...arguments);
5
5
  this.d = 0;
6
6
  this.i = 0;
7
- this.overridden = false;
8
7
  this.p = 0;
9
8
  this.used = true;
10
9
  }
@@ -13,6 +13,7 @@ export declare enum CodeChannel {
13
13
  autopause = 11,
14
14
  file2 = 12,
15
15
  queue2 = 13,
16
- unknown = 14
16
+ usb2 = 14,
17
+ unknown = 15
17
18
  }
18
19
  export default CodeChannel;
@@ -14,6 +14,7 @@ export var CodeChannel;
14
14
  CodeChannel[CodeChannel["autopause"] = 11] = "autopause";
15
15
  CodeChannel[CodeChannel["file2"] = 12] = "file2";
16
16
  CodeChannel[CodeChannel["queue2"] = 13] = "queue2";
17
- CodeChannel[CodeChannel["unknown"] = 14] = "unknown";
17
+ CodeChannel[CodeChannel["usb2"] = 14] = "usb2";
18
+ CodeChannel[CodeChannel["unknown"] = 15] = "unknown";
18
19
  })(CodeChannel || (CodeChannel = {}));
19
20
  export default CodeChannel;
@@ -6,7 +6,7 @@ export declare class GCodeFileInfo extends ModelObject {
6
6
  readonly customInfo: ModelDictionary<any>;
7
7
  filament: Array<number>;
8
8
  fileName: string;
9
- generatedBy: string;
9
+ generatedBy: string | null;
10
10
  height: number;
11
11
  lastModified: string | null;
12
12
  layerHeight: number;
@@ -8,7 +8,7 @@ export class GCodeFileInfo extends ModelObject {
8
8
  this.customInfo = new ModelDictionary(false);
9
9
  this.filament = new Array();
10
10
  this.fileName = "";
11
- this.generatedBy = "";
11
+ this.generatedBy = null;
12
12
  this.height = 0;
13
13
  this.lastModified = null;
14
14
  this.layerHeight = 0;
@@ -11,7 +11,7 @@ export declare class Layer extends ModelObject {
11
11
  filamentUsage: number;
12
12
  fractionPrinted: number;
13
13
  height: number;
14
- temperatures: Array<number>;
14
+ temperatures: Array<number | null>;
15
15
  }
16
16
  export declare class TimesLeft extends ModelObject {
17
17
  filament: number | null;
@@ -21,9 +21,9 @@ export declare class TimesLeft extends ModelObject {
21
21
  }
22
22
  export declare class Job extends ModelObject {
23
23
  constructor();
24
- build: Build;
24
+ build: Build | null;
25
25
  duration: number | null;
26
- file: GCodeFileInfo | null;
26
+ readonly file: GCodeFileInfo;
27
27
  filePosition: number | bigint | null;
28
28
  lastDuration: number | null;
29
29
  lastFileName: string | null;
package/dist/job/index.js CHANGED
@@ -28,9 +28,9 @@ export class TimesLeft extends ModelObject {
28
28
  export class Job extends ModelObject {
29
29
  constructor() {
30
30
  super();
31
- this.build = new Build();
31
+ this.build = null;
32
32
  this.duration = null;
33
- this.file = null;
33
+ this.file = new GCodeFileInfo();
34
34
  this.filePosition = null;
35
35
  this.lastDuration = null;
36
36
  this.lastFileName = null;
@@ -46,7 +46,6 @@ export class Job extends ModelObject {
46
46
  this.timesLeft = new TimesLeft();
47
47
  this.warmUpDuration = null;
48
48
  ModelObject.wrapModelProperty(this, "build", Build);
49
- ModelObject.wrapModelProperty(this, "file", GCodeFileInfo);
50
49
  }
51
50
  }
52
51
  export default Job;
@@ -18,7 +18,7 @@ export class LedStrip extends ModelObject {
18
18
  constructor() {
19
19
  super(...arguments);
20
20
  this.board = 0;
21
- this.colorOrder = LedStripColorOrder.GRB;
21
+ this.colorOrder = LedStripColorOrder.BGR;
22
22
  this.maxLeds = 0;
23
23
  this.pin = "";
24
24
  this.stopMovement = false;
@@ -20,7 +20,7 @@ export declare class MoveSegmentation extends ModelObject {
20
20
  }
21
21
  export declare abstract class KinematicsBase extends ModelObject {
22
22
  readonly name: KinematicsName;
23
- readonly segmentation: MoveSegmentation;
23
+ segmentation: MoveSegmentation | null;
24
24
  constructor(name: KinematicsName);
25
25
  }
26
26
  export default KinematicsBase;
@@ -25,8 +25,9 @@ export class MoveSegmentation extends ModelObject {
25
25
  export class KinematicsBase extends ModelObject {
26
26
  constructor(name) {
27
27
  super();
28
- this.segmentation = new MoveSegmentation();
28
+ this.segmentation = null;
29
29
  this.name = name;
30
+ ModelObject.wrapModelProperty(this, "segmentation", MoveSegmentation);
30
31
  }
31
32
  }
32
33
  export default KinematicsBase;
@@ -11,6 +11,7 @@ export declare enum NetworkProtocol {
11
11
  export declare enum NetworkInterfaceState {
12
12
  disabled = "disabled",
13
13
  enabled = "enabled",
14
+ initFailed = "initFailed",
14
15
  starting1 = "starting1",
15
16
  starting2 = "starting2",
16
17
  changingMode = "changingMode",
@@ -32,7 +33,6 @@ export declare class NetworkInterface extends ModelObject {
32
33
  firmwareVersion: string | null;
33
34
  gateway: string | null;
34
35
  mac: string | null;
35
- numReconnects: number | null;
36
36
  rssi: number | null;
37
37
  /** @deprecated use rssi instead */
38
38
  signal: number | null;
@@ -13,6 +13,7 @@ export var NetworkInterfaceState;
13
13
  (function (NetworkInterfaceState) {
14
14
  NetworkInterfaceState["disabled"] = "disabled";
15
15
  NetworkInterfaceState["enabled"] = "enabled";
16
+ NetworkInterfaceState["initFailed"] = "initFailed";
16
17
  NetworkInterfaceState["starting1"] = "starting1";
17
18
  NetworkInterfaceState["starting2"] = "starting2";
18
19
  NetworkInterfaceState["changingMode"] = "changingMode";
@@ -37,7 +38,6 @@ export class NetworkInterface extends ModelObject {
37
38
  this.firmwareVersion = null;
38
39
  this.gateway = null;
39
40
  this.mac = null;
40
- this.numReconnects = null;
41
41
  this.rssi = null;
42
42
  /** @deprecated use rssi instead */
43
43
  this.signal = null;
@@ -1,6 +1,6 @@
1
1
  import ModelObject from "../ModelObject";
2
2
  export declare class Memory extends ModelObject {
3
- available: number | null;
4
- total: number | null;
3
+ available: number | bigint | null;
4
+ total: number | bigint | null;
5
5
  }
6
6
  export default Memory;
@@ -11,7 +11,7 @@ export declare enum SessionType {
11
11
  export declare class UserSession extends ModelObject {
12
12
  accessLevel: AccessLevel;
13
13
  id: number;
14
- origin: string | null;
14
+ origin: string;
15
15
  originId: number;
16
16
  sessionType: SessionType;
17
17
  }
@@ -15,7 +15,7 @@ export class UserSession extends ModelObject {
15
15
  super(...arguments);
16
16
  this.accessLevel = AccessLevel.readOnly;
17
17
  this.id = 0;
18
- this.origin = null;
18
+ this.origin = "";
19
19
  this.originId = -1;
20
20
  this.sessionType = SessionType.local;
21
21
  }
@@ -16,3 +16,4 @@ export declare class DSF extends ModelObject {
16
16
  export default DSF;
17
17
  export * from "./CommunicationMethod";
18
18
  export * from "./HttpEndpoint";
19
+ export * from "./UserSession";
@@ -19,3 +19,4 @@ export class DSF extends ModelObject {
19
19
  export default DSF;
20
20
  export * from "./CommunicationMethod";
21
21
  export * from "./HttpEndpoint";
22
+ export * from "./UserSession";
@@ -12,8 +12,13 @@ export declare enum AnalogSensorType {
12
12
  bme280 = "bme280",
13
13
  bme280pressure = "bmepressure",
14
14
  bme280humidity = "bmehumidity",
15
- currentLoop = "currentloooppyro",
16
- ads131chan0 = "ads131.chan0",
15
+ bme68x = "bme68x",
16
+ bme68xpressure = "bme68xpressure",
17
+ bme68xhumidity = "bme68xhumidity",
18
+ bme68xgas = "bme68xgas",
19
+ currentLoop = "currentloop",
20
+ ads131chan0Unipolar = "ads131.chan0.u",
21
+ ads131chan0Bipolar = "ads131.chan0.b",
17
22
  ads131chan1 = "ads131.chan1",
18
23
  mcuTemp = "mcutemp",
19
24
  drivers = "drivers",
@@ -39,6 +44,10 @@ export declare enum TemperatureError {
39
44
  overOrUnderVoltage = "overOrUnderVoltage",
40
45
  badVref = "badVref",
41
46
  badVssa = "badVssa",
47
+ readingTooLow = "readingTooLow",
48
+ readingTooHigh = "readingTooHigh",
49
+ ambientReadingTooLow = "ambientReadingTooLow",
50
+ ambientReadingTooHigh = "ambientReadingTooHigh",
42
51
  unknownError = "unknownError"
43
52
  }
44
53
  export declare class AnalogSensor extends ModelObject {
@@ -13,8 +13,13 @@ export var AnalogSensorType;
13
13
  AnalogSensorType["bme280"] = "bme280";
14
14
  AnalogSensorType["bme280pressure"] = "bmepressure";
15
15
  AnalogSensorType["bme280humidity"] = "bmehumidity";
16
- AnalogSensorType["currentLoop"] = "currentloooppyro";
17
- AnalogSensorType["ads131chan0"] = "ads131.chan0";
16
+ AnalogSensorType["bme68x"] = "bme68x";
17
+ AnalogSensorType["bme68xpressure"] = "bme68xpressure";
18
+ AnalogSensorType["bme68xhumidity"] = "bme68xhumidity";
19
+ AnalogSensorType["bme68xgas"] = "bme68xgas";
20
+ AnalogSensorType["currentLoop"] = "currentloop";
21
+ AnalogSensorType["ads131chan0Unipolar"] = "ads131.chan0.u";
22
+ AnalogSensorType["ads131chan0Bipolar"] = "ads131.chan0.b";
18
23
  AnalogSensorType["ads131chan1"] = "ads131.chan1";
19
24
  AnalogSensorType["mcuTemp"] = "mcutemp";
20
25
  AnalogSensorType["drivers"] = "drivers";
@@ -41,6 +46,10 @@ export var TemperatureError;
41
46
  TemperatureError["overOrUnderVoltage"] = "overOrUnderVoltage";
42
47
  TemperatureError["badVref"] = "badVref";
43
48
  TemperatureError["badVssa"] = "badVssa";
49
+ TemperatureError["readingTooLow"] = "readingTooLow";
50
+ TemperatureError["readingTooHigh"] = "readingTooHigh";
51
+ TemperatureError["ambientReadingTooLow"] = "ambientReadingTooLow";
52
+ TemperatureError["ambientReadingTooHigh"] = "ambientReadingTooHigh";
44
53
  TemperatureError["unknownError"] = "unknownError";
45
54
  })(TemperatureError || (TemperatureError = {}));
46
55
  export class AnalogSensor extends ModelObject {
@@ -21,8 +21,6 @@ export declare class ProbeTouchMode extends ModelObject {
21
21
  }
22
22
  export declare class Probe extends ModelObject {
23
23
  constructor();
24
- calibA: number | null;
25
- calibB: number | null;
26
24
  calibrationTemperature: number;
27
25
  deployedByUser: boolean;
28
26
  disablesHeaters: boolean;
@@ -26,8 +26,6 @@ export class ProbeTouchMode extends ModelObject {
26
26
  export class Probe extends ModelObject {
27
27
  constructor() {
28
28
  super();
29
- this.calibA = null;
30
- this.calibB = null;
31
29
  this.calibrationTemperature = 0;
32
30
  this.deployedByUser = false;
33
31
  this.disablesHeaters = false;
@@ -22,7 +22,7 @@ export declare class Tool extends ModelObject {
22
22
  name: string;
23
23
  number: number;
24
24
  offsets: Array<number>;
25
- offsetsProbed: boolean;
25
+ offsetsProbed: number;
26
26
  retraction: ToolRetraction;
27
27
  spindle: number;
28
28
  spindleRpm: number;
@@ -25,7 +25,7 @@ export class Tool extends ModelObject {
25
25
  this.name = "";
26
26
  this.number = 0;
27
27
  this.offsets = [];
28
- this.offsetsProbed = false;
28
+ this.offsetsProbed = 0;
29
29
  this.retraction = new ToolRetraction();
30
30
  this.spindle = -1;
31
31
  this.spindleRpm = 0;
@@ -4,7 +4,7 @@ export declare class Volume extends ModelObject {
4
4
  freeSpace: number | bigint | null;
5
5
  mounted: boolean;
6
6
  name: string | null;
7
- openFiles: number | null;
7
+ openFiles: boolean | null;
8
8
  partitionSize: number | bigint | null;
9
9
  path: string | null;
10
10
  speed: number | null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@duet3d/objectmodel",
3
- "version": "3.7.0-alpha.14",
3
+ "version": "3.7.0-alpha.15",
4
4
  "description": "TypeScript implementation of the Duet3D Object Model",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",