motion-master-client 0.0.246 → 0.0.248
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/package.json +1 -1
- package/src/index.d.ts +2 -0
- package/src/index.js +2 -0
- package/src/index.js.map +1 -1
- package/src/lib/config-file.js +1 -1
- package/src/lib/config-file.js.map +1 -1
- package/src/lib/motion-master-req-res-client.d.ts +186 -22
- package/src/lib/motion-master-req-res-client.js +231 -45
- package/src/lib/motion-master-req-res-client.js.map +1 -1
- package/src/lib/os-command.d.ts +58 -0
- package/src/lib/os-command.js +10 -0
- package/src/lib/os-command.js.map +1 -1
- package/src/lib/parameter.d.ts +1 -1
- package/src/lib/parameter.js +3 -3
- package/src/lib/parameter.js.map +1 -1
- package/src/lib/smm-od-v1.json +1851 -0
- package/src/lib/smm-od-v2.json +2051 -0
- package/src/lib/smm-od.d.ts +41 -0
- package/src/lib/smm-od.js +6 -0
- package/src/lib/smm-od.js.map +1 -0
- package/src/lib/smm.d.ts +200 -48
- package/src/lib/smm.js +275 -95
- package/src/lib/smm.js.map +1 -1
- package/src/lib/util.d.ts +257 -6
- package/src/lib/util.js +328 -4
- package/src/lib/util.js.map +1 -1
package/package.json
CHANGED
package/src/index.d.ts
CHANGED
|
@@ -36,6 +36,8 @@ export * from './lib/parameter';
|
|
|
36
36
|
export * from './lib/product';
|
|
37
37
|
export * from './lib/request-status-resolver';
|
|
38
38
|
export * from './lib/sii';
|
|
39
|
+
export * from './lib/smm-od';
|
|
40
|
+
export * from './lib/smm';
|
|
39
41
|
export * from './lib/system-log-line';
|
|
40
42
|
export * from './lib/types';
|
|
41
43
|
export * from './lib/units';
|
package/src/index.js
CHANGED
|
@@ -39,6 +39,8 @@ tslib_1.__exportStar(require("./lib/parameter"), exports);
|
|
|
39
39
|
tslib_1.__exportStar(require("./lib/product"), exports);
|
|
40
40
|
tslib_1.__exportStar(require("./lib/request-status-resolver"), exports);
|
|
41
41
|
tslib_1.__exportStar(require("./lib/sii"), exports);
|
|
42
|
+
tslib_1.__exportStar(require("./lib/smm-od"), exports);
|
|
43
|
+
tslib_1.__exportStar(require("./lib/smm"), exports);
|
|
42
44
|
tslib_1.__exportStar(require("./lib/system-log-line"), exports);
|
|
43
45
|
tslib_1.__exportStar(require("./lib/types"), exports);
|
|
44
46
|
tslib_1.__exportStar(require("./lib/units"), exports);
|
package/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../libs/motion-master-client/src/index.ts"],"names":[],"mappings":";;;AAAA,uDAA6B;AAC7B,4DAAkC;AAClC,gEAAsC;AACtC,uDAA6B;AAC7B,iEAAuC;AACvC,gEAAsC;AACtC,wDAA8B;AAC9B,yDAA+B;AAC/B,yDAA+B;AAC/B,sDAA4B;AAC5B,yDAA+B;AAC/B,qEAA2C;AAC3C,uDAA6B;AAC7B,4EAAkD;AAClD,gEAAsC;AACtC,0DAAgC;AAChC,uDAA6B;AAC7B,kEAAwC;AACxC,iEAAuC;AACvC,gEAAsC;AACtC,qEAA2C;AAC3C,6EAAmD;AACnD,6EAAmD;AACnD,iFAAuD;AACvD,oFAA0D;AAC1D,6EAAmD;AACnD,6EAAmD;AACnD,iFAAuD;AACvD,oFAA0D;AAC1D,qEAA2C;AAC3C,uDAA6B;AAC7B,0DAAgC;AAChC,wDAA8B;AAC9B,2DAAiC;AACjC,0DAAgC;AAChC,wDAA8B;AAC9B,wEAA8C;AAC9C,oDAA0B;AAC1B,gEAAsC;AACtC,sDAA4B;AAC5B,sDAA4B;AAC5B,8DAAoC;AACpC,qDAA2B;AAC3B,kFAAwD"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../libs/motion-master-client/src/index.ts"],"names":[],"mappings":";;;AAAA,uDAA6B;AAC7B,4DAAkC;AAClC,gEAAsC;AACtC,uDAA6B;AAC7B,iEAAuC;AACvC,gEAAsC;AACtC,wDAA8B;AAC9B,yDAA+B;AAC/B,yDAA+B;AAC/B,sDAA4B;AAC5B,yDAA+B;AAC/B,qEAA2C;AAC3C,uDAA6B;AAC7B,4EAAkD;AAClD,gEAAsC;AACtC,0DAAgC;AAChC,uDAA6B;AAC7B,kEAAwC;AACxC,iEAAuC;AACvC,gEAAsC;AACtC,qEAA2C;AAC3C,6EAAmD;AACnD,6EAAmD;AACnD,iFAAuD;AACvD,oFAA0D;AAC1D,6EAAmD;AACnD,6EAAmD;AACnD,iFAAuD;AACvD,oFAA0D;AAC1D,qEAA2C;AAC3C,uDAA6B;AAC7B,0DAAgC;AAChC,wDAA8B;AAC9B,2DAAiC;AACjC,0DAAgC;AAChC,wDAA8B;AAC9B,wEAA8C;AAC9C,oDAA0B;AAC1B,uDAA6B;AAC7B,oDAA0B;AAC1B,gEAAsC;AACtC,sDAA4B;AAC5B,sDAA4B;AAC5B,8DAAoC;AACpC,qDAA2B;AAC3B,kFAAwD"}
|
package/src/lib/config-file.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-file.js","sourceRoot":"","sources":["../../../../../libs/motion-master-client/src/lib/config-file.ts"],"names":[],"mappings":";;;AAAA,yCAA+C;AAC/C,
|
|
1
|
+
{"version":3,"file":"config-file.js","sourceRoot":"","sources":["../../../../../libs/motion-master-client/src/lib/config-file.ts"],"names":[],"mappings":"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"}
|
|
@@ -4,15 +4,14 @@ import { Device } from './device';
|
|
|
4
4
|
import { DeviceParameter } from './device-parameter';
|
|
5
5
|
import { HardwareDescription, StackInfo } from './hardware-description';
|
|
6
6
|
import { MotionMasterReqResSocket } from './motion-master-req-res-socket';
|
|
7
|
-
import {
|
|
7
|
+
import { UIFeaturesConfig } from './parameter';
|
|
8
8
|
import { SystemLogLine } from './system-log-line';
|
|
9
9
|
import { MotionMasterMessage, ParameterValueType, ParameterTypeValue, DeviceParameterValuesStatus, ParameterTypeValueKey, DeviceRefObj, DeviceRef, FullAutoTuningStatus, SystemVersionStatus, DeviceInfoStatus, DeviceParameterInfoStatus, GetDeviceParameterInfoRequest, GetDeviceParameterValuesRequest, GetMultiDeviceParameterValuesRequest, MultiDeviceParameterValuesStatus, SetDeviceParameterValuesRequest, SetMultiDeviceParameterValuesRequest, GetDeviceFileListRequest, DeviceFileListStatus, GetDeviceFileRequest, DeviceFileStatus, SetDeviceFileRequest, DeleteDeviceFileRequest, ResetDeviceFaultRequest, DeviceFaultResetStatus, StopDeviceRequest, DeviceStopStatus, StartDeviceFirmwareInstallationRequest, DeviceFirmwareInstallationStatus, GetDeviceLogRequest, DeviceLogStatus, StartCoggingTorqueRecordingRequest, CoggingTorqueRecordingStatus, GetCoggingTorqueDataRequest, CoggingTorqueDataStatus, StartOffsetDetectionRequest, OffsetDetectionStatus, StartPlantModelIdentificationRequest, PlantIdentificationStatus, ComputeAutoTuningGainsRequest, AutoTuningStatus, SetMotionControllerParametersRequest, MotionControllerStatus, EnableMotionControllerRequest, SetSignalGeneratorParametersRequest, SignalGeneratorStatus, StopSignalGeneratorRequest, StartMonitoringDeviceParameterValuesRequest, MonitoringParameterValuesStatus, StopMonitoringDeviceParameterValuesRequest, GetEthercatNetworkStateRequest, EthercatNetworkStateStatus, SetEthercatNetworkStateRequest, StartNarrowAngleCalibrationRequest, NarrowAngleCalibrationStatus, SetSystemClientTimeoutRequest, StartSystemIdentificationRequest, SystemIdentificationStatus, CirculoEncoderMagnetDistanceStatus, StartCirculoEncoderNarrowAngleCalibrationProcedureRequest, CirculoEncoderNarrowAngleCalibrationProcedureStatus, GetDeviceCiA402StateRequest, DeviceCiA402StateStatus, SetDeviceCiA402StateRequest, SystemLogStatus, StartDeviceSiiRestoreRequest, DeviceSiiRestoreStatus, StartOpenLoopFieldControlRequest, OpenLoopFieldControlStatus, ComputeFullAutoTuningGainsRequest, StartFullAutoTuningRequest, StopFullAutoTuningRequest, StartCirculoEncoderConfigurationRequest, CirculoEncoderConfigurationStatus, StopCirculoEncoderNarrowAngleCalibrationProcedureRequest, StartOsCommandRequest, OsCommandStatus, RestoreDefaultParametersType, DeviceParameterAddressValue, DeviceParameterIds, DeviceParameterInfo, RequestStatusMessage } from './types';
|
|
10
10
|
import { Cia402State, ModesOfOperation } from './cia402';
|
|
11
|
-
import { EncoderRegisterCommunicationOsCommandResponse, MotorPhaseOrderDetectionOsCommandResponse, OpenPhaseDetectionOsCommandResponse, OsCommandMode, OsCommandResponse, PhaseResistanceMeasurementOsCommandResponse, PhaseInductanceMeasurementOsCommandResponse, PolePairDetectionOsCommandResponse, CommutationOffsetMeasurementOsCommandResponse, IcMuCalibrationModeOsCommandResponse, OpenLoopFieldModeOsCommandResponse, HrdStreamingOsCommandResponse, TorqueConstantMeasurementOsCommandResponse, SkippedCyclesCounterOsCommandResponse, IgnoreBissStatusBitsOsCommandResponse, SystemIdentificationOsCommandResponse, KublerEncoderCommandOsCommandResponse, UseInternalEncoderVelocityOsCommandResponse, KublerEncoderRegisterCommunicationOsCommandResponse, SmmAcyclicHandlerOsCommandResponse, HrdStreamingOsCommandAction, HrdStreamingOsCommandDataIndex } from './os-command';
|
|
11
|
+
import { EncoderRegisterCommunicationOsCommandResponse, MotorPhaseOrderDetectionOsCommandResponse, OpenPhaseDetectionOsCommandResponse, OsCommandMode, OsCommandResponse, PhaseResistanceMeasurementOsCommandResponse, PhaseInductanceMeasurementOsCommandResponse, PolePairDetectionOsCommandResponse, CommutationOffsetMeasurementOsCommandResponse, IcMuCalibrationModeOsCommandResponse, OpenLoopFieldModeOsCommandResponse, HrdStreamingOsCommandResponse, TorqueConstantMeasurementOsCommandResponse, SkippedCyclesCounterOsCommandResponse, IgnoreBissStatusBitsOsCommandResponse, SystemIdentificationOsCommandResponse, KublerEncoderCommandOsCommandResponse, UseInternalEncoderVelocityOsCommandResponse, KublerEncoderRegisterCommunicationOsCommandResponse, SmmAcyclicHandlerOsCommandResponse, HrdStreamingOsCommandAction, HrdStreamingOsCommandDataIndex, SmmAcyclicHandlerLoadParametersForVerificationOsCommandResponse } from './os-command';
|
|
12
12
|
import { IntegroVariant } from './integro-variant';
|
|
13
13
|
import { ConfigParameter } from './config-file';
|
|
14
14
|
import { MotionMasterClientIndexedDB } from './mmcidb';
|
|
15
|
-
import { SmmVerificationGroupOrdinal } from './smm';
|
|
16
15
|
import { DataType } from 'python-struct';
|
|
17
16
|
/**
|
|
18
17
|
* This class contains methods for making requests to Motion Master using the injected request/response socket.
|
|
@@ -1110,7 +1109,7 @@ export declare class MotionMasterReqResClient {
|
|
|
1110
1109
|
* @param deviceRef The reference to the device on which the command will be executed.
|
|
1111
1110
|
* @param command The command to be executed, represented as a Uint8Array.
|
|
1112
1111
|
* @param commandTimeout The maximum time allowed for the command to complete.
|
|
1113
|
-
* @param responsePollingInterval The interval (in milliseconds) for polling the command response.
|
|
1112
|
+
* @param responsePollingInterval The interval (in milliseconds) for polling the command response.
|
|
1114
1113
|
* @param osCommandMode Specifies whether the next OS command should run immediately after the current one or abort the current command. Sets the OS Command Mode. Defaults to false.
|
|
1115
1114
|
* @param fsBufferContent If true, the content of the fs-buffer will be read and assigned to the `fsBuffer` property of {@link OsCommandResponse}. If a Uint8Array is provided, the content will be written to the fs-buffer file. If undefined, only the OS command will be executed, and its response will be read and parsed.
|
|
1116
1115
|
* @returns An observable of type T, which extends {@link OsCommandResponse}, representing the result of the command execution.
|
|
@@ -1269,8 +1268,8 @@ export declare class MotionMasterReqResClient {
|
|
|
1269
1268
|
* @param deviceRef - The reference to the device to which the command will be sent.
|
|
1270
1269
|
* @param index - The index of the SMM parameter to read.
|
|
1271
1270
|
* @param subindex - The subindex of the SMM parameter to read. Defaults to 0.
|
|
1272
|
-
* @param commandTimeout - The timeout for the command in milliseconds.
|
|
1273
|
-
* @param responsePollingInterval - The interval between polling attempts for a response in milliseconds.
|
|
1271
|
+
* @param commandTimeout - The timeout for the command in milliseconds.
|
|
1272
|
+
* @param responsePollingInterval - The interval between polling attempts for a response in milliseconds.
|
|
1274
1273
|
*
|
|
1275
1274
|
* @returns An observable that emits the response from the command once it is received.
|
|
1276
1275
|
*/
|
|
@@ -1321,7 +1320,7 @@ export declare class MotionMasterReqResClient {
|
|
|
1321
1320
|
*/
|
|
1322
1321
|
readSmmParameterArrayValue(deviceRef: DeviceRef, index: number, subindex?: number): Observable<number[]>;
|
|
1323
1322
|
/**
|
|
1324
|
-
* Reads the SMM firmware version from a device.
|
|
1323
|
+
* Reads the SMM firmware version from a device as an array of bytes.
|
|
1325
1324
|
*
|
|
1326
1325
|
* This method reads the firmware version (MCU Software Version 0x0001:00) of the device as an array of numbers.
|
|
1327
1326
|
* The first byte represents the minor version, and the second byte represents the major version.
|
|
@@ -1331,6 +1330,32 @@ export declare class MotionMasterReqResClient {
|
|
|
1331
1330
|
* @returns An observable that emits an array of numbers, representing the byte values of the firmware version.
|
|
1332
1331
|
*/
|
|
1333
1332
|
readSmmFirmareVersion(deviceRef: DeviceRef): Observable<number[]>;
|
|
1333
|
+
/**
|
|
1334
|
+
* Reads the SMM firmware version from a device as a number.
|
|
1335
|
+
*
|
|
1336
|
+
* This function retrieves a specific parameter from the device's SMM memory
|
|
1337
|
+
* and interprets the result as a 16-bit version number.
|
|
1338
|
+
*
|
|
1339
|
+
* @param deviceRef - A reference to the target device.
|
|
1340
|
+
* @returns An `Observable<number>` emitting the firmware version, represented as an integer.
|
|
1341
|
+
*/
|
|
1342
|
+
readSmmFirmareVersionAsNumber(deviceRef: DeviceRef): Observable<number>;
|
|
1343
|
+
/**
|
|
1344
|
+
* Resolves the SMM parameter structure version for the specified device based on its firmware version.
|
|
1345
|
+
*
|
|
1346
|
+
* @param deviceRef - The reference to the target device.
|
|
1347
|
+
*
|
|
1348
|
+
* @returns An Observable that emits the appropriate SMM parameter structure version:
|
|
1349
|
+
* - 0x0041 for firmware versions below 2.3 (0x0203).
|
|
1350
|
+
* - 0x0203 for firmware versions 2.3 (0x0203) and above.
|
|
1351
|
+
*
|
|
1352
|
+
* @remarks
|
|
1353
|
+
* - The function first reads the firmware version of the device.
|
|
1354
|
+
* - Based on the firmware version, it returns the corresponding parameter structure version:
|
|
1355
|
+
* - If the firmware version is less than 0x0203, the parameter structure version is 0x0041.
|
|
1356
|
+
* - If the firmware version is 0x0203 or greater, the parameter structure version is 0x0203.
|
|
1357
|
+
*/
|
|
1358
|
+
resolveSmmParameterStructureVersion(deviceRef: DeviceRef): Observable<number>;
|
|
1334
1359
|
/**
|
|
1335
1360
|
* Reads the SMM serial number from a device.
|
|
1336
1361
|
*
|
|
@@ -1387,13 +1412,15 @@ export declare class MotionMasterReqResClient {
|
|
|
1387
1412
|
* @param deviceRef - The reference to the device to which the login command will be sent.
|
|
1388
1413
|
* @param username - The optional username used for logging in to the SMM. If not provided, it will be treated as an empty string.
|
|
1389
1414
|
* @param password - The password used for logging in to the SMM.
|
|
1415
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1416
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1390
1417
|
*
|
|
1391
1418
|
* @returns An observable that emits a boolean value indicating whether the login attempt succeeded.
|
|
1392
1419
|
*
|
|
1393
1420
|
* @remarks
|
|
1394
1421
|
* If the device is already logged in, the next login attempt will fail unless the user logs out first.
|
|
1395
1422
|
*/
|
|
1396
|
-
loginToSmmForParameterDownload(deviceRef: DeviceRef, username: string, password: string): Observable<boolean>;
|
|
1423
|
+
loginToSmmForParameterDownload(deviceRef: DeviceRef, username: string, password: string, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1397
1424
|
/**
|
|
1398
1425
|
* Logs into the SMM for software update with the provided credentials.
|
|
1399
1426
|
*
|
|
@@ -1404,13 +1431,15 @@ export declare class MotionMasterReqResClient {
|
|
|
1404
1431
|
* @param deviceRef - The reference to the device to which the login command will be sent.
|
|
1405
1432
|
* @param username - The optional username used for logging in to the SMM. If not provided, it will be treated as an empty string.
|
|
1406
1433
|
* @param password - The password used for logging in to the SMM.
|
|
1434
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1435
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1407
1436
|
*
|
|
1408
1437
|
* @returns An observable that emits a boolean value indicating whether the login attempt succeeded.
|
|
1409
1438
|
*
|
|
1410
1439
|
* @remarks
|
|
1411
1440
|
* If the device is already logged in, the next login attempt will fail unless the user logs out first.
|
|
1412
1441
|
*/
|
|
1413
|
-
loginToSmmForSoftwareUpdate(deviceRef: DeviceRef, username: string, password: string): Observable<boolean>;
|
|
1442
|
+
loginToSmmForSoftwareUpdate(deviceRef: DeviceRef, username: string, password: string, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1414
1443
|
/**
|
|
1415
1444
|
* Logs out from the SMM.
|
|
1416
1445
|
*
|
|
@@ -1418,10 +1447,12 @@ export declare class MotionMasterReqResClient {
|
|
|
1418
1447
|
* is successful and `false` otherwise. The command times out after 10 seconds if no response is received.
|
|
1419
1448
|
*
|
|
1420
1449
|
* @param deviceRef - The reference to the device to which the logout command will be sent.
|
|
1450
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1451
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1421
1452
|
*
|
|
1422
1453
|
* @returns An observable that emits a boolean value indicating whether the logout attempt succeeded.
|
|
1423
1454
|
*/
|
|
1424
|
-
logoutFromSmm(deviceRef: DeviceRef): Observable<boolean>;
|
|
1455
|
+
logoutFromSmm(deviceRef: DeviceRef, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1425
1456
|
/**
|
|
1426
1457
|
* Logs out from the SMM and then logs back in with the provided credentials for parameter download.
|
|
1427
1458
|
*
|
|
@@ -1432,11 +1463,29 @@ export declare class MotionMasterReqResClient {
|
|
|
1432
1463
|
* @param deviceRef - The reference to the device to which the logout and login commands will be sent.
|
|
1433
1464
|
* @param username - The username used for logging in to the SMM.
|
|
1434
1465
|
* @param password - The password used for logging in to the SMM.
|
|
1466
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1467
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1435
1468
|
*
|
|
1436
1469
|
* @returns An observable that emits a boolean value indicating whether the relogin attempt succeeded.
|
|
1437
1470
|
*/
|
|
1438
|
-
reloginToSmmForParameterDownload(deviceRef: DeviceRef, username: string, password: string): Observable<boolean>;
|
|
1439
|
-
|
|
1471
|
+
reloginToSmmForParameterDownload(deviceRef: DeviceRef, username: string, password: string, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1472
|
+
/**
|
|
1473
|
+
* Changes the SMM password for the specified device.
|
|
1474
|
+
*
|
|
1475
|
+
* @param deviceRef - A reference to the target device.
|
|
1476
|
+
* @param oldPassword - The current SMM password.
|
|
1477
|
+
* @param newPassword - The new password to set for the SMM.
|
|
1478
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1479
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1480
|
+
* @returns An Observable that emits `true` if the password change and SMM restart succeed, otherwise `false`.
|
|
1481
|
+
*
|
|
1482
|
+
* @remarks
|
|
1483
|
+
* A prior successful login is required before changing the password.
|
|
1484
|
+
* The new password must be at least 4 characters long.
|
|
1485
|
+
*
|
|
1486
|
+
* This function sends an acyclic command to update the password. If successful, it triggers an SMM restart.
|
|
1487
|
+
*/
|
|
1488
|
+
changeSmmPassword(deviceRef: DeviceRef, oldPassword: string, newPassword: string, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1440
1489
|
/**
|
|
1441
1490
|
* Triggers a restart for the specified device.
|
|
1442
1491
|
*
|
|
@@ -1444,8 +1493,8 @@ export declare class MotionMasterReqResClient {
|
|
|
1444
1493
|
* The method will return `true` if the restart was successful, otherwise `false`.
|
|
1445
1494
|
*
|
|
1446
1495
|
* @param deviceRef - The reference to the device to restart.
|
|
1447
|
-
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1448
|
-
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1496
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1497
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1449
1498
|
*
|
|
1450
1499
|
* @returns An Observable that emits `true` if the restart was successful, or `false` otherwise.
|
|
1451
1500
|
*/
|
|
@@ -1457,18 +1506,133 @@ export declare class MotionMasterReqResClient {
|
|
|
1457
1506
|
* The method will return `true` if the acknowledgment was successful, otherwise `false`.
|
|
1458
1507
|
*
|
|
1459
1508
|
* @param deviceRef - The reference to the device to acknowledge the I/O failure on.
|
|
1460
|
-
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1461
|
-
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1509
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1510
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1462
1511
|
*
|
|
1463
1512
|
* @returns An Observable that emits `true` if the acknowledgment was successful, or `false` otherwise.
|
|
1464
1513
|
*/
|
|
1465
1514
|
acknowledgeIoFailureOnSmm(deviceRef: DeviceRef, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1466
1515
|
configureSmmSoftwareUpdate(deviceRef: DeviceRef, fileSize: number): Observable<boolean>;
|
|
1467
1516
|
updateSmmSoftware(deviceRef: DeviceRef, username: string, password: string, buffer: Uint8Array, crc: number, chunkSize?: number): Observable<boolean>;
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1517
|
+
/**
|
|
1518
|
+
* Transmits SMM parameters to the specified device.
|
|
1519
|
+
*
|
|
1520
|
+
* @param deviceRef - The reference to the target device.
|
|
1521
|
+
* @param values - An array of data values to transmit.
|
|
1522
|
+
* @param parameterStructureVersion - The version of the parameter structure (default: 0x0041).
|
|
1523
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1524
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1525
|
+
*
|
|
1526
|
+
* @returns An Observable that emits `true` if the operation succeeds, or `false` if it fails, the `values` array is empty.
|
|
1527
|
+
*
|
|
1528
|
+
* @remarks
|
|
1529
|
+
* - If the `values` array is empty, the function immediately returns `false`.
|
|
1530
|
+
* - The `version` is prepended to the values array before packing.
|
|
1531
|
+
* - The function constructs an OS command for transmitting the parameters and writes the packed buffer to the fs-buffer file.
|
|
1532
|
+
*/
|
|
1533
|
+
transmitSmmParameters(deviceRef: DeviceRef, values: DataType[], parameterStructureVersion?: number, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1534
|
+
/**
|
|
1535
|
+
* Loads the SMM parameters for verification on the specified device.
|
|
1536
|
+
*
|
|
1537
|
+
* This method sends a command to the device to load the SMM parameters for verification and waits for the response.
|
|
1538
|
+
* The device returns a buffer with all bits inverted. The OS command will invert the bits and reconstruct the buffer
|
|
1539
|
+
* into valid parameter values, which are then returned in sequence within the OS command response.
|
|
1540
|
+
*
|
|
1541
|
+
* @param deviceRef - The reference to the device from which the parameters should be loaded.
|
|
1542
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1543
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1544
|
+
* @returns An Observable that emits the response from the device, containing the valid parameter values for verification
|
|
1545
|
+
* after the buffer is processed and reconstructed.
|
|
1546
|
+
*
|
|
1547
|
+
* @throws Will throw an error if the command fails or times out.
|
|
1548
|
+
*/
|
|
1549
|
+
loadSmmParametersForVerification(deviceRef: DeviceRef, commandTimeout?: number, responsePollingInterval?: number): Observable<SmmAcyclicHandlerLoadParametersForVerificationOsCommandResponse>;
|
|
1550
|
+
/**
|
|
1551
|
+
* Verifies a group of SMM parameters for the specified device.
|
|
1552
|
+
*
|
|
1553
|
+
* This function calculates a bitmask from the provided values and group ordinal,
|
|
1554
|
+
* then sends an SMM OS command (subcommand VERIFY_PARAMETERS) along with the bitmask content
|
|
1555
|
+
* via `fs-buffer` to the device for verification.
|
|
1556
|
+
*
|
|
1557
|
+
* @param deviceRef - A reference to the target device.
|
|
1558
|
+
* @param values - An array of parameter values to verify.
|
|
1559
|
+
* @param groupIndex - The verification group index used for bitmask calculation.
|
|
1560
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1561
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1562
|
+
* @returns An `Observable<boolean>` that emits `true` if the verification succeeded, or `false` otherwise.
|
|
1563
|
+
*
|
|
1564
|
+
* @remarks
|
|
1565
|
+
* This function requires parameters to be previously loaded for verification to succeed. If parameters are not preloaded, the verification will fail.
|
|
1566
|
+
* The same group can be verified multiple times without causing an error.
|
|
1567
|
+
*/
|
|
1568
|
+
verifySmmParameters(deviceRef: DeviceRef, values: DataType[], groupIndex: number, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1569
|
+
/**
|
|
1570
|
+
* Loads the SMM validation file on the specified device.
|
|
1571
|
+
*
|
|
1572
|
+
* @param deviceRef - A reference to the target device.
|
|
1573
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1574
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1575
|
+
* @returns An Observable emitting the OS command response.
|
|
1576
|
+
*
|
|
1577
|
+
* @remarks
|
|
1578
|
+
* This function should only be called **after all parameter groups have been successfully verified**.
|
|
1579
|
+
*/
|
|
1580
|
+
loadSmmValidationFile(deviceRef: DeviceRef, commandTimeout?: number, responsePollingInterval?: number): Observable<OsCommandResponse>;
|
|
1581
|
+
/**
|
|
1582
|
+
* Loads the SMM validation file and then retrieves the safety parameters report file.
|
|
1583
|
+
*
|
|
1584
|
+
* @param deviceRef - A reference to the target device.
|
|
1585
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1586
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1587
|
+
* @returns An Observable emitting the decoded content of the `.safety_parameters_report` file.
|
|
1588
|
+
*
|
|
1589
|
+
* @throws An error if loading the validation file fails.
|
|
1590
|
+
*
|
|
1591
|
+
* @remarks
|
|
1592
|
+
* This function should only be called **after all parameter groups have been successfully verified**.
|
|
1593
|
+
*/
|
|
1594
|
+
loadSmmValidationFileAndReadSafetyParametersReportFile(deviceRef: DeviceRef, commandTimeout?: number, responsePollingInterval?: number): Observable<string>;
|
|
1595
|
+
/**
|
|
1596
|
+
* Validates the SMM configuration on the specified device.
|
|
1597
|
+
*
|
|
1598
|
+
* @param deviceRef - The reference to the target device.
|
|
1599
|
+
* @param report - A `Uint8Array` representing the validation report data.
|
|
1600
|
+
* @param date - The date associated with the validation.
|
|
1601
|
+
* @param username - The username used for authentication.
|
|
1602
|
+
* @param password - The password used for authentication.
|
|
1603
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1604
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1605
|
+
*
|
|
1606
|
+
* @returns An Observable that emits `true` if the configuration validation succeeds, or `false` if it fails.
|
|
1607
|
+
*
|
|
1608
|
+
* @remarks
|
|
1609
|
+
* - Packs the validation report, date, username, and password into a buffer.
|
|
1610
|
+
* - Constructs an OS command using the `VALIDATE_CONFIGURATION` subcommand.
|
|
1611
|
+
* - Sends the command to the device and writes the packed buffer to the fs-buffer file.
|
|
1612
|
+
* - **Important:** Once the configuration is successfully validated, subsequent calls to this function will fail. To revalidate, the user must go through the verification process again.
|
|
1613
|
+
*/
|
|
1614
|
+
validateSmmConfiguration(deviceRef: DeviceRef, report: Uint8Array, date: Date, username: string, password: string, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1615
|
+
/**
|
|
1616
|
+
* Reads the safety parameters report from the device and validates the SMM configuration.
|
|
1617
|
+
*
|
|
1618
|
+
* @param deviceRef - The reference to the target device.
|
|
1619
|
+
* @param date - The date associated with the validation.
|
|
1620
|
+
* @param username - The username used for authentication.
|
|
1621
|
+
* @param password - The password used for authentication.
|
|
1622
|
+
* @param commandTimeout - The timeout in milliseconds for the command to complete.
|
|
1623
|
+
* @param responsePollingInterval - The interval in milliseconds between polling for the response.
|
|
1624
|
+
*
|
|
1625
|
+
* @returns An Observable that emits `true` if the SMM configuration is successfully validated, or `false` if validation fails.
|
|
1626
|
+
*
|
|
1627
|
+
* @throws An error if the `.safety_parameters_report` file is missing.
|
|
1628
|
+
*
|
|
1629
|
+
* @remarks
|
|
1630
|
+
* - The function attempts to retrieve the `.safety_parameters_report` file from the device.
|
|
1631
|
+
* - If the file is missing, an error is thrown.
|
|
1632
|
+
* - The file content is read into a `Uint8Array` and passed to `validateSmmConfiguration`.
|
|
1633
|
+
* - The SMM configuration validation follows the same behavior as `validateSmmConfiguration`:
|
|
1634
|
+
* - If validation succeeds, subsequent calls to this function will fail.
|
|
1635
|
+
* - To revalidate, the user must repeat the verification process.
|
|
1636
|
+
*/
|
|
1637
|
+
readSafetyParametersReportAndValidateSmmConfiguration(deviceRef: DeviceRef, date: Date, username: string, password: string, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
|
|
1474
1638
|
}
|