@zaber/motion 4.5.0 → 4.5.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.
@@ -8,9 +8,7 @@ import { ProcessControllerSource } from './process_controller_source';
8
8
  import { Measurement } from '../measurement';
9
9
  /**
10
10
  * Use to drive voltage for a process such as a heater, valve, Peltier device, etc.
11
- * WARNING: DO NOT USE. This API is for an as-yet unreleased product and firmware version.
12
- * It is subject to breaking changes without warning until further notice.
13
- * Requires at least Firmware 7.34.
11
+ * Requires at least Firmware 7.35.
14
12
  */
15
13
  export declare class Process {
16
14
  /**
@@ -36,9 +36,7 @@ const process_controller_source_1 = require("./process_controller_source");
36
36
  const measurement_1 = require("../measurement");
37
37
  /**
38
38
  * Use to drive voltage for a process such as a heater, valve, Peltier device, etc.
39
- * WARNING: DO NOT USE. This API is for an as-yet unreleased product and firmware version.
40
- * It is subject to breaking changes without warning until further notice.
41
- * Requires at least Firmware 7.34.
39
+ * Requires at least Firmware 7.35.
42
40
  */
43
41
  class Process {
44
42
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"process.js","sourceRoot":"","sources":["../../../src/product/process.ts"],"names":[],"mappings":";AAAA,sDAAsD;AACtD,sDAAsD;;;;;;;;;;;;;;;;;;;;;;;;;;AAGtD,oDAAsC;AACtC,wCAAqC;AACrC,gDAA6C;AAC7C,0DAAsD;AACtD,8CAA+C;AAC/C,gDAA6C;AAE7C,2EAAsE;AACtE,gDAA6C;AAE7C;;;;;GAKG;AACH,MAAa,OAAO;IAClB;;OAEG;IACH,IAAW,UAAU;QACnB,OAAO,IAAI,CAAC,WAAW,CAAC;IAC1B,CAAC;IAGD;;OAEG;IACH,IAAW,aAAa;QACtB,OAAO,IAAI,CAAC,cAAc,CAAC;IAC7B,CAAC;IAKD;;OAEG;IACH,IAAW,QAAQ;QACjB,OAAO,IAAI,CAAC,SAAS,CAAC;IACxB,CAAC;IAGD;;OAEG;IACH,IAAW,OAAO;QAChB,OAA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SAAS,CACtC,2BAA2B,EAC3B,OAAO,EACP,OAAO,CAAC,uBAAuB,CAAC,CAAC;QACnC,OAAO,QAAQ,CAAC,QAAQ,EAAE,CAAC;IAC7B,CAAC;CACF;AA5WD,0BA4WC","sourcesContent":["// ==== THIS FILE IS GENERATED FROM A TEMPLATE ==== //\n// ============= DO NOT EDIT DIRECTLY ============= //\n\nimport { ProcessController } from './process_controller';\nimport * as gateway from '../gateway';\nimport { Axis } from '../ascii/axis';\nimport { Response } from '../ascii/response';\nimport { AxisSettings } from '../ascii/axis_settings';\nimport { AxisStorage } from '../ascii/storage';\nimport { Warnings } from '../ascii/warnings';\nimport { ProcessControllerMode } from './process_controller_mode';\nimport { ProcessControllerSource } from './process_controller_source';\nimport { Measurement } from '../measurement';\n\n/**\n * Use to drive voltage for a process such as a heater, valve, Peltier device, etc.\n * WARNING: DO NOT USE. This API is for an as-yet unreleased product and firmware version.\n * It is subject to breaking changes without warning until further notice.\n * Requires at least Firmware 7.34.\n */\nexport class Process {\n /**\n * Controller for this process.\n */\n public get controller(): ProcessController {\n return this._controller;\n }\n private _controller: ProcessController;\n\n /**\n * The process number identifies the process on the controller.\n */\n public get processNumber(): number {\n return this._processNumber;\n }\n private _processNumber: number;\n\n private _axis: Axis;\n\n /**\n * Settings and properties of this process.\n */\n public get settings(): AxisSettings {\n return this._settings;\n }\n private _settings: AxisSettings;\n\n /**\n * Key-value storage of this process.\n */\n public get storage(): AxisStorage {\n return this._storage;\n }\n private _storage: AxisStorage;\n\n /**\n * Warnings and faults of this process.\n */\n public get warnings(): Warnings {\n return this._warnings;\n }\n private _warnings: Warnings;\n\n constructor(controller: ProcessController, processNumber: number) {\n this._controller = controller;\n this._processNumber = processNumber;\n this._axis = new Axis(controller.device, processNumber);\n this._settings = new AxisSettings(this._axis);\n this._storage = new AxisStorage(this._axis);\n this._warnings = new Warnings(controller.device, processNumber);\n }\n\n /**\n * Sets the enabled state of the driver.\n * @param [enabled=true] If true (default) enables drive. If false disables.\n */\n public async enable(\n enabled: boolean = true\n ): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(enabled);\n\n await gateway.callAsync('process-controller/enable', request);\n }\n\n /**\n * Turns this process on. In manual mode, this supplies voltage; in controlled mode, it starts the control loop.\n * @param [duration=0] How long to leave the process on in milliseconds.\n */\n public async on(\n duration: number = 0\n ): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(true);\n request.setDuration(duration);\n\n await gateway.callAsync('process-controller/on', request);\n }\n\n /**\n * Turns this process off.\n */\n public async off(): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(false);\n\n await gateway.callAsync('process-controller/on', request);\n }\n\n /**\n * Sets the control mode of this process.\n * @param mode Mode to set this process to.\n */\n public async setMode(\n mode: ProcessControllerMode\n ): Promise<void> {\n const request = new gateway.DeviceSetSettingRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setSetting('process.control.mode');\n request.setValue(mode);\n\n await gateway.callAsync('device/set_setting', request);\n }\n\n /**\n * Gets the control mode of this process.\n * @returns Control mode.\n */\n public async getMode(): Promise<ProcessControllerMode> {\n const request = new gateway.DeviceGetSettingRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setSetting('process.control.mode');\n\n const response = await gateway.callAsync<gateway.DoubleResponse>(\n 'device/get_setting',\n request,\n gateway.DoubleResponse);\n return response.getValue();\n }\n\n /**\n * Gets the source used to control this process.\n * @returns The source providing feedback for this process.\n */\n public async getSource(): Promise<ProcessControllerSource> {\n const request = new gateway.AxisEmptyRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n\n const response = await gateway.callAsync<gateway.ProcessControllerSource>(\n 'process_controller/get_source',\n request,\n gateway.ProcessControllerSource);\n return ProcessControllerSource.fromProtobuf(response.toObject());\n }\n\n /**\n * Sets the source used to control this process.\n * @param source Sets the source that should provide feedback for this process.\n */\n public async setSource(\n source: ProcessControllerSource\n ): Promise<void> {\n const request = new gateway.SetProcessControllerSource();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setSource(ProcessControllerSource.toProtobuf(source));\n\n await gateway.callAsync('process_controller/set_source', request);\n }\n\n /**\n * Gets the current value of the source used to control this process.\n * @returns The current value of this process's controlling source.\n */\n public async getInput(): Promise<Measurement> {\n const request = new gateway.AxisEmptyRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n\n const response = await gateway.callAsync<gateway.Measurement>(\n 'process_controller/get_input',\n request,\n gateway.Measurement);\n return Measurement.fromProtobuf(response.toObject());\n }\n\n /**\n * Creates an H-bridge between this process and its neighbor. This method is only callable on axis 1 and 3.\n */\n public async bridge(): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(true);\n\n await gateway.callAsync('process_controller/bridge', request);\n }\n\n /**\n * Breaks the H-bridge between this process and its neighbor, allowing them to be independently controlled.\n * This method is only callable on axis 1 and 3.\n */\n public async unbridge(): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(false);\n\n await gateway.callAsync('process_controller/bridge', request);\n }\n\n /**\n * Detects if the given process is in bridging mode.\n * @returns Whether this process is bridged with its neighbor.\n */\n public async isBridge(): Promise<boolean> {\n const request = new gateway.AxisEmptyRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n\n const response = await gateway.callAsync<gateway.BoolResponse>(\n 'process_controller/is_bridge',\n request,\n gateway.BoolResponse);\n return response.getValue();\n }\n\n /**\n * Sends a generic ASCII command to this process' underlying axis.\n * For more information refer to: [ASCII Protocol Manual](https://www.zaber.com/protocol-manual#topic_commands).\n * @param command Command and its parameters.\n * @param [options.checkErrors=true] Controls whether to throw an exception when the device rejects the command.\n * @param [options.timeout=0] The timeout, in milliseconds, for a device to respond to the command.\n * Overrides the connection default request timeout.\n * @returns A response to the command.\n */\n public async genericCommand(\n command: string,\n options: Process.GenericCommandOptions = {}\n ): Promise<Response> {\n const {\n checkErrors = true,\n timeout = 0,\n } = options;\n const request = new gateway.GenericCommandRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setCommand(command);\n request.setCheckErrors(checkErrors);\n request.setTimeout(timeout);\n\n const response = await gateway.callAsync<gateway.GenericCommandResponse>(\n 'interface/generic_command',\n request,\n gateway.GenericCommandResponse);\n return Response.fromProtobuf(response.toObject());\n }\n\n /**\n * Sends a generic ASCII command to this process and expect multiple responses.\n * Responses are returned in order of arrival.\n * For more information refer to: [ASCII Protocol Manual](https://www.zaber.com/protocol-manual#topic_commands).\n * @param command Command and its parameters.\n * @param [options.checkErrors=true] Controls whether to throw an exception when a device rejects the command.\n * @param [options.timeout=0] The timeout, in milliseconds, for a device to respond to the command.\n * Overrides the connection default request timeout.\n * @returns All responses to the command.\n */\n public async genericCommandMultiResponse(\n command: string,\n options: Process.GenericCommandMultiResponseOptions = {}\n ): Promise<Response[]> {\n const {\n checkErrors = true,\n timeout = 0,\n } = options;\n const request = new gateway.GenericCommandRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setCommand(command);\n request.setCheckErrors(checkErrors);\n request.setTimeout(timeout);\n\n const response = await gateway.callAsync<gateway.GenericCommandResponseCollection>(\n 'interface/generic_command_multi_response',\n request,\n gateway.GenericCommandResponseCollection);\n return response.getResponsesList().map(a => Response.fromProtobuf(a.toObject()));\n }\n\n /**\n * Sends a generic ASCII command to this process without expecting a response and without adding a message ID\n * For more information refer to: [ASCII Protocol Manual](https://www.zaber.com/protocol-manual#topic_commands).\n * @param command Command and its parameters.\n */\n public async genericCommandNoResponse(\n command: string\n ): Promise<void> {\n const request = new gateway.GenericCommandRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setCommand(command);\n\n await gateway.callAsync('interface/generic_command_no_response', request);\n }\n\n /**\n * Returns a serialization of the current process state that can be saved and reapplied.\n * @returns A serialization of the current state of the process.\n */\n public async getState(): Promise<string> {\n const request = new gateway.AxisEmptyRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n\n const response = await gateway.callAsync<gateway.StringResponse>(\n 'device/get_state',\n request,\n gateway.StringResponse);\n return response.getValue();\n }\n\n /**\n * Applies a saved state to this process.\n * @param state The state object to apply to this process.\n */\n public async setState(\n state: string\n ): Promise<void> {\n const request = new gateway.SetStateRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setState(state);\n\n await gateway.callAsync('device/set_state', request);\n }\n\n /**\n * Checks if a state can be applied to this process.\n * This only covers exceptions that can be determined statically such as mismatches of ID or version,\n * the process of applying the state can still fail when running.\n * @param state The state object to check against.\n * @returns An explanation of why this state cannot be set to this process.\n */\n public async canSetState(\n state: string\n ): Promise<string> {\n const request = new gateway.CanSetStateRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setState(state);\n\n const response = await gateway.callAsync<gateway.CanSetStateAxisResponse>(\n 'device/can_set_axis_state',\n request,\n gateway.CanSetStateAxisResponse);\n return response.getError();\n }\n}\n\nnamespace Process {\n export interface GenericCommandOptions {\n checkErrors?: boolean;\n timeout?: number;\n }\n export interface GenericCommandMultiResponseOptions {\n checkErrors?: boolean;\n timeout?: number;\n }\n}\n"]}
1
+ {"version":3,"file":"process.js","sourceRoot":"","sources":["../../../src/product/process.ts"],"names":[],"mappings":";AAAA,sDAAsD;AACtD,sDAAsD;;;;;;;;;;;;;;;;;;;;;;;;;;AAGtD,oDAAsC;AACtC,wCAAqC;AACrC,gDAA6C;AAC7C,0DAAsD;AACtD,8CAA+C;AAC/C,gDAA6C;AAE7C,2EAAsE;AACtE,gDAA6C;AAE7C;;;GAGG;AACH,MAAa,OAAO;IAClB;;OAEG;IACH,IAAW,UAAU;QACnB,OAAO,IAAI,CAAC,WAAW,CAAC;IAC1B,CAAC;IAGD;;OAEG;IACH,IAAW,aAAa;QACtB,OAAO,IAAI,CAAC,cAAc,CAAC;IAC7B,CAAC;IAKD;;OAEG;IACH,IAAW,QAAQ;QACjB,OAAO,IAAI,CAAC,SAAS,CAAC;IACxB,CAAC;IAGD;;OAEG;IACH,IAAW,OAAO;QAChB,OAAO,IAAI,CAAC,QAAQ,CAAC;IACvB,CAAC;IAGD;;OAEG;IACH,IAAW,QAAQ;QACjB,OAAO,IAAI,CAAC,SAAS,CAAC;IACxB,CAAC;IAGD,YAAY,UAA6B,EAAE,aAAqB;QAC9D,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;QAC9B,IAAI,CAAC,cAAc,GAAG,aAAa,CAAC;QACpC,IAAI,CAAC,KAAK,GAAG,IAAI,WAAI,CAAC,UA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;IAC7B,CAAC;IAED;;;OAGG;IACI,KAAK,CAAC,QAAQ,CACnB,KAAa;QAEb,MAAM,OAAO,GAAG,IAAI,OAAO,CAAC,eAAe,EAAE,CAAC;QAC9C,OAAO,CAAC,cAAc,CAAC,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC;QACtE,OAAO,CAAC,SAAS,CAAC,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC;QACxD,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;QACpC,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;QAExB,MAAM,OAAO,CAAC,SAAS,CAAC,kBAAkB,EAAE,OAAO,CAAC,CAAC;IACvD,CAAC;IAED;;;;;;OAMG;IACI,KAAK,CAAC,WAAW,CACtB,KAAa;QAEb,MAAM,OAAO,GAAG,IAAI,OAAO,CAAC,kBAAkB,EAAE,CAAC;QACjD,OAAO,CAAC,cAAc,CAAC,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC;QACtE,OAAO,CAAC,SAAS,CAAC,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC;QACxD,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;QACpC,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;QAExB,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,SAAS,CACtC,2BAA2B,EAC3B,OAAO,EACP,OAAO,CAAC,uBAAuB,CAAC,CAAC;QACnC,OAAO,QAAQ,CAAC,QAAQ,EAAE,CAAC;IAC7B,CAAC;CACF;AA5WD,0BA4WC","sourcesContent":["// ==== THIS FILE IS GENERATED FROM A TEMPLATE ==== //\n// ============= DO NOT EDIT DIRECTLY ============= //\n\nimport { ProcessController } from './process_controller';\nimport * as gateway from '../gateway';\nimport { Axis } from '../ascii/axis';\nimport { Response } from '../ascii/response';\nimport { AxisSettings } from '../ascii/axis_settings';\nimport { AxisStorage } from '../ascii/storage';\nimport { Warnings } from '../ascii/warnings';\nimport { ProcessControllerMode } from './process_controller_mode';\nimport { ProcessControllerSource } from './process_controller_source';\nimport { Measurement } from '../measurement';\n\n/**\n * Use to drive voltage for a process such as a heater, valve, Peltier device, etc.\n * Requires at least Firmware 7.35.\n */\nexport class Process {\n /**\n * Controller for this process.\n */\n public get controller(): ProcessController {\n return this._controller;\n }\n private _controller: ProcessController;\n\n /**\n * The process number identifies the process on the controller.\n */\n public get processNumber(): number {\n return this._processNumber;\n }\n private _processNumber: number;\n\n private _axis: Axis;\n\n /**\n * Settings and properties of this process.\n */\n public get settings(): AxisSettings {\n return this._settings;\n }\n private _settings: AxisSettings;\n\n /**\n * Key-value storage of this process.\n */\n public get storage(): AxisStorage {\n return this._storage;\n }\n private _storage: AxisStorage;\n\n /**\n * Warnings and faults of this process.\n */\n public get warnings(): Warnings {\n return this._warnings;\n }\n private _warnings: Warnings;\n\n constructor(controller: ProcessController, processNumber: number) {\n this._controller = controller;\n this._processNumber = processNumber;\n this._axis = new Axis(controller.device, processNumber);\n this._settings = new AxisSettings(this._axis);\n this._storage = new AxisStorage(this._axis);\n this._warnings = new Warnings(controller.device, processNumber);\n }\n\n /**\n * Sets the enabled state of the driver.\n * @param [enabled=true] If true (default) enables drive. If false disables.\n */\n public async enable(\n enabled: boolean = true\n ): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(enabled);\n\n await gateway.callAsync('process-controller/enable', request);\n }\n\n /**\n * Turns this process on. In manual mode, this supplies voltage; in controlled mode, it starts the control loop.\n * @param [duration=0] How long to leave the process on in milliseconds.\n */\n public async on(\n duration: number = 0\n ): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(true);\n request.setDuration(duration);\n\n await gateway.callAsync('process-controller/on', request);\n }\n\n /**\n * Turns this process off.\n */\n public async off(): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(false);\n\n await gateway.callAsync('process-controller/on', request);\n }\n\n /**\n * Sets the control mode of this process.\n * @param mode Mode to set this process to.\n */\n public async setMode(\n mode: ProcessControllerMode\n ): Promise<void> {\n const request = new gateway.DeviceSetSettingRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setSetting('process.control.mode');\n request.setValue(mode);\n\n await gateway.callAsync('device/set_setting', request);\n }\n\n /**\n * Gets the control mode of this process.\n * @returns Control mode.\n */\n public async getMode(): Promise<ProcessControllerMode> {\n const request = new gateway.DeviceGetSettingRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setSetting('process.control.mode');\n\n const response = await gateway.callAsync<gateway.DoubleResponse>(\n 'device/get_setting',\n request,\n gateway.DoubleResponse);\n return response.getValue();\n }\n\n /**\n * Gets the source used to control this process.\n * @returns The source providing feedback for this process.\n */\n public async getSource(): Promise<ProcessControllerSource> {\n const request = new gateway.AxisEmptyRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n\n const response = await gateway.callAsync<gateway.ProcessControllerSource>(\n 'process_controller/get_source',\n request,\n gateway.ProcessControllerSource);\n return ProcessControllerSource.fromProtobuf(response.toObject());\n }\n\n /**\n * Sets the source used to control this process.\n * @param source Sets the source that should provide feedback for this process.\n */\n public async setSource(\n source: ProcessControllerSource\n ): Promise<void> {\n const request = new gateway.SetProcessControllerSource();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setSource(ProcessControllerSource.toProtobuf(source));\n\n await gateway.callAsync('process_controller/set_source', request);\n }\n\n /**\n * Gets the current value of the source used to control this process.\n * @returns The current value of this process's controlling source.\n */\n public async getInput(): Promise<Measurement> {\n const request = new gateway.AxisEmptyRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n\n const response = await gateway.callAsync<gateway.Measurement>(\n 'process_controller/get_input',\n request,\n gateway.Measurement);\n return Measurement.fromProtobuf(response.toObject());\n }\n\n /**\n * Creates an H-bridge between this process and its neighbor. This method is only callable on axis 1 and 3.\n */\n public async bridge(): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(true);\n\n await gateway.callAsync('process_controller/bridge', request);\n }\n\n /**\n * Breaks the H-bridge between this process and its neighbor, allowing them to be independently controlled.\n * This method is only callable on axis 1 and 3.\n */\n public async unbridge(): Promise<void> {\n const request = new gateway.ProcessOn();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setOn(false);\n\n await gateway.callAsync('process_controller/bridge', request);\n }\n\n /**\n * Detects if the given process is in bridging mode.\n * @returns Whether this process is bridged with its neighbor.\n */\n public async isBridge(): Promise<boolean> {\n const request = new gateway.AxisEmptyRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n\n const response = await gateway.callAsync<gateway.BoolResponse>(\n 'process_controller/is_bridge',\n request,\n gateway.BoolResponse);\n return response.getValue();\n }\n\n /**\n * Sends a generic ASCII command to this process' underlying axis.\n * For more information refer to: [ASCII Protocol Manual](https://www.zaber.com/protocol-manual#topic_commands).\n * @param command Command and its parameters.\n * @param [options.checkErrors=true] Controls whether to throw an exception when the device rejects the command.\n * @param [options.timeout=0] The timeout, in milliseconds, for a device to respond to the command.\n * Overrides the connection default request timeout.\n * @returns A response to the command.\n */\n public async genericCommand(\n command: string,\n options: Process.GenericCommandOptions = {}\n ): Promise<Response> {\n const {\n checkErrors = true,\n timeout = 0,\n } = options;\n const request = new gateway.GenericCommandRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setCommand(command);\n request.setCheckErrors(checkErrors);\n request.setTimeout(timeout);\n\n const response = await gateway.callAsync<gateway.GenericCommandResponse>(\n 'interface/generic_command',\n request,\n gateway.GenericCommandResponse);\n return Response.fromProtobuf(response.toObject());\n }\n\n /**\n * Sends a generic ASCII command to this process and expect multiple responses.\n * Responses are returned in order of arrival.\n * For more information refer to: [ASCII Protocol Manual](https://www.zaber.com/protocol-manual#topic_commands).\n * @param command Command and its parameters.\n * @param [options.checkErrors=true] Controls whether to throw an exception when a device rejects the command.\n * @param [options.timeout=0] The timeout, in milliseconds, for a device to respond to the command.\n * Overrides the connection default request timeout.\n * @returns All responses to the command.\n */\n public async genericCommandMultiResponse(\n command: string,\n options: Process.GenericCommandMultiResponseOptions = {}\n ): Promise<Response[]> {\n const {\n checkErrors = true,\n timeout = 0,\n } = options;\n const request = new gateway.GenericCommandRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setCommand(command);\n request.setCheckErrors(checkErrors);\n request.setTimeout(timeout);\n\n const response = await gateway.callAsync<gateway.GenericCommandResponseCollection>(\n 'interface/generic_command_multi_response',\n request,\n gateway.GenericCommandResponseCollection);\n return response.getResponsesList().map(a => Response.fromProtobuf(a.toObject()));\n }\n\n /**\n * Sends a generic ASCII command to this process without expecting a response and without adding a message ID\n * For more information refer to: [ASCII Protocol Manual](https://www.zaber.com/protocol-manual#topic_commands).\n * @param command Command and its parameters.\n */\n public async genericCommandNoResponse(\n command: string\n ): Promise<void> {\n const request = new gateway.GenericCommandRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setCommand(command);\n\n await gateway.callAsync('interface/generic_command_no_response', request);\n }\n\n /**\n * Returns a serialization of the current process state that can be saved and reapplied.\n * @returns A serialization of the current state of the process.\n */\n public async getState(): Promise<string> {\n const request = new gateway.AxisEmptyRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n\n const response = await gateway.callAsync<gateway.StringResponse>(\n 'device/get_state',\n request,\n gateway.StringResponse);\n return response.getValue();\n }\n\n /**\n * Applies a saved state to this process.\n * @param state The state object to apply to this process.\n */\n public async setState(\n state: string\n ): Promise<void> {\n const request = new gateway.SetStateRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setState(state);\n\n await gateway.callAsync('device/set_state', request);\n }\n\n /**\n * Checks if a state can be applied to this process.\n * This only covers exceptions that can be determined statically such as mismatches of ID or version,\n * the process of applying the state can still fail when running.\n * @param state The state object to check against.\n * @returns An explanation of why this state cannot be set to this process.\n */\n public async canSetState(\n state: string\n ): Promise<string> {\n const request = new gateway.CanSetStateRequest();\n request.setInterfaceId(this.controller.device.connection.interfaceId);\n request.setDevice(this.controller.device.deviceAddress);\n request.setAxis(this.processNumber);\n request.setState(state);\n\n const response = await gateway.callAsync<gateway.CanSetStateAxisResponse>(\n 'device/can_set_axis_state',\n request,\n gateway.CanSetStateAxisResponse);\n return response.getError();\n }\n}\n\nnamespace Process {\n export interface GenericCommandOptions {\n checkErrors?: boolean;\n timeout?: number;\n }\n export interface GenericCommandMultiResponseOptions {\n checkErrors?: boolean;\n timeout?: number;\n }\n}\n"]}
@@ -3,9 +3,7 @@ import { Device } from '../ascii/device';
3
3
  import { Process } from './process';
4
4
  /**
5
5
  * Use to manage a process controller.
6
- * WARNING: DO NOT USE. This API is for an as-yet unreleased product and firmware version.
7
- * It is subject to breaking changes without warning until further notice.
8
- * Requires at least Firmware 7.34.
6
+ * Requires at least Firmware 7.35.
9
7
  */
10
8
  export declare class ProcessController {
11
9
  /**
@@ -30,9 +30,7 @@ const gateway = __importStar(require("../gateway"));
30
30
  const process_1 = require("./process");
31
31
  /**
32
32
  * Use to manage a process controller.
33
- * WARNING: DO NOT USE. This API is for an as-yet unreleased product and firmware version.
34
- * It is subject to breaking changes without warning until further notice.
35
- * Requires at least Firmware 7.34.
33
+ * Requires at least Firmware 7.35.
36
34
  */
37
35
  class ProcessController {
38
36
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"process_controller.js","sourceRoot":"","sources":["../../../src/product/process_controller.ts"],"names":[],"mappings":";AAAA,sDAAsD;AACtD,sDAAsD;;;;;;;;;;;;;;;;;;;;;;;;;;AAItD,oDAAsC;AACtC,uCAAoC;AAEpC;;;;;GAKG;AACH,MAAa,iBAAiB;IAC5B;;OAEG;IACH,IAAW,MAAM;QACf,OAAO,IAAI,CAAC,OAAO,CAAC;IACtB,CAAC;IAGD;;;OAGG;IACH,YAAY,MAAc;QACxB,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC;QACtB,IAAI,CAAC,0BAA0B,EAAE,CAAC;IACpC,CAAC;IAED;;;;;OAKG;IACI,MAAM,CAAC,KAAK,CAAC,MAAM,CACxB,UAAsB,EACtB,WAAoB,IAAI;QAExB,MAAM,OAAO,GAAG,IAAI,OAAO,CAAC,mBAAmB,EAAE,CAAC;QAClD,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC,mBAAmB,CAAC,UAAU,CAAC,kBAAkB,CAAC,CAAC;QAC3E,OAAO,CAAC,cAAc,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC;QAC/C,OAAO,CAAC,kBAAkB,CAAC,QAAQ,CAAC,CAAC;QAErC,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,SAAS,CACtC,eAAe,EACf,OAAO,EACP,OAAO,CAAC,oBAAoB,CAAC,CAAC;QAChC,OAAO,QAAQ,CAAC,cAAc,EAAE,CAAC,GAAG,CAAC,aAAa,CAAC,EAAE,CAAC,IAAI,iBAAiB,CAAC,UAAU,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;IACpH,CAAC;IAED;;;;;OAKG;IACI,UAAU,CACf,aAAqB;QAErB,IAAI,aAAa,IAAI,CAAC,EAAE;YACtB,MAAM,IAAI,SAAS,CAAC,+CAA+C,CAAC,CAAC;SACtE;QACD,OAAO,IAAI,iBAAO,CAAC,IAAI,EAAE,aAAa,CAAC,CAAC;IAC1C,CAAC;IAED;;OAEG;IACK,0BAA0B;QAChC,MAAM,OAAO,GAAG,IAAI,OAAO,CAAC,kBAAkB,EAAE,CAAC;QACjD,OAAO,CAAC,cAAc,CAAC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC;QAC3D,OAAO,CAAC,SAAS,CAAC,IAAI,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC;QAE7C,OAAO,CAAC,QAAQ,CAAC,2BAA2B,EAAE,OAAO,CAAC,CAAC;IACzD,CAAC;CACF;AAjED,8CAiEC","sourcesContent":["// ==== THIS FILE IS GENERATED FROM A TEMPLATE ==== //\n// ============= DO NOT EDIT DIRECTLY ============= //\n\nimport { Connection } from '../ascii/connection';\nimport { Device } from '../ascii/device';\nimport * as gateway from '../gateway';\nimport { Process } from './process';\n\n/**\n * Use to manage a process controller.\n * WARNING: DO NOT USE. This API is for an as-yet unreleased product and firmware version.\n * It is subject to breaking changes without warning until further notice.\n * Requires at least Firmware 7.34.\n */\nexport class ProcessController {\n /**\n * The base device of this process controller.\n */\n public get device(): Device {\n return this._device;\n }\n private _device: Device;\n\n /**\n * Creates instance of `ProcessController` of the given device.\n * If the device is identified, this constructor will ensure it is a process controller.\n */\n constructor(device: Device) {\n this._device = device;\n this._verifyIsProcessController();\n }\n\n /**\n * Detects the process controllers on the connection.\n * @param connection The connection to detect process controllers on.\n * @param [identify=true] If the Process Controllers should be identified upon detection.\n * @returns A list of all `ProcessController`s on the connection.\n */\n public static async detect(\n connection: Connection,\n identify: boolean = true\n ): Promise<ProcessController[]> {\n const request = new gateway.DeviceDetectRequest();\n request.setType(gateway.DeviceDetectRequest.DeviceType.PROCESS_CONTROLLER);\n request.setInterfaceId(connection.interfaceId);\n request.setIdentifyDevices(identify);\n\n const response = await gateway.callAsync<gateway.DeviceDetectResponse>(\n 'device/detect',\n request,\n gateway.DeviceDetectResponse);\n return response.getDevicesList().map(deviceAddress => new ProcessController(connection.getDevice(deviceAddress)));\n }\n\n /**\n * Gets an Process class instance which allows you to control a particular voltage source.\n * Axes are numbered from 1.\n * @param processNumber Number of process to control.\n * @returns Process instance.\n */\n public getProcess(\n processNumber: number\n ): Process {\n if (processNumber <= 0) {\n throw new TypeError('Invalid value; processes are numbered from 1.');\n }\n return new Process(this, processNumber);\n }\n\n /**\n * Checks if this is a process controller or some other type of device and throws a detect error if it is not.\n */\n private _verifyIsProcessController(): void {\n const request = new gateway.DeviceEmptyRequest();\n request.setInterfaceId(this.device.connection.interfaceId);\n request.setDevice(this.device.deviceAddress);\n\n gateway.callSync('process_controller/verify', request);\n }\n}\n\nnamespace ProcessController {\n}\n"]}
1
+ {"version":3,"file":"process_controller.js","sourceRoot":"","sources":["../../../src/product/process_controller.ts"],"names":[],"mappings":";AAAA,sDAAsD;AACtD,sDAAsD;;;;;;;;;;;;;;;;;;;;;;;;;;AAItD,oDAAsC;AACtC,uCAAoC;AAEpC;;;GAGG;AACH,MAAa,iBAAiB;IAC5B;;OAEG;IACH,IAAW,MAAM;QACf,OAAO,IAAI,CAAC,OAAO,CAAC;IACtB,CAAC;IAGD;;;OAGG;IACH,YAAY,MAAc;QACxB,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CAAC;CACF;AAjED,8CAiEC","sourcesContent":["// ==== THIS FILE IS GENERATED FROM A TEMPLATE ==== //\n// ============= DO NOT EDIT DIRECTLY ============= //\n\nimport { Connection } from '../ascii/connection';\nimport { Device } from '../ascii/device';\nimport * as gateway from '../gateway';\nimport { Process } from './process';\n\n/**\n * Use to manage a process controller.\n * Requires at least Firmware 7.35.\n */\nexport class ProcessController {\n /**\n * The base device of this process controller.\n */\n public get device(): Device {\n return this._device;\n }\n private _device: Device;\n\n /**\n * Creates instance of `ProcessController` of the given device.\n * If the device is identified, this constructor will ensure it is a process controller.\n */\n constructor(device: Device) {\n this._device = device;\n this._verifyIsProcessController();\n }\n\n /**\n * Detects the process controllers on the connection.\n * @param connection The connection to detect process controllers on.\n * @param [identify=true] If the Process Controllers should be identified upon detection.\n * @returns A list of all `ProcessController`s on the connection.\n */\n public static async detect(\n connection: Connection,\n identify: boolean = true\n ): Promise<ProcessController[]> {\n const request = new gateway.DeviceDetectRequest();\n request.setType(gateway.DeviceDetectRequest.DeviceType.PROCESS_CONTROLLER);\n request.setInterfaceId(connection.interfaceId);\n request.setIdentifyDevices(identify);\n\n const response = await gateway.callAsync<gateway.DeviceDetectResponse>(\n 'device/detect',\n request,\n gateway.DeviceDetectResponse);\n return response.getDevicesList().map(deviceAddress => new ProcessController(connection.getDevice(deviceAddress)));\n }\n\n /**\n * Gets an Process class instance which allows you to control a particular voltage source.\n * Axes are numbered from 1.\n * @param processNumber Number of process to control.\n * @returns Process instance.\n */\n public getProcess(\n processNumber: number\n ): Process {\n if (processNumber <= 0) {\n throw new TypeError('Invalid value; processes are numbered from 1.');\n }\n return new Process(this, processNumber);\n }\n\n /**\n * Checks if this is a process controller or some other type of device and throws a detect error if it is not.\n */\n private _verifyIsProcessController(): void {\n const request = new gateway.DeviceEmptyRequest();\n request.setInterfaceId(this.device.connection.interfaceId);\n request.setDevice(this.device.deviceAddress);\n\n gateway.callSync('process_controller/verify', request);\n }\n}\n\nnamespace ProcessController {\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zaber/motion",
3
- "version": "4.5.0",
3
+ "version": "4.5.1",
4
4
  "description": "Zaber Motion Library is a multi-platform library used to operate Zaber devices.",
5
5
  "keywords": [],
6
6
  "main": "dist/lib/index.js",