conson-xp 1.1.0__py3-none-any.whl → 1.3.0__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.
Files changed (174) hide show
  1. {conson_xp-1.1.0.dist-info → conson_xp-1.3.0.dist-info}/METADATA +1 -5
  2. conson_xp-1.3.0.dist-info/RECORD +164 -0
  3. xp/__init__.py +4 -3
  4. xp/cli/__init__.py +1 -1
  5. xp/cli/commands/__init__.py +1 -2
  6. xp/cli/commands/conbus/conbus.py +9 -37
  7. xp/cli/commands/conbus/conbus_actiontable_commands.py +26 -4
  8. xp/cli/commands/conbus/conbus_autoreport_commands.py +58 -30
  9. xp/cli/commands/conbus/conbus_blink_commands.py +61 -29
  10. xp/cli/commands/conbus/conbus_config_commands.py +10 -5
  11. xp/cli/commands/conbus/conbus_custom_commands.py +16 -5
  12. xp/cli/commands/conbus/conbus_datapoint_commands.py +32 -10
  13. xp/cli/commands/conbus/conbus_discover_commands.py +20 -7
  14. xp/cli/commands/conbus/conbus_lightlevel_commands.py +114 -39
  15. xp/cli/commands/conbus/conbus_linknumber_commands.py +50 -25
  16. xp/cli/commands/conbus/conbus_msactiontable_commands.py +36 -5
  17. xp/cli/commands/conbus/conbus_output_commands.py +52 -14
  18. xp/cli/commands/conbus/conbus_raw_commands.py +17 -6
  19. xp/cli/commands/conbus/conbus_receive_commands.py +20 -10
  20. xp/cli/commands/conbus/conbus_scan_commands.py +17 -4
  21. xp/cli/commands/file_commands.py +35 -18
  22. xp/cli/commands/homekit/homekit.py +14 -8
  23. xp/cli/commands/homekit/homekit_start_commands.py +8 -6
  24. xp/cli/commands/module_commands.py +38 -23
  25. xp/cli/commands/reverse_proxy_commands.py +27 -19
  26. xp/cli/commands/server/server_commands.py +18 -18
  27. xp/cli/commands/telegram/telegram.py +4 -12
  28. xp/cli/commands/telegram/telegram_blink_commands.py +10 -8
  29. xp/cli/commands/telegram/telegram_checksum_commands.py +19 -8
  30. xp/cli/commands/telegram/telegram_discover_commands.py +2 -4
  31. xp/cli/commands/telegram/telegram_linknumber_commands.py +11 -8
  32. xp/cli/commands/telegram/telegram_parse_commands.py +10 -9
  33. xp/cli/commands/telegram/telegram_version_commands.py +8 -4
  34. xp/cli/main.py +5 -3
  35. xp/cli/utils/click_tree.py +23 -3
  36. xp/cli/utils/datapoint_type_choice.py +20 -0
  37. xp/cli/utils/decorators.py +165 -14
  38. xp/cli/utils/error_handlers.py +49 -18
  39. xp/cli/utils/formatters.py +95 -10
  40. xp/cli/utils/serial_number_type.py +18 -0
  41. xp/cli/utils/system_function_choice.py +20 -0
  42. xp/cli/utils/xp_module_type.py +20 -0
  43. xp/connection/__init__.py +1 -1
  44. xp/connection/exceptions.py +5 -5
  45. xp/models/__init__.py +1 -1
  46. xp/models/actiontable/__init__.py +1 -0
  47. xp/models/actiontable/actiontable.py +17 -1
  48. xp/models/actiontable/msactiontable_xp20.py +10 -0
  49. xp/models/actiontable/msactiontable_xp24.py +20 -3
  50. xp/models/actiontable/msactiontable_xp33.py +27 -4
  51. xp/models/conbus/__init__.py +1 -0
  52. xp/models/conbus/conbus.py +34 -4
  53. xp/models/conbus/conbus_autoreport.py +20 -2
  54. xp/models/conbus/conbus_blink.py +22 -2
  55. xp/models/conbus/conbus_client_config.py +22 -1
  56. xp/models/conbus/conbus_connection_status.py +16 -2
  57. xp/models/conbus/conbus_custom.py +21 -2
  58. xp/models/conbus/conbus_datapoint.py +25 -2
  59. xp/models/conbus/conbus_discover.py +18 -2
  60. xp/models/conbus/conbus_lightlevel.py +20 -2
  61. xp/models/conbus/conbus_linknumber.py +20 -2
  62. xp/models/conbus/conbus_output.py +22 -2
  63. xp/models/conbus/conbus_raw.py +17 -2
  64. xp/models/conbus/conbus_receive.py +16 -2
  65. xp/models/conbus/conbus_writeconfig.py +60 -0
  66. xp/models/homekit/__init__.py +1 -0
  67. xp/models/homekit/homekit_accessory.py +15 -1
  68. xp/models/homekit/homekit_config.py +52 -0
  69. xp/models/homekit/homekit_conson_config.py +32 -0
  70. xp/models/log_entry.py +49 -9
  71. xp/models/protocol/__init__.py +1 -0
  72. xp/models/protocol/conbus_protocol.py +130 -21
  73. xp/models/telegram/__init__.py +1 -0
  74. xp/models/telegram/action_type.py +16 -2
  75. xp/models/telegram/datapoint_type.py +36 -2
  76. xp/models/telegram/event_telegram.py +46 -10
  77. xp/models/telegram/event_type.py +8 -1
  78. xp/models/telegram/input_action_type.py +34 -2
  79. xp/models/telegram/input_type.py +9 -1
  80. xp/models/telegram/module_type.py +69 -19
  81. xp/models/telegram/module_type_code.py +43 -1
  82. xp/models/telegram/output_telegram.py +30 -6
  83. xp/models/telegram/reply_telegram.py +56 -11
  84. xp/models/telegram/system_function.py +35 -3
  85. xp/models/telegram/system_telegram.py +18 -4
  86. xp/models/telegram/telegram.py +12 -3
  87. xp/models/telegram/telegram_type.py +8 -1
  88. xp/models/telegram/timeparam_type.py +27 -0
  89. xp/models/write_config_type.py +17 -2
  90. xp/services/__init__.py +1 -1
  91. xp/services/conbus/__init__.py +1 -0
  92. xp/services/conbus/actiontable/__init__.py +1 -0
  93. xp/services/conbus/actiontable/actiontable_service.py +33 -2
  94. xp/services/conbus/actiontable/msactiontable_service.py +40 -3
  95. xp/services/conbus/actiontable/msactiontable_xp24_serializer.py +36 -4
  96. xp/services/conbus/actiontable/msactiontable_xp33_serializer.py +45 -5
  97. xp/services/conbus/conbus_blink_all_service.py +40 -21
  98. xp/services/conbus/conbus_blink_service.py +37 -13
  99. xp/services/conbus/conbus_custom_service.py +29 -13
  100. xp/services/conbus/conbus_datapoint_queryall_service.py +40 -16
  101. xp/services/conbus/conbus_datapoint_service.py +42 -18
  102. xp/services/conbus/conbus_discover_service.py +43 -7
  103. xp/services/conbus/conbus_output_service.py +33 -13
  104. xp/services/conbus/conbus_raw_service.py +36 -16
  105. xp/services/conbus/conbus_receive_service.py +38 -6
  106. xp/services/conbus/conbus_scan_service.py +44 -18
  107. xp/services/conbus/write_config_service.py +193 -0
  108. xp/services/homekit/__init__.py +1 -0
  109. xp/services/homekit/homekit_cache_service.py +31 -6
  110. xp/services/homekit/homekit_conbus_service.py +33 -2
  111. xp/services/homekit/homekit_config_validator.py +97 -15
  112. xp/services/homekit/homekit_conson_validator.py +51 -7
  113. xp/services/homekit/homekit_dimminglight.py +47 -1
  114. xp/services/homekit/homekit_dimminglight_service.py +35 -1
  115. xp/services/homekit/homekit_hap_service.py +71 -18
  116. xp/services/homekit/homekit_lightbulb.py +35 -1
  117. xp/services/homekit/homekit_lightbulb_service.py +30 -2
  118. xp/services/homekit/homekit_module_service.py +23 -1
  119. xp/services/homekit/homekit_outlet.py +47 -1
  120. xp/services/homekit/homekit_outlet_service.py +44 -2
  121. xp/services/homekit/homekit_service.py +113 -19
  122. xp/services/log_file_service.py +37 -41
  123. xp/services/module_type_service.py +26 -5
  124. xp/services/protocol/__init__.py +1 -1
  125. xp/services/protocol/conbus_protocol.py +110 -16
  126. xp/services/protocol/protocol_factory.py +40 -0
  127. xp/services/protocol/telegram_protocol.py +38 -7
  128. xp/services/reverse_proxy_service.py +79 -14
  129. xp/services/server/__init__.py +1 -0
  130. xp/services/server/base_server_service.py +102 -14
  131. xp/services/server/cp20_server_service.py +12 -4
  132. xp/services/server/server_service.py +26 -11
  133. xp/services/server/xp130_server_service.py +11 -3
  134. xp/services/server/xp20_server_service.py +11 -3
  135. xp/services/server/xp230_server_service.py +11 -3
  136. xp/services/server/xp24_server_service.py +33 -6
  137. xp/services/server/xp33_server_service.py +41 -8
  138. xp/services/telegram/__init__.py +1 -0
  139. xp/services/telegram/telegram_blink_service.py +19 -31
  140. xp/services/telegram/telegram_checksum_service.py +10 -10
  141. xp/services/telegram/telegram_datapoint_service.py +70 -0
  142. xp/services/telegram/telegram_discover_service.py +58 -29
  143. xp/services/telegram/telegram_link_number_service.py +27 -40
  144. xp/services/telegram/telegram_output_service.py +46 -49
  145. xp/services/telegram/telegram_service.py +41 -41
  146. xp/services/telegram/telegram_version_service.py +4 -2
  147. xp/utils/__init__.py +1 -1
  148. xp/utils/dependencies.py +4 -47
  149. xp/utils/serialization.py +6 -0
  150. xp/utils/time_utils.py +6 -11
  151. conson_xp-1.1.0.dist-info/RECORD +0 -181
  152. xp/api/__init__.py +0 -1
  153. xp/api/main.py +0 -110
  154. xp/api/models/__init__.py +0 -1
  155. xp/api/models/api.py +0 -20
  156. xp/api/models/discover.py +0 -21
  157. xp/api/routers/__init__.py +0 -17
  158. xp/api/routers/conbus.py +0 -5
  159. xp/api/routers/conbus_blink.py +0 -105
  160. xp/api/routers/conbus_custom.py +0 -63
  161. xp/api/routers/conbus_datapoint.py +0 -67
  162. xp/api/routers/conbus_output.py +0 -147
  163. xp/api/routers/errors.py +0 -37
  164. xp/cli/commands/api.py +0 -16
  165. xp/cli/commands/api_start_commands.py +0 -126
  166. xp/services/conbus/conbus_autoreport_get_service.py +0 -85
  167. xp/services/conbus/conbus_autoreport_set_service.py +0 -128
  168. xp/services/conbus/conbus_lightlevel_get_service.py +0 -101
  169. xp/services/conbus/conbus_lightlevel_set_service.py +0 -205
  170. xp/services/conbus/conbus_linknumber_get_service.py +0 -86
  171. xp/services/conbus/conbus_linknumber_set_service.py +0 -155
  172. {conson_xp-1.1.0.dist-info → conson_xp-1.3.0.dist-info}/WHEEL +0 -0
  173. {conson_xp-1.1.0.dist-info → conson_xp-1.3.0.dist-info}/entry_points.txt +0 -0
  174. {conson_xp-1.1.0.dist-info → conson_xp-1.3.0.dist-info}/licenses/LICENSE +0 -0
