motion-master-client 0.0.245 → 0.0.246

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.
Files changed (102) hide show
  1. package/README.md +24 -18
  2. package/package.json +1 -1
  3. package/src/api.js +21 -5
  4. package/src/api.js.map +1 -1
  5. package/src/cli.js +47 -19
  6. package/src/cli.js.map +1 -1
  7. package/src/lib/cia402.js +11 -36
  8. package/src/lib/cia402.js.map +1 -1
  9. package/src/lib/config-file.js +3 -1
  10. package/src/lib/config-file.js.map +1 -1
  11. package/src/lib/data-monitoring.d.ts +4 -4
  12. package/src/lib/data-monitoring.js +8 -6
  13. package/src/lib/data-monitoring.js.map +1 -1
  14. package/src/lib/device-parameter.d.ts +5 -5
  15. package/src/lib/device-parameter.js +10 -44
  16. package/src/lib/device-parameter.js.map +1 -1
  17. package/src/lib/device.d.ts +4 -4
  18. package/src/lib/device.js +9 -7
  19. package/src/lib/device.js.map +1 -1
  20. package/src/lib/encoder.js +4 -1
  21. package/src/lib/encoder.js.map +1 -1
  22. package/src/lib/error-report.d.ts +4 -4
  23. package/src/lib/error-report.js +0 -1
  24. package/src/lib/error-report.js.map +1 -1
  25. package/src/lib/ethercat.js +119 -33
  26. package/src/lib/ethercat.js.map +1 -1
  27. package/src/lib/ethernet.d.ts +3 -3
  28. package/src/lib/ethernet.js +5 -5
  29. package/src/lib/ethernet.js.map +1 -1
  30. package/src/lib/fetch.d.ts +1 -1
  31. package/src/lib/fetch.js +7 -7
  32. package/src/lib/fetch.js.map +1 -1
  33. package/src/lib/firmware.js +3 -1
  34. package/src/lib/firmware.js.map +1 -1
  35. package/src/lib/homing.d.ts +1 -1
  36. package/src/lib/homing.js.map +1 -1
  37. package/src/lib/integro-encoder-calibration.js +11 -4
  38. package/src/lib/integro-encoder-calibration.js.map +1 -1
  39. package/src/lib/integro-variant.js.map +1 -1
  40. package/src/lib/is-online.js +2 -2
  41. package/src/lib/is-online.js.map +1 -1
  42. package/src/lib/logger.js +1 -1
  43. package/src/lib/mmcidb.js.map +1 -1
  44. package/src/lib/monitoring-config.d.ts +1 -1
  45. package/src/lib/monitoring-entry.d.ts +3 -3
  46. package/src/lib/motion-composer.d.ts +4 -4
  47. package/src/lib/motion-composer.js +3 -2
  48. package/src/lib/motion-composer.js.map +1 -1
  49. package/src/lib/motion-master-client.d.ts +10 -10
  50. package/src/lib/motion-master-client.js +15 -10
  51. package/src/lib/motion-master-client.js.map +1 -1
  52. package/src/lib/motion-master-pub-sub-client.d.ts +4 -4
  53. package/src/lib/motion-master-pub-sub-client.js +2 -2
  54. package/src/lib/motion-master-pub-sub-client.js.map +1 -1
  55. package/src/lib/motion-master-pub-sub-socket.d.ts +2 -2
  56. package/src/lib/motion-master-pub-sub-web-socket.d.ts +3 -3
  57. package/src/lib/motion-master-pub-sub-web-socket.js.map +1 -1
  58. package/src/lib/motion-master-pub-sub-worker-socket.d.ts +3 -3
  59. package/src/lib/motion-master-pub-sub-worker-socket.js +1 -1
  60. package/src/lib/motion-master-pub-sub-worker-socket.js.map +1 -1
  61. package/src/lib/motion-master-req-res-client.d.ts +225 -15
  62. package/src/lib/motion-master-req-res-client.js +420 -57
  63. package/src/lib/motion-master-req-res-client.js.map +1 -1
  64. package/src/lib/motion-master-req-res-socket.d.ts +2 -2
  65. package/src/lib/motion-master-req-res-web-socket.d.ts +3 -3
  66. package/src/lib/motion-master-req-res-web-socket.js +2 -2
  67. package/src/lib/motion-master-req-res-web-socket.js.map +1 -1
  68. package/src/lib/motion-master-req-res-worker-socket.d.ts +3 -3
  69. package/src/lib/motion-master-req-res-worker-socket.js.map +1 -1
  70. package/src/lib/online.d.ts +1 -1
  71. package/src/lib/online.js +3 -2
  72. package/src/lib/online.js.map +1 -1
  73. package/src/lib/operators.js.map +1 -1
  74. package/src/lib/options.js +5 -5
  75. package/src/lib/options.js.map +1 -1
  76. package/src/lib/os-command.d.ts +24 -22
  77. package/src/lib/os-command.js +85 -55
  78. package/src/lib/os-command.js.map +1 -1
  79. package/src/lib/parameter.js +3 -1
  80. package/src/lib/parameter.js.map +1 -1
  81. package/src/lib/product-id-range.js +5 -5
  82. package/src/lib/product-id-range.js.map +1 -1
  83. package/src/lib/product.js +256 -34
  84. package/src/lib/product.js.map +1 -1
  85. package/src/lib/request-status-resolver.d.ts +1 -1
  86. package/src/lib/request-status-resolver.js +8 -6
  87. package/src/lib/request-status-resolver.js.map +1 -1
  88. package/src/lib/sii.js +4 -11
  89. package/src/lib/sii.js.map +1 -1
  90. package/src/lib/smm.d.ts +62 -0
  91. package/src/lib/smm.js +175 -0
  92. package/src/lib/smm.js.map +1 -0
  93. package/src/lib/types.d.ts +8 -8
  94. package/src/lib/types.js +0 -4
  95. package/src/lib/types.js.map +1 -1
  96. package/src/lib/units.js +11 -23
  97. package/src/lib/units.js.map +1 -1
  98. package/src/lib/util.d.ts +3 -2
  99. package/src/lib/util.js +23 -11
  100. package/src/lib/util.js.map +1 -1
  101. package/src/lib/web-socket-connection-close-codes.js +2 -2
  102. package/src/lib/web-socket-connection-close-codes.js.map +1 -1
