DLMS-SPODES 0.87.13__py3-none-any.whl → 0.87.16__py3-none-any.whl
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.
- DLMS_SPODES/Values/EN/__init__.py +1 -1
- DLMS_SPODES/Values/EN/actors.py +8 -8
- DLMS_SPODES/Values/EN/relation_to_obis_names.py +387 -387
- DLMS_SPODES/Values/RU/__init__.py +1 -1
- DLMS_SPODES/Values/RU/actors.py +8 -8
- DLMS_SPODES/Values/RU/relation_to_obis_names.py +396 -396
- DLMS_SPODES/__init__.py +6 -6
- DLMS_SPODES/configEN.ini +126 -126
- DLMS_SPODES/config_parser.py +53 -53
- DLMS_SPODES/cosem_interface_classes/__class_init__.py +3 -3
- DLMS_SPODES/cosem_interface_classes/__init__.py +1 -1
- DLMS_SPODES/cosem_interface_classes/a_parameter.py +20 -20
- DLMS_SPODES/cosem_interface_classes/activity_calendar.py +254 -254
- DLMS_SPODES/cosem_interface_classes/arbitrator.py +105 -105
- DLMS_SPODES/cosem_interface_classes/association_ln/abstract.py +34 -34
- DLMS_SPODES/cosem_interface_classes/association_ln/authentication_mechanism_name.py +25 -25
- DLMS_SPODES/cosem_interface_classes/association_ln/mechanism_id.py +25 -25
- DLMS_SPODES/cosem_interface_classes/association_ln/method.py +5 -5
- DLMS_SPODES/cosem_interface_classes/association_ln/ver0.py +485 -485
- DLMS_SPODES/cosem_interface_classes/association_ln/ver1.py +133 -133
- DLMS_SPODES/cosem_interface_classes/association_ln/ver2.py +36 -36
- DLMS_SPODES/cosem_interface_classes/association_ln/ver3.py +4 -4
- DLMS_SPODES/cosem_interface_classes/association_sn/ver0.py +12 -12
- DLMS_SPODES/cosem_interface_classes/attr_indexes.py +12 -12
- DLMS_SPODES/cosem_interface_classes/clock.py +131 -131
- DLMS_SPODES/cosem_interface_classes/collection.py +2122 -2122
- DLMS_SPODES/cosem_interface_classes/cosem_interface_class.py +583 -583
- DLMS_SPODES/cosem_interface_classes/data.py +21 -21
- DLMS_SPODES/cosem_interface_classes/demand_register/ver0.py +59 -59
- DLMS_SPODES/cosem_interface_classes/disconnect_control.py +74 -74
- DLMS_SPODES/cosem_interface_classes/extended_register.py +27 -27
- DLMS_SPODES/cosem_interface_classes/gprs_modem_setup.py +43 -43
- DLMS_SPODES/cosem_interface_classes/gsm_diagnostic/ver0.py +103 -103
- DLMS_SPODES/cosem_interface_classes/gsm_diagnostic/ver1.py +40 -40
- DLMS_SPODES/cosem_interface_classes/gsm_diagnostic/ver2.py +9 -9
- DLMS_SPODES/cosem_interface_classes/iec_hdlc_setup/ver0.py +11 -11
- DLMS_SPODES/cosem_interface_classes/iec_hdlc_setup/ver1.py +53 -53
- DLMS_SPODES/cosem_interface_classes/iec_local_port_setup.py +11 -11
- DLMS_SPODES/cosem_interface_classes/image_transfer/image_transfer_status.py +15 -15
- DLMS_SPODES/cosem_interface_classes/image_transfer/ver0.py +126 -126
- DLMS_SPODES/cosem_interface_classes/implementations/__init__.py +3 -3
- DLMS_SPODES/cosem_interface_classes/implementations/arbitrator.py +19 -19
- DLMS_SPODES/cosem_interface_classes/implementations/data.py +487 -487
- DLMS_SPODES/cosem_interface_classes/implementations/profile_generic.py +83 -83
- DLMS_SPODES/cosem_interface_classes/ipv4_setup.py +72 -72
- DLMS_SPODES/cosem_interface_classes/limiter.py +111 -111
- DLMS_SPODES/cosem_interface_classes/ln_pattern.py +333 -333
- DLMS_SPODES/cosem_interface_classes/modem_configuration/ver0.py +65 -65
- DLMS_SPODES/cosem_interface_classes/modem_configuration/ver1.py +39 -39
- DLMS_SPODES/cosem_interface_classes/ntp_setup/ver0.py +67 -67
- DLMS_SPODES/cosem_interface_classes/obis.py +23 -23
- DLMS_SPODES/cosem_interface_classes/overview.py +197 -197
- DLMS_SPODES/cosem_interface_classes/parameter.py +547 -547
- DLMS_SPODES/cosem_interface_classes/parameters.py +172 -172
- DLMS_SPODES/cosem_interface_classes/profile_generic/ver0.py +122 -122
- DLMS_SPODES/cosem_interface_classes/profile_generic/ver1.py +277 -277
- DLMS_SPODES/cosem_interface_classes/push_setup/ver0.py +12 -12
- DLMS_SPODES/cosem_interface_classes/push_setup/ver1.py +10 -10
- DLMS_SPODES/cosem_interface_classes/push_setup/ver2.py +166 -166
- DLMS_SPODES/cosem_interface_classes/register.py +45 -45
- DLMS_SPODES/cosem_interface_classes/register_activation/ver0.py +80 -80
- DLMS_SPODES/cosem_interface_classes/register_monitor.py +46 -46
- DLMS_SPODES/cosem_interface_classes/reports.py +70 -70
- DLMS_SPODES/cosem_interface_classes/schedule.py +176 -176
- DLMS_SPODES/cosem_interface_classes/script_table.py +87 -87
- DLMS_SPODES/cosem_interface_classes/security_setup/ver0.py +68 -68
- DLMS_SPODES/cosem_interface_classes/security_setup/ver1.py +158 -158
- DLMS_SPODES/cosem_interface_classes/single_action_schedule.py +50 -50
- DLMS_SPODES/cosem_interface_classes/special_days_table.py +84 -84
- DLMS_SPODES/cosem_interface_classes/tcp_udp_setup.py +42 -42
- DLMS_SPODES/cosem_pdu.py +93 -93
- DLMS_SPODES/enums.py +625 -625
- DLMS_SPODES/exceptions.py +106 -106
- DLMS_SPODES/firmwares.py +99 -99
- DLMS_SPODES/hdlc/frame.py +875 -875
- DLMS_SPODES/hdlc/sub_layer.py +54 -54
- DLMS_SPODES/literals.py +17 -17
- DLMS_SPODES/obis/__init__.py +1 -1
- DLMS_SPODES/obis/media_id.py +931 -931
- DLMS_SPODES/pardata.py +22 -22
- DLMS_SPODES/pdu_enums.py +98 -98
- DLMS_SPODES/relation_to_OBIS.py +465 -463
- DLMS_SPODES/settings.py +551 -551
- DLMS_SPODES/types/choices.py +142 -142
- DLMS_SPODES/types/common_data_types.py +2401 -2401
- DLMS_SPODES/types/cosem_service_types.py +109 -109
- DLMS_SPODES/types/implementations/arrays.py +25 -25
- DLMS_SPODES/types/implementations/bitstrings.py +97 -97
- DLMS_SPODES/types/implementations/double_long_usingneds.py +35 -35
- DLMS_SPODES/types/implementations/enums.py +57 -57
- DLMS_SPODES/types/implementations/integers.py +11 -11
- DLMS_SPODES/types/implementations/long_unsigneds.py +127 -127
- DLMS_SPODES/types/implementations/octet_string.py +11 -11
- DLMS_SPODES/types/implementations/structs.py +64 -64
- DLMS_SPODES/types/useful_types.py +677 -677
- {dlms_spodes-0.87.13.dist-info → dlms_spodes-0.87.16.dist-info}/METADATA +30 -30
- dlms_spodes-0.87.16.dist-info/RECORD +117 -0
- {dlms_spodes-0.87.13.dist-info → dlms_spodes-0.87.16.dist-info}/WHEEL +1 -1
- dlms_spodes-0.87.13.dist-info/RECORD +0 -117
- {dlms_spodes-0.87.13.dist-info → dlms_spodes-0.87.16.dist-info}/top_level.txt +0 -0
|
@@ -1,131 +1,131 @@
|
|
|
1
|
-
import datetime
|
|
2
|
-
from .__class_init__ import *
|
|
3
|
-
from ..types.implementations import integers
|
|
4
|
-
from .overview import VERSION_0
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
class ClockStatus(cdt.Unsigned):
|
|
8
|
-
""" interpreted as 8 bit string """
|
|
9
|
-
|
|
10
|
-
# TODO: finish write as bit_string
|
|
11
|
-
def __str__(self):
|
|
12
|
-
value = int.from_bytes(self.contents, 'big')
|
|
13
|
-
ret = ''
|
|
14
|
-
if bool(value & 0b1):
|
|
15
|
-
ret += ' invalid value'
|
|
16
|
-
if bool(value & 0b10):
|
|
17
|
-
ret += ' doubtful value'
|
|
18
|
-
if bool(value & 0b100):
|
|
19
|
-
ret += ' different clock base'
|
|
20
|
-
if bool(value & 0b1000):
|
|
21
|
-
ret += ' invalid clock status'
|
|
22
|
-
if bool(value & 0b1000000):
|
|
23
|
-
ret += ' daylight saving active'
|
|
24
|
-
if ret == '':
|
|
25
|
-
ret = 'empty'
|
|
26
|
-
return ret
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
class DaylightSavingsDeviation(cdt.Integer, min=-120, max=120):
|
|
30
|
-
"""Contains the number of minutes by which the deviation in generalized time must be corrected at daylight savings begin.
|
|
31
|
-
Deviation range of up to ± 120 min"""
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
class ClockBase(cdt.Enum, elements=(0, 1, 2, 3, 4, 5)):
|
|
35
|
-
""" Defines where the basic timing information comes from. """
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
class PresetAdjustingTime(cdt.Structure):
|
|
39
|
-
""" Presets the time to a new value (preset_time) and defines a validity_interval within which the new time can be activated """
|
|
40
|
-
DEFAULT = b'\x02\x03\x19\x07\xe4\x01\x01\xff\xff\xff\xff\xff\x80\x00\xff' \
|
|
41
|
-
b'\x19\x07\xe4\x01\x01\xff\xff\xff\xff\xff\x80\x00\xff\x19\x07\xe4\x01\x01\xff\xff\xff\xff\xff\x80\x00\xff'
|
|
42
|
-
preset_time: cdt.DateTime
|
|
43
|
-
validity_interval_start: cdt.DateTime
|
|
44
|
-
validity_interval_end: cdt.DateTime
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
class ShiftTime(cdt.Long, min=-900, max=900):
|
|
48
|
-
""" Limited Long -900..900 """
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
class TimeZone(cdt.Long):
|
|
52
|
-
""""""
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
class Clock(ic.COSEMInterfaceClasses):
|
|
56
|
-
"""4.5.1 Clock"""
|
|
57
|
-
CLASS_ID = ClassID.CLOCK
|
|
58
|
-
VERSION = VERSION_0
|
|
59
|
-
A_ELEMENTS = (ic.ICAElement("time", cst.OctetStringDateTime, classifier=ic.Classifier.DYNAMIC),
|
|
60
|
-
ic.ICAElement("time_zone", TimeZone, -720, 840),
|
|
61
|
-
ic.ICAElement("status", ClockStatus, classifier=ic.Classifier.DYNAMIC),
|
|
62
|
-
ic.ICAElement("daylight_savings_begin", cst.OctetStringDateTime),
|
|
63
|
-
ic.ICAElement("daylight_savings_end", cst.OctetStringDateTime),
|
|
64
|
-
ic.ICAElement("daylight_savings_deviation", DaylightSavingsDeviation, -120, 120),
|
|
65
|
-
ic.ICAElement("daylight_savings_enabled", cdt.Boolean),
|
|
66
|
-
ic.ICAElement("clock_base", ClockBase))
|
|
67
|
-
M_ELEMENTS = (ic.ICMElement("adjust_to_quarter", integers.Only0),
|
|
68
|
-
ic.ICMElement("adjust_to_measuring_period", integers.Only0),
|
|
69
|
-
ic.ICMElement("adjust_to_minute", integers.Only0),
|
|
70
|
-
ic.ICMElement("adjust_to_preset_time", integers.Only0),
|
|
71
|
-
ic.ICMElement("preset_adjusting_time", PresetAdjustingTime),
|
|
72
|
-
ic.ICMElement("shift_time", ShiftTime))
|
|
73
|
-
|
|
74
|
-
def characteristics_init(self):
|
|
75
|
-
...
|
|
76
|
-
|
|
77
|
-
@property
|
|
78
|
-
def time(self) -> cst.OctetStringDateTime:
|
|
79
|
-
return self.get_attr(2)
|
|
80
|
-
|
|
81
|
-
@property
|
|
82
|
-
def time_zone(self) -> cdt.Long:
|
|
83
|
-
return self.get_attr(3)
|
|
84
|
-
|
|
85
|
-
@property
|
|
86
|
-
def status(self) -> ClockStatus:
|
|
87
|
-
return self.get_attr(4)
|
|
88
|
-
|
|
89
|
-
@property
|
|
90
|
-
def daylight_savings_begin(self) -> cst.OctetStringDateTime:
|
|
91
|
-
return self.get_attr(5)
|
|
92
|
-
|
|
93
|
-
@property
|
|
94
|
-
def daylight_savings_end(self) -> cst.OctetStringDateTime:
|
|
95
|
-
return self.get_attr(6)
|
|
96
|
-
|
|
97
|
-
@property
|
|
98
|
-
def daylight_savings_deviation(self) -> DaylightSavingsDeviation:
|
|
99
|
-
return self.get_attr(7)
|
|
100
|
-
|
|
101
|
-
@property
|
|
102
|
-
def daylight_savings_enabled(self) -> cdt.Boolean:
|
|
103
|
-
return self.get_attr(8)
|
|
104
|
-
|
|
105
|
-
@property
|
|
106
|
-
def clock_base(self) -> ClockBase:
|
|
107
|
-
return self.get_attr(9)
|
|
108
|
-
|
|
109
|
-
@property
|
|
110
|
-
def adjust_to_quarter(self) -> integers.Only0:
|
|
111
|
-
return self.get_meth(1)
|
|
112
|
-
|
|
113
|
-
@property
|
|
114
|
-
def adjust_to_measuring_period(self) -> integers.Only0:
|
|
115
|
-
return self.get_meth(2)
|
|
116
|
-
|
|
117
|
-
@property
|
|
118
|
-
def adjust_to_minute(self) -> integers.Only0:
|
|
119
|
-
return self.get_meth(3)
|
|
120
|
-
|
|
121
|
-
@property
|
|
122
|
-
def adjust_to_preset_time(self) -> integers.Only0:
|
|
123
|
-
return self.get_meth(4)
|
|
124
|
-
|
|
125
|
-
@property
|
|
126
|
-
def preset_adjusting_time(self) -> PresetAdjustingTime:
|
|
127
|
-
return self.get_meth(5)
|
|
128
|
-
|
|
129
|
-
@property
|
|
130
|
-
def shift_time(self) -> ShiftTime:
|
|
131
|
-
return self.get_meth(6)
|
|
1
|
+
import datetime
|
|
2
|
+
from .__class_init__ import *
|
|
3
|
+
from ..types.implementations import integers
|
|
4
|
+
from .overview import VERSION_0
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class ClockStatus(cdt.Unsigned):
|
|
8
|
+
""" interpreted as 8 bit string """
|
|
9
|
+
|
|
10
|
+
# TODO: finish write as bit_string
|
|
11
|
+
def __str__(self):
|
|
12
|
+
value = int.from_bytes(self.contents, 'big')
|
|
13
|
+
ret = ''
|
|
14
|
+
if bool(value & 0b1):
|
|
15
|
+
ret += ' invalid value'
|
|
16
|
+
if bool(value & 0b10):
|
|
17
|
+
ret += ' doubtful value'
|
|
18
|
+
if bool(value & 0b100):
|
|
19
|
+
ret += ' different clock base'
|
|
20
|
+
if bool(value & 0b1000):
|
|
21
|
+
ret += ' invalid clock status'
|
|
22
|
+
if bool(value & 0b1000000):
|
|
23
|
+
ret += ' daylight saving active'
|
|
24
|
+
if ret == '':
|
|
25
|
+
ret = 'empty'
|
|
26
|
+
return ret
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
class DaylightSavingsDeviation(cdt.Integer, min=-120, max=120):
|
|
30
|
+
"""Contains the number of minutes by which the deviation in generalized time must be corrected at daylight savings begin.
|
|
31
|
+
Deviation range of up to ± 120 min"""
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class ClockBase(cdt.Enum, elements=(0, 1, 2, 3, 4, 5)):
|
|
35
|
+
""" Defines where the basic timing information comes from. """
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
class PresetAdjustingTime(cdt.Structure):
|
|
39
|
+
""" Presets the time to a new value (preset_time) and defines a validity_interval within which the new time can be activated """
|
|
40
|
+
DEFAULT = b'\x02\x03\x19\x07\xe4\x01\x01\xff\xff\xff\xff\xff\x80\x00\xff' \
|
|
41
|
+
b'\x19\x07\xe4\x01\x01\xff\xff\xff\xff\xff\x80\x00\xff\x19\x07\xe4\x01\x01\xff\xff\xff\xff\xff\x80\x00\xff'
|
|
42
|
+
preset_time: cdt.DateTime
|
|
43
|
+
validity_interval_start: cdt.DateTime
|
|
44
|
+
validity_interval_end: cdt.DateTime
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
class ShiftTime(cdt.Long, min=-900, max=900):
|
|
48
|
+
""" Limited Long -900..900 """
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
class TimeZone(cdt.Long):
|
|
52
|
+
""""""
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
class Clock(ic.COSEMInterfaceClasses):
|
|
56
|
+
"""4.5.1 Clock"""
|
|
57
|
+
CLASS_ID = ClassID.CLOCK
|
|
58
|
+
VERSION = VERSION_0
|
|
59
|
+
A_ELEMENTS = (ic.ICAElement("time", cst.OctetStringDateTime, classifier=ic.Classifier.DYNAMIC),
|
|
60
|
+
ic.ICAElement("time_zone", TimeZone, -720, 840),
|
|
61
|
+
ic.ICAElement("status", ClockStatus, classifier=ic.Classifier.DYNAMIC),
|
|
62
|
+
ic.ICAElement("daylight_savings_begin", cst.OctetStringDateTime),
|
|
63
|
+
ic.ICAElement("daylight_savings_end", cst.OctetStringDateTime),
|
|
64
|
+
ic.ICAElement("daylight_savings_deviation", DaylightSavingsDeviation, -120, 120),
|
|
65
|
+
ic.ICAElement("daylight_savings_enabled", cdt.Boolean),
|
|
66
|
+
ic.ICAElement("clock_base", ClockBase))
|
|
67
|
+
M_ELEMENTS = (ic.ICMElement("adjust_to_quarter", integers.Only0),
|
|
68
|
+
ic.ICMElement("adjust_to_measuring_period", integers.Only0),
|
|
69
|
+
ic.ICMElement("adjust_to_minute", integers.Only0),
|
|
70
|
+
ic.ICMElement("adjust_to_preset_time", integers.Only0),
|
|
71
|
+
ic.ICMElement("preset_adjusting_time", PresetAdjustingTime),
|
|
72
|
+
ic.ICMElement("shift_time", ShiftTime))
|
|
73
|
+
|
|
74
|
+
def characteristics_init(self):
|
|
75
|
+
...
|
|
76
|
+
|
|
77
|
+
@property
|
|
78
|
+
def time(self) -> cst.OctetStringDateTime:
|
|
79
|
+
return self.get_attr(2)
|
|
80
|
+
|
|
81
|
+
@property
|
|
82
|
+
def time_zone(self) -> cdt.Long:
|
|
83
|
+
return self.get_attr(3)
|
|
84
|
+
|
|
85
|
+
@property
|
|
86
|
+
def status(self) -> ClockStatus:
|
|
87
|
+
return self.get_attr(4)
|
|
88
|
+
|
|
89
|
+
@property
|
|
90
|
+
def daylight_savings_begin(self) -> cst.OctetStringDateTime:
|
|
91
|
+
return self.get_attr(5)
|
|
92
|
+
|
|
93
|
+
@property
|
|
94
|
+
def daylight_savings_end(self) -> cst.OctetStringDateTime:
|
|
95
|
+
return self.get_attr(6)
|
|
96
|
+
|
|
97
|
+
@property
|
|
98
|
+
def daylight_savings_deviation(self) -> DaylightSavingsDeviation:
|
|
99
|
+
return self.get_attr(7)
|
|
100
|
+
|
|
101
|
+
@property
|
|
102
|
+
def daylight_savings_enabled(self) -> cdt.Boolean:
|
|
103
|
+
return self.get_attr(8)
|
|
104
|
+
|
|
105
|
+
@property
|
|
106
|
+
def clock_base(self) -> ClockBase:
|
|
107
|
+
return self.get_attr(9)
|
|
108
|
+
|
|
109
|
+
@property
|
|
110
|
+
def adjust_to_quarter(self) -> integers.Only0:
|
|
111
|
+
return self.get_meth(1)
|
|
112
|
+
|
|
113
|
+
@property
|
|
114
|
+
def adjust_to_measuring_period(self) -> integers.Only0:
|
|
115
|
+
return self.get_meth(2)
|
|
116
|
+
|
|
117
|
+
@property
|
|
118
|
+
def adjust_to_minute(self) -> integers.Only0:
|
|
119
|
+
return self.get_meth(3)
|
|
120
|
+
|
|
121
|
+
@property
|
|
122
|
+
def adjust_to_preset_time(self) -> integers.Only0:
|
|
123
|
+
return self.get_meth(4)
|
|
124
|
+
|
|
125
|
+
@property
|
|
126
|
+
def preset_adjusting_time(self) -> PresetAdjustingTime:
|
|
127
|
+
return self.get_meth(5)
|
|
128
|
+
|
|
129
|
+
@property
|
|
130
|
+
def shift_time(self) -> ShiftTime:
|
|
131
|
+
return self.get_meth(6)
|