xp/utils/dependencies.py CHANGED
@@ -21,8 +21,6 @@ from xp.services.conbus.actiontable.msactiontable_xp24_serializer import (
21
21
  from xp.services.conbus.actiontable.msactiontable_xp33_serializer import (
22
22
  Xp33MsActionTableSerializer,
23
23
  )
24
- from xp.services.conbus.conbus_autoreport_get_service import ConbusAutoreportGetService
25
- from xp.services.conbus.conbus_autoreport_set_service import ConbusAutoreportSetService
26
24
  from xp.services.conbus.conbus_blink_all_service import ConbusBlinkAllService
27
25
  from xp.services.conbus.conbus_blink_service import ConbusBlinkService
28
26
  from xp.services.conbus.conbus_custom_service import ConbusCustomService
@@ -33,13 +31,11 @@ from xp.services.conbus.conbus_datapoint_service import (
33
31
  ConbusDatapointService,
34
32
  )
35
33
  from xp.services.conbus.conbus_discover_service import ConbusDiscoverService
36
- from xp.services.conbus.conbus_lightlevel_set_service import ConbusLightlevelSetService
37
- from xp.services.conbus.conbus_linknumber_get_service import ConbusLinknumberGetService
38
- from xp.services.conbus.conbus_linknumber_set_service import ConbusLinknumberSetService
39
34
  from xp.services.conbus.conbus_output_service import ConbusOutputService
40
35
  from xp.services.conbus.conbus_raw_service import ConbusRawService
41
36
  from xp.services.conbus.conbus_receive_service import ConbusReceiveService
42
37
  from xp.services.conbus.conbus_scan_service import ConbusScanService
38
+ from xp.services.conbus.write_config_service import WriteConfigService
43
39
  from xp.services.homekit.homekit_cache_service import HomeKitCacheService
44
40
  from xp.services.homekit.homekit_conbus_service import HomeKitConbusService
45
41
  from xp.services.homekit.homekit_dimminglight_service import HomeKitDimmingLightService
@@ -101,7 +97,6 @@ class ServiceContainer:
101
97
 
102
98
  def _register_services(self) -> None:
103
99
  """Register all services in the container based on dependency graph."""
104
-
105
100
  # ConbusClientConfig
106
101
  self.container.register(
107
102
  ConbusClientConfig,
@@ -192,8 +187,9 @@ class ServiceContainer:
192
187
  )
193
188
 
194
189
  self.container.register(
195
- ConbusLightlevelSetService,
196
- factory=lambda: ConbusLightlevelSetService(
190
+ WriteConfigService,
191
+ factory=lambda: WriteConfigService(
192
+ telegram_service=self.container.resolve(TelegramService),
197
193
  cli_config=self.container.resolve(ConbusClientConfig),
198
194
  reactor=self.container.resolve(PosixReactorBase),
199
195
  ),
@@ -248,45 +244,6 @@ class ServiceContainer:
248
244
  scope=punq.Scope.singleton,
249
245
  )
250
246
 
251
- self.container.register(
252
- ConbusAutoreportSetService,
253
- factory=lambda: ConbusAutoreportSetService(
254
- cli_config=self.container.resolve(ConbusClientConfig),
255
- reactor=self.container.resolve(PosixReactorBase),
256
- ),
257
- scope=punq.Scope.singleton,
258
- )
259
-
260
- self.container.register(
261
- ConbusAutoreportGetService,
262
- factory=lambda: ConbusAutoreportGetService(
263
- telegram_service=self.container.resolve(TelegramService),
264
- cli_config=self.container.resolve(ConbusClientConfig),
265
- reactor=self.container.resolve(PosixReactorBase),
266
- ),
267
- scope=punq.Scope.singleton,
268
- )
269
-
270
- self.container.register(
271
- ConbusLinknumberGetService,
272
- factory=lambda: ConbusLinknumberGetService(
273
- telegram_service=self.container.resolve(TelegramService),
274
- cli_config=self.container.resolve(ConbusClientConfig),
275
- reactor=self.container.resolve(PosixReactorBase),
276
- ),
277
- scope=punq.Scope.singleton,
278
- )
279
-
280
- self.container.register(
281
- ConbusLinknumberSetService,
282
- factory=lambda: ConbusLinknumberSetService(
283
- telegram_service=self.container.resolve(TelegramService),
284
- cli_config=self.container.resolve(ConbusClientConfig),
285
- reactor=self.container.resolve(PosixReactorBase),
286
- ),
287
- scope=punq.Scope.singleton,
288
- )
289
-
290
247
  self.container.register(
291
248
  ConbusCustomService,
292
249
  factory=lambda: ConbusCustomService(
xp/utils/serialization.py CHANGED
@@ -153,6 +153,9 @@ def de_nibble(nibble_str: str) -> int:
153
153
 
154
154
  Returns:
155
155
  Byte value (0-255)
156
+
157
+ Raises:
158
+ ValueError: If nibble string is not exactly 2 characters
156
159
  """
157
160
  if len(nibble_str) != 2:
158
161
  raise ValueError("Nibble string must be exactly 2 characters")
@@ -177,6 +180,9 @@ def de_nibbles(str_val: str) -> bytearray:
177
180
 
178
181
  Returns:
179
182
  List of integers representing the decoded bytes
183
+
184
+ Raises:
185
+ ValueError: If string length is not even for nibble conversion
180
186
  """
181
187
  if len(str_val) % 2 != 0:
182
188
  raise ValueError("String length must be even for nibble conversion")
xp/utils/time_utils.py CHANGED
@@ -6,7 +6,7 @@ from typing import Optional
6
6
 
7
7
 
8
8
  class TimeParsingError(Exception):
9
- """Raised when time parsing fails"""
9
+ """Raised when time parsing fails."""
10
10
 
11
11
  pass
12
12
 
@@ -14,8 +14,7 @@ class TimeParsingError(Exception):
14
14
  def parse_log_timestamp(
15
15
  timestamp_str: str, base_date: Optional[datetime] = None
16
16
  ) -> datetime:
17
- """
18
- Parse timestamp from console bus log format: HH:MM:SS,mmm
17
+ """Parse timestamp from console bus log format: HH:MM:SS,mmm.
19
18
 
20
19
  Args:
21
20
  timestamp_str: Timestamp string (e.g., "22:44:20,352")
@@ -66,8 +65,7 @@ def parse_log_timestamp(
66
65
 
67
66
 
68
67
  def format_log_timestamp(dt: datetime) -> str:
69
- """
70
- Format datetime to console bus log timestamp format: HH:MM:SS,mmm
68
+ """Format datetime to console bus log timestamp format: HH:MM:SS,mmm.
71
69
 
72
70
  Args:
73
71
  dt: datetime object to format
@@ -81,8 +79,7 @@ def format_log_timestamp(dt: datetime) -> str:
81
79
  def parse_time_range(
82
80
  time_range_str: str, base_date: Optional[datetime] = None
83
81
  ) -> tuple[datetime, datetime]:
84
- """
85
- Parse time range string like "22:44:20,352-22:44:25,500"
82
+ """Parse time range string like "22:44:20,352-22:44:25,500".
86
83
 
87
84
  Args:
88
85
  time_range_str: Time range string
@@ -108,8 +105,7 @@ def parse_time_range(
108
105
 
109
106
 
110
107
  def calculate_duration_ms(start_time: datetime, end_time: datetime) -> int:
111
- """
112
- Calculate duration between two timestamps in milliseconds
108
+ """Calculate duration between two timestamps in milliseconds.
113
109
 
114
110
  Args:
115
111
  start_time: Start timestamp
@@ -123,8 +119,7 @@ def calculate_duration_ms(start_time: datetime, end_time: datetime) -> int:
123
119
 
124
120
 
125
121
  def is_valid_log_timestamp(timestamp_str: str) -> bool:
126
- """
127
- Check if timestamp string is valid console bus log format
122
+ """Check if timestamp string is valid console bus log format.
128
123
 
129
124
  Args:
130
125
  timestamp_str: Timestamp string to validate
@@ -1,181 +0,0 @@
1
- conson_xp-1.1.0.dist-info/METADATA,sha256=KNX3bIZASGxhb2Jhka3QNunZP3mYShzXHmoq1KwMMJ8,9296
2
- conson_xp-1.1.0.dist-info/WHEEL,sha256=9P2ygRxDrTJz3gsagc0Z96ukrxjr-LFBGOgv3AuKlCA,90
3
- conson_xp-1.1.0.dist-info/entry_points.txt,sha256=1OcdIcDM1hz3ljCXgybaPUh1IOFEwkaTgLIW9u9zGeg,50
4
- conson_xp-1.1.0.dist-info/licenses/LICENSE,sha256=rxj6woMM-r3YCyGq_UHFtbh7kHTAJgrccH6O-33IDE4,1419
5
- xp/__init__.py,sha256=xf8lEjT8dAYyPp5o_Owqe-WYUCt94T7RPlhhUrh5Tr0,175
6
- xp/api/__init__.py,sha256=fCWjkuTzDlyJ8hIpU_QEBNcah3BB2bqVSfZwmP4ee5k,51
7
- xp/api/main.py,sha256=8OMXUYKnpsqjjnLChokC_M0DXZy-whrxY2dU4QTvr8A,3389
8
- xp/api/models/__init__.py,sha256=Xl8j2qiHc-Vb8b1ZmNZaMj7RtMvk0G_2SOvMgQumYzs,54
9
- xp/api/models/api.py,sha256=a4sfsLihNezgorDx1D820YPiRDzMsmjVzAZDwpQY79g,664
10
- xp/api/models/discover.py,sha256=f5GNNJ0PhQ8eKx4fY8r_80LmP8NRE3Sw58NNKaGmaDg,637
11
- xp/api/routers/__init__.py,sha256=yVfLRQz6iw48vZF_i1cqTCrmy9gycmmmny6iG_1dM24,307
12
- xp/api/routers/conbus.py,sha256=OUlsiAQwH5Xk38ueywvWVhD7LoTfyuUoHnqGtOF4ZCU,134
13
- xp/api/routers/conbus_blink.py,sha256=zixLBlDYC72Tgjr90bo2YHucnB_Bt6KuWX8nC3w4dcE,3624
14
- xp/api/routers/conbus_custom.py,sha256=LFEpzdJak6D9jnYRiFCRvAuoR98AwwdpP9j2lUvxkZs,2247
15
- xp/api/routers/conbus_datapoint.py,sha256=RBzWyUkcI91L1OpL3nP9KTD2fprbifl1VuMES_Sx4ak,2377
16
- xp/api/routers/conbus_output.py,sha256=U-i7kjZv7H6aE0O_8AcZIKZDJuYwU8XostEWoNccnpk,5343
17
- xp/api/routers/errors.py,sha256=5vzpeTt0cPQZDHL5YgrYJUxMh4uI7IgUNFAvL0NpLKM,1267
18
- xp/cli/__init__.py,sha256=KWYwhOU46dNEerlc2i4FHsVR4Fxmt90Pw5L5i2v1Jqc,80
19
- xp/cli/__main__.py,sha256=l2iKwMdat5rTGd3JWs-uGksnYYDDffp_Npz05QdKEeU,117
20
- xp/cli/commands/__init__.py,sha256=dJ_VaOojg14vdx4OwxbDH-egJd16h3uT7f5DSQX4ZB0,4459
21
- xp/cli/commands/api.py,sha256=d9uD5NnDV807suEK6eLzJSl62TGTtFSwIA_foPc6wtg,340
22
- xp/cli/commands/api_start_commands.py,sha256=q9yOkiIY-NmRD04pq3N6rRe-BjnrcMRZmai8Jg5TKhA,3116
23
- xp/cli/commands/conbus/__init__.py,sha256=gE3K5OEoXkkZX8UOc2v3nreQQzwkOQi7n0VZ-Z2juXA,495
24
- xp/cli/commands/conbus/conbus.py,sha256=fVLbAg0kuodUdx9RfE4vVR3L_bc8liDP2cOEyup7ud0,2973
25
- xp/cli/commands/conbus/conbus_actiontable_commands.py,sha256=CjJKFTB_oHENKY165j0lQBBndf9S36K-ykogv7kSppQ,1436
26
- xp/cli/commands/conbus/conbus_autoreport_commands.py,sha256=EfCLZhuDu8uXDVGKE1eJ5Ji9mUauJLoGXqP4zFn2LhA,2501
27
- xp/cli/commands/conbus/conbus_blink_commands.py,sha256=g2zGEXce2aTReCCNp7ph0-uI7YhWEgz_Z048-3YC36w,3696
28
- xp/cli/commands/conbus/conbus_config_commands.py,sha256=Wphy_gxjc5pdPRzw8ElHC3G1jLxoUqmIBe-MFL54LN8,593
29
- xp/cli/commands/conbus/conbus_custom_commands.py,sha256=NH8WDm31-7tb-KYH8nZprEXgo8a4asLWmNd0EgJVSHQ,1336
30
- xp/cli/commands/conbus/conbus_datapoint_commands.py,sha256=Ozc36DFKVfzDZyWU9xVdhebiYy8yodb_DgVKEpzK9Jg,2842
31
- xp/cli/commands/conbus/conbus_discover_commands.py,sha256=5HwuhlC3qyYJqLBuqQVyu5kr493BJOZ281V2pXtfoCY,961
32
- xp/cli/commands/conbus/conbus_lightlevel_commands.py,sha256=hMzQewTgqGNB6s_Pag2HNfImhpgXnitwUVgMM6XXJv8,4161
33
- xp/cli/commands/conbus/conbus_linknumber_commands.py,sha256=IQ_DjBoUOYSkP5JxUuJYaKdxjwcOWGUZz7R-6sFeAAk,2256
34
- xp/cli/commands/conbus/conbus_msactiontable_commands.py,sha256=n1g-ZKjjjbCQqTPGCrcCB595QoRClv0DGvGEx8y7BAY,1728
35
- xp/cli/commands/conbus/conbus_output_commands.py,sha256=Y98-ibcgGB_L52VtczyJqtkGLKESzZjeGvwdLdwM35E,3900
36
- xp/cli/commands/conbus/conbus_raw_commands.py,sha256=NRST1cg9tO7zVUwiTKqCBpwfwP1-yvnKTDrwwIMaz68,1572
37
- xp/cli/commands/conbus/conbus_receive_commands.py,sha256=jV5zAmiIKK3_oDpTs9yF1YklIRcJNvOrkI6O2deb1eQ,1380
38
- xp/cli/commands/conbus/conbus_scan_commands.py,sha256=5SeRL-RZaXkqgKEGA4wt9zayS8GHiPU3yMHBb1kNfj8,1329
39
- xp/cli/commands/file_commands.py,sha256=YEkho5HU5-SEVqTKKWoYPYXI0qWDr9PZaAuEt8fIXak,4855
40
- xp/cli/commands/homekit/__init__.py,sha256=qqwY8ulxTx1S74Mzpb6EKjBLT6fWTNdf9PQ3HKuERKY,50
41
- xp/cli/commands/homekit/homekit.py,sha256=EOaGvXybNlxYxRr4gtml7OtRWbOIV5wVaYfMrpIFJk4,3355
42
- xp/cli/commands/homekit/homekit_start_commands.py,sha256=Y6IyTvD33z1AkQzmSym4LN7XKDpWJ8fGRxh0ItXKw5s,1036
43
- xp/cli/commands/module_commands.py,sha256=v8u6aDKvLQ-zlKNs7dlDbV81XdwAWXwp1hmcEXCjtG8,4869
44
- xp/cli/commands/reverse_proxy_commands.py,sha256=RQ4S-ip2LFm2lt0DTWmabQ32EHAmvemc18F3bJhrA0A,5031
45
- xp/cli/commands/server/__init__.py,sha256=iunDmcaax9U-SHymgGzUlPadGdZLFl9LlhXu2mnyb64,49
46
- xp/cli/commands/server/server_commands.py,sha256=FuDN5aUPemTGFxjGqLzJl2JJ8ExQ6jMGqGhC5iwP0eQ,3691
47
- xp/cli/commands/telegram/__init__.py,sha256=KPhwoU5uscHe3tFAxWXxgFV5OKi9bISBh_TSREnxBFQ,181
48
- xp/cli/commands/telegram/telegram.py,sha256=-8lJDnY_GDS23Ckyn344ye-GEVZ7KxcnPOUwQbrGiWo,964
49
- xp/cli/commands/telegram/telegram_blink_commands.py,sha256=NeCdgEug4iir0XVNy0lz538rpynp6mBWNlarGWUcbrg,2060
50
- xp/cli/commands/telegram/telegram_checksum_commands.py,sha256=T3UyZRoQIafnss05SpTLSD5AdD6W_nCWl0LDtMtfdc0,2970
51
- xp/cli/commands/telegram/telegram_discover_commands.py,sha256=Hy8MvUhUHZqL1ornk0P7uOR_YOB4ahrEY5H1lebDIgw,1115
52
- xp/cli/commands/telegram/telegram_linknumber_commands.py,sha256=9zh3x9rBfxaWDFLR0Roq4PHhqmc5I42nQIpZJMFBpvc,2342
53
- xp/cli/commands/telegram/telegram_parse_commands.py,sha256=RVUs0yHK0mgi77YaEf4wFF05uO_hIrSJLk6JxxxeNBg,2108
54
- xp/cli/commands/telegram/telegram_version_commands.py,sha256=Xo2nDb-_9toWOfOXslK1jMEF8-rHUY12L2DBhhpFgSI,1424
55
- xp/cli/main.py,sha256=qZ1zErt5tN23KzNIlzUxSnLU1RGYReOsxYIgYcJvPOQ,2782
56
- xp/cli/utils/__init__.py,sha256=gTGIj60Uai0iE7sr9_TtEpl04fD7krtTzbbigXUsUVU,46
57
- xp/cli/utils/click_tree.py,sha256=-tJw1LNL8aLBgvcokjKHhj8M4pO1C1_SWDpUAwdYh4Q,1182
58
- xp/cli/utils/datapoint_type_choice.py,sha256=Rj5XNg5stgjM5IJX1AzGBYnLTPmlN7URW_EYd7snsig,1056
59
- xp/cli/utils/decorators.py,sha256=5iGV4PM29KEJF1PC4uLm1dlcKoA3PgBAMeuiPOdjeMs,6296
60
- xp/cli/utils/error_handlers.py,sha256=hKineSAsEdypwb7DlOE6IpHsxxHwW08lRw_S0qHUcyk,5637
61
- xp/cli/utils/formatters.py,sha256=fh5qNq2B5XpEiZZfpQvqXxEhcgtqq_P4a2LfFADuwlc,7751
62
- xp/cli/utils/serial_number_type.py,sha256=CdhY5g_Cg6gEhuQ5onFEq0pCD__jsXX74WCftvY8oMk,963
63
- xp/cli/utils/system_function_choice.py,sha256=bxBe6bJDRWoFlu0nIt5kLo7mH-Zl5jI8506GbBglmCg,1008
64
- xp/cli/utils/xp_module_type.py,sha256=E96hJWpUDK17aIXTII91Y1_VbcNWP8Hd6IGnzk2UEHs,875
65
- xp/connection/__init__.py,sha256=gbqlPa58gaBLQSAakBbrI1lSwxAeYqqe8DgG7kl9rrk,208
66
- xp/connection/exceptions.py,sha256=YwdOpJSqYWZ_fA7eNSOYDDDG1cEN62bBU6Cz77DNTB4,362
67
- xp/models/__init__.py,sha256=-dchbBhm_7uvZjGlCG8lf8X4qokgH5LWU-lSr5EzGhE,1110
68
- xp/models/actiontable/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
69
- xp/models/actiontable/actiontable.py,sha256=BgAzb-wG8pUaVVeZTRARdS8fD_O0c5pSFcTTw3AW-Hg,750
70
- xp/models/actiontable/msactiontable_xp20.py,sha256=JNi2gx0ObbEZ-qq-MNECc4zoCypDpMjoYykLgQ103uM,1542
71
- xp/models/actiontable/msactiontable_xp24.py,sha256=edDG2wCf1IFgUPm4qnfB9GlXHagf5T6JgCLRVJEfBDw,1390
72
- xp/models/actiontable/msactiontable_xp33.py,sha256=vYXJnyqnazUQ_6lkoDnDVh31bo-Mq6-6tQOnYiC766Y,1101
73
- xp/models/conbus/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
74
- xp/models/conbus/conbus.py,sha256=ePdihpX2w-A3t-nrvOpWVNwNoS4cDRJ9jpVvhEM_Jwg,1735
75
- xp/models/conbus/conbus_autoreport.py,sha256=dx9CzlDwDWrLkyvfVsz4dKFouiCl4YcQ80rue97Zfbk,1652
76
- xp/models/conbus/conbus_blink.py,sha256=xwe8A-C1ywbLKYARRUwUEX0sq6QALQiv1C8R3RyQOSM,2196
77
- xp/models/conbus/conbus_client_config.py,sha256=HVaGZkhZI6cBpJaEgybq8TFARyrI9-dM6U6IPc2hOKQ,940
78
- xp/models/conbus/conbus_connection_status.py,sha256=YGrusHpc7cHEG4zU6j0yU-BTICqm0tyymQnblDO4C0Q,706
79
- xp/models/conbus/conbus_custom.py,sha256=hjzL7n5eIWfascyWNA2F6L3W5nnG4JgzAz2wL_chCyI,1322
80
- xp/models/conbus/conbus_datapoint.py,sha256=t41goYkzDf7booC6yBbvlYgX-nH5H0-YE7Yb-JncXJ4,2525
81
- xp/models/conbus/conbus_discover.py,sha256=lLwWkQYMZXMc0cbjx8oFfippE0aFWjfapgfOBIGkMlc,1087
82
- xp/models/conbus/conbus_lightlevel.py,sha256=A4DYVejsTa3_SR37oFfG4XNRqjbOKCDbmHg_vA8PqVM,1091
83
- xp/models/conbus/conbus_linknumber.py,sha256=IaA-Lk6o3KQoEvxcYf9cWNpVdjkzOZIQSPVOylzqCWU,1198
84
- xp/models/conbus/conbus_output.py,sha256=tXAAJqySzbpHJauDEQf8PCYP_hbz31NK5bFs6GUJu_U,1238
85
- xp/models/conbus/conbus_raw.py,sha256=kP_w9_e-qHv-2cDMm4_nAa1g3G8GFlrxOiYXR5IOq8o,994
86
- xp/models/conbus/conbus_receive.py,sha256=hVI3CEGQ74UqqLVH8RhlQvOVtmqlcmeI2kWVY1CPPCI,896
87
- xp/models/homekit/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
88
- xp/models/homekit/homekit_accessory.py,sha256=unL4QshZX4aHR0gWChHLIK0iGfm-WZE4GXSJN4VkyN8,616
89
- xp/models/homekit/homekit_config.py,sha256=hvC5OMn_7oU1TVQ-aYV6BFtA5gfBp6ImSqXkRBBaeU0,1352
90
- xp/models/homekit/homekit_conson_config.py,sha256=XDzFftUF5pv2bhT0PaB1FkIX3h0U1M70v9ylVlACi2Y,990
91
- xp/models/log_entry.py,sha256=5guLL9mCx0-7Ma1OkMl3TI8HRif9CRQ2AtgsgGtszi4,3108
92
- xp/models/protocol/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
93
- xp/models/protocol/conbus_protocol.py,sha256=DLFna5y9kelnO6srM2wRCoaFCtaM_oNDCQtVK3r2lbA,6062
94
- xp/models/response.py,sha256=h6_B1k_v6IrWhgNWBohEGQGRCp5TcVhgQ3RJS8gTkhY,1230
95
- xp/models/telegram/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
96
- xp/models/telegram/action_type.py,sha256=4X6lhcpKGTO80n8qwDvNQea7iZJZRnXamA9wmUIlIQw,468
97
- xp/models/telegram/datapoint_type.py,sha256=DlnK_BGuYwkBgqoTJSg286obwvA9_kLUpZ0_as8hEkA,1714
98
- xp/models/telegram/event_telegram.py,sha256=8s0hufcOaPnlfbHL0UnH7Dco5_zehp4jIaB6HZKCILI,3622
99
- xp/models/telegram/event_type.py,sha256=e7ImqpiQKyotS1U9YJ1NFF4qv0khv2rdzVCJ35LnfAQ,156
100
- xp/models/telegram/input_action_type.py,sha256=QxzQW0fJ9AxN6m4MYm4u0nxE5FIIS5i4vEEnkvibGsA,739
101
- xp/models/telegram/input_type.py,sha256=pOBU4KwLZ6e-7CG5TEWga7RcTA_EN__DOib1HSN4WYU,243
102
- xp/models/telegram/module_type.py,sha256=vZw_zaVLNncew5hTaoSxnMAtauS_TnMx0ljcW0xhbRg,3979
103
- xp/models/telegram/module_type_code.py,sha256=hoXLZ0iOAZOIHyy22Ow_NwXR_tk7foCsHxe5YZsVscQ,6172
104
- xp/models/telegram/output_telegram.py,sha256=OpWLIEZsNNi2JCPPbXD3YcxpgmTapm3sIpz-shq9-dU,2728
105
- xp/models/telegram/reply_telegram.py,sha256=Ew_AxiQky-5GWZt2gOsZ1bDK3BelYw5q65EBsxlWv8k,9205
106
- xp/models/telegram/system_function.py,sha256=Lp-9M0kr337oEoD28akJHKcVmak0M8kO5WS80Y9mtAw,2233
107
- xp/models/telegram/system_telegram.py,sha256=ZjVBIa1rqjkyyT8kcBZwDXrtDOmyCbYR95AATCPB2fQ,2793
108
- xp/models/telegram/telegram.py,sha256=IrdUXDtrt1nUdDiH57V4DR7m3l1UKRov8ezUJMQrQoQ,496
109
- xp/models/telegram/telegram_type.py,sha256=rDmxAcoVWlyiBu7rOESbBfjj2K2Wmtj-U6VOX10YTlc,254
110
- xp/models/telegram/timeparam_type.py,sha256=iamLpHd34u6e6PPTkd6uW8MPDJaPAhrpo5YkTO9eXfw,356
111
- xp/models/write_config_type.py,sha256=zUjI7hO7-gY5wTCfkULjVWdv8tppr3uwPz90AQg7BuU,484
112
- xp/services/__init__.py,sha256=dmFf0QUTHaWx9ycpnvkdivWOlNuGpXd5SY32mnTRrgw,781
113
- xp/services/conbus/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
114
- xp/services/conbus/actiontable/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
115
- xp/services/conbus/actiontable/actiontable_serializer.py,sha256=x45-8d5Ba9l3hX2TFC5nqKv-g_244g-VTWhXvVXL8Jg,5159
116
- xp/services/conbus/actiontable/actiontable_service.py,sha256=GXY0t1FkTefoqSxunPBQHK_3bPgOud2Oq5Q1jERKMaE,4671
117
- xp/services/conbus/actiontable/msactiontable_service.py,sha256=89pxbUVlKd6mplpIeuo8b-B2qxtTeJT5p4KLGkzcVfg,6207
118
- xp/services/conbus/actiontable/msactiontable_xp20_serializer.py,sha256=EYspooOdi0Z8oaXGxpazwnUoTmh-d7U9auhu11iBgmU,6527
119
- xp/services/conbus/actiontable/msactiontable_xp24_serializer.py,sha256=J_ve6uyMmsb_QT2Py1ciZngf4C0pfHpkbWFc8OL2QEk,3752
120
- xp/services/conbus/actiontable/msactiontable_xp33_serializer.py,sha256=AeGBbum5eIqlgVm9t4igfF6vyl-ACVpuzSUQm4TYfUQ,7962
121
- xp/services/conbus/conbus_autoreport_get_service.py,sha256=Jzu8tBIwt9nb9X60LcWnV72wblpVJCZjyfPb45kkCtA,3165
122
- xp/services/conbus/conbus_autoreport_set_service.py,sha256=0fa2xGVE1GSoBvEcOH8cnjAdhvEoamvHE27t40f7lUk,4937
123
- xp/services/conbus/conbus_blink_all_service.py,sha256=t_oaztEFRirjS3nL50AEBrKKpNXYssWwSBwWjWhhKqU,5959
124
- xp/services/conbus/conbus_blink_service.py,sha256=mHaD-84RCmEGqD2cD4Ve85A36D08tMBPwMgDEyAEMCc,5031
125
- xp/services/conbus/conbus_custom_service.py,sha256=jM6B085GTT8epCE9EqVTT8mZLPMXM3tVwvO-yJulJ5s,5290
126
- xp/services/conbus/conbus_datapoint_queryall_service.py,sha256=FBpFmwXVKoTiqMwQW-z2eYbamKL_ZGlTI86720ZcGt8,6095
127
- xp/services/conbus/conbus_datapoint_service.py,sha256=YpInc-Wq4pIjy6ksTWE2mdBSeGWU-VxUNEVyYUi07jM,5577
128
- xp/services/conbus/conbus_discover_service.py,sha256=kA_ewxXgbqXng0cXBjSgQSGYesyesbN2wK0tMp1fgfc,4281
129
- xp/services/conbus/conbus_lightlevel_get_service.py,sha256=Z7Pg_c0sI6gMNnoThN7DruEOGyM3-i4D-rO2WKfHXjw,3699
130
- xp/services/conbus/conbus_lightlevel_set_service.py,sha256=6Mhq9xjWx-ixGVfcWBcJSnuYT256m8Lps1g8Tg-1nkM,7483
131
- xp/services/conbus/conbus_linknumber_get_service.py,sha256=debaacIbwFLUkXwhG0cJ9Wh31rzmWEmd_o1YC9PvpBY,3195
132
- xp/services/conbus/conbus_linknumber_set_service.py,sha256=cmCP8zZ8Szb-vwYHvDbZUyEfZJOjO_zSptJUZhHRctQ,6019
133
- xp/services/conbus/conbus_output_service.py,sha256=w2yBeMdZn3g3wbwUoUnv3gKbqUuGcabeEaH8qw1AyUs,6689
134
- xp/services/conbus/conbus_raw_service.py,sha256=riANTAiXTdSzOWbp_g-IQjdRhAf8CzZnNJtlT-aDvRs,3746
135
- xp/services/conbus/conbus_receive_service.py,sha256=k6hzxh-D4piizb3e5Vsz-2Mfft_5KnAXoov4xk9wVY0,3123
136
- xp/services/conbus/conbus_scan_service.py,sha256=faiSeaNGYRPb9qWsmFE4cjiz3Tkv6vQVZHdwIlPzU9s,4494
137
- xp/services/homekit/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
138
- xp/services/homekit/homekit_cache_service.py,sha256=XMZBTz2ZVTq8OZM3h0Fxu738XPlPRdvq6JLaWMbAS4Q,10289
139
- xp/services/homekit/homekit_conbus_service.py,sha256=71JeM-phBTiGMRr2bEfCiF85eHNIzmxtkCi2Zn0B5uA,2595
140
- xp/services/homekit/homekit_config_validator.py,sha256=zxzF3DtaLqcgLfFPohjmKzysVT9lI_BRg_lMMYgcpw4,8851
141
- xp/services/homekit/homekit_conson_validator.py,sha256=ZK_nW-1fCiY3KGf0k4oEArKkaN90D9y3BbVK82lUM6k,2795
142
- xp/services/homekit/homekit_dimminglight.py,sha256=sBYPFKwVu-UaLEDiXl2V24ACdzwSoBaKQ67-o6WIkAk,4376
143
- xp/services/homekit/homekit_dimminglight_service.py,sha256=CFK58wTVjN7t16MEYMNE8LE5ewPqHqWRlfjQPodI6kc,4368
144
- xp/services/homekit/homekit_hap_service.py,sha256=ffdLB7rLSPOv_pa4iL7zTo4mtFRGt1_fXqsVzeoCoQI,10992
145
- xp/services/homekit/homekit_lightbulb.py,sha256=TGz_olsqJdxoQddVAR2-UgYpYQGB1uMfgC9fJ4pSKwA,2655
146
- xp/services/homekit/homekit_lightbulb_service.py,sha256=wvUyAyPCNiQCtr7gk8xfLl-lOPeKDyZYXdX51d-9N4c,2038
147
- xp/services/homekit/homekit_module_service.py,sha256=9rmLSIQnaFzfDZYGpzF8A4xUgPoDkSvRxlCJm0xlavg,925
148
- xp/services/homekit/homekit_outlet.py,sha256=qgDQExIaJacVH_0NghIMZyV2b8aHjyAoT1sZ1YnEBBA,3941
149
- xp/services/homekit/homekit_outlet_service.py,sha256=V46xx-OgTS65XJiLLQCwL8MIHbiPqj9SegBI10YWDlA,2774
150
- xp/services/homekit/homekit_service.py,sha256=yksnbcqbrckxWTqtJkaaPh_wd2xYH9yCOtLgEAuUA0E,11274
151
- xp/services/log_file_service.py,sha256=E2CSVbw5W_uk13efILb6OGqeERbxCBWjIsCbHjeps_0,10401
152
- xp/services/module_type_service.py,sha256=Q3TFZdiknF24OqGAP6Op1F8_SL8aslkHwPh6o_M7wxM,7010
153
- xp/services/protocol/__init__.py,sha256=XUj54if_nJTfqrEDZfj40nfLr-2xjfKm4CIgHMabp-o,719
154
- xp/services/protocol/conbus_protocol.py,sha256=ePDP3O-xmEFROaOJ-2ndSUpN0TMrVGhodWT66spfdlE,7676
155
- xp/services/protocol/protocol_factory.py,sha256=c3CkMoWAuk9lmHdXIG51B5-S0aIaB7-mHuyULyr_jS4,1248
156
- xp/services/protocol/telegram_protocol.py,sha256=4mybR5gFreN_Kxw04fujt1gKIvr3Mg6O_6WwoTXe2i8,8568
157
- xp/services/reverse_proxy_service.py,sha256=OIPm-9y2I-xf1tESZBfgiLd_hgfGQdgrsxAFdhotmJ0,13231
158
- xp/services/server/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
159
- xp/services/server/base_server_service.py,sha256=URmlNxavEqQv5ugfqW5lGhk2aAaQRWI3C6ydGu907C8,6524
160
- xp/services/server/cp20_server_service.py,sha256=N6qdVV7ZcbrNesCSYlVrZvoS9z1boVyrFAWw-Zm1X8Y,1462
161
- xp/services/server/server_service.py,sha256=UAImbBOCKIRWEnXIn9Spl0PusiaKZTDQRi63VrzOWP4,11994
162
- xp/services/server/xp130_server_service.py,sha256=O-PMtSEq-YoglXSNWxgDRKcDeZwWulUiVFKmijPvEIk,1603
163
- xp/services/server/xp20_server_service.py,sha256=bYzpO3LCbRvA7BmTIBGG79xQHJhIcn3VPbUswST0as8,1213
164
- xp/services/server/xp230_server_service.py,sha256=MQWRQQaZvJkKNA-0OyILDjpT4XlsKaKG8rxTcIIVCaQ,1227
165
- xp/services/server/xp24_server_service.py,sha256=H-5ct5mc0t5HEs6Pz3CY4Idz5cJ93aPFiYbkZfVCL74,3203
166
- xp/services/server/xp33_server_service.py,sha256=OfvPOCQtIfShSc0qzkPfqGaF0AqcthdFDBhNcX6LjXQ,5565
167
- xp/services/telegram/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
168
- xp/services/telegram/telegram_blink_service.py,sha256=3NqTJnXZM_Vo5hQGC2iY4Jo67dOSn-s01lVSFWAZUc0,4635
169
- xp/services/telegram/telegram_checksum_service.py,sha256=tyTIwmvvOqmHiUhl60w_dmq85uRYUnQoSQWS2mDpcmQ,4719
170
- xp/services/telegram/telegram_discover_service.py,sha256=rdZM7eT6dHmJQPRLxRzt2GPjaWDCKm5FqU18Tykcvkg,8177
171
- xp/services/telegram/telegram_link_number_service.py,sha256=8-YNl7HNbdn4RZVLKpU6mW8G5sZZZg6YT87TepHUhzY,7051
172
- xp/services/telegram/telegram_output_service.py,sha256=HLEM2uIG310MbXLyqfoZdyeT1d7xpER0MMTqKXCXaWY,10553
173
- xp/services/telegram/telegram_service.py,sha256=Mp20QB50WDp43QBl8TzsR9BKV_hHP53RUZVzHVZ_FGk,12855
174
- xp/services/telegram/telegram_version_service.py,sha256=21v256THg0lidTyUtp2i8r6TAl8J0CTaZo4bZw59nFk,10479
175
- xp/utils/__init__.py,sha256=clisBctja_VwtkAM9wnbOGDRPfbKHlCUqq4Sa4Z6zng,331
176
- xp/utils/checksum.py,sha256=HDpiQxmdIedbCbZ4o_Box0i_Zig417BtCV_46ZyhiTk,1711
177
- xp/utils/dependencies.py,sha256=PbdI30ug3JCNn1IS9B1jGDEq5wQ_3hDrTLE2Pr-f7AA,19602
178
- xp/utils/event_helper.py,sha256=W-A_xmoXlpWZBbJH6qdaN50o3-XrwFsDgvAGMJDiAgo,1001
179
- xp/utils/serialization.py,sha256=hZcrpzaBOe3a2wS_RFCIRs9PvnYsrbK7Ulq6s1rU0q4,4456
180
- xp/utils/time_utils.py,sha256=Yi3JxHrHsd9ZZxTBRIqlTOz1FYTCeE1IZbefDaXIop8,3800
181
- conson_xp-1.1.0.dist-info/RECORD,,
xp/api/__init__.py DELETED
@@ -1 +0,0 @@
1
- """API module for FastAPI endpoints and models."""
xp/api/main.py DELETED
@@ -1,110 +0,0 @@
1
- """FastAPI application for XP Protocol API endpoints."""
2
-
3
- import logging
4
- import os
5
- from pathlib import Path
6
- from typing import Any
7
-
8
- import yaml
9
- from fastapi import FastAPI
10
- from fastapi.middleware.cors import CORSMiddleware
11
-
12
- from xp.api.routers import conbus
13
- from xp.utils.dependencies import ServiceContainer
14
-
15
- # Set up logging
16
- logging.basicConfig(level=logging.INFO)
17
- logger = logging.getLogger(__name__)
18
-
19
-
20
- def load_api_config() -> dict[str, Any]:
21
- """Load API configuration from api.yml or environment variables."""
22
- config = {
23
- "title": "XP Protocol API",
24
- "description": "REST API for XP Protocol Conbus operations",
25
- "version": "0.2.0",
26
- "cors_origins": ["*"],
27
- "cors_methods": ["GET", "POST"],
28
- "cors_headers": ["*"],
29
- }
30
-
31
- # Try to load from api.yml
32
- try:
33
- if Path("api.yml").exists():
34
- with Path("api.yml").open("r") as file:
35
- file_config = yaml.safe_load(file)
36
- if file_config:
37
- config.update(file_config.get("api", {}))
38
- logger.info("Loaded API configuration from api.yml")
39
- except Exception as e:
40
- logger.warning(f"Could not load api.yml: {e}")
41
-
42
- # Override with environment variables
43
- config["title"] = os.getenv("API_TITLE", config["title"])
44
- config["description"] = os.getenv("API_DESCRIPTION", config["description"])
45
- config["version"] = os.getenv("API_VERSION", config["version"])
46
-
47
- # CORS configuration from environment
48
- cors_origins = os.getenv("CORS_ORIGINS")
49
- if cors_origins is not None:
50
- config["cors_origins"] = cors_origins.split(",")
51
- cors_methods = os.getenv("CORS_METHODS")
52
- if cors_methods is not None:
53
- config["cors_methods"] = cors_methods.split(",")
54
- cors_headers = os.getenv("CORS_HEADERS")
55
- if cors_headers is not None:
56
- config["cors_headers"] = cors_headers.split(",")
57
-
58
- return config
59
-
60
-
61
- def create_app(container: ServiceContainer) -> FastAPI:
62
- """Create and configure the FastAPI application.
63
-
64
- Args:
65
- container: Optional ServiceContainer instance. If not provided, a new one will be created.
66
- """
67
- config = load_api_config()
68
-
69
- fastapi = FastAPI(
70
- title=config["title"],
71
- description=config["description"],
72
- version=config["version"],
73
- docs_url="/docs",
74
- redoc_url="/redoc",
75
- )
76
-
77
- # Add CORS middleware
78
- fastapi.add_middleware(
79
- CORSMiddleware,
80
- allow_origins=config["cors_origins"],
81
- allow_credentials=True,
82
- allow_methods=config["cors_methods"],
83
- allow_headers=config["cors_headers"],
84
- )
85
-
86
- # Initialize service container
87
- fastapi.state.container = container
88
-
89
- # Include routers
90
- fastapi.include_router(conbus.router)
91
-
92
- # Health check endpoint
93
- @fastapi.get("/health")
94
- async def health_check() -> dict[str, str]:
95
- """Health check endpoint."""
96
- return {"status": "healthy", "service": "xp-api"}
97
-
98
- # Root endpoint
99
- @fastapi.get("/")
100
- async def root() -> dict[str, str]:
101
- """Root endpoint with API information."""
102
- return {
103
- "message": "XP Protocol API",
104
- "version": config["version"],
105
- "docs": "/docs",
106
- "health": "/health",
107
- }
108
-
109
- logger.info(f"FastAPI application created: {config['title']} v{config['version']}")
110
- return fastapi
xp/api/models/__init__.py DELETED
@@ -1 +0,0 @@
1
- """API models for request and response validation."""
xp/api/models/api.py DELETED
@@ -1,20 +0,0 @@
1
- """Pydantic models for Input API endpoints."""
2
-
3
- from typing import Optional
4
-
5
- from pydantic import BaseModel, Field
6
-
7
-
8
- class ApiResponse(BaseModel):
9
- """Response model for successful Input operation."""
10
-
11
- success: bool = Field(default=True, description="Operation success status")
12
- result: Optional[str] = Field(default=None, description="Result")
13
- description: Optional[str] = Field(default=None, description="Description")
14
-
15
-
16
- class ApiErrorResponse(BaseModel):
17
- """Response model for failed Input operation."""
18
-
19
- success: bool = Field(default=False, description="Operation success status")
20
- error: str = Field(..., description="Error message")
xp/api/models/discover.py DELETED
@@ -1,21 +0,0 @@
1
- """Pydantic models for discover API endpoints."""
2
-
3
- from typing import List
4
-
5
- from pydantic import BaseModel, Field
6
-
7
-
8
- class DiscoverResponse(BaseModel):
9
- """Response model for successful discover operation."""
10
-
11
- success: bool = Field(default=True, description="Operation success status")
12
- devices: List[str] = Field(
13
- default_factory=list, description="Parsed device information"
14
- )
15
-
16
-
17
- class DiscoverErrorResponse(BaseModel):
18
- """Response model for failed discover operation."""
19
-
20
- success: bool = Field(default=False, description="Operation success status")
21
- error: str = Field(..., description="Error message")
@@ -1,17 +0,0 @@
1
- """API routers for FastAPI endpoints."""
2
-
3
- from xp.api.routers import (
4
- conbus_blink,
5
- conbus_custom,
6
- conbus_datapoint,
7
- conbus_output,
8
- )
9
- from xp.api.routers.conbus import router
10
-
11
- __all__ = [
12
- "router",
13
- "conbus_blink",
14
- "conbus_custom",
15
- "conbus_datapoint",
16
- "conbus_output",
17
- ]
xp/api/routers/conbus.py DELETED
@@ -1,5 +0,0 @@
1
- """FastAPI router for Conbus operations."""
2
-
3
- from fastapi import APIRouter
4
-
5
- router = APIRouter(prefix="/api/conbus", tags=["conbus"])
@@ -1,105 +0,0 @@
1
- """FastAPI router for Conbus operations."""
2
-
3
- import json
4
- import logging
5
- from typing import Union
6
-
7
- from fastapi import Request
8
- from fastapi.responses import JSONResponse
9
-
10
- from xp.api.models.api import ApiErrorResponse, ApiResponse
11
- from xp.api.routers.conbus import router
12
- from xp.api.routers.errors import handle_service_error
13
- from xp.services.conbus.conbus_blink_service import ConbusBlinkService
14
-
15
- logger = logging.getLogger(__name__)
16
-
17
-
18
- @router.get(
19
- "/blink/on/{serial_number}",
20
- response_model=Union[ApiResponse, ApiErrorResponse],
21
- responses={
22
- 200: {"model": ApiResponse, "description": "Input completed successfully"},
23
- 400: {"model": ApiErrorResponse, "description": "Connection or request error"},
24
- 408: {"model": ApiErrorResponse, "description": "Request timeout"},
25
- 500: {"model": ApiErrorResponse, "description": "Internal server error"},
26
- },
27
- )
28
- async def blink_on(
29
- request: Request,
30
- serial_number: str = "1702033007",
31
- ) -> Union[ApiResponse, ApiErrorResponse, JSONResponse]:
32
- """
33
- Initiate Input operation to find devices on the network.
34
-
35
- Sends a broadcastInput telegram and collects responses from all connected devices.
36
- """
37
- service = request.app.state.container.get_container().resolve(ConbusBlinkService)
38
-
39
- # SendInput telegram and receive responses
40
- with service:
41
- response = service.send_blink_telegram(
42
- serial_number=serial_number, on_or_off="on"
43
- )
44
-
45
- if not response.success:
46
- return handle_service_error(response.error or "Unknown error")
47
-
48
- logger.debug(json.dumps(response.to_dict(), indent=2))
49
-
50
- # Build successful response
51
- return ApiResponse(
52
- success=True,
53
- result=response.system_function.name,
54
- description=(
55
- response.reply_telegram.system_function.get_description()
56
- if response.reply_telegram and response.reply_telegram.system_function
57
- else None
58
- ),
59
- # raw_telegram = response.output_telegram.raw_telegram,
60
- )
61
-
62
-
63
- @router.get(
64
- "/blink/off/{serial_number}",
65
- response_model=Union[ApiResponse, ApiErrorResponse],
66
- responses={
67
- 200: {"model": ApiResponse, "description": "Input completed successfully"},
68
- 400: {"model": ApiErrorResponse, "description": "Connection or request error"},
69
- 408: {"model": ApiErrorResponse, "description": "Request timeout"},
70
- 500: {"model": ApiErrorResponse, "description": "Internal server error"},
71
- },
72
- )
73
- async def blink_off(
74
- request: Request,
75
- serial_number: str = "1702033007",
76
- ) -> Union[ApiResponse, ApiErrorResponse, JSONResponse]:
77
- """
78
- Initiate Input operation to find devices on the network.
79
-
80
- Sends a broadcastInput telegram and collects responses from all connected devices.
81
- """
82
- service = request.app.state.container.get_container().resolve(ConbusBlinkService)
83
-
84
- # SendInput telegram and receive responses
85
- with service:
86
- response = service.send_blink_telegram(
87
- serial_number=serial_number, on_or_off="off"
88
- )
89
-
90
- if not response.success:
91
- return handle_service_error(response.error or "Unknown error")
92
-
93
- logger.debug(json.dumps(response.to_dict(), indent=2))
94
-
95
- # Build successful response
96
- return ApiResponse(
97
- success=True,
98
- result=response.system_function.name,
99
- description=(
100
- response.reply_telegram.system_function.get_description()
101
- if response.reply_telegram and response.reply_telegram.system_function
102
- else None
103
- ),
104
- # raw_telegram = response.output_telegram.raw_telegram,
105
- )