@@ -1,17 +1,19 @@
1
- import { Observable } from "rxjs";
2
- import { RetryConfig } from "rxjs/operators";
3
- import { Device } from "./device";
4
- import { DeviceParameter } from "./device-parameter";
5
- import { HardwareDescription, StackInfo } from "./hardware-description";
6
- import { MotionMasterReqResSocket } from "./motion-master-req-res-socket";
7
- import { UIFeaturesConfig } from "./parameter";
8
- import { SystemLogLine } from "./system-log-line";
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
- 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";
12
- import { IntegroVariant } from "./integro-variant";
1
+ import { Observable } from 'rxjs';
2
+ import { RetryConfig } from 'rxjs/operators';
3
+ import { Device } from './device';
4
+ import { DeviceParameter } from './device-parameter';
5
+ import { HardwareDescription, StackInfo } from './hardware-description';
6
+ import { MotionMasterReqResSocket } from './motion-master-req-res-socket';
7
+ import { Parameter, UIFeaturesConfig } from './parameter';
8
+ import { SystemLogLine } from './system-log-line';
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
+ 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';
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
+ import { DataType } from 'python-struct';
15
17
  /**
16
18
  * This class contains methods for making requests to Motion Master using the injected request/response socket.
17
19
  *
@@ -860,7 +862,7 @@ export declare class MotionMasterReqResClient {
860
862
  /**
861
863
  * Get file content.
862
864
  */
863
- getFile(deviceRef: DeviceRef, name: string, requestTimeout?: number, messageId?: string): Observable<Uint8Array | null | undefined>;
865
+ getFile(deviceRef: DeviceRef, name: string, requestTimeout?: number, messageId?: string): Observable<Uint8Array | number[] | null | undefined>;
864
866
  /**
865
867
  * Get decoded file content.
866
868
  *
@@ -1143,7 +1145,7 @@ export declare class MotionMasterReqResClient {
1143
1145
  resetKublerEncoderMultiturnPosition(deviceRef: DeviceRef): Observable<KublerEncoderRegisterCommunicationOsCommandResponse>;
1144
1146
  readOsCommandResponse(deviceRef: DeviceRef): Observable<OsCommandResponse>;
1145
1147
  runOsCommandAndWriteFsBuffer<T extends OsCommandResponse>(deviceRef: DeviceRef, command: Uint8Array, content: Uint8Array, commandTimeout?: number, responsePollingInterval?: number, osCommandMode?: boolean | OsCommandMode): Observable<T>;
1146
- runOsCommandAndReadFsBuffer<T extends OsCommandResponse>(deviceRef: DeviceRef, command: Uint8Array, commandTimeout: 30000, responsePollingInterval?: number, osCommandMode?: boolean | OsCommandMode): Observable<T>;
1148
+ runOsCommandAndReadFsBuffer<T extends OsCommandResponse>(deviceRef: DeviceRef, command: Uint8Array, commandTimeout?: number, responsePollingInterval?: number, osCommandMode?: boolean | OsCommandMode): Observable<T>;
1147
1149
  /**
1148
1150
  * Set halt bit.
1149
1151
  *
@@ -1260,5 +1262,213 @@ export declare class MotionMasterReqResClient {
1260
1262
  * @returns {Promise<void>} Resolves when all PDO parameter updates are complete.
1261
1263
  * The function processes and applies updates sequentially to ensure they are performed in order.
1262
1264
  */
