jooby-codec 2.8.2 → 2.10.0
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/dist/analog/Command.d.ts +1 -0
- package/dist/analog/Command.js +4 -0
- package/dist/analog/Command.js.map +1 -1
- package/dist/analog/message.d.ts +2 -0
- package/dist/analog/message.js +4 -0
- package/dist/analog/message.js.map +1 -1
- package/dist/obis-observer/Command.d.ts +1 -0
- package/dist/obis-observer/Command.js +7 -8
- package/dist/obis-observer/Command.js.map +1 -1
- package/dist/obis-observer/CommandBinaryBuffer.d.ts +7 -7
- package/dist/obis-observer/CommandBinaryBuffer.js +11 -11
- package/dist/obis-observer/CommandBinaryBuffer.js.map +1 -1
- package/dist/obis-observer/commands/downlink/AddMeterProfile.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/AddMeterProfile.js +34 -0
- package/dist/obis-observer/commands/downlink/AddMeterProfile.js.map +1 -0
- package/dist/obis-observer/commands/downlink/AddObisProfile.d.ts +18 -0
- package/dist/obis-observer/commands/downlink/{AddShortNameProfile.js → AddObisProfile.js} +20 -17
- package/dist/obis-observer/commands/downlink/AddObisProfile.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetLorawanInfo.d.ts +2 -2
- package/dist/obis-observer/commands/downlink/GetLorawanInfo.js +6 -13
- package/dist/obis-observer/commands/downlink/GetLorawanInfo.js.map +1 -1
- package/dist/obis-observer/commands/downlink/GetLorawanState.d.ts +2 -2
- package/dist/obis-observer/commands/downlink/GetLorawanState.js +6 -13
- package/dist/obis-observer/commands/downlink/GetLorawanState.js.map +1 -1
- package/dist/obis-observer/commands/downlink/GetMeterArchiveProfile.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/GetMeterArchiveProfile.js +34 -0
- package/dist/obis-observer/commands/downlink/GetMeterArchiveProfile.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetMeterArchiveState.d.ts +17 -0
- package/dist/obis-observer/commands/downlink/GetMeterArchiveState.js +35 -0
- package/dist/obis-observer/commands/downlink/GetMeterArchiveState.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetMeterDate.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/GetMeterDate.js +33 -0
- package/dist/obis-observer/commands/downlink/GetMeterDate.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetMeterId.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/{GetShortNameInfo.js → GetMeterId.js} +17 -17
- package/dist/obis-observer/commands/downlink/GetMeterId.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetMeterIdList.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/GetMeterIdList.js +33 -0
- package/dist/obis-observer/commands/downlink/GetMeterIdList.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetMeterInfo.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/GetMeterInfo.js +33 -0
- package/dist/obis-observer/commands/downlink/GetMeterInfo.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetMeterProfileIdList.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/GetMeterProfileIdList.js +33 -0
- package/dist/obis-observer/commands/downlink/GetMeterProfileIdList.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetMeterReadoutState.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/GetMeterReadoutState.js +33 -0
- package/dist/obis-observer/commands/downlink/GetMeterReadoutState.js.map +1 -0
- package/dist/obis-observer/commands/downlink/{GetContentByObis.d.ts → GetObisContent.d.ts} +2 -1
- package/dist/obis-observer/commands/downlink/{GetContentByObis.js → GetObisContent.js} +9 -6
- package/dist/obis-observer/commands/downlink/GetObisContent.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetObisContentById.d.ts +17 -0
- package/dist/obis-observer/commands/downlink/GetObisContentById.js +34 -0
- package/dist/obis-observer/commands/downlink/GetObisContentById.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetObisIdList.d.ts +17 -0
- package/dist/obis-observer/commands/downlink/{SetShortName.js → GetObisIdList.js} +15 -15
- package/dist/obis-observer/commands/downlink/GetObisIdList.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetObisInfo.d.ts +17 -0
- package/dist/obis-observer/commands/downlink/GetObisInfo.js +34 -0
- package/dist/obis-observer/commands/downlink/GetObisInfo.js.map +1 -0
- package/dist/obis-observer/commands/downlink/GetObisProfile.d.ts +17 -0
- package/dist/obis-observer/commands/downlink/GetObisProfile.js +35 -0
- package/dist/obis-observer/commands/downlink/GetObisProfile.js.map +1 -0
- package/dist/obis-observer/commands/downlink/{GetReadoutState.d.ts → GetObserverCapabilities.d.ts} +4 -4
- package/dist/obis-observer/commands/downlink/GetObserverCapabilities.js +32 -0
- package/dist/obis-observer/commands/downlink/GetObserverCapabilities.js.map +1 -0
- package/dist/obis-observer/commands/downlink/{GetDeviceInfo.d.ts → GetObserverInfo.d.ts} +4 -4
- package/dist/obis-observer/commands/downlink/GetObserverInfo.js +32 -0
- package/dist/obis-observer/commands/downlink/GetObserverInfo.js.map +1 -0
- package/dist/obis-observer/commands/downlink/{GetArchiveProfile.d.ts → GetObserverSingleMode.d.ts} +3 -3
- package/dist/obis-observer/commands/downlink/GetObserverSingleMode.js +32 -0
- package/dist/obis-observer/commands/downlink/GetObserverSingleMode.js.map +1 -0
- package/dist/obis-observer/commands/downlink/{GetDate.d.ts → GetObserverUptime.d.ts} +4 -4
- package/dist/obis-observer/commands/downlink/GetObserverUptime.js +32 -0
- package/dist/obis-observer/commands/downlink/GetObserverUptime.js.map +1 -0
- package/dist/obis-observer/commands/downlink/ReadMeterArchive.d.ts +19 -0
- package/dist/obis-observer/commands/downlink/ReadMeterArchive.js +61 -0
- package/dist/obis-observer/commands/downlink/ReadMeterArchive.js.map +1 -0
- package/dist/obis-observer/commands/downlink/Reboot.d.ts +2 -2
- package/dist/obis-observer/commands/downlink/Reboot.js +6 -12
- package/dist/obis-observer/commands/downlink/Reboot.js.map +1 -1
- package/dist/obis-observer/commands/downlink/RemoveMeter.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/RemoveMeter.js +34 -0
- package/dist/obis-observer/commands/downlink/RemoveMeter.js.map +1 -0
- package/dist/obis-observer/commands/downlink/RemoveMeterProfile.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/RemoveMeterProfile.js +34 -0
- package/dist/obis-observer/commands/downlink/RemoveMeterProfile.js.map +1 -0
- package/dist/obis-observer/commands/downlink/RemoveObisProfile.d.ts +17 -0
- package/dist/obis-observer/commands/downlink/RemoveObisProfile.js +35 -0
- package/dist/obis-observer/commands/downlink/RemoveObisProfile.js.map +1 -0
- package/dist/obis-observer/commands/downlink/SetLorawanActivationMethod.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/SetLorawanActivationMethod.js +34 -0
- package/dist/obis-observer/commands/downlink/SetLorawanActivationMethod.js.map +1 -0
- package/dist/obis-observer/commands/downlink/SetMeterArchiveProfile.d.ts +18 -0
- package/dist/obis-observer/commands/downlink/SetMeterArchiveProfile.js +48 -0
- package/dist/obis-observer/commands/downlink/SetMeterArchiveProfile.js.map +1 -0
- package/dist/obis-observer/commands/downlink/SetObisId.d.ts +18 -0
- package/dist/obis-observer/commands/downlink/{GetShortNames.js → SetObisId.js} +19 -13
- package/dist/obis-observer/commands/downlink/SetObisId.js.map +1 -0
- package/dist/obis-observer/commands/downlink/SetObserverSingleMode.d.ts +16 -0
- package/dist/obis-observer/commands/downlink/SetObserverSingleMode.js +34 -0
- package/dist/obis-observer/commands/downlink/SetObserverSingleMode.js.map +1 -0
- package/dist/obis-observer/commands/downlink/SetSerialPort.d.ts +1 -1
- package/dist/obis-observer/commands/downlink/SetSerialPort.js +3 -3
- package/dist/obis-observer/commands/downlink/SetSerialPort.js.map +1 -1
- package/dist/obis-observer/commands/downlink/SetupMeter.d.ts +18 -0
- package/dist/obis-observer/commands/downlink/SetupMeter.js +50 -0
- package/dist/obis-observer/commands/downlink/SetupMeter.js.map +1 -0
- package/dist/obis-observer/commands/downlink/UpdateImageVerify.d.ts +2 -2
- package/dist/obis-observer/commands/downlink/UpdateImageVerify.js +6 -12
- package/dist/obis-observer/commands/downlink/UpdateImageVerify.js.map +1 -1
- package/dist/obis-observer/commands/downlink/UpdateImageWrite.d.ts +1 -1
- package/dist/obis-observer/commands/downlink/UpdateImageWrite.js +4 -6
- package/dist/obis-observer/commands/downlink/UpdateImageWrite.js.map +1 -1
- package/dist/obis-observer/commands/downlink/UpdateRun.d.ts +2 -2
- package/dist/obis-observer/commands/downlink/UpdateRun.js +6 -12
- package/dist/obis-observer/commands/downlink/UpdateRun.js.map +1 -1
- package/dist/obis-observer/commands/downlink/index.d.ts +28 -15
- package/dist/obis-observer/commands/downlink/index.js +28 -15
- package/dist/obis-observer/commands/downlink/index.js.map +1 -1
- package/dist/obis-observer/commands/uplink/AddMeterProfileResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/AddMeterProfileResponse.js +35 -0
- package/dist/obis-observer/commands/uplink/AddMeterProfileResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/AddObisProfileResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/AddObisProfileResponse.js +35 -0
- package/dist/obis-observer/commands/uplink/AddObisProfileResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetLorawanInfoResponse.d.ts +1 -1
- package/dist/obis-observer/commands/uplink/GetLorawanInfoResponse.js +3 -3
- package/dist/obis-observer/commands/uplink/GetLorawanInfoResponse.js.map +1 -1
- package/dist/obis-observer/commands/uplink/GetLorawanStateResponse.d.ts +1 -1
- package/dist/obis-observer/commands/uplink/GetLorawanStateResponse.js +23 -26
- package/dist/obis-observer/commands/uplink/GetLorawanStateResponse.js.map +1 -1
- package/dist/obis-observer/commands/uplink/{GetArchiveProfileResponse.d.ts → GetMeterArchiveProfileResponse.d.ts} +1 -1
- package/dist/obis-observer/commands/uplink/{GetArchiveProfileResponse.js → GetMeterArchiveProfileResponse.js} +4 -4
- package/dist/obis-observer/commands/uplink/GetMeterArchiveProfileResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetMeterArchiveStateResponse.d.ts +19 -0
- package/dist/obis-observer/commands/uplink/GetMeterArchiveStateResponse.js +78 -0
- package/dist/obis-observer/commands/uplink/GetMeterArchiveStateResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetMeterDateResponse.d.ts +18 -0
- package/dist/obis-observer/commands/uplink/{GetDateResponse.js → GetMeterDateResponse.js} +18 -18
- package/dist/obis-observer/commands/uplink/GetMeterDateResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetMeterIdListResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/GetMeterIdListResponse.js +43 -0
- package/dist/obis-observer/commands/uplink/GetMeterIdListResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetMeterIdResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/GetMeterIdResponse.js +34 -0
- package/dist/obis-observer/commands/uplink/GetMeterIdResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetMeterInfoResponse.d.ts +17 -0
- package/dist/obis-observer/commands/uplink/GetMeterInfoResponse.js +57 -0
- package/dist/obis-observer/commands/uplink/GetMeterInfoResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetMeterProfileIdListResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/GetMeterProfileIdListResponse.js +43 -0
- package/dist/obis-observer/commands/uplink/GetMeterProfileIdListResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/{GetReadoutStateResponse.d.ts → GetMeterReadoutStateResponse.d.ts} +7 -7
- package/dist/obis-observer/commands/uplink/{GetReadoutStateResponse.js → GetMeterReadoutStateResponse.js} +11 -11
- package/dist/obis-observer/commands/uplink/GetMeterReadoutStateResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetObisContentByIdResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/{GetContentByShortNameResponse.js → GetObisContentByIdResponse.js} +11 -11
- package/dist/obis-observer/commands/uplink/GetObisContentByIdResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetObisContentByIdStringResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/{GetContentByShortNameStringResponse.js → GetObisContentByIdStringResponse.js} +12 -14
- package/dist/obis-observer/commands/uplink/GetObisContentByIdStringResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/{GetContentByObisResponse.d.ts → GetObisContentResponse.d.ts} +1 -1
- package/dist/obis-observer/commands/uplink/{GetContentByObisResponse.js → GetObisContentResponse.js} +5 -7
- package/dist/obis-observer/commands/uplink/GetObisContentResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetObisIdListResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/GetObisIdListResponse.js +43 -0
- package/dist/obis-observer/commands/uplink/GetObisIdListResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetObisInfoResponse.d.ts +17 -0
- package/dist/obis-observer/commands/uplink/{GetShortNameInfoResponse.js → GetObisInfoResponse.js} +13 -14
- package/dist/obis-observer/commands/uplink/GetObisInfoResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetObisProfileResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/{GetShortNameProfileResponse.js → GetObisProfileResponse.js} +11 -11
- package/dist/obis-observer/commands/uplink/GetObisProfileResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetObserverCapabilitiesResponse.d.ts +19 -0
- package/dist/obis-observer/commands/uplink/GetObserverCapabilitiesResponse.js +53 -0
- package/dist/obis-observer/commands/uplink/GetObserverCapabilitiesResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/{GetDeviceInfoResponse.d.ts → GetObserverInfoResponse.d.ts} +7 -7
- package/dist/obis-observer/commands/uplink/{GetDeviceInfoResponse.js → GetObserverInfoResponse.js} +13 -15
- package/dist/obis-observer/commands/uplink/GetObserverInfoResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetObserverSingleModeResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/GetObserverSingleModeResponse.js +33 -0
- package/dist/obis-observer/commands/uplink/GetObserverSingleModeResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/GetObserverUptimeResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/GetObserverUptimeResponse.js +44 -0
- package/dist/obis-observer/commands/uplink/GetObserverUptimeResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/ObservationReport.d.ts +3 -3
- package/dist/obis-observer/commands/uplink/ObservationReport.js +15 -16
- package/dist/obis-observer/commands/uplink/ObservationReport.js.map +1 -1
- package/dist/obis-observer/commands/uplink/ObservationReportString.d.ts +3 -3
- package/dist/obis-observer/commands/uplink/ObservationReportString.js +16 -17
- package/dist/obis-observer/commands/uplink/ObservationReportString.js.map +1 -1
- package/dist/obis-observer/commands/uplink/ReadMeterArchiveResponse.d.ts +18 -0
- package/dist/obis-observer/commands/uplink/{ReadArchiveResponse.js → ReadMeterArchiveResponse.js} +22 -23
- package/dist/obis-observer/commands/uplink/ReadMeterArchiveResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/RebootResponse.d.ts +7 -4
- package/dist/obis-observer/commands/uplink/RebootResponse.js +11 -12
- package/dist/obis-observer/commands/uplink/RebootResponse.js.map +1 -1
- package/dist/obis-observer/commands/uplink/RemoveMeterProfileResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/RemoveMeterProfileResponse.js +35 -0
- package/dist/obis-observer/commands/uplink/RemoveMeterProfileResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/RemoveMeterResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/RemoveMeterResponse.js +35 -0
- package/dist/obis-observer/commands/uplink/RemoveMeterResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/RemoveObisProfileResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/RemoveObisProfileResponse.js +35 -0
- package/dist/obis-observer/commands/uplink/RemoveObisProfileResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/SetLorawanActivationMethodResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/SetLorawanActivationMethodResponse.js +35 -0
- package/dist/obis-observer/commands/uplink/SetLorawanActivationMethodResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/SetMeterArchiveProfileResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/SetMeterArchiveProfileResponse.js +43 -0
- package/dist/obis-observer/commands/uplink/SetMeterArchiveProfileResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/SetObisIdResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/SetObisIdResponse.js +35 -0
- package/dist/obis-observer/commands/uplink/SetObisIdResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/SetObserverSingleModeResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/SetObserverSingleModeResponse.js +35 -0
- package/dist/obis-observer/commands/uplink/SetObserverSingleModeResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/SetSerialPortResponse.d.ts +2 -2
- package/dist/obis-observer/commands/uplink/SetSerialPortResponse.js +9 -17
- package/dist/obis-observer/commands/uplink/SetSerialPortResponse.js.map +1 -1
- package/dist/obis-observer/commands/uplink/SetupMeterResponse.d.ts +16 -0
- package/dist/obis-observer/commands/uplink/SetupMeterResponse.js +35 -0
- package/dist/obis-observer/commands/uplink/SetupMeterResponse.js.map +1 -0
- package/dist/obis-observer/commands/uplink/UpdateImageVerifyResponse.d.ts +2 -2
- package/dist/obis-observer/commands/uplink/UpdateImageVerifyResponse.js +8 -16
- package/dist/obis-observer/commands/uplink/UpdateImageVerifyResponse.js.map +1 -1
- package/dist/obis-observer/commands/uplink/UpdateImageWriteResponse.d.ts +2 -2
- package/dist/obis-observer/commands/uplink/UpdateImageWriteResponse.js +8 -16
- package/dist/obis-observer/commands/uplink/UpdateImageWriteResponse.js.map +1 -1
- package/dist/obis-observer/commands/uplink/UpdateRunResponse.d.ts +2 -2
- package/dist/obis-observer/commands/uplink/UpdateRunResponse.js +8 -16
- package/dist/obis-observer/commands/uplink/UpdateRunResponse.js.map +1 -1
- package/dist/obis-observer/commands/uplink/index.d.ts +29 -16
- package/dist/obis-observer/commands/uplink/index.js +29 -16
- package/dist/obis-observer/commands/uplink/index.js.map +1 -1
- package/dist/obis-observer/constants/commandRelations.js +31 -12
- package/dist/obis-observer/constants/commandRelations.js.map +1 -1
- package/dist/obis-observer/constants/index.d.ts +1 -1
- package/dist/obis-observer/constants/index.js +1 -1
- package/dist/obis-observer/constants/index.js.map +1 -1
- package/dist/obis-observer/constants/{shortNames.d.ts → obisIds.d.ts} +4 -4
- package/dist/obis-observer/constants/obisIds.js +228 -0
- package/dist/obis-observer/constants/obisIds.js.map +1 -0
- package/dist/obis-observer/message.d.ts +2 -0
- package/dist/obis-observer/message.js +8 -12
- package/dist/obis-observer/message.js.map +1 -1
- package/dist/utils/getBase64FromBytes.d.ts +2 -0
- package/dist/utils/getBase64FromBytes.js +5 -0
- package/dist/utils/getBase64FromBytes.js.map +1 -0
- package/dist/utils/getBytesFromBase64.d.ts +2 -0
- package/dist/utils/getBytesFromBase64.js +2 -0
- package/dist/utils/getBytesFromBase64.js.map +1 -0
- package/dist/utils/index.d.ts +2 -0
- package/dist/utils/index.js +2 -0
- package/dist/utils/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/obis-observer/commands/downlink/AddShortNameProfile.d.ts +0 -17
- package/dist/obis-observer/commands/downlink/AddShortNameProfile.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetArchiveProfile.js +0 -39
- package/dist/obis-observer/commands/downlink/GetArchiveProfile.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetArchiveState.d.ts +0 -16
- package/dist/obis-observer/commands/downlink/GetArchiveState.js +0 -42
- package/dist/obis-observer/commands/downlink/GetArchiveState.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetContentByObis.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetContentByShortName.d.ts +0 -17
- package/dist/obis-observer/commands/downlink/GetContentByShortName.js +0 -44
- package/dist/obis-observer/commands/downlink/GetContentByShortName.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetDate.js +0 -39
- package/dist/obis-observer/commands/downlink/GetDate.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetDeviceInfo.js +0 -39
- package/dist/obis-observer/commands/downlink/GetDeviceInfo.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetReadoutState.js +0 -39
- package/dist/obis-observer/commands/downlink/GetReadoutState.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetShortNameInfo.d.ts +0 -17
- package/dist/obis-observer/commands/downlink/GetShortNameInfo.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetShortNameProfile.d.ts +0 -16
- package/dist/obis-observer/commands/downlink/GetShortNameProfile.js +0 -45
- package/dist/obis-observer/commands/downlink/GetShortNameProfile.js.map +0 -1
- package/dist/obis-observer/commands/downlink/GetShortNames.d.ts +0 -16
- package/dist/obis-observer/commands/downlink/GetShortNames.js.map +0 -1
- package/dist/obis-observer/commands/downlink/ReadArchive.d.ts +0 -18
- package/dist/obis-observer/commands/downlink/ReadArchive.js +0 -57
- package/dist/obis-observer/commands/downlink/ReadArchive.js.map +0 -1
- package/dist/obis-observer/commands/downlink/RemoveShortNameProfile.d.ts +0 -16
- package/dist/obis-observer/commands/downlink/RemoveShortNameProfile.js +0 -42
- package/dist/obis-observer/commands/downlink/RemoveShortNameProfile.js.map +0 -1
- package/dist/obis-observer/commands/downlink/SetArchiveProfile.d.ts +0 -17
- package/dist/obis-observer/commands/downlink/SetArchiveProfile.js +0 -45
- package/dist/obis-observer/commands/downlink/SetArchiveProfile.js.map +0 -1
- package/dist/obis-observer/commands/downlink/SetShortName.d.ts +0 -17
- package/dist/obis-observer/commands/downlink/SetShortName.js.map +0 -1
- package/dist/obis-observer/commands/uplink/AddShortNameProfileResponse.d.ts +0 -16
- package/dist/obis-observer/commands/uplink/AddShortNameProfileResponse.js +0 -43
- package/dist/obis-observer/commands/uplink/AddShortNameProfileResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetArchiveProfileResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetArchiveStateResponse.d.ts +0 -19
- package/dist/obis-observer/commands/uplink/GetArchiveStateResponse.js +0 -58
- package/dist/obis-observer/commands/uplink/GetArchiveStateResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetContentByObisResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetContentByShortNameResponse.d.ts +0 -16
- package/dist/obis-observer/commands/uplink/GetContentByShortNameResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetContentByShortNameStringResponse.d.ts +0 -16
- package/dist/obis-observer/commands/uplink/GetContentByShortNameStringResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetDateResponse.d.ts +0 -18
- package/dist/obis-observer/commands/uplink/GetDateResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetDeviceInfoResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetReadoutStateResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetShortNameInfoResponse.d.ts +0 -17
- package/dist/obis-observer/commands/uplink/GetShortNameInfoResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetShortNameProfileResponse.d.ts +0 -16
- package/dist/obis-observer/commands/uplink/GetShortNameProfileResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/GetShortNamesResponse.d.ts +0 -16
- package/dist/obis-observer/commands/uplink/GetShortNamesResponse.js +0 -45
- package/dist/obis-observer/commands/uplink/GetShortNamesResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/ReadArchiveResponse.d.ts +0 -18
- package/dist/obis-observer/commands/uplink/ReadArchiveResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/RemoveShortNameProfileResponse.d.ts +0 -16
- package/dist/obis-observer/commands/uplink/RemoveShortNameProfileResponse.js +0 -43
- package/dist/obis-observer/commands/uplink/RemoveShortNameProfileResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/SetArchiveProfileResponse.d.ts +0 -16
- package/dist/obis-observer/commands/uplink/SetArchiveProfileResponse.js +0 -51
- package/dist/obis-observer/commands/uplink/SetArchiveProfileResponse.js.map +0 -1
- package/dist/obis-observer/commands/uplink/SetShortNameResponse.d.ts +0 -16
- package/dist/obis-observer/commands/uplink/SetShortNameResponse.js +0 -43
- package/dist/obis-observer/commands/uplink/SetShortNameResponse.js.map +0 -1
- package/dist/obis-observer/constants/shortNames.js +0 -228
- package/dist/obis-observer/constants/shortNames.js.map +0 -1
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import Command from '../../Command.js';
|
|
2
|
+
import { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
|
+
const COMMAND_ID = 0x46;
|
|
5
|
+
const COMMAND_SIZE = REQUEST_ID_SIZE + 1;
|
|
6
|
+
const examples = [
|
|
7
|
+
{
|
|
8
|
+
name: 'remove obis profile for obisId 28 in meter profile 4',
|
|
9
|
+
parameters: {
|
|
10
|
+
requestId: 5,
|
|
11
|
+
meterProfileId: 4,
|
|
12
|
+
obisId: 28
|
|
13
|
+
},
|
|
14
|
+
hex: { header: '46 03', body: '05 04 1c' }
|
|
15
|
+
}
|
|
16
|
+
];
|
|
17
|
+
class RemoveObisProfile extends Command {
|
|
18
|
+
constructor(parameters) {
|
|
19
|
+
super();
|
|
20
|
+
this.parameters = parameters;
|
|
21
|
+
this.size = COMMAND_SIZE;
|
|
22
|
+
}
|
|
23
|
+
static fromBytes([requestId, meterProfileId, obisId]) {
|
|
24
|
+
return new RemoveObisProfile({ requestId, meterProfileId, obisId });
|
|
25
|
+
}
|
|
26
|
+
toBytes() {
|
|
27
|
+
return Command.toBytes(COMMAND_ID, new Uint8Array([this.parameters.requestId, this.parameters.meterProfileId, this.parameters.obisId]));
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
RemoveObisProfile.id = COMMAND_ID;
|
|
31
|
+
RemoveObisProfile.directionType = DOWNLINK;
|
|
32
|
+
RemoveObisProfile.examples = examples;
|
|
33
|
+
RemoveObisProfile.hasParameters = true;
|
|
34
|
+
export default RemoveObisProfile;
|
|
35
|
+
//# sourceMappingURL=RemoveObisProfile.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RemoveObisProfile.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/RemoveObisProfile.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AAYvD,MAAM,UAAU,GAAG,IAAI,CAAC;AACxB,MAAM,YAAY,GAAG,eAAe,GAAG,CAAC,CAAC;AAEzC,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,sDAAsD;QAC5D,UAAU,EAAE;YACR,SAAS,EAAE,CAAC;YACZ,cAAc,EAAE,CAAC;YACjB,MAAM,EAAE,EAAE;SACb;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,UAAU,EAAC;KAC3C;CACJ,CAAC;AAwBF,MAAM,iBAAkB,SAAQ,OAAO;IACnC,YAAqB,UAAwC;QACzD,KAAK,EAAE,CAAC;QADS,eAAU,GAAV,UAAU,CAA8B;QAGzD,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;IAC7B,CAAC;IAaD,MAAM,CAAC,SAAS,CAAG,CAAC,SAAS,EAAE,cAAc,EAAE,MAAM,CAAa;QAC9D,OAAO,IAAI,iBAAiB,CAAC,EAAC,SAAS,EAAE,cAAc,EAAE,MAAM,EAAC,CAAC,CAAC;IACtE,CAAC;IAGD,OAAO;QACH,OAAO,OAAO,CAAC,OAAO,CAClB,UAAU,EACV,IAAI,UAAU,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,SAAS,EAAE,IAAI,CAAC,UAAU,CAAC,cAAc,EAAE,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CACtG,CAAC;IACN,CAAC;;AApBe,oBAAE,GAAG,UAAU,CAAC;AAEhB,+BAAa,GAAG,QAAQ,CAAC;AAEzB,0BAAQ,GAAG,QAAQ,CAAC;AAEpB,+BAAa,GAAG,IAAI,CAAC;AAkBzC,eAAe,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import Command, { TCommandExampleList } from '../../Command.js';
|
|
2
|
+
import { ICommandParameters } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
interface ISetLorawanActivationMethodParameters extends ICommandParameters {
|
|
4
|
+
activationMethod: number;
|
|
5
|
+
}
|
|
6
|
+
declare class SetLorawanActivationMethod extends Command {
|
|
7
|
+
parameters: ISetLorawanActivationMethodParameters;
|
|
8
|
+
constructor(parameters: ISetLorawanActivationMethodParameters);
|
|
9
|
+
static readonly id = 23;
|
|
10
|
+
static readonly directionType = 1;
|
|
11
|
+
static readonly examples: TCommandExampleList;
|
|
12
|
+
static readonly hasParameters = true;
|
|
13
|
+
static fromBytes([requestId, activationMethod]: Uint8Array): SetLorawanActivationMethod;
|
|
14
|
+
toBytes(): Uint8Array;
|
|
15
|
+
}
|
|
16
|
+
export default SetLorawanActivationMethod;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import Command from '../../Command.js';
|
|
2
|
+
import { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
|
+
const COMMAND_ID = 0x17;
|
|
5
|
+
const COMMAND_SIZE = REQUEST_ID_SIZE + 1;
|
|
6
|
+
const examples = [
|
|
7
|
+
{
|
|
8
|
+
name: 'set lorawan activation mode to ABP',
|
|
9
|
+
parameters: {
|
|
10
|
+
requestId: 3,
|
|
11
|
+
activationMethod: 1
|
|
12
|
+
},
|
|
13
|
+
hex: { header: '17 02', body: '03 01' }
|
|
14
|
+
}
|
|
15
|
+
];
|
|
16
|
+
class SetLorawanActivationMethod extends Command {
|
|
17
|
+
constructor(parameters) {
|
|
18
|
+
super();
|
|
19
|
+
this.parameters = parameters;
|
|
20
|
+
this.size = COMMAND_SIZE;
|
|
21
|
+
}
|
|
22
|
+
static fromBytes([requestId, activationMethod]) {
|
|
23
|
+
return new SetLorawanActivationMethod({ requestId, activationMethod });
|
|
24
|
+
}
|
|
25
|
+
toBytes() {
|
|
26
|
+
return Command.toBytes(COMMAND_ID, new Uint8Array([this.parameters.requestId, this.parameters.activationMethod]));
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
SetLorawanActivationMethod.id = COMMAND_ID;
|
|
30
|
+
SetLorawanActivationMethod.directionType = DOWNLINK;
|
|
31
|
+
SetLorawanActivationMethod.examples = examples;
|
|
32
|
+
SetLorawanActivationMethod.hasParameters = true;
|
|
33
|
+
export default SetLorawanActivationMethod;
|
|
34
|
+
//# sourceMappingURL=SetLorawanActivationMethod.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SetLorawanActivationMethod.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/SetLorawanActivationMethod.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AAWvD,MAAM,UAAU,GAAG,IAAI,CAAC;AACxB,MAAM,YAAY,GAAG,eAAe,GAAG,CAAC,CAAC;AAEzC,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,oCAAoC;QAC1C,UAAU,EAAE;YACR,SAAS,EAAE,CAAC;YACZ,gBAAgB,EAAE,CAAC;SACtB;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAC;KACxC;CACJ,CAAC;AAuBF,MAAM,0BAA2B,SAAQ,OAAO;IAC5C,YAAqB,UAAiD;QAClE,KAAK,EAAE,CAAC;QADS,eAAU,GAAV,UAAU,CAAuC;QAGlE,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;IAC7B,CAAC;IAaD,MAAM,CAAC,SAAS,CAAG,CAAC,SAAS,EAAE,gBAAgB,CAAa;QACxD,OAAO,IAAI,0BAA0B,CAAC,EAAC,SAAS,EAAE,gBAAgB,EAAC,CAAC,CAAC;IACzE,CAAC;IAGD,OAAO;QACH,OAAO,OAAO,CAAC,OAAO,CAClB,UAAU,EACV,IAAI,UAAU,CACV,CAAC,IAAI,CAAC,UAAU,CAAC,SAAS,EAAE,IAAI,CAAC,UAAU,CAAC,gBAAgB,CAAC,CAChE,CACJ,CAAC;IACN,CAAC;;AAtBe,6BAAE,GAAG,UAAU,CAAC;AAEhB,wCAAa,GAAG,QAAQ,CAAC;AAEzB,mCAAQ,GAAG,QAAQ,CAAC;AAEpB,wCAAa,GAAG,IAAI,CAAC;AAoBzC,eAAe,0BAA0B,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import Command, { TCommandExampleList } from '../../Command.js';
|
|
2
|
+
import { ICommandParameters } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
interface ISetMeterArchiveProfileParameters extends ICommandParameters {
|
|
4
|
+
meterProfileId: number;
|
|
5
|
+
archive1Period: number;
|
|
6
|
+
archive2Period: number;
|
|
7
|
+
}
|
|
8
|
+
declare class SetMeterArchiveProfile extends Command {
|
|
9
|
+
parameters: ISetMeterArchiveProfileParameters;
|
|
10
|
+
constructor(parameters: ISetMeterArchiveProfileParameters);
|
|
11
|
+
static readonly id = 104;
|
|
12
|
+
static readonly directionType = 1;
|
|
13
|
+
static readonly examples: TCommandExampleList;
|
|
14
|
+
static readonly hasParameters = true;
|
|
15
|
+
static fromBytes(data: Uint8Array): SetMeterArchiveProfile;
|
|
16
|
+
toBytes(): Uint8Array;
|
|
17
|
+
}
|
|
18
|
+
export default SetMeterArchiveProfile;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import Command from '../../Command.js';
|
|
2
|
+
import CommandBinaryBuffer, { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
|
+
const COMMAND_ID = 0x68;
|
|
5
|
+
const COMMAND_SIZE = REQUEST_ID_SIZE + 1 + 2 + 2;
|
|
6
|
+
const examples = [
|
|
7
|
+
{
|
|
8
|
+
name: 'set archive settings in meter profile 8',
|
|
9
|
+
parameters: {
|
|
10
|
+
requestId: 68,
|
|
11
|
+
meterProfileId: 8,
|
|
12
|
+
archive1Period: 2880,
|
|
13
|
+
archive2Period: 30
|
|
14
|
+
},
|
|
15
|
+
hex: { header: '68 06', body: '44 08 0b 40 00 1e' }
|
|
16
|
+
}
|
|
17
|
+
];
|
|
18
|
+
class SetMeterArchiveProfile extends Command {
|
|
19
|
+
constructor(parameters) {
|
|
20
|
+
super();
|
|
21
|
+
this.parameters = parameters;
|
|
22
|
+
this.size = COMMAND_SIZE;
|
|
23
|
+
}
|
|
24
|
+
static fromBytes(data) {
|
|
25
|
+
const buffer = new CommandBinaryBuffer(data);
|
|
26
|
+
return new SetMeterArchiveProfile({
|
|
27
|
+
requestId: buffer.getUint8(),
|
|
28
|
+
meterProfileId: buffer.getUint8(),
|
|
29
|
+
archive1Period: buffer.getUint16(),
|
|
30
|
+
archive2Period: buffer.getUint16()
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
toBytes() {
|
|
34
|
+
const buffer = new CommandBinaryBuffer(COMMAND_SIZE);
|
|
35
|
+
const { requestId, meterProfileId, archive1Period, archive2Period } = this.parameters;
|
|
36
|
+
buffer.setUint8(requestId);
|
|
37
|
+
buffer.setUint8(meterProfileId);
|
|
38
|
+
buffer.setUint16(archive1Period);
|
|
39
|
+
buffer.setUint16(archive2Period);
|
|
40
|
+
return Command.toBytes(COMMAND_ID, buffer.toUint8Array());
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
SetMeterArchiveProfile.id = COMMAND_ID;
|
|
44
|
+
SetMeterArchiveProfile.directionType = DOWNLINK;
|
|
45
|
+
SetMeterArchiveProfile.examples = examples;
|
|
46
|
+
SetMeterArchiveProfile.hasParameters = true;
|
|
47
|
+
export default SetMeterArchiveProfile;
|
|
48
|
+
//# sourceMappingURL=SetMeterArchiveProfile.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SetMeterArchiveProfile.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/SetMeterArchiveProfile.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,mBAAmB,EAAE,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACtG,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AAavD,MAAM,UAAU,GAAG,IAAI,CAAC;AACxB,MAAM,YAAY,GAAG,eAAe,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AAEjD,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,yCAAyC;QAC/C,UAAU,EAAE;YACR,SAAS,EAAE,EAAE;YACb,cAAc,EAAE,CAAC;YACjB,cAAc,EAAE,IAAI;YACpB,cAAc,EAAE,EAAE;SACrB;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,mBAAmB,EAAC;KACpD;CACJ,CAAC;AAwBF,MAAM,sBAAuB,SAAQ,OAAO;IACxC,YAAqB,UAA6C;QAC9D,KAAK,EAAE,CAAC;QADS,eAAU,GAAV,UAAU,CAAmC;QAG9D,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;IAC7B,CAAC;IAaD,MAAM,CAAC,SAAS,CAAG,IAAgB;QAC/B,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,IAAI,CAAC,CAAC;QAE7C,OAAO,IAAI,sBAAsB,CAAC;YAC9B,SAAS,EAAE,MAAM,CAAC,QAAQ,EAAE;YAC5B,cAAc,EAAE,MAAM,CAAC,QAAQ,EAAE;YACjC,cAAc,EAAE,MAAM,CAAC,SAAS,EAAE;YAClC,cAAc,EAAE,MAAM,CAAC,SAAS,EAAE;SACrC,CAAC,CAAC;IACP,CAAC;IAGD,OAAO;QACH,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,YAAY,CAAC,CAAC;QACrD,MAAM,EAAC,SAAS,EAAE,cAAc,EAAE,cAAc,EAAE,cAAc,EAAC,GAAG,IAAI,CAAC,UAAU,CAAC;QAEpF,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;QAC3B,MAAM,CAAC,QAAQ,CAAC,cAAc,CAAC,CAAC;QAChC,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC;QACjC,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC;QAEjC,OAAO,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,MAAM,CAAC,YAAY,EAAE,CAAC,CAAC;IAC9D,CAAC;;AAhCe,yBAAE,GAAG,UAAU,CAAC;AAEhB,oCAAa,GAAG,QAAQ,CAAC;AAEzB,+BAAQ,GAAG,QAAQ,CAAC;AAEpB,oCAAa,GAAG,IAAI,CAAC;AA8BzC,eAAe,sBAAsB,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import Command, { TCommandExampleList } from '../../Command.js';
|
|
2
|
+
import { ICommandParameters, IObis } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
interface ISetObisIdParameters extends ICommandParameters {
|
|
4
|
+
meterProfileId: number;
|
|
5
|
+
obisId: number;
|
|
6
|
+
obis: IObis;
|
|
7
|
+
}
|
|
8
|
+
declare class SetObisId extends Command {
|
|
9
|
+
parameters: ISetObisIdParameters;
|
|
10
|
+
constructor(parameters: ISetObisIdParameters);
|
|
11
|
+
static readonly id = 66;
|
|
12
|
+
static readonly directionType = 1;
|
|
13
|
+
static readonly examples: TCommandExampleList;
|
|
14
|
+
static readonly hasParameters = true;
|
|
15
|
+
static fromBytes(data: Uint8Array): SetObisId;
|
|
16
|
+
toBytes(): Uint8Array;
|
|
17
|
+
}
|
|
18
|
+
export default SetObisId;
|
|
@@ -1,31 +1,35 @@
|
|
|
1
1
|
import Command from '../../Command.js';
|
|
2
2
|
import CommandBinaryBuffer, { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
3
|
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
|
-
const COMMAND_ID =
|
|
4
|
+
const COMMAND_ID = 0x42;
|
|
5
5
|
const examples = [
|
|
6
6
|
{
|
|
7
|
-
name: '
|
|
7
|
+
name: 'set obisId 44 for OBIS code 0.9.1 in meter profile 2',
|
|
8
8
|
parameters: {
|
|
9
9
|
requestId: 3,
|
|
10
|
+
meterProfileId: 2,
|
|
11
|
+
obisId: 44,
|
|
10
12
|
obis: {
|
|
11
13
|
c: 0,
|
|
12
14
|
d: 9,
|
|
13
15
|
e: 1
|
|
14
16
|
}
|
|
15
17
|
},
|
|
16
|
-
hex: { header: '
|
|
18
|
+
hex: { header: '42 07', body: '03 02 2c 02 00 09 01' }
|
|
17
19
|
}
|
|
18
20
|
];
|
|
19
|
-
class
|
|
21
|
+
class SetObisId extends Command {
|
|
20
22
|
constructor(parameters) {
|
|
21
23
|
super();
|
|
22
24
|
this.parameters = parameters;
|
|
23
|
-
this.size = REQUEST_ID_SIZE + CommandBinaryBuffer.getObisSize(parameters.obis);
|
|
25
|
+
this.size = REQUEST_ID_SIZE + 1 + 1 + CommandBinaryBuffer.getObisSize(parameters.obis);
|
|
24
26
|
}
|
|
25
27
|
static fromBytes(data) {
|
|
26
28
|
const buffer = new CommandBinaryBuffer(data);
|
|
27
|
-
return new
|
|
29
|
+
return new SetObisId({
|
|
28
30
|
requestId: buffer.getUint8(),
|
|
31
|
+
meterProfileId: buffer.getUint8(),
|
|
32
|
+
obisId: buffer.getUint8(),
|
|
29
33
|
obis: buffer.getObis()
|
|
30
34
|
});
|
|
31
35
|
}
|
|
@@ -33,16 +37,18 @@ class GetShortNames extends Command {
|
|
|
33
37
|
if (typeof this.size !== 'number') {
|
|
34
38
|
throw new Error('unknown or invalid size');
|
|
35
39
|
}
|
|
36
|
-
const { requestId, obis } = this.parameters;
|
|
37
40
|
const buffer = new CommandBinaryBuffer(this.size);
|
|
41
|
+
const { requestId, meterProfileId, obisId, obis } = this.parameters;
|
|
38
42
|
buffer.setUint8(requestId);
|
|
43
|
+
buffer.setUint8(meterProfileId);
|
|
44
|
+
buffer.setUint8(obisId);
|
|
39
45
|
buffer.setObis(obis);
|
|
40
46
|
return Command.toBytes(COMMAND_ID, buffer.toUint8Array());
|
|
41
47
|
}
|
|
42
48
|
}
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
export default
|
|
48
|
-
//# sourceMappingURL=
|
|
49
|
+
SetObisId.id = COMMAND_ID;
|
|
50
|
+
SetObisId.directionType = DOWNLINK;
|
|
51
|
+
SetObisId.examples = examples;
|
|
52
|
+
SetObisId.hasParameters = true;
|
|
53
|
+
export default SetObisId;
|
|
54
|
+
//# sourceMappingURL=SetObisId.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SetObisId.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/SetObisId.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,mBAAmB,EAAE,EAAC,eAAe,EAA4B,MAAM,8BAA8B,CAAC;AAC7G,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AAavD,MAAM,UAAU,GAAG,IAAI,CAAC;AAExB,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,sDAAsD;QAC5D,UAAU,EAAE;YACR,SAAS,EAAE,CAAC;YACZ,cAAc,EAAE,CAAC;YACjB,MAAM,EAAE,EAAE;YACV,IAAI,EAAE;gBACF,CAAC,EAAE,CAAC;gBACJ,CAAC,EAAE,CAAC;gBACJ,CAAC,EAAE,CAAC;aACP;SACJ;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,sBAAsB,EAAC;KACvD;CACJ,CAAC;AA2BF,MAAM,SAAU,SAAQ,OAAO;IAC3B,YAAqB,UAAgC;QACjD,KAAK,EAAE,CAAC;QADS,eAAU,GAAV,UAAU,CAAsB;QAIjD,IAAI,CAAC,IAAI,GAAG,eAAe,GAAG,CAAC,GAAG,CAAC,GAAG,mBAAmB,CAAC,WAAW,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;IAC3F,CAAC;IAaD,MAAM,CAAC,SAAS,CAAG,IAAgB;QAC/B,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,IAAI,CAAC,CAAC;QAE7C,OAAO,IAAI,SAAS,CAAC;YACjB,SAAS,EAAE,MAAM,CAAC,QAAQ,EAAE;YAC5B,cAAc,EAAE,MAAM,CAAC,QAAQ,EAAE;YACjC,MAAM,EAAE,MAAM,CAAC,QAAQ,EAAE;YACzB,IAAI,EAAE,MAAM,CAAC,OAAO,EAAE;SACzB,CAAC,CAAC;IACP,CAAC;IAGD,OAAO;QACH,IAAK,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAG;YACjC,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;SAC9C;QAED,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAClD,MAAM,EAAC,SAAS,EAAE,cAAc,EAAE,MAAM,EAAE,IAAI,EAAC,GAAG,IAAI,CAAC,UAAU,CAAC;QAElE,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;QAC3B,MAAM,CAAC,QAAQ,CAAC,cAAc,CAAC,CAAC;QAChC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;QACxB,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QAErB,OAAO,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,MAAM,CAAC,YAAY,EAAE,CAAC,CAAC;IAC9D,CAAC;;AApCe,YAAE,GAAG,UAAU,CAAC;AAEhB,uBAAa,GAAG,QAAQ,CAAC;AAEzB,kBAAQ,GAAG,QAAQ,CAAC;AAEpB,uBAAa,GAAG,IAAI,CAAC;AAkCzC,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import Command, { TCommandExampleList } from '../../Command.js';
|
|
2
|
+
import { ICommandParameters } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
interface ISetObserverSingleModeParameters extends ICommandParameters {
|
|
4
|
+
singleMode: boolean;
|
|
5
|
+
}
|
|
6
|
+
declare class SetObserverSingleMode extends Command {
|
|
7
|
+
parameters: ISetObserverSingleModeParameters;
|
|
8
|
+
constructor(parameters: ISetObserverSingleModeParameters);
|
|
9
|
+
static readonly id = 11;
|
|
10
|
+
static readonly directionType = 1;
|
|
11
|
+
static readonly examples: TCommandExampleList;
|
|
12
|
+
static readonly hasParameters = true;
|
|
13
|
+
static fromBytes([requestId, singleMode]: Uint8Array): SetObserverSingleMode;
|
|
14
|
+
toBytes(): Uint8Array;
|
|
15
|
+
}
|
|
16
|
+
export default SetObserverSingleMode;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import Command from '../../Command.js';
|
|
2
|
+
import { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
|
+
const COMMAND_ID = 0x0b;
|
|
5
|
+
const COMMAND_SIZE = REQUEST_ID_SIZE + 1;
|
|
6
|
+
const examples = [
|
|
7
|
+
{
|
|
8
|
+
name: 'set observer single mode',
|
|
9
|
+
parameters: {
|
|
10
|
+
requestId: 3,
|
|
11
|
+
singleMode: true
|
|
12
|
+
},
|
|
13
|
+
hex: { header: '0b 02', body: '03 01' }
|
|
14
|
+
}
|
|
15
|
+
];
|
|
16
|
+
class SetObserverSingleMode extends Command {
|
|
17
|
+
constructor(parameters) {
|
|
18
|
+
super();
|
|
19
|
+
this.parameters = parameters;
|
|
20
|
+
this.size = COMMAND_SIZE;
|
|
21
|
+
}
|
|
22
|
+
static fromBytes([requestId, singleMode]) {
|
|
23
|
+
return new SetObserverSingleMode({ requestId, singleMode: singleMode !== 0 });
|
|
24
|
+
}
|
|
25
|
+
toBytes() {
|
|
26
|
+
return Command.toBytes(COMMAND_ID, new Uint8Array([this.parameters.requestId, this.parameters.singleMode ? 1 : 0]));
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
SetObserverSingleMode.id = COMMAND_ID;
|
|
30
|
+
SetObserverSingleMode.directionType = DOWNLINK;
|
|
31
|
+
SetObserverSingleMode.examples = examples;
|
|
32
|
+
SetObserverSingleMode.hasParameters = true;
|
|
33
|
+
export default SetObserverSingleMode;
|
|
34
|
+
//# sourceMappingURL=SetObserverSingleMode.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SetObserverSingleMode.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/SetObserverSingleMode.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AAWvD,MAAM,UAAU,GAAG,IAAI,CAAC;AACxB,MAAM,YAAY,GAAG,eAAe,GAAG,CAAC,CAAC;AAEzC,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,0BAA0B;QAChC,UAAU,EAAE;YACR,SAAS,EAAE,CAAC;YACZ,UAAU,EAAE,IAAI;SACnB;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAC;KACxC;CACJ,CAAC;AAuBF,MAAM,qBAAsB,SAAQ,OAAO;IACvC,YAAqB,UAA4C;QAC7D,KAAK,EAAE,CAAC;QADS,eAAU,GAAV,UAAU,CAAkC;QAG7D,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;IAC7B,CAAC;IAaD,MAAM,CAAC,SAAS,CAAG,CAAC,SAAS,EAAE,UAAU,CAAa;QAClD,OAAO,IAAI,qBAAqB,CAAC,EAAC,SAAS,EAAE,UAAU,EAAE,UAAU,KAAK,CAAC,EAAC,CAAC,CAAC;IAChF,CAAC;IAGD,OAAO;QACH,OAAO,OAAO,CAAC,OAAO,CAClB,UAAU,EACV,IAAI,UAAU,CACV,CAAC,IAAI,CAAC,UAAU,CAAC,SAAS,EAAE,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAClE,CACJ,CAAC;IACN,CAAC;;AAtBe,wBAAE,GAAG,UAAU,CAAC;AAEhB,mCAAa,GAAG,QAAQ,CAAC;AAEzB,8BAAQ,GAAG,QAAQ,CAAC;AAEpB,mCAAa,GAAG,IAAI,CAAC;AAoBzC,eAAe,qBAAqB,CAAC"}
|
|
@@ -9,7 +9,7 @@ interface ISetSerialPortParameters extends ICommandParameters {
|
|
|
9
9
|
declare class SetSerialPort extends Command {
|
|
10
10
|
parameters: ISetSerialPortParameters;
|
|
11
11
|
constructor(parameters: ISetSerialPortParameters);
|
|
12
|
-
static readonly id =
|
|
12
|
+
static readonly id = 9;
|
|
13
13
|
static readonly directionType = 1;
|
|
14
14
|
static readonly examples: TCommandExampleList;
|
|
15
15
|
static readonly hasParameters = true;
|
|
@@ -2,7 +2,7 @@ import Command from '../../Command.js';
|
|
|
2
2
|
import CommandBinaryBuffer, { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
3
|
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
4
|
import * as parityTypes from '../../constants/parityTypes.js';
|
|
5
|
-
const COMMAND_ID =
|
|
5
|
+
const COMMAND_ID = 0x09;
|
|
6
6
|
const COMMAND_SIZE = REQUEST_ID_SIZE + 3;
|
|
7
7
|
const examples = [
|
|
8
8
|
{
|
|
@@ -14,7 +14,7 @@ const examples = [
|
|
|
14
14
|
parity: parityTypes.ODD,
|
|
15
15
|
fixed: true
|
|
16
16
|
},
|
|
17
|
-
hex: { header: '
|
|
17
|
+
hex: { header: '09 04', body: '34 05 08 05' }
|
|
18
18
|
},
|
|
19
19
|
{
|
|
20
20
|
name: 'set settings: 115200, 7, none',
|
|
@@ -25,7 +25,7 @@ const examples = [
|
|
|
25
25
|
parity: parityTypes.NONE,
|
|
26
26
|
fixed: false
|
|
27
27
|
},
|
|
28
|
-
hex: { header: '
|
|
28
|
+
hex: { header: '09 04', body: '34 0c 07 00' }
|
|
29
29
|
}
|
|
30
30
|
];
|
|
31
31
|
class SetSerialPort extends Command {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SetSerialPort.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/SetSerialPort.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,mBAAmB,EAAE,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACtG,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AACvD,OAAO,KAAK,WAAW,MAAM,gCAAgC,CAAC;AAc9D,MAAM,UAAU,GAAG,IAAI,CAAC;AACxB,MAAM,YAAY,GAAG,eAAe,GAAG,CAAC,CAAC;AAEzC,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,kCAAkC;QACxC,UAAU,EAAE;YACR,SAAS,EAAE,EAAE;YACb,QAAQ,EAAE,CAAC;YACX,QAAQ,EAAE,CAAC;YACX,MAAM,EAAE,WAAW,CAAC,GAAG;YACvB,KAAK,EAAE,IAAI;SACd;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,
|
|
1
|
+
{"version":3,"file":"SetSerialPort.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/SetSerialPort.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,mBAAmB,EAAE,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACtG,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AACvD,OAAO,KAAK,WAAW,MAAM,gCAAgC,CAAC;AAc9D,MAAM,UAAU,GAAG,IAAI,CAAC;AACxB,MAAM,YAAY,GAAG,eAAe,GAAG,CAAC,CAAC;AAEzC,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,kCAAkC;QACxC,UAAU,EAAE;YACR,SAAS,EAAE,EAAE;YACb,QAAQ,EAAE,CAAC;YACX,QAAQ,EAAE,CAAC;YACX,MAAM,EAAE,WAAW,CAAC,GAAG;YACvB,KAAK,EAAE,IAAI;SACd;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,aAAa,EAAC;KAC9C;IACD;QACI,IAAI,EAAE,+BAA+B;QACrC,UAAU,EAAE;YACR,SAAS,EAAE,EAAE;YACb,QAAQ,EAAE,EAAE;YACZ,QAAQ,EAAE,CAAC;YACX,MAAM,EAAE,WAAW,CAAC,IAAI;YACxB,KAAK,EAAE,KAAK;SACf;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,aAAa,EAAC;KAC9C;CACJ,CAAC;AA0BF,MAAM,aAAc,SAAQ,OAAO;IAC/B,YAAqB,UAAoC;QACrD,KAAK,EAAE,CAAC;QADS,eAAU,GAAV,UAAU,CAA0B;QAGrD,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;IAC7B,CAAC;IAaD,MAAM,CAAC,SAAS,CAAG,IAAgB;QAC/B,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,IAAI,CAAC,CAAC;QAE7C,OAAO,IAAI,aAAa,CAAC;YACrB,SAAS,EAAE,MAAM,CAAC,QAAQ,EAAE;YAC5B,QAAQ,EAAE,MAAM,CAAC,QAAQ,EAAE;YAC3B,QAAQ,EAAE,MAAM,CAAC,QAAQ,EAAE;YAE3B,GAAG,MAAM,CAAC,kBAAkB,EAAE;SACjC,CAAC,CAAC;IACP,CAAC;IAGD,OAAO;QACH,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,YAAY,CAAC,CAAC;QACrD,MAAM,EACF,SAAS,EACT,QAAQ,EACR,QAAQ,EACR,MAAM,EACN,KAAK,EACR,GAAG,IAAI,CAAC,UAAU,CAAC;QAEpB,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;QAC3B,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QAC1B,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QAC1B,MAAM,CAAC,kBAAkB,CAAC,EAAC,MAAM,EAAE,KAAK,EAAC,CAAC,CAAC;QAE3C,OAAO,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,MAAM,CAAC,YAAY,EAAE,CAAC,CAAC;IAC9D,CAAC;;AAvCe,gBAAE,GAAG,UAAU,CAAC;AAEhB,2BAAa,GAAG,QAAQ,CAAC;AAEzB,sBAAQ,GAAG,QAAQ,CAAC;AAEpB,2BAAa,GAAG,IAAI,CAAC;AAqCzC,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import Command, { TCommandExampleList } from '../../Command.js';
|
|
2
|
+
import { ICommandParameters } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
interface ISetupMeterParameters extends ICommandParameters {
|
|
4
|
+
meterId: number;
|
|
5
|
+
meterProfileId: number;
|
|
6
|
+
address: string;
|
|
7
|
+
}
|
|
8
|
+
declare class SetupMeter extends Command {
|
|
9
|
+
parameters: ISetupMeterParameters;
|
|
10
|
+
constructor(parameters: ISetupMeterParameters);
|
|
11
|
+
static readonly id = 112;
|
|
12
|
+
static readonly directionType = 1;
|
|
13
|
+
static readonly examples: TCommandExampleList;
|
|
14
|
+
static readonly hasParameters = true;
|
|
15
|
+
static fromBytes(data: Uint8Array): SetupMeter;
|
|
16
|
+
toBytes(): Uint8Array;
|
|
17
|
+
}
|
|
18
|
+
export default SetupMeter;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import Command from '../../Command.js';
|
|
2
|
+
import CommandBinaryBuffer, { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
|
+
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
|
+
const COMMAND_ID = 0x70;
|
|
5
|
+
const examples = [
|
|
6
|
+
{
|
|
7
|
+
name: 'setup meter with Id 20',
|
|
8
|
+
parameters: {
|
|
9
|
+
requestId: 3,
|
|
10
|
+
meterId: 20,
|
|
11
|
+
meterProfileId: 17,
|
|
12
|
+
address: 'ma2375'
|
|
13
|
+
},
|
|
14
|
+
hex: { header: '70 0a', body: '03 14 11 06 6d 61 32 33 37 35' }
|
|
15
|
+
}
|
|
16
|
+
];
|
|
17
|
+
class SetupMeter extends Command {
|
|
18
|
+
constructor(parameters) {
|
|
19
|
+
super();
|
|
20
|
+
this.parameters = parameters;
|
|
21
|
+
this.size = REQUEST_ID_SIZE + 3 + parameters.address.length;
|
|
22
|
+
}
|
|
23
|
+
static fromBytes(data) {
|
|
24
|
+
const buffer = new CommandBinaryBuffer(data);
|
|
25
|
+
return new SetupMeter({
|
|
26
|
+
requestId: buffer.getUint8(),
|
|
27
|
+
meterId: buffer.getUint8(),
|
|
28
|
+
meterProfileId: buffer.getUint8(),
|
|
29
|
+
address: buffer.getString()
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
toBytes() {
|
|
33
|
+
if (typeof this.size !== 'number') {
|
|
34
|
+
throw new Error('unknown or invalid size');
|
|
35
|
+
}
|
|
36
|
+
const buffer = new CommandBinaryBuffer(this.size);
|
|
37
|
+
const { requestId, meterId, meterProfileId, address } = this.parameters;
|
|
38
|
+
buffer.setUint8(requestId);
|
|
39
|
+
buffer.setUint8(meterId);
|
|
40
|
+
buffer.setUint8(meterProfileId);
|
|
41
|
+
buffer.setString(address);
|
|
42
|
+
return Command.toBytes(COMMAND_ID, buffer.toUint8Array());
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
SetupMeter.id = COMMAND_ID;
|
|
46
|
+
SetupMeter.directionType = DOWNLINK;
|
|
47
|
+
SetupMeter.examples = examples;
|
|
48
|
+
SetupMeter.hasParameters = true;
|
|
49
|
+
export default SetupMeter;
|
|
50
|
+
//# sourceMappingURL=SetupMeter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SetupMeter.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/SetupMeter.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,mBAAmB,EAAE,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACtG,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AAavD,MAAM,UAAU,GAAG,IAAI,CAAC;AAExB,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,wBAAwB;QAC9B,UAAU,EAAE;YACR,SAAS,EAAE,CAAC;YACZ,OAAO,EAAE,EAAE;YACX,cAAc,EAAE,EAAE;YAClB,OAAO,EAAE,QAAQ;SACpB;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,+BAA+B,EAAC;KAChE;CACJ,CAAC;AAyBF,MAAM,UAAW,SAAQ,OAAO;IAC5B,YAAqB,UAAiC;QAClD,KAAK,EAAE,CAAC;QADS,eAAU,GAAV,UAAU,CAAuB;QAGlD,IAAI,CAAC,IAAI,GAAG,eAAe,GAAG,CAAC,GAAG,UAAU,CAAC,OAAO,CAAC,MAAM,CAAC;IAChE,CAAC;IAaD,MAAM,CAAC,SAAS,CAAG,IAAgB;QAC/B,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,IAAI,CAAC,CAAC;QAE7C,OAAO,IAAI,UAAU,CAAC;YAClB,SAAS,EAAE,MAAM,CAAC,QAAQ,EAAE;YAC5B,OAAO,EAAE,MAAM,CAAC,QAAQ,EAAE;YAC1B,cAAc,EAAE,MAAM,CAAC,QAAQ,EAAE;YACjC,OAAO,EAAE,MAAM,CAAC,SAAS,EAAE;SAC9B,CAAC,CAAC;IACP,CAAC;IAGD,OAAO;QACH,IAAK,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAG;YACjC,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;SAC9C;QAED,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAClD,MAAM,EAAC,SAAS,EAAE,OAAO,EAAE,cAAc,EAAE,OAAO,EAAC,GAAG,IAAI,CAAC,UAAU,CAAC;QAEtE,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;QAC3B,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;QACzB,MAAM,CAAC,QAAQ,CAAC,cAAc,CAAC,CAAC;QAChC,MAAM,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;QAE1B,OAAO,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,MAAM,CAAC,YAAY,EAAE,CAAC,CAAC;IAC9D,CAAC;;AApCe,aAAE,GAAG,UAAU,CAAC;AAEhB,wBAAa,GAAG,QAAQ,CAAC;AAEzB,mBAAQ,GAAG,QAAQ,CAAC;AAEpB,wBAAa,GAAG,IAAI,CAAC;AAkCzC,eAAe,UAAU,CAAC"}
|
|
@@ -3,11 +3,11 @@ import { ICommandParameters } from '../../CommandBinaryBuffer.js';
|
|
|
3
3
|
declare class UpdateImageVerify extends Command {
|
|
4
4
|
parameters: ICommandParameters;
|
|
5
5
|
constructor(parameters: ICommandParameters);
|
|
6
|
-
static readonly id =
|
|
6
|
+
static readonly id = 48;
|
|
7
7
|
static readonly directionType = 1;
|
|
8
8
|
static readonly examples: TCommandExampleList;
|
|
9
9
|
static readonly hasParameters = true;
|
|
10
|
-
static fromBytes(
|
|
10
|
+
static fromBytes([requestId]: Uint8Array): UpdateImageVerify;
|
|
11
11
|
toBytes(): Uint8Array;
|
|
12
12
|
}
|
|
13
13
|
export default UpdateImageVerify;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import Command from '../../Command.js';
|
|
2
|
-
import
|
|
2
|
+
import { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
3
|
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
|
-
const COMMAND_ID =
|
|
4
|
+
const COMMAND_ID = 0x30;
|
|
5
5
|
const COMMAND_SIZE = REQUEST_ID_SIZE;
|
|
6
6
|
const examples = [
|
|
7
7
|
{
|
|
@@ -9,7 +9,7 @@ const examples = [
|
|
|
9
9
|
parameters: {
|
|
10
10
|
requestId: 33
|
|
11
11
|
},
|
|
12
|
-
hex: { header: '
|
|
12
|
+
hex: { header: '30 01', body: '21' }
|
|
13
13
|
}
|
|
14
14
|
];
|
|
15
15
|
class UpdateImageVerify extends Command {
|
|
@@ -18,17 +18,11 @@ class UpdateImageVerify extends Command {
|
|
|
18
18
|
this.parameters = parameters;
|
|
19
19
|
this.size = COMMAND_SIZE;
|
|
20
20
|
}
|
|
21
|
-
static fromBytes(
|
|
22
|
-
|
|
23
|
-
return new UpdateImageVerify({ requestId: buffer.getUint8() });
|
|
21
|
+
static fromBytes([requestId]) {
|
|
22
|
+
return new UpdateImageVerify({ requestId });
|
|
24
23
|
}
|
|
25
24
|
toBytes() {
|
|
26
|
-
|
|
27
|
-
throw new Error('unknown or invalid size');
|
|
28
|
-
}
|
|
29
|
-
const buffer = new CommandBinaryBuffer(this.size);
|
|
30
|
-
buffer.setUint8(this.parameters.requestId);
|
|
31
|
-
return Command.toBytes(COMMAND_ID, buffer.toUint8Array());
|
|
25
|
+
return Command.toBytes(COMMAND_ID, new Uint8Array([this.parameters.requestId]));
|
|
32
26
|
}
|
|
33
27
|
}
|
|
34
28
|
UpdateImageVerify.id = COMMAND_ID;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UpdateImageVerify.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/UpdateImageVerify.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,
|
|
1
|
+
{"version":3,"file":"UpdateImageVerify.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/UpdateImageVerify.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AAGvD,MAAM,UAAU,GAAG,IAAI,CAAC;AACxB,MAAM,YAAY,GAAG,eAAe,CAAC;AAErC,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,gBAAgB;QACtB,UAAU,EAAE;YACR,SAAS,EAAE,EAAE;SAChB;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAC;KACrC;CACJ,CAAC;AAsBF,MAAM,iBAAkB,SAAQ,OAAO;IACnC,YAAqB,UAA8B;QAC/C,KAAK,EAAE,CAAC;QADS,eAAU,GAAV,UAAU,CAAoB;QAG/C,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;IAC7B,CAAC;IAaD,MAAM,CAAC,SAAS,CAAG,CAAC,SAAS,CAAa;QACtC,OAAO,IAAI,iBAAiB,CAAC,EAAC,SAAS,EAAC,CAAC,CAAC;IAC9C,CAAC;IAGD,OAAO;QACH,OAAO,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,IAAI,UAAU,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;IACpF,CAAC;;AAjBe,oBAAE,GAAG,UAAU,CAAC;AAEhB,+BAAa,GAAG,QAAQ,CAAC;AAEzB,0BAAQ,GAAG,QAAQ,CAAC;AAEpB,+BAAa,GAAG,IAAI,CAAC;AAezC,eAAe,iBAAiB,CAAC"}
|
|
@@ -7,7 +7,7 @@ interface IUpdateImageWriteParameters extends ICommandParameters {
|
|
|
7
7
|
declare class UpdateImageWrite extends Command {
|
|
8
8
|
parameters: IUpdateImageWriteParameters;
|
|
9
9
|
constructor(parameters: IUpdateImageWriteParameters);
|
|
10
|
-
static readonly id =
|
|
10
|
+
static readonly id = 50;
|
|
11
11
|
static readonly directionType = 1;
|
|
12
12
|
static readonly examples: TCommandExampleList;
|
|
13
13
|
static readonly hasParameters = true;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import Command from '../../Command.js';
|
|
2
2
|
import CommandBinaryBuffer, { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
3
|
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
|
-
const COMMAND_ID =
|
|
5
|
-
const COMMAND_HEADER_SIZE =
|
|
4
|
+
const COMMAND_ID = 0x32;
|
|
5
|
+
const COMMAND_HEADER_SIZE = REQUEST_ID_SIZE + 4;
|
|
6
6
|
const examples = [
|
|
7
7
|
{
|
|
8
8
|
name: 'write image data part',
|
|
@@ -13,7 +13,7 @@ const examples = [
|
|
|
13
13
|
0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
|
|
14
14
|
])
|
|
15
15
|
},
|
|
16
|
-
hex: { header: '
|
|
16
|
+
hex: { header: '32 15', body: '21 00 00 08 40 00 01 02 03 04 05 06 07 08 09 00 00 00 00 00 00' }
|
|
17
17
|
}
|
|
18
18
|
];
|
|
19
19
|
class UpdateImageWrite extends Command {
|
|
@@ -24,10 +24,9 @@ class UpdateImageWrite extends Command {
|
|
|
24
24
|
}
|
|
25
25
|
static fromBytes(data) {
|
|
26
26
|
const buffer = new CommandBinaryBuffer(data);
|
|
27
|
-
const size = buffer.getUint8();
|
|
28
27
|
const requestId = buffer.getUint8();
|
|
29
28
|
const offset = buffer.getUint32();
|
|
30
|
-
const imageData =
|
|
29
|
+
const imageData = data.slice(COMMAND_HEADER_SIZE);
|
|
31
30
|
return new UpdateImageWrite({ requestId, offset, data: imageData });
|
|
32
31
|
}
|
|
33
32
|
toBytes() {
|
|
@@ -37,7 +36,6 @@ class UpdateImageWrite extends Command {
|
|
|
37
36
|
const { requestId, offset, data } = this.parameters;
|
|
38
37
|
const buffer = new CommandBinaryBuffer(COMMAND_HEADER_SIZE);
|
|
39
38
|
const result = new Uint8Array(this.size);
|
|
40
|
-
buffer.setUint8(this.size - 1);
|
|
41
39
|
buffer.setUint8(requestId);
|
|
42
40
|
buffer.setUint32(offset);
|
|
43
41
|
result.set(buffer.toUint8Array());
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UpdateImageWrite.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/UpdateImageWrite.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,mBAAmB,EAAE,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACtG,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AAYvD,MAAM,UAAU,GAAG,IAAI,CAAC;AAGxB,MAAM,mBAAmB,GAAG,
|
|
1
|
+
{"version":3,"file":"UpdateImageWrite.js","sourceRoot":"","sources":["../../../../src/obis-observer/commands/downlink/UpdateImageWrite.ts"],"names":[],"mappings":"AAAA,OAAO,OAA8B,MAAM,kBAAkB,CAAC;AAC9D,OAAO,mBAAmB,EAAE,EAAC,eAAe,EAAqB,MAAM,8BAA8B,CAAC;AACtG,OAAO,EAAC,QAAQ,EAAC,MAAM,+BAA+B,CAAC;AAYvD,MAAM,UAAU,GAAG,IAAI,CAAC;AAGxB,MAAM,mBAAmB,GAAG,eAAe,GAAG,CAAC,CAAC;AAEhD,MAAM,QAAQ,GAAwB;IAClC;QACI,IAAI,EAAE,uBAAuB;QAC7B,UAAU,EAAE;YACR,SAAS,EAAE,EAAE;YACb,MAAM,EAAE,IAAI;YACZ,IAAI,EAAE,IAAI,UAAU,CAAC;gBACjB,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI;aACjG,CAAC;SACL;QACD,GAAG,EAAE,EAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,gEAAgE,EAAC;KACjG;CACJ,CAAC;AA0BF,MAAM,gBAAiB,SAAQ,OAAO;IAClC,YAAqB,UAAuC;QACxD,KAAK,EAAE,CAAC;QADS,eAAU,GAAV,UAAU,CAA6B;QAGxD,IAAI,CAAC,IAAI,GAAG,mBAAmB,GAAG,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC;IAC7D,CAAC;IAaD,MAAM,CAAC,SAAS,CAAG,IAAgB;QAC/B,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,IAAI,CAAC,CAAC;QAC7C,MAAM,SAAS,GAAG,MAAM,CAAC,QAAQ,EAAE,CAAC;QACpC,MAAM,MAAM,GAAG,MAAM,CAAC,SAAS,EAAE,CAAC;QAClC,MAAM,SAAS,GAAG,IAAI,CAAC,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAElD,OAAO,IAAI,gBAAgB,CAAC,EAAC,SAAS,EAAE,MAAM,EAAE,IAAI,EAAE,SAAS,EAAC,CAAC,CAAC;IACtE,CAAC;IAGD,OAAO;QACH,IAAK,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAG;YACjC,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;SAC9C;QAED,MAAM,EAAC,SAAS,EAAE,MAAM,EAAE,IAAI,EAAC,GAAG,IAAI,CAAC,UAAU,CAAC;QAClD,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC,mBAAmB,CAAC,CAAC;QAC5D,MAAM,MAAM,GAAG,IAAI,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAEzC,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;QAC3B,MAAM,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;QAGzB,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,YAAY,EAAE,CAAC,CAAC;QAClC,MAAM,CAAC,GAAG,CAAC,IAAI,EAAE,mBAAmB,CAAC,CAAC;QAEtC,OAAO,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC;IAC/C,CAAC;;AArCe,mBAAE,GAAG,UAAU,CAAC;AAEhB,8BAAa,GAAG,QAAQ,CAAC;AAEzB,yBAAQ,GAAG,QAAQ,CAAC;AAEpB,8BAAa,GAAG,IAAI,CAAC;AAmCzC,eAAe,gBAAgB,CAAC"}
|
|
@@ -3,11 +3,11 @@ import { ICommandParameters } from '../../CommandBinaryBuffer.js';
|
|
|
3
3
|
declare class UpdateRun extends Command {
|
|
4
4
|
parameters: ICommandParameters;
|
|
5
5
|
constructor(parameters: ICommandParameters);
|
|
6
|
-
static readonly id =
|
|
6
|
+
static readonly id = 52;
|
|
7
7
|
static readonly directionType = 1;
|
|
8
8
|
static readonly examples: TCommandExampleList;
|
|
9
9
|
static readonly hasParameters = true;
|
|
10
|
-
static fromBytes(
|
|
10
|
+
static fromBytes([requestId]: Uint8Array): UpdateRun;
|
|
11
11
|
toBytes(): Uint8Array;
|
|
12
12
|
}
|
|
13
13
|
export default UpdateRun;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import Command from '../../Command.js';
|
|
2
|
-
import
|
|
2
|
+
import { REQUEST_ID_SIZE } from '../../CommandBinaryBuffer.js';
|
|
3
3
|
import { DOWNLINK } from '../../constants/directions.js';
|
|
4
|
-
const COMMAND_ID =
|
|
4
|
+
const COMMAND_ID = 0x34;
|
|
5
5
|
const COMMAND_SIZE = REQUEST_ID_SIZE;
|
|
6
6
|
const examples = [
|
|
7
7
|
{
|
|
@@ -9,7 +9,7 @@ const examples = [
|
|
|
9
9
|
parameters: {
|
|
10
10
|
requestId: 33
|
|
11
11
|
},
|
|
12
|
-
hex: { header: '
|
|
12
|
+
hex: { header: '34 01', body: '21' }
|
|
13
13
|
}
|
|
14
14
|
];
|
|
15
15
|
class UpdateRun extends Command {
|
|
@@ -18,17 +18,11 @@ class UpdateRun extends Command {
|
|
|
18
18
|
this.parameters = parameters;
|
|
19
19
|
this.size = COMMAND_SIZE;
|
|
20
20
|
}
|
|
21
|
-
static fromBytes(
|
|
22
|
-
|
|
23
|
-
return new UpdateRun({ requestId: buffer.getUint8() });
|
|
21
|
+
static fromBytes([requestId]) {
|
|
22
|
+
return new UpdateRun({ requestId });
|
|
24
23
|
}
|
|
25
24
|
toBytes() {
|
|
26
|
-
|
|
27
|
-
throw new Error('unknown or invalid size');
|
|
28
|
-
}
|
|
29
|
-
const buffer = new CommandBinaryBuffer(this.size);
|
|
30
|
-
buffer.setUint8(this.parameters.requestId);
|
|
31
|
-
return Command.toBytes(COMMAND_ID, buffer.toUint8Array());
|
|
25
|
+
return Command.toBytes(COMMAND_ID, new Uint8Array([this.parameters.requestId]));
|
|
32
26
|
}
|
|
33
27
|
}
|
|
34
28
|
UpdateRun.id = COMMAND_ID;
|