1263
- updatePdoParameterGroupedValues(deviceRef: DeviceRef, pdoGroupedValues: number[][], pdoIndex: 0x1600 | 0x1A00): Promise<void>;
1265
+ updatePdoParameterGroupedValues(deviceRef: DeviceRef, pdoGroupedValues: number[][], pdoIndex: 0x1600 | 0x1a00): Promise<void>;
1266
+ /**
1267
+ * Reads the SMM parameter for a given device.
1268
+ *
1269
+ * @param deviceRef - The reference to the device to which the command will be sent.
1270
+ * @param index - The index of the SMM parameter to read.
1271
+ * @param subindex - The subindex of the SMM parameter to read. Defaults to 0.
1272
+ * @param commandTimeout - The timeout for the command in milliseconds. Defaults to 10,000 ms (10 seconds).
1273
+ * @param responsePollingInterval - The interval between polling attempts for a response in milliseconds. Defaults to 100 ms.
1274
+ *
1275
+ * @returns An observable that emits the response from the command once it is received.
1276
+ */
1277
+ readSmmParameter(deviceRef: DeviceRef, index: number, subindex?: number, commandTimeout?: number, responsePollingInterval?: number): Observable<OsCommandResponse>;
1278
+ /**
1279
+ * Reads the SMM parameter value as a number.
1280
+ *
1281
+ * This method reads a parameter from a device and extracts its value based on the provided `dataViewExtractor`.
1282
+ * The default behavior is to extract a 32-bit integer in little-endian format.
1283
+ *
1284
+ * @param deviceRef - A reference to the device from which the SMM parameter is being read.
1285
+ * @param index - The index of the parameter to read.
1286
+ * @param subindex - The subindex of the parameter (default is 0).
1287
+ * @param dataViewExtractor - A function that extracts a number from the `DataView` (default is `view.getInt32(0, true)`).
1288
+ *
1289
+ * @returns An observable that emits the extracted number value.
1290
+ *
1291
+ * @throws {Error} If the response buffer is empty or invalid.
1292
+ */
1293
+ readSmmParameterNumberValue(deviceRef: DeviceRef, index: number, subindex?: number, dataViewExtractor?: (view: DataView) => number): Observable<number>;
1294
+ /**
1295
+ * Reads the SMM parameter value as a string.
1296
+ *
1297
+ * This method reads a parameter from a device and decodes its value as a UTF-8 string from the response buffer.
1298
+ *
1299
+ * @param deviceRef - A reference to the device from which the SMM parameter is being read.
1300
+ * @param index - The index of the parameter to read.
1301
+ * @param subindex - The subindex of the parameter (default is 0).
1302
+ *
1303
+ * @returns An observable that emits the decoded string value.
1304
+ *
1305
+ * @throws {Error} If the response buffer is empty or invalid.
1306
+ */
1307
+ readSmmParameterStringValue(deviceRef: DeviceRef, index: number, subindex?: number): Observable<string>;
1308
+ /**
1309
+ * Reads the SMM parameter value as an array of numbers.
1310
+ *
1311
+ * This method reads a parameter from a device and returns the values as an array of numbers,
1312
+ * where each element corresponds to a byte from the response buffer.
1313
+ *
1314
+ * @param deviceRef - A reference to the device from which the SMM parameter is being read.
1315
+ * @param index - The index of the parameter to read.
1316
+ * @param subindex - The subindex of the parameter (default is 0).
1317
+ *
1318
+ * @returns An observable that emits an array of numbers, representing the byte values in the response buffer.
1319
+ *
1320
+ * @throws {Error} If the response buffer is empty or invalid.
1321
+ */
1322
+ readSmmParameterArrayValue(deviceRef: DeviceRef, index: number, subindex?: number): Observable<number[]>;
1323
+ /**
1324
+ * Reads the SMM firmware version from a device.
1325
+ *
1326
+ * This method reads the firmware version (MCU Software Version 0x0001:00) of the device as an array of numbers.
1327
+ * The first byte represents the minor version, and the second byte represents the major version.
1328
+ *
1329
+ * @param deviceRef - A reference to the device from which the firmware version is being read.
1330
+ *
1331
+ * @returns An observable that emits an array of numbers, representing the byte values of the firmware version.
1332
+ */
1333
+ readSmmFirmareVersion(deviceRef: DeviceRef): Observable<number[]>;
1334
+ /**
1335
+ * Reads the SMM serial number from a device.
1336
+ *
1337
+ * This method reads the serial number of the device as a string.
1338
+ * The serial number is retrieved from the device using the appropriate SMM parameter (0x0003:00).
1339
+ *
1340
+ * @param deviceRef - A reference to the device from which the serial number is being read.
1341
+ *
1342
+ * @returns An observable that emits the serial number as a string.
1343
+ */
1344
+ readSmmSerialNumber(deviceRef: DeviceRef): Observable<string>;
1345
+ /**
1346
+ * Reads the SMM temperature value from a device.
1347
+ *
1348
+ * This method reads the temperature of the device as a number. The temperature is retrieved from the device
1349
+ * using the appropriate SMM parameter (0x000a:00).
1350
+ *
1351
+ * @param deviceRef - A reference to the device from which the temperature is being read.
1352
+ *
1353
+ * @returns An observable that emits the temperature value as a number.
1354
+ */
1355
+ readSmmTemperature(deviceRef: DeviceRef): Observable<number>;
1356
+ /**
1357
+ * Reads the SMM parameter check value from a device.
1358
+ *
1359
+ * This method reads the parameter check value from the device as a 16-bit unsigned integer. The value represents
1360
+ * the number of parameters available on the SMM and is retrieved from the device using the appropriate SMM parameter (0x000b:00).
1361
+ * and the custom data extraction function.
1362
+ *
1363
+ * @param deviceRef - A reference to the device from which the parameter check value is being read.
1364
+ *
1365
+ * @returns An observable that emits the parameter check value as a 16-bit unsigned integer, which represents
1366
+ * the number of parameters available on the SMM.
1367
+ */
1368
+ readSmmParameterCheck(deviceRef: DeviceRef): Observable<number>;
1369
+ /**
1370
+ * Reads the SMM maximum position discrepancy value from a device.
1371
+ *
1372
+ * This method reads the maximum position discrepancy value from the device as a 32-bit unsigned integer.
1373
+ * The value is retrieved from the device using the appropriate SMM parameter and the custom data extraction function.
1374
+ *
1375
+ * @param deviceRef - A reference to the device from which the maximum position discrepancy value is being read.
1376
+ *
1377
+ * @returns An observable that emits the maximum position discrepancy value as a 32-bit unsigned integer.
1378
+ */
1379
+ readSmmMaxPositionDiscrepancy(deviceRef: DeviceRef): Observable<number>;
1380
+ /**
1381
+ * Logs into the SMM for parameter download with the provided credentials.
1382
+ *
1383
+ * This function sends a login command to the device using the provided username and password. It returns an observable
1384
+ * that emits `true` if the login is successful and `false` otherwise. If the device is already logged in, the next login
1385
+ * attempt will fail unless the user logs out beforehand.
1386
+ *
1387
+ * @param deviceRef - The reference to the device to which the login command will be sent.
1388
+ * @param username - The optional username used for logging in to the SMM. If not provided, it will be treated as an empty string.
1389
+ * @param password - The password used for logging in to the SMM.
1390
+ *
1391
+ * @returns An observable that emits a boolean value indicating whether the login attempt succeeded.
1392
+ *
1393
+ * @remarks
1394
+ * If the device is already logged in, the next login attempt will fail unless the user logs out first.
1395
+ */
1396
+ loginToSmmForParameterDownload(deviceRef: DeviceRef, username: string, password: string): Observable<boolean>;
1397
+ /**
1398
+ * Logs into the SMM for software update with the provided credentials.
1399
+ *
1400
+ * This function sends a login command to the device using the provided username and password. It returns an observable
1401
+ * that emits `true` if the login is successful and `false` otherwise. If the device is already logged in, the next login
1402
+ * attempt will fail unless the user logs out beforehand.
1403
+ *
1404
+ * @param deviceRef - The reference to the device to which the login command will be sent.
1405
+ * @param username - The optional username used for logging in to the SMM. If not provided, it will be treated as an empty string.
1406
+ * @param password - The password used for logging in to the SMM.
1407
+ *
1408
+ * @returns An observable that emits a boolean value indicating whether the login attempt succeeded.
1409
+ *
1410
+ * @remarks
1411
+ * If the device is already logged in, the next login attempt will fail unless the user logs out first.
1412
+ */
1413
+ loginToSmmForSoftwareUpdate(deviceRef: DeviceRef, username: string, password: string): Observable<boolean>;
1414
+ /**
1415
+ * Logs out from the SMM.
1416
+ *
1417
+ * This function sends a logout command to the device and returns an observable that emits `true` if the logout
1418
+ * is successful and `false` otherwise. The command times out after 10 seconds if no response is received.
1419
+ *
1420
+ * @param deviceRef - The reference to the device to which the logout command will be sent.
1421
+ *
1422
+ * @returns An observable that emits a boolean value indicating whether the logout attempt succeeded.
1423
+ */
1424
+ logoutFromSmm(deviceRef: DeviceRef): Observable<boolean>;
1425
+ /**
1426
+ * Logs out from the SMM and then logs back in with the provided credentials for parameter download.
1427
+ *
1428
+ * This function first sends a logout command to the device, followed by a login command using the provided username
1429
+ * and password. It returns an observable that emits `true` if both the logout and login attempts are successful
1430
+ * and `false` otherwise. The login process is handled through the `loginToSmmForParameterDownload` function.
1431
+ *
1432
+ * @param deviceRef - The reference to the device to which the logout and login commands will be sent.
1433
+ * @param username - The username used for logging in to the SMM.
1434
+ * @param password - The password used for logging in to the SMM.
1435
+ *
1436
+ * @returns An observable that emits a boolean value indicating whether the relogin attempt succeeded.
1437
+ */
1438
+ reloginToSmmForParameterDownload(deviceRef: DeviceRef, username: string, password: string): Observable<boolean>;
1439
+ changeSmmPassword(deviceRef: DeviceRef, oldPassword: string, newPassword: string): Observable<boolean>;
1440
+ /**
1441
+ * Triggers a restart for the specified device.
1442
+ *
1443
+ * This method sends a command to the device to trigger an SMM restart and waits for a response.
1444
+ * The method will return `true` if the restart was successful, otherwise `false`.
1445
+ *
1446
+ * @param deviceRef - The reference to the device to restart.
1447
+ * @param commandTimeout - The timeout in milliseconds for the command to complete. Default is 10000ms (10 seconds).
1448
+ * @param responsePollingInterval - The interval in milliseconds between polling for the response. Default is 100ms.
1449
+ *
1450
+ * @returns An Observable that emits `true` if the restart was successful, or `false` otherwise.
1451
+ */
1452
+ triggerSmmRestart(deviceRef: DeviceRef, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
1453
+ /**
1454
+ * Acknowledges an I/O failure on the specified device.
1455
+ *
1456
+ * This method sends a command to the device to acknowledge an I/O failure and waits for a response.
1457
+ * The method will return `true` if the acknowledgment was successful, otherwise `false`.
1458
+ *
1459
+ * @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. Default is 10000ms (10 seconds).
1461
+ * @param responsePollingInterval - The interval in milliseconds between polling for the response. Default is 100ms.
1462
+ *
1463
+ * @returns An Observable that emits `true` if the acknowledgment was successful, or `false` otherwise.
1464
+ */
1465
+ acknowledgeIoFailureOnSmm(deviceRef: DeviceRef, commandTimeout?: number, responsePollingInterval?: number): Observable<boolean>;
1466
+ configureSmmSoftwareUpdate(deviceRef: DeviceRef, fileSize: number): Observable<boolean>;
1467
+ updateSmmSoftware(deviceRef: DeviceRef, username: string, password: string, buffer: Uint8Array, crc: number, chunkSize?: number): Observable<boolean>;
1468
+ transmitSmmParameters(deviceRef: DeviceRef, parameters: Pick<Parameter, 'value'>[], version?: number): Observable<boolean>;
1469
+ loadSmmParametersForVerification(deviceRef: DeviceRef): Observable<OsCommandResponse>;
1470
+ loadSmmParametersForVerificationAndUnpack(deviceRef: DeviceRef): Observable<DataType[]>;
1471
+ verifySmmParameters(deviceRef: DeviceRef, parameters: Pick<Parameter, 'value'>[], groupOrdinal: SmmVerificationGroupOrdinal): Observable<boolean>;
1472
+ loadSmmValidationFile(deviceRef: DeviceRef): Observable<OsCommandResponse>;
1473
+ validateSmmConfiguration(deviceRef: DeviceRef, report: Uint8Array, date: Date, username: string, password: string): Observable<boolean>;
1264
1474
  }