aiohomematic-test-support 2025.12.23__py3-none-any.whl → 2025.12.42__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.
- aiohomematic_test_support/__init__.py +2 -2
- aiohomematic_test_support/const.py +24 -365
- aiohomematic_test_support/data/device_translation.json +364 -0
- aiohomematic_test_support/factory.py +60 -21
- aiohomematic_test_support/mock.py +36 -15
- {aiohomematic_test_support-2025.12.23.dist-info → aiohomematic_test_support-2025.12.42.dist-info}/METADATA +1 -1
- aiohomematic_test_support-2025.12.42.dist-info/RECORD +13 -0
- aiohomematic_test_support-2025.12.23.dist-info/RECORD +0 -12
- {aiohomematic_test_support-2025.12.23.dist-info → aiohomematic_test_support-2025.12.42.dist-info}/WHEEL +0 -0
- {aiohomematic_test_support-2025.12.23.dist-info → aiohomematic_test_support-2025.12.42.dist-info}/top_level.txt +0 -0
|
@@ -30,7 +30,7 @@ Using the factory to create a test central with session playback:
|
|
|
30
30
|
|
|
31
31
|
# Test operations
|
|
32
32
|
await central.start()
|
|
33
|
-
device = central.get_device_by_address("VCU0000001")
|
|
33
|
+
device = central.device_coordinator.get_device_by_address("VCU0000001")
|
|
34
34
|
await central.stop()
|
|
35
35
|
|
|
36
36
|
The session player replays pre-recorded backend responses, enabling fast and
|
|
@@ -45,4 +45,4 @@ test dependencies to access test support functionality.
|
|
|
45
45
|
|
|
46
46
|
from __future__ import annotations
|
|
47
47
|
|
|
48
|
-
__version__ = "2025.12.
|
|
48
|
+
__version__ = "2025.12.42"
|
|
@@ -2,8 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
|
+
import functools
|
|
6
|
+
import json
|
|
7
|
+
import os
|
|
8
|
+
from typing import cast
|
|
9
|
+
|
|
5
10
|
from aiohomematic.client.json_rpc import _JsonKey
|
|
6
|
-
from aiohomematic.const import LOCAL_HOST, HubValueType, Interface, ProgramData, SystemVariableData
|
|
11
|
+
from aiohomematic.const import LOCAL_HOST, UTF_8, HubValueType, Interface, ProgramData, SystemVariableData
|
|
7
12
|
|
|
8
13
|
CENTRAL_NAME = "CentralTest"
|
|
9
14
|
CCU_HOST = LOCAL_HOST
|
|
@@ -237,367 +242,21 @@ PROGRAM_DATA_JSON_DESCRIPTION = [
|
|
|
237
242
|
for p in PROGRAM_DATA
|
|
238
243
|
]
|
|
239
244
|
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
"
|
|
244
|
-
"
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
"
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
"VCU0000275": "HM-Sen-Wa-Od.json",
|
|
259
|
-
"VCU5092447": "HmIP-SMO-A.json",
|
|
260
|
-
"VCU3941846": "HMIP-PSM.json",
|
|
261
|
-
"VCU4984404": "HmIPW-STHD.json",
|
|
262
|
-
"VCU0000026": "HM-WDS20-TH-O.json",
|
|
263
|
-
"VCU0000064": "HM-LC-Dim1L-Pl-2.json",
|
|
264
|
-
"VCU1150287": "HmIP-HAP.json",
|
|
265
|
-
"VCU0000348": "HM-Sec-WDS.json",
|
|
266
|
-
"VCU0000017": "HM-PB-4Dis-WM.json",
|
|
267
|
-
"VCU3560967": "HmIP-HDM1.json",
|
|
268
|
-
"VCU0000287": "HM-LC-Sw2PBU-FM.json",
|
|
269
|
-
"VCU0000014": "HMW-LC-Sw2-DR.json",
|
|
270
|
-
"VCU0000155": "OLIGO.smart.iq.HM.json",
|
|
271
|
-
"VCU0000343": "HM-Sec-TiS.json",
|
|
272
|
-
"VCU5864966": "HmIP-SWDO-I.json",
|
|
273
|
-
"VCU0000150": "KS550.json",
|
|
274
|
-
"VCU0000121": "HM-LC-Dim1L-Pl.json",
|
|
275
|
-
"VCU0000177": "HM-RC-Key4-2.json",
|
|
276
|
-
"VCU0000216": "HM-Sec-RHS.json",
|
|
277
|
-
"VCU0000142": "HM-Dis-TD-T.json",
|
|
278
|
-
"VCU0000305": "HM-LC-Sw1-Pl-CT-R1.json",
|
|
279
|
-
"VCU0000131": "HM-ES-PMSw1-Pl-DN-R3.json",
|
|
280
|
-
"VCU0000114": "HM-Dis-WM55.json",
|
|
281
|
-
"VCU0000105": "263 134.json",
|
|
282
|
-
"VCU0000334": "HM-LC-Sw2-DR.json",
|
|
283
|
-
"VCU0000328": "HM-LC-Sw1-FM.json",
|
|
284
|
-
"VCU4264293": "HmIP-RCV-50.json",
|
|
285
|
-
"VCU0000196": "HM-RC-12-SW.json",
|
|
286
|
-
"VCU0000310": "HM-LC-Sw1-PCB.json",
|
|
287
|
-
"VCU0000002": "HMW-IO-12-Sw14-DR.json",
|
|
288
|
-
"VCU0000138": "HM-ES-PMSwX.json",
|
|
289
|
-
"VCU4613288": "HmIP-FROLL.json",
|
|
290
|
-
"VCU0000130": "HM-ES-PMSw1-Pl-DN-R2.json",
|
|
291
|
-
"VCU8655720": "HmIP-CCU3.json",
|
|
292
|
-
"VCU0000166": "263 135.json",
|
|
293
|
-
"VCU0000339": "HM-LC-Sw1-SM-ATmega168.json",
|
|
294
|
-
"VCU0000353": "WS888.json",
|
|
295
|
-
"VCU0000178": "HM-RC-Key4-3.json",
|
|
296
|
-
"VCU1289997": "HmIP-SPDR.json",
|
|
297
|
-
"VCU0000252": "263 162.json",
|
|
298
|
-
"VCU0000198": "HM-RC-19-B.json",
|
|
299
|
-
"VCU0000016": "HMW-Sen-SC-12-FM.json",
|
|
300
|
-
"VCU1815001": "HmIP-SWD.json",
|
|
301
|
-
"VCU7171997": "HB-WDS40-THP-O.json",
|
|
302
|
-
"VCU0000100": "HM-LC-Dim2T-SM-2.json",
|
|
303
|
-
"VCU0000167": "HM-PB-2-FM.json",
|
|
304
|
-
"VCU0000239": "ZEL STG RM FFK.json",
|
|
305
|
-
"VCU2721398": "HmIPW-DRI32.json",
|
|
306
|
-
"VCU0000345": "HM-WDS30-OT2-SM-2.json",
|
|
307
|
-
"VCU0000025": "263 158.json",
|
|
308
|
-
"VCU0000280": "HM-SwI-X.json",
|
|
309
|
-
"VCU1673350": "HmIPW-FIO6.json",
|
|
310
|
-
"VCU0000073": "HM-LC-Dim1L-Pl-3.json",
|
|
311
|
-
"VCU5429697": "HmIP-SAM.json",
|
|
312
|
-
"VCU0000096": "HM-LC-Dim2L-SM-2.json",
|
|
313
|
-
"VCU0000236": "S550IA.json",
|
|
314
|
-
"VCU0000211": "ZEL STG RM FDK.json",
|
|
315
|
-
"VCU7808411": "HmIP-eTRV-B1.json",
|
|
316
|
-
"VCU8333683": "HmIP-SWDM-B2.json",
|
|
317
|
-
"VCU0000054": "HM-CC-TC.json",
|
|
318
|
-
"VCU0000169": "ZEL STG RM FST UP4.json",
|
|
319
|
-
"VCU4523900": "HmIP-STHO.json",
|
|
320
|
-
"VCU0000340": "HM-LC-Sw4-SM-ATmega168.json",
|
|
321
|
-
"VCU0000087": "HM-LC-Dim1T-Pl-3.json",
|
|
322
|
-
"VCU0000137": "HM-ES-PMSw1-Pl.json",
|
|
323
|
-
"VCU0000175": "HM-RC-4-3.json",
|
|
324
|
-
"VCU0000341": "HM-TC-IT-WM-W-EU.json",
|
|
325
|
-
"VCU0000300": "HM-LC-Sw1-Pl-DN-R2.json",
|
|
326
|
-
"VCU0000081": "HM-LC-Dim1TPBU-FM-2.json",
|
|
327
|
-
"VCU0000240": "HM-Sec-SC-2.json",
|
|
328
|
-
"VCU8066814": "RPI-RF-MOD.json",
|
|
329
|
-
"VCU4898089": "HmIP-KRC4.json",
|
|
330
|
-
"VCU1954019": "HmIP-FAL230-C10.json",
|
|
331
|
-
"VCU0000350": "HM-Sec-Win.json",
|
|
332
|
-
"VCU0000243": "HM-SCI-3-FM.json",
|
|
333
|
-
"VCU0000023": "ASH550.json",
|
|
334
|
-
"VCU4567298": "HmIP-DBB.json",
|
|
335
|
-
"VCU8492627": "HB-UNI-Sensor1.json",
|
|
336
|
-
"VCU0000218": "WDF solar.json",
|
|
337
|
-
"VCU0000327": "HM-LC-Sw4-WM.json",
|
|
338
|
-
"VCU0000208": "HM-ReSC-Win-PCB-xx.json",
|
|
339
|
-
"VCU0000278": "ZEL STG RM FSS UP3.json",
|
|
340
|
-
"VCU0000122": "HM-LC-Dim1L-CV.json",
|
|
341
|
-
"VCU0000004": "HMW-IO-12-Sw7-DR.json",
|
|
342
|
-
"VCU0000055": "HM-CC-VD.json",
|
|
343
|
-
"VCU0000135": "HM-ES-PMSw1-SM.json",
|
|
344
|
-
"VCU0000296": "HM-LC-Sw2-FM-2.json",
|
|
345
|
-
"VCU3790312": "HmIP-SWO-B.json",
|
|
346
|
-
"VCU0000256": "HM-Sec-SD-Generic.json",
|
|
347
|
-
"VCU0000148": "HM-Sec-Key-O.json",
|
|
348
|
-
"VCU7652142": "HmIP-SRD.json",
|
|
349
|
-
"VCU0000183": "HM-RC-P1.json",
|
|
350
|
-
"VCU0000115": "HM-LC-DW-WM.json",
|
|
351
|
-
"VCU0000322": "HM-LC-Sw1-Pl-2.json",
|
|
352
|
-
"VCU0000193": "HM-RC-X.json",
|
|
353
|
-
"VCU0000060": "HM-OU-CFM-TW.json",
|
|
354
|
-
"VCU1891174": "HmIPW-DRS8.json",
|
|
355
|
-
"VCU6874371": "HmIP-MOD-RC8.json",
|
|
356
|
-
"VCU0000010": "HMW-LC-Bl1-DR-2.json",
|
|
357
|
-
"VCU0000273": "HM-MD.json",
|
|
358
|
-
"VCU0000018": "ZEL STG RM DWT 10.json",
|
|
359
|
-
"VCU0000337": "HM-LC-SwX.json",
|
|
360
|
-
"VCU0000133": "HM-ES-PMSw1-Pl-DN-R5.json",
|
|
361
|
-
"VCU0000247": "HM-Sec-MDIR-2.json",
|
|
362
|
-
"VCU6354483": "HmIP-STHD.json",
|
|
363
|
-
"VCU0000066": "263 132.json",
|
|
364
|
-
"VCU0000330": "HM-LC-Sw2-FM.json",
|
|
365
|
-
"VCU1769958": "HmIP-BWTH.json",
|
|
366
|
-
"VCU0000203": "BRC-H.json",
|
|
367
|
-
"VCU0000304": "HM-LC-Sw1-DR.json",
|
|
368
|
-
"VCU2118827": "HmIP-DLS.json",
|
|
369
|
-
"VCU0000165": "ZEL STG RM WT 2.json",
|
|
370
|
-
"VCU0000199": "HM-RC-19-SW.json",
|
|
371
|
-
"VCU5778428": "HmIP-HEATING.json",
|
|
372
|
-
"VCU0000201": "HM-RC-2-PBU-FM-2.json",
|
|
373
|
-
"VCU1437294": "HmIP-SMI.json",
|
|
374
|
-
"VCU0000293": "HM-LC-Sw4-PCB-2.json",
|
|
375
|
-
"VCU7981740": "HmIP-SRH.json",
|
|
376
|
-
"VCU0000170": "263 145.json",
|
|
377
|
-
"VCU3056370": "HmIP-SLO.json",
|
|
378
|
-
"VCU4243444": "HmIP-WRCD.json",
|
|
379
|
-
"VCU0000036": "HM-LC-Bl1-SM-2.json",
|
|
380
|
-
"VCU0000159": "HM-OU-X.json",
|
|
381
|
-
"VCU0000303": "HM-LC-Sw1-Pl-DN-R5.json",
|
|
382
|
-
"VCU9834159": "HB-LC-Bl1PBU-FM.json",
|
|
383
|
-
"VCU0000251": "HM-Sec-MDIR.json",
|
|
384
|
-
"VCU0000357": "HM-WDC7000.json",
|
|
385
|
-
"VCU0000111": "HM-LC-Dim1T-FM.json",
|
|
386
|
-
"VCU0000277": "HM-SwI-3-FM.json",
|
|
387
|
-
"VCU0000152": "KS550Tech.json",
|
|
388
|
-
"VCU0000188": "HM-PB-4-WM.json",
|
|
389
|
-
"VCU1543608": "HmIP-MP3P.json",
|
|
390
|
-
"VCU0000037": "HM-LC-Bl1-FM-2.json",
|
|
391
|
-
"VCU0000164": "HM-PB-2-WM55.json",
|
|
392
|
-
"VCU0000045": "HM-LC-Bl1-FM.json",
|
|
393
|
-
"VCU0000276": "ST6-SH.json",
|
|
394
|
-
"VCU2128127": "HmIP-BSM.json",
|
|
395
|
-
"VCU6985973": "HmIP-BSL.json",
|
|
396
|
-
"VCU6153495": "HmIP-FCI1.json",
|
|
397
|
-
"VCU0000265": "HM-Sen-LI-O.json",
|
|
398
|
-
"VCU0000146": "HM-Sec-Key.json",
|
|
399
|
-
"VCU2737768": "HMIP-SWDO.json",
|
|
400
|
-
"VCU0000143": "HM-WDS100-C6-O-2.json",
|
|
401
|
-
"VCU0000302": "HM-LC-Sw1-Pl-DN-R4.json",
|
|
402
|
-
"VCU0000057": "HM-RCV-50.json",
|
|
403
|
-
"VCU1152627": "HmIP-RC8.json",
|
|
404
|
-
"VCU0000336": "ZEL STG RM FZS-2.json",
|
|
405
|
-
"VCU0000279": "263 144.json",
|
|
406
|
-
"VCU0000012": "HMW-LC-Dim1L-DR.json",
|
|
407
|
-
"VCU0000094": "HM-LC-Dim1T-FM-LF.json",
|
|
408
|
-
"VCU0000292": "HM-LC-Sw4-SM-2.json",
|
|
409
|
-
"VCU7204276": "HmIP-DRSI4.json",
|
|
410
|
-
"VCU2333555": "HmIP-FSI16.json",
|
|
411
|
-
"VCU5424977": "HmIP-DSD-PCB.json",
|
|
412
|
-
"VCU8063453": "HmIP-STH.json",
|
|
413
|
-
"VCU0000237": "HM-WDS30-T-O.json",
|
|
414
|
-
"VCU0000332": "HM-LC-Sw2-PB-FM.json",
|
|
415
|
-
"VCU0000021": "HM-LC-AO-SM.json",
|
|
416
|
-
"VCU0000264": "HM-Sen-X.json",
|
|
417
|
-
"VCU0000132": "HM-ES-PMSw1-Pl-DN-R4.json",
|
|
418
|
-
"VCU0000246": "HM-Sec-MDIR-3.json",
|
|
419
|
-
"VCU0000145": "HM-LC-JaX.json",
|
|
420
|
-
"VCU0000083": "263 133.json",
|
|
421
|
-
"VCU0000346": "HM-WDS40-TH-I-2.json",
|
|
422
|
-
"VCU0000182": "HM-RC-4-B.json",
|
|
423
|
-
"VCU0000190": "RC-H.json",
|
|
424
|
-
"VCU7447418": "HmIP-PCBS2.json",
|
|
425
|
-
"VCU9344471": "HmIP-SPI.json",
|
|
426
|
-
"VCU0000351": "HM-Sec-Win-Generic.json",
|
|
427
|
-
"VCU0000015": "HMW-Sen-SC-12-DR.json",
|
|
428
|
-
"VCU7935803": "HMIP-WRC2.json",
|
|
429
|
-
"VCU0000289": "HM-LC-Sw1-Pl-3.json",
|
|
430
|
-
"VCU2680226": "HmIP-WTH-2.json",
|
|
431
|
-
"VCU6306084": "HmIP-BRC2.json",
|
|
432
|
-
"VCU0000335": "ZEL STG RM FZS.json",
|
|
433
|
-
"VCU0000168": "HM-PBI-4-FM.json",
|
|
434
|
-
"VCU0000074": "HM-LC-Dim1L-CV-2.json",
|
|
435
|
-
"VCU0000288": "HM-LC-Sw4-Ba-PCB.json",
|
|
436
|
-
"VCU2573721": "HmIP-SMO-2.json",
|
|
437
|
-
"VCU0000180": "HM-RC-Sec4-3.json",
|
|
438
|
-
"VCU0000181": "HM-RC-4.json",
|
|
439
|
-
"VCU0000186": "HM-RC-Key3.json",
|
|
440
|
-
"VCU0000272": "HM-Sen-MDIR-O.json",
|
|
441
|
-
"VCU0000329": "263 130.json",
|
|
442
|
-
"VCU0000309": "HM-LC-Sw1-Pl-CT-R5.json",
|
|
443
|
-
"VCU5980155": "HmIP-PCBS-BAT.json",
|
|
444
|
-
"INT0000001": "HM-CC-VG-1.json",
|
|
445
|
-
"VCU0000354": "WS550Tech.json",
|
|
446
|
-
"VCU0000259": "263 167.json",
|
|
447
|
-
"VCU0000344": "HM-WDS30-OT2-SM.json",
|
|
448
|
-
"VCU8249617": "HmIP-ASIR-2.json",
|
|
449
|
-
"VCU0000158": "HM-OU-LED16.json",
|
|
450
|
-
"VCU1004487": "HmIPW-DRAP.json",
|
|
451
|
-
"VCU0000290": "HM-LC-Sw1-SM-2.json",
|
|
452
|
-
"VCU7549831": "HmIP-STE2-PCB.json",
|
|
453
|
-
"VCU0000082": "HM-LC-Dim1TPBU-FM.json",
|
|
454
|
-
"VCU0000321": "HM-LC-Sw1-Pl.json",
|
|
455
|
-
"VCU0000206": "HM-Sen-RD-O.json",
|
|
456
|
-
"VCU9724704": "HmIP-DLD.json",
|
|
457
|
-
"VCU1768323": "HmIP-eTRV-C-2.json",
|
|
458
|
-
"VCU0000217": "HM-Sec-xx.json",
|
|
459
|
-
"VCU0000123": "HM-LC-Dim2L-CV.json",
|
|
460
|
-
"VCU0000295": "HM-LC-Sw1-FM-2.json",
|
|
461
|
-
"VCU0000056": "ZEL STG RM FSA.json",
|
|
462
|
-
"VCU0000078": "HM-LC-Dim1PWM-CV-2.json",
|
|
463
|
-
"VCU0000001": "HMW-RCV-50.json",
|
|
464
|
-
"VCU0000051": "HM-CC-RT-DN-BoM.json",
|
|
465
|
-
"VCU0000153": "KS550LC.json",
|
|
466
|
-
"VCU0000174": "HM-RC-8.json",
|
|
467
|
-
"VCU0000192": "ZEL STG RM HS 4.json",
|
|
468
|
-
"VCU0000171": "HM-PBI-X.json",
|
|
469
|
-
"VCU0000027": "HM-WDS40-TH-I.json",
|
|
470
|
-
"VCU0000088": "HM-LC-Dim1T-CV-2.json",
|
|
471
|
-
"VCU0000043": "263 147.json",
|
|
472
|
-
"VCU8205532": "HmIP-SCTH230.json",
|
|
473
|
-
"VCU0000266": "HM-Sen-MDIR-O-3.json",
|
|
474
|
-
"VCU0000352": "WS550.json",
|
|
475
|
-
"VCU0000331": "HM-LC-Sw1-PB-FM.json",
|
|
476
|
-
"VCU3880755": "HB-UNI-Sensor-THPD-BME280.json",
|
|
477
|
-
"VCU0000020": "HM-PB-4Dis-WM-2.json",
|
|
478
|
-
"VCU0000267": "HM-Sen-MDIR-O-2.json",
|
|
479
|
-
"VCU2407364": "HmIP-PCBS.json",
|
|
480
|
-
"VCU1841406": "HmIP-SWO-PL.json",
|
|
481
|
-
"VCU2826390": "HmIPW-STH.json",
|
|
482
|
-
"VCU0000197": "HM-RC-19.json",
|
|
483
|
-
"VCU0000260": "HM-Sec-SFA-SM.json",
|
|
484
|
-
"VCU0000007": "HMW-IO-4-FM.json",
|
|
485
|
-
"VCU3188750": "HmIP-WGC.json",
|
|
486
|
-
"VCU0000048": "263 146.json",
|
|
487
|
-
"VCU0000062": "CMM.json",
|
|
488
|
-
"VCU3609622": "HmIP-eTRV-2.json",
|
|
489
|
-
"VCU4743739": "HmIPW-SPI.json",
|
|
490
|
-
"VCU0000294": "HM-LC-Sw4-WM-2.json",
|
|
491
|
-
"VCU0000187": "HM-RC-Key3-B.json",
|
|
492
|
-
"VCU6948166": "HmIP-DRDI3.json",
|
|
493
|
-
"VCU0000311": "HM-MOD-Re-8.json",
|
|
494
|
-
"VCU0000202": "HM-RC-Dis-H-x-EU.json",
|
|
495
|
-
"VCU5801873": "HmIP-PMFS.json",
|
|
496
|
-
"VCU0000209": "HM-LC-RGBW-WM.json",
|
|
497
|
-
"VCU0000324": "HM-LC-Sw2-SM.json",
|
|
498
|
-
"VCU5644414": "HmIP-SWDM.json",
|
|
499
|
-
"VCU0000262": "HM-Sen-DB-PCB.json",
|
|
500
|
-
"VCU8539034": "HmIP-WRCR.json",
|
|
501
|
-
"VCU0000022": "ASH550I.json",
|
|
502
|
-
"VCU0000126": "HM-MOD-EM-8.json",
|
|
503
|
-
"VCU0000149": "HM-Sec-Key-Generic.json",
|
|
504
|
-
"VCU0000151": "KS888.json",
|
|
505
|
-
"VCU0000059": "HM-OU-CFM-Pl.json",
|
|
506
|
-
"VCU0000254": "HM-Sec-SCo.json",
|
|
507
|
-
"VCU3015080": "HmIP-SCI.json",
|
|
508
|
-
"VCU0000125": "HSS-DX.json",
|
|
509
|
-
"VCU0000049": "HM-LC-BlX.json",
|
|
510
|
-
"VCU0000333": "HM-LC-Sw4-DR.json",
|
|
511
|
-
"VCU0000047": "ZEL STG RM FEP 230V.json",
|
|
512
|
-
"VCU0000312": "HM-LC-Sw1-Ba-PCB.json",
|
|
513
|
-
"VCU1494703": "HmIP-eTRV-E.json",
|
|
514
|
-
"VCU0000070": "HM-LC-DDC1-PCB.json",
|
|
515
|
-
"VCU0000053": "ZEL STG RM FWT.json",
|
|
516
|
-
"VCU0000005": "HMW-IO-12-FM.json",
|
|
517
|
-
"VCU9333179": "HmIP-ASIR.json",
|
|
518
|
-
"VCU0000046": "HM-LC-Bl1-PB-FM.json",
|
|
519
|
-
"VCU0000204": "HM-RC-SB-X.json",
|
|
520
|
-
"VCU0000207": "HM-Sys-sRP-Pl.json",
|
|
521
|
-
"VCU0000286": "263 131.json",
|
|
522
|
-
"VCU0000308": "HM-LC-Sw1-Pl-CT-R4.json",
|
|
523
|
-
"VCU8126977": "HmIP-MOD-OC8.json",
|
|
524
|
-
"VCU4704397": "HmIPW-WRC6.json",
|
|
525
|
-
"VCU7807849": "HmIPW-DRBL4.json",
|
|
526
|
-
"VCU0000255": "HM-Sec-SD.json",
|
|
527
|
-
"VCU5597068": "HmIPW-SMI55.json",
|
|
528
|
-
"VCU0000179": "HM-RC-Sec4-2.json",
|
|
529
|
-
"VCU1399816": "HmIP-BDT.json",
|
|
530
|
-
"VCU0000044": "HM-LC-Bl1-SM.json",
|
|
531
|
-
"VCU0000297": "HM-LC-Sw4-DR-2.json",
|
|
532
|
-
"VCU0000191": "atent.json",
|
|
533
|
-
"VCU0000089": "HM-LC-Dim1T-FM-2.json",
|
|
534
|
-
"VCU0000029": "IS-WDS-TH-OD-S-R3.json",
|
|
535
|
-
"VCU8255833": "HmIP-STHO-A.json",
|
|
536
|
-
"VCU1803301": "HmIP-USBSM.json",
|
|
537
|
-
"VCU9933791": "HmIPW-DRD3.json",
|
|
538
|
-
"VCU0000299": "HM-LC-Sw1-Pl-DN-R1.json",
|
|
539
|
-
"VCU1366171": "HMIP-PS.json",
|
|
540
|
-
"VCU6977344": "HmIP-MIO16-PCB.json",
|
|
541
|
-
"VCU0000212": "HM-Sec-RHS-2.json",
|
|
542
|
-
"VCU0000028": "263 157.json",
|
|
543
|
-
"VCU0000108": "HM-LC-Dim1T-Pl.json",
|
|
544
|
-
"VCU2913614": "HmIP-WHS2.json",
|
|
545
|
-
"VCU8585352": "HmIP-DRSI1.json",
|
|
546
|
-
"VCU8451105": "HmIPW-WTH.json",
|
|
547
|
-
"VCU1362746": "HmIP-SWO-PR.json",
|
|
548
|
-
"VCU7631078": "HmIP-FDT.json",
|
|
549
|
-
"VCU0000154": "HM-WDS100-C6-O.json",
|
|
550
|
-
"VCU0000356": "WS550LCW.json",
|
|
551
|
-
"VCU0000124": "HM-LC-Dim2L-SM.json",
|
|
552
|
-
"VCU0000253": "HM-Sec-MD.json",
|
|
553
|
-
"VCU0000113": "HM-Dis-EP-WM55.json",
|
|
554
|
-
"VCU0000245": "HM-Sec-SC.json",
|
|
555
|
-
"VCU1223813": "HmIP-FBL.json",
|
|
556
|
-
"VCU0000307": "HM-LC-Sw1-Pl-CT-R3.json",
|
|
557
|
-
"VCU0000129": "HM-ES-PMSw1-Pl-DN-R1.json",
|
|
558
|
-
"VCU8688276": "HmIP-eTRV-B.json",
|
|
559
|
-
"VCU0000241": "HM-CC-SCD.json",
|
|
560
|
-
"VCU6531931": "HmIP-RCB1.json",
|
|
561
|
-
"VCU0000008": "HMW-IO-SR-FM.json",
|
|
562
|
-
"VCU0000194": "HM-RC-12.json",
|
|
563
|
-
"VCU0000144": "HM-LC-Ja1PBU-FM.json",
|
|
564
|
-
"VCU0000355": "WS550LCB.json",
|
|
565
|
-
"VCU0000042": "HM-LC-Bl1PBU-FM.json",
|
|
566
|
-
"VCU0000061": "HM-OU-CM-PCB.json",
|
|
567
|
-
"VCU1111390": "HmIP-HDM2.json",
|
|
568
|
-
"VCU0000258": "HM-Sec-SD-2-Generic.json",
|
|
569
|
-
"VCU0000050": "HM-CC-RT-DN.json",
|
|
570
|
-
"VCU0000141": "HM-ES-TX-WM.json",
|
|
571
|
-
"VCU0000109": "HM-LC-Dim1T-CV.json",
|
|
572
|
-
"VCU2822385": "HmIP-SWSD.json",
|
|
573
|
-
"VCU0000160": "HM-PB-2-WM55-2.json",
|
|
574
|
-
"VCU1533290": "HmIP-WRC6.json",
|
|
575
|
-
"VCU5334484": "HmIP-KRCA.json",
|
|
576
|
-
"VCU1260322": "HmIP-RFUSB.json",
|
|
577
|
-
"VCU0000242": "263 160.json",
|
|
578
|
-
"VCU0000306": "HM-LC-Sw1-Pl-CT-R2.json",
|
|
579
|
-
"VCU0000298": "HM-LC-Sw2-DR-2.json",
|
|
580
|
-
"VCU0000338": "HM-LC-Sw1-Pl-OM54.json",
|
|
581
|
-
"VCU0000195": "HM-RC-12-B.json",
|
|
582
|
-
"VCU0000176": "HM-RC-4-3-D.json",
|
|
583
|
-
"VCU0000261": "HM-Sec-Sir-WM.json",
|
|
584
|
-
"VCU8537918": "HmIP-BROLL.json",
|
|
585
|
-
"VCU0000134": "HM-ES-PMSw1-DR.json",
|
|
586
|
-
"VCU0000326": "HM-LC-Sw4-PCB.json",
|
|
587
|
-
"VCU0000271": "HM-Sen-MDIR-SM.json",
|
|
588
|
-
"VCU9981826": "HmIP-SFD.json",
|
|
589
|
-
"VCU0000349": "HM-Sec-WDS-2.json",
|
|
590
|
-
"VCU0000189": "HM-PB-2-WM.json",
|
|
591
|
-
"VCU0000098": "HM-DW-WM.json",
|
|
592
|
-
"VCU0000058": "HM-OU-CF-Pl.json",
|
|
593
|
-
"VCU0000285": "HM-LC-Sw1PBU-FM.json",
|
|
594
|
-
"VCU0000257": "HM-Sec-SD-2.json",
|
|
595
|
-
"VCU0000147": "HM-Sec-Key-S.json",
|
|
596
|
-
"VCU2428569": "HmIPW-FAL230-C6.json",
|
|
597
|
-
"VCU0000263": "HM-Sen-EP.json",
|
|
598
|
-
"VCU9628024": "HmIPW-FALMOT-C12.json",
|
|
599
|
-
"VCU0000024": "HM-WDS10-TH-O.json",
|
|
600
|
-
"VCU0000173": "HM-PB-6-WM55.json",
|
|
601
|
-
"VCU9710932": "HmIP-SMI55.json",
|
|
602
|
-
"VCU0000323": "HM-LC-Sw1-SM.json",
|
|
603
|
-
}
|
|
245
|
+
|
|
246
|
+
@functools.cache
|
|
247
|
+
def _load_device_translation() -> dict[str, str]:
|
|
248
|
+
"""Load device translation mapping from JSON file."""
|
|
249
|
+
file_path = os.path.join(os.path.dirname(__file__), "data", "device_translation.json")
|
|
250
|
+
if os.path.exists(file_path):
|
|
251
|
+
with open(file_path, encoding=UTF_8) as f:
|
|
252
|
+
return cast(dict[str, str], json.load(f))
|
|
253
|
+
return {}
|
|
254
|
+
|
|
255
|
+
|
|
256
|
+
def get_address_device_translation() -> dict[str, str]:
|
|
257
|
+
"""Return the address to device translation mapping."""
|
|
258
|
+
return _load_device_translation()
|
|
259
|
+
|
|
260
|
+
|
|
261
|
+
# Public accessor - use this instead of direct dict access
|
|
262
|
+
ADDRESS_DEVICE_TRANSLATION = get_address_device_translation()
|
|
@@ -0,0 +1,364 @@
|
|
|
1
|
+
{
|
|
2
|
+
"INT0000001": "HM-CC-VG-1.json",
|
|
3
|
+
"VCU0000001": "HMW-RCV-50.json",
|
|
4
|
+
"VCU0000002": "HMW-IO-12-Sw14-DR.json",
|
|
5
|
+
"VCU0000004": "HMW-IO-12-Sw7-DR.json",
|
|
6
|
+
"VCU0000005": "HMW-IO-12-FM.json",
|
|
7
|
+
"VCU0000007": "HMW-IO-4-FM.json",
|
|
8
|
+
"VCU0000008": "HMW-IO-SR-FM.json",
|
|
9
|
+
"VCU0000010": "HMW-LC-Bl1-DR-2.json",
|
|
10
|
+
"VCU0000011": "HMW-LC-Bl1-DR.json",
|
|
11
|
+
"VCU0000012": "HMW-LC-Dim1L-DR.json",
|
|
12
|
+
"VCU0000014": "HMW-LC-Sw2-DR.json",
|
|
13
|
+
"VCU0000015": "HMW-Sen-SC-12-DR.json",
|
|
14
|
+
"VCU0000016": "HMW-Sen-SC-12-FM.json",
|
|
15
|
+
"VCU0000017": "HM-PB-4Dis-WM.json",
|
|
16
|
+
"VCU0000018": "ZEL STG RM DWT 10.json",
|
|
17
|
+
"VCU0000019": "263 155.json",
|
|
18
|
+
"VCU0000020": "HM-PB-4Dis-WM-2.json",
|
|
19
|
+
"VCU0000021": "HM-LC-AO-SM.json",
|
|
20
|
+
"VCU0000022": "ASH550I.json",
|
|
21
|
+
"VCU0000023": "ASH550.json",
|
|
22
|
+
"VCU0000024": "HM-WDS10-TH-O.json",
|
|
23
|
+
"VCU0000025": "263 158.json",
|
|
24
|
+
"VCU0000026": "HM-WDS20-TH-O.json",
|
|
25
|
+
"VCU0000027": "HM-WDS40-TH-I.json",
|
|
26
|
+
"VCU0000028": "263 157.json",
|
|
27
|
+
"VCU0000029": "IS-WDS-TH-OD-S-R3.json",
|
|
28
|
+
"VCU0000036": "HM-LC-Bl1-SM-2.json",
|
|
29
|
+
"VCU0000037": "HM-LC-Bl1-FM-2.json",
|
|
30
|
+
"VCU0000042": "HM-LC-Bl1PBU-FM.json",
|
|
31
|
+
"VCU0000043": "263 147.json",
|
|
32
|
+
"VCU0000044": "HM-LC-Bl1-SM.json",
|
|
33
|
+
"VCU0000045": "HM-LC-Bl1-FM.json",
|
|
34
|
+
"VCU0000046": "HM-LC-Bl1-PB-FM.json",
|
|
35
|
+
"VCU0000047": "ZEL STG RM FEP 230V.json",
|
|
36
|
+
"VCU0000048": "263 146.json",
|
|
37
|
+
"VCU0000049": "HM-LC-BlX.json",
|
|
38
|
+
"VCU0000050": "HM-CC-RT-DN.json",
|
|
39
|
+
"VCU0000051": "HM-CC-RT-DN-BoM.json",
|
|
40
|
+
"VCU0000053": "ZEL STG RM FWT.json",
|
|
41
|
+
"VCU0000054": "HM-CC-TC.json",
|
|
42
|
+
"VCU0000055": "HM-CC-VD.json",
|
|
43
|
+
"VCU0000056": "ZEL STG RM FSA.json",
|
|
44
|
+
"VCU0000057": "HM-RCV-50.json",
|
|
45
|
+
"VCU0000058": "HM-OU-CF-Pl.json",
|
|
46
|
+
"VCU0000059": "HM-OU-CFM-Pl.json",
|
|
47
|
+
"VCU0000060": "HM-OU-CFM-TW.json",
|
|
48
|
+
"VCU0000061": "HM-OU-CM-PCB.json",
|
|
49
|
+
"VCU0000062": "CMM.json",
|
|
50
|
+
"VCU0000064": "HM-LC-Dim1L-Pl-2.json",
|
|
51
|
+
"VCU0000066": "263 132.json",
|
|
52
|
+
"VCU0000070": "HM-LC-DDC1-PCB.json",
|
|
53
|
+
"VCU0000073": "HM-LC-Dim1L-Pl-3.json",
|
|
54
|
+
"VCU0000074": "HM-LC-Dim1L-CV-2.json",
|
|
55
|
+
"VCU0000078": "HM-LC-Dim1PWM-CV-2.json",
|
|
56
|
+
"VCU0000079": "HM-LC-Dim1PWM-CV.json",
|
|
57
|
+
"VCU0000081": "HM-LC-Dim1TPBU-FM-2.json",
|
|
58
|
+
"VCU0000082": "HM-LC-Dim1TPBU-FM.json",
|
|
59
|
+
"VCU0000083": "263 133.json",
|
|
60
|
+
"VCU0000087": "HM-LC-Dim1T-Pl-3.json",
|
|
61
|
+
"VCU0000088": "HM-LC-Dim1T-CV-2.json",
|
|
62
|
+
"VCU0000089": "HM-LC-Dim1T-FM-2.json",
|
|
63
|
+
"VCU0000093": "HM-LC-Dim1T-DR.json",
|
|
64
|
+
"VCU0000094": "HM-LC-Dim1T-FM-LF.json",
|
|
65
|
+
"VCU0000096": "HM-LC-Dim2L-SM-2.json",
|
|
66
|
+
"VCU0000098": "HM-DW-WM.json",
|
|
67
|
+
"VCU0000100": "HM-LC-Dim2T-SM-2.json",
|
|
68
|
+
"VCU0000103": "HM-LC-Dim1T-Pl-2.json",
|
|
69
|
+
"VCU0000105": "263 134.json",
|
|
70
|
+
"VCU0000108": "HM-LC-Dim1T-Pl.json",
|
|
71
|
+
"VCU0000109": "HM-LC-Dim1T-CV.json",
|
|
72
|
+
"VCU0000110": "HM-LC-Dim2T-SM.json",
|
|
73
|
+
"VCU0000111": "HM-LC-Dim1T-FM.json",
|
|
74
|
+
"VCU0000113": "HM-Dis-EP-WM55.json",
|
|
75
|
+
"VCU0000114": "HM-Dis-WM55.json",
|
|
76
|
+
"VCU0000115": "HM-LC-DW-WM.json",
|
|
77
|
+
"VCU0000121": "HM-LC-Dim1L-Pl.json",
|
|
78
|
+
"VCU0000122": "HM-LC-Dim1L-CV.json",
|
|
79
|
+
"VCU0000123": "HM-LC-Dim2L-CV.json",
|
|
80
|
+
"VCU0000124": "HM-LC-Dim2L-SM.json",
|
|
81
|
+
"VCU0000125": "HSS-DX.json",
|
|
82
|
+
"VCU0000126": "HM-MOD-EM-8.json",
|
|
83
|
+
"VCU0000127": "HM-MOD-EM-8Bit.json",
|
|
84
|
+
"VCU0000129": "HM-ES-PMSw1-Pl-DN-R1.json",
|
|
85
|
+
"VCU0000130": "HM-ES-PMSw1-Pl-DN-R2.json",
|
|
86
|
+
"VCU0000131": "HM-ES-PMSw1-Pl-DN-R3.json",
|
|
87
|
+
"VCU0000132": "HM-ES-PMSw1-Pl-DN-R4.json",
|
|
88
|
+
"VCU0000133": "HM-ES-PMSw1-Pl-DN-R5.json",
|
|
89
|
+
"VCU0000134": "HM-ES-PMSw1-DR.json",
|
|
90
|
+
"VCU0000135": "HM-ES-PMSw1-SM.json",
|
|
91
|
+
"VCU0000137": "HM-ES-PMSw1-Pl.json",
|
|
92
|
+
"VCU0000138": "HM-ES-PMSwX.json",
|
|
93
|
+
"VCU0000141": "HM-ES-TX-WM.json",
|
|
94
|
+
"VCU0000142": "HM-Dis-TD-T.json",
|
|
95
|
+
"VCU0000143": "HM-WDS100-C6-O-2.json",
|
|
96
|
+
"VCU0000144": "HM-LC-Ja1PBU-FM.json",
|
|
97
|
+
"VCU0000145": "HM-LC-JaX.json",
|
|
98
|
+
"VCU0000146": "HM-Sec-Key.json",
|
|
99
|
+
"VCU0000147": "HM-Sec-Key-S.json",
|
|
100
|
+
"VCU0000148": "HM-Sec-Key-O.json",
|
|
101
|
+
"VCU0000149": "HM-Sec-Key-Generic.json",
|
|
102
|
+
"VCU0000150": "KS550.json",
|
|
103
|
+
"VCU0000151": "KS888.json",
|
|
104
|
+
"VCU0000152": "KS550Tech.json",
|
|
105
|
+
"VCU0000153": "KS550LC.json",
|
|
106
|
+
"VCU0000154": "HM-WDS100-C6-O.json",
|
|
107
|
+
"VCU0000155": "OLIGO.smart.iq.HM.json",
|
|
108
|
+
"VCU0000158": "HM-OU-LED16.json",
|
|
109
|
+
"VCU0000159": "HM-OU-X.json",
|
|
110
|
+
"VCU0000160": "HM-PB-2-WM55-2.json",
|
|
111
|
+
"VCU0000164": "HM-PB-2-WM55.json",
|
|
112
|
+
"VCU0000165": "ZEL STG RM WT 2.json",
|
|
113
|
+
"VCU0000166": "263 135.json",
|
|
114
|
+
"VCU0000167": "HM-PB-2-FM.json",
|
|
115
|
+
"VCU0000168": "HM-PBI-4-FM.json",
|
|
116
|
+
"VCU0000169": "ZEL STG RM FST UP4.json",
|
|
117
|
+
"VCU0000170": "263 145.json",
|
|
118
|
+
"VCU0000171": "HM-PBI-X.json",
|
|
119
|
+
"VCU0000172": "HM-RC-4-2.json",
|
|
120
|
+
"VCU0000173": "HM-PB-6-WM55.json",
|
|
121
|
+
"VCU0000174": "HM-RC-8.json",
|
|
122
|
+
"VCU0000175": "HM-RC-4-3.json",
|
|
123
|
+
"VCU0000176": "HM-RC-4-3-D.json",
|
|
124
|
+
"VCU0000177": "HM-RC-Key4-2.json",
|
|
125
|
+
"VCU0000178": "HM-RC-Key4-3.json",
|
|
126
|
+
"VCU0000179": "HM-RC-Sec4-2.json",
|
|
127
|
+
"VCU0000180": "HM-RC-Sec4-3.json",
|
|
128
|
+
"VCU0000181": "HM-RC-4.json",
|
|
129
|
+
"VCU0000182": "HM-RC-4-B.json",
|
|
130
|
+
"VCU0000183": "HM-RC-P1.json",
|
|
131
|
+
"VCU0000184": "HM-RC-Sec3.json",
|
|
132
|
+
"VCU0000185": "HM-RC-Sec3-B.json",
|
|
133
|
+
"VCU0000186": "HM-RC-Key3.json",
|
|
134
|
+
"VCU0000187": "HM-RC-Key3-B.json",
|
|
135
|
+
"VCU0000188": "HM-PB-4-WM.json",
|
|
136
|
+
"VCU0000189": "HM-PB-2-WM.json",
|
|
137
|
+
"VCU0000190": "RC-H.json",
|
|
138
|
+
"VCU0000191": "atent.json",
|
|
139
|
+
"VCU0000192": "ZEL STG RM HS 4.json",
|
|
140
|
+
"VCU0000193": "HM-RC-X.json",
|
|
141
|
+
"VCU0000194": "HM-RC-12.json",
|
|
142
|
+
"VCU0000195": "HM-RC-12-B.json",
|
|
143
|
+
"VCU0000196": "HM-RC-12-SW.json",
|
|
144
|
+
"VCU0000197": "HM-RC-19.json",
|
|
145
|
+
"VCU0000198": "HM-RC-19-B.json",
|
|
146
|
+
"VCU0000199": "HM-RC-19-SW.json",
|
|
147
|
+
"VCU0000200": "HM-RC-2-PBU-FM.json",
|
|
148
|
+
"VCU0000201": "HM-RC-2-PBU-FM-2.json",
|
|
149
|
+
"VCU0000202": "HM-RC-Dis-H-x-EU.json",
|
|
150
|
+
"VCU0000203": "BRC-H.json",
|
|
151
|
+
"VCU0000204": "HM-RC-SB-X.json",
|
|
152
|
+
"VCU0000206": "HM-Sen-RD-O.json",
|
|
153
|
+
"VCU0000207": "HM-Sys-sRP-Pl.json",
|
|
154
|
+
"VCU0000208": "HM-ReSC-Win-PCB-xx.json",
|
|
155
|
+
"VCU0000209": "HM-LC-RGBW-WM.json",
|
|
156
|
+
"VCU0000211": "ZEL STG RM FDK.json",
|
|
157
|
+
"VCU0000212": "HM-Sec-RHS-2.json",
|
|
158
|
+
"VCU0000216": "HM-Sec-RHS.json",
|
|
159
|
+
"VCU0000217": "HM-Sec-xx.json",
|
|
160
|
+
"VCU0000218": "WDF solar.json",
|
|
161
|
+
"VCU0000236": "S550IA.json",
|
|
162
|
+
"VCU0000237": "HM-WDS30-T-O.json",
|
|
163
|
+
"VCU0000239": "ZEL STG RM FFK.json",
|
|
164
|
+
"VCU0000240": "HM-Sec-SC-2.json",
|
|
165
|
+
"VCU0000241": "HM-CC-SCD.json",
|
|
166
|
+
"VCU0000242": "263 160.json",
|
|
167
|
+
"VCU0000243": "HM-SCI-3-FM.json",
|
|
168
|
+
"VCU0000245": "HM-Sec-SC.json",
|
|
169
|
+
"VCU0000246": "HM-Sec-MDIR-3.json",
|
|
170
|
+
"VCU0000247": "HM-Sec-MDIR-2.json",
|
|
171
|
+
"VCU0000251": "HM-Sec-MDIR.json",
|
|
172
|
+
"VCU0000252": "263 162.json",
|
|
173
|
+
"VCU0000253": "HM-Sec-MD.json",
|
|
174
|
+
"VCU0000254": "HM-Sec-SCo.json",
|
|
175
|
+
"VCU0000255": "HM-Sec-SD.json",
|
|
176
|
+
"VCU0000256": "HM-Sec-SD-Generic.json",
|
|
177
|
+
"VCU0000257": "HM-Sec-SD-2.json",
|
|
178
|
+
"VCU0000258": "HM-Sec-SD-2-Generic.json",
|
|
179
|
+
"VCU0000259": "263 167.json",
|
|
180
|
+
"VCU0000260": "HM-Sec-SFA-SM.json",
|
|
181
|
+
"VCU0000261": "HM-Sec-Sir-WM.json",
|
|
182
|
+
"VCU0000262": "HM-Sen-DB-PCB.json",
|
|
183
|
+
"VCU0000263": "HM-Sen-EP.json",
|
|
184
|
+
"VCU0000264": "HM-Sen-X.json",
|
|
185
|
+
"VCU0000265": "HM-Sen-LI-O.json",
|
|
186
|
+
"VCU0000266": "HM-Sen-MDIR-O-3.json",
|
|
187
|
+
"VCU0000267": "HM-Sen-MDIR-O-2.json",
|
|
188
|
+
"VCU0000271": "HM-Sen-MDIR-SM.json",
|
|
189
|
+
"VCU0000272": "HM-Sen-MDIR-O.json",
|
|
190
|
+
"VCU0000273": "HM-MD.json",
|
|
191
|
+
"VCU0000274": "HM-Sen-MDIR-WM55.json",
|
|
192
|
+
"VCU0000275": "HM-Sen-Wa-Od.json",
|
|
193
|
+
"VCU0000276": "ST6-SH.json",
|
|
194
|
+
"VCU0000277": "HM-SwI-3-FM.json",
|
|
195
|
+
"VCU0000278": "ZEL STG RM FSS UP3.json",
|
|
196
|
+
"VCU0000279": "263 144.json",
|
|
197
|
+
"VCU0000280": "HM-SwI-X.json",
|
|
198
|
+
"VCU0000285": "HM-LC-Sw1PBU-FM.json",
|
|
199
|
+
"VCU0000286": "263 131.json",
|
|
200
|
+
"VCU0000287": "HM-LC-Sw2PBU-FM.json",
|
|
201
|
+
"VCU0000288": "HM-LC-Sw4-Ba-PCB.json",
|
|
202
|
+
"VCU0000289": "HM-LC-Sw1-Pl-3.json",
|
|
203
|
+
"VCU0000290": "HM-LC-Sw1-SM-2.json",
|
|
204
|
+
"VCU0000292": "HM-LC-Sw4-SM-2.json",
|
|
205
|
+
"VCU0000293": "HM-LC-Sw4-PCB-2.json",
|
|
206
|
+
"VCU0000294": "HM-LC-Sw4-WM-2.json",
|
|
207
|
+
"VCU0000295": "HM-LC-Sw1-FM-2.json",
|
|
208
|
+
"VCU0000296": "HM-LC-Sw2-FM-2.json",
|
|
209
|
+
"VCU0000297": "HM-LC-Sw4-DR-2.json",
|
|
210
|
+
"VCU0000298": "HM-LC-Sw2-DR-2.json",
|
|
211
|
+
"VCU0000299": "HM-LC-Sw1-Pl-DN-R1.json",
|
|
212
|
+
"VCU0000300": "HM-LC-Sw1-Pl-DN-R2.json",
|
|
213
|
+
"VCU0000301": "HM-LC-Sw1-Pl-DN-R3.json",
|
|
214
|
+
"VCU0000302": "HM-LC-Sw1-Pl-DN-R4.json",
|
|
215
|
+
"VCU0000303": "HM-LC-Sw1-Pl-DN-R5.json",
|
|
216
|
+
"VCU0000304": "HM-LC-Sw1-DR.json",
|
|
217
|
+
"VCU0000305": "HM-LC-Sw1-Pl-CT-R1.json",
|
|
218
|
+
"VCU0000306": "HM-LC-Sw1-Pl-CT-R2.json",
|
|
219
|
+
"VCU0000307": "HM-LC-Sw1-Pl-CT-R3.json",
|
|
220
|
+
"VCU0000308": "HM-LC-Sw1-Pl-CT-R4.json",
|
|
221
|
+
"VCU0000309": "HM-LC-Sw1-Pl-CT-R5.json",
|
|
222
|
+
"VCU0000310": "HM-LC-Sw1-PCB.json",
|
|
223
|
+
"VCU0000311": "HM-MOD-Re-8.json",
|
|
224
|
+
"VCU0000312": "HM-LC-Sw1-Ba-PCB.json",
|
|
225
|
+
"VCU0000321": "HM-LC-Sw1-Pl.json",
|
|
226
|
+
"VCU0000322": "HM-LC-Sw1-Pl-2.json",
|
|
227
|
+
"VCU0000323": "HM-LC-Sw1-SM.json",
|
|
228
|
+
"VCU0000324": "HM-LC-Sw2-SM.json",
|
|
229
|
+
"VCU0000325": "HM-LC-Sw4-SM.json",
|
|
230
|
+
"VCU0000326": "HM-LC-Sw4-PCB.json",
|
|
231
|
+
"VCU0000327": "HM-LC-Sw4-WM.json",
|
|
232
|
+
"VCU0000328": "HM-LC-Sw1-FM.json",
|
|
233
|
+
"VCU0000329": "263 130.json",
|
|
234
|
+
"VCU0000330": "HM-LC-Sw2-FM.json",
|
|
235
|
+
"VCU0000331": "HM-LC-Sw1-PB-FM.json",
|
|
236
|
+
"VCU0000332": "HM-LC-Sw2-PB-FM.json",
|
|
237
|
+
"VCU0000333": "HM-LC-Sw4-DR.json",
|
|
238
|
+
"VCU0000334": "HM-LC-Sw2-DR.json",
|
|
239
|
+
"VCU0000335": "ZEL STG RM FZS.json",
|
|
240
|
+
"VCU0000336": "ZEL STG RM FZS-2.json",
|
|
241
|
+
"VCU0000337": "HM-LC-SwX.json",
|
|
242
|
+
"VCU0000338": "HM-LC-Sw1-Pl-OM54.json",
|
|
243
|
+
"VCU0000339": "HM-LC-Sw1-SM-ATmega168.json",
|
|
244
|
+
"VCU0000340": "HM-LC-Sw4-SM-ATmega168.json",
|
|
245
|
+
"VCU0000341": "HM-TC-IT-WM-W-EU.json",
|
|
246
|
+
"VCU0000343": "HM-Sec-TiS.json",
|
|
247
|
+
"VCU0000344": "HM-WDS30-OT2-SM.json",
|
|
248
|
+
"VCU0000345": "HM-WDS30-OT2-SM-2.json",
|
|
249
|
+
"VCU0000346": "HM-WDS40-TH-I-2.json",
|
|
250
|
+
"VCU0000348": "HM-Sec-WDS.json",
|
|
251
|
+
"VCU0000349": "HM-Sec-WDS-2.json",
|
|
252
|
+
"VCU0000350": "HM-Sec-Win.json",
|
|
253
|
+
"VCU0000351": "HM-Sec-Win-Generic.json",
|
|
254
|
+
"VCU0000352": "WS550.json",
|
|
255
|
+
"VCU0000353": "WS888.json",
|
|
256
|
+
"VCU0000354": "WS550Tech.json",
|
|
257
|
+
"VCU0000355": "WS550LCB.json",
|
|
258
|
+
"VCU0000356": "WS550LCW.json",
|
|
259
|
+
"VCU0000357": "HM-WDC7000.json",
|
|
260
|
+
"VCU1004487": "HmIPW-DRAP.json",
|
|
261
|
+
"VCU1111390": "HmIP-HDM2.json",
|
|
262
|
+
"VCU1150287": "HmIP-HAP.json",
|
|
263
|
+
"VCU1152627": "HmIP-RC8.json",
|
|
264
|
+
"VCU1223813": "HmIP-FBL.json",
|
|
265
|
+
"VCU1260322": "HmIP-RFUSB.json",
|
|
266
|
+
"VCU1289997": "HmIP-SPDR.json",
|
|
267
|
+
"VCU1362746": "HmIP-SWO-PR.json",
|
|
268
|
+
"VCU1366171": "HMIP-PS.json",
|
|
269
|
+
"VCU1399816": "HmIP-BDT.json",
|
|
270
|
+
"VCU1437294": "HmIP-SMI.json",
|
|
271
|
+
"VCU1494703": "HmIP-eTRV-E.json",
|
|
272
|
+
"VCU1533290": "HmIP-WRC6.json",
|
|
273
|
+
"VCU1543608": "HmIP-MP3P.json",
|
|
274
|
+
"VCU1673350": "HmIPW-FIO6.json",
|
|
275
|
+
"VCU1768323": "HmIP-eTRV-C-2.json",
|
|
276
|
+
"VCU1769958": "HmIP-BWTH.json",
|
|
277
|
+
"VCU1803301": "HmIP-USBSM.json",
|
|
278
|
+
"VCU1815001": "HmIP-SWD.json",
|
|
279
|
+
"VCU1841406": "HmIP-SWO-PL.json",
|
|
280
|
+
"VCU1891174": "HmIPW-DRS8.json",
|
|
281
|
+
"VCU1954019": "HmIP-FAL230-C10.json",
|
|
282
|
+
"VCU2118827": "HmIP-DLS.json",
|
|
283
|
+
"VCU2128127": "HmIP-BSM.json",
|
|
284
|
+
"VCU2333555": "HmIP-FSI16.json",
|
|
285
|
+
"VCU2407364": "HmIP-PCBS.json",
|
|
286
|
+
"VCU2428569": "HmIPW-FAL230-C6.json",
|
|
287
|
+
"VCU2573721": "HmIP-SMO-2.json",
|
|
288
|
+
"VCU2680226": "HmIP-WTH-2.json",
|
|
289
|
+
"VCU2721398": "HmIPW-DRI32.json",
|
|
290
|
+
"VCU2737768": "HMIP-SWDO.json",
|
|
291
|
+
"VCU2822385": "HmIP-SWSD.json",
|
|
292
|
+
"VCU2826390": "HmIPW-STH.json",
|
|
293
|
+
"VCU2913614": "HmIP-WHS2.json",
|
|
294
|
+
"VCU3015080": "HmIP-SCI.json",
|
|
295
|
+
"VCU3056370": "HmIP-SLO.json",
|
|
296
|
+
"VCU3188750": "HmIP-WGC.json",
|
|
297
|
+
"VCU3432945": "HmIP-STV.json",
|
|
298
|
+
"VCU3560967": "HmIP-HDM1.json",
|
|
299
|
+
"VCU3609622": "HmIP-eTRV-2.json",
|
|
300
|
+
"VCU3790312": "HmIP-SWO-B.json",
|
|
301
|
+
"VCU3880755": "HB-UNI-Sensor-THPD-BME280.json",
|
|
302
|
+
"VCU3941846": "HMIP-PSM.json",
|
|
303
|
+
"VCU4070501": "HmIP-FSM16.json",
|
|
304
|
+
"VCU4243444": "HmIP-WRCD.json",
|
|
305
|
+
"VCU4264293": "HmIP-RCV-50.json",
|
|
306
|
+
"VCU4523900": "HmIP-STHO.json",
|
|
307
|
+
"VCU4567298": "HmIP-DBB.json",
|
|
308
|
+
"VCU4613288": "HmIP-FROLL.json",
|
|
309
|
+
"VCU4704397": "HmIPW-WRC6.json",
|
|
310
|
+
"VCU4743739": "HmIPW-SPI.json",
|
|
311
|
+
"VCU4898089": "HmIP-KRC4.json",
|
|
312
|
+
"VCU4984404": "HmIPW-STHD.json",
|
|
313
|
+
"VCU5092447": "HmIP-SMO-A.json",
|
|
314
|
+
"VCU5334484": "HmIP-KRCA.json",
|
|
315
|
+
"VCU5424977": "HmIP-DSD-PCB.json",
|
|
316
|
+
"VCU5429697": "HmIP-SAM.json",
|
|
317
|
+
"VCU5597068": "HmIPW-SMI55.json",
|
|
318
|
+
"VCU5628817": "HmIP-SMO.json",
|
|
319
|
+
"VCU5644414": "HmIP-SWDM.json",
|
|
320
|
+
"VCU5778428": "HmIP-HEATING.json",
|
|
321
|
+
"VCU5801873": "HmIP-PMFS.json",
|
|
322
|
+
"VCU5864966": "HmIP-SWDO-I.json",
|
|
323
|
+
"VCU5980155": "HmIP-PCBS-BAT.json",
|
|
324
|
+
"VCU6153495": "HmIP-FCI1.json",
|
|
325
|
+
"VCU6306084": "HmIP-BRC2.json",
|
|
326
|
+
"VCU6354483": "HmIP-STHD.json",
|
|
327
|
+
"VCU6531931": "HmIP-RCB1.json",
|
|
328
|
+
"VCU6874371": "HmIP-MOD-RC8.json",
|
|
329
|
+
"VCU6948166": "HmIP-DRDI3.json",
|
|
330
|
+
"VCU6977344": "HmIP-MIO16-PCB.json",
|
|
331
|
+
"VCU6985973": "HmIP-BSL.json",
|
|
332
|
+
"VCU7171997": "HB-WDS40-THP-O.json",
|
|
333
|
+
"VCU7204276": "HmIP-DRSI4.json",
|
|
334
|
+
"VCU7447418": "HmIP-PCBS2.json",
|
|
335
|
+
"VCU7549831": "HmIP-STE2-PCB.json",
|
|
336
|
+
"VCU7631078": "HmIP-FDT.json",
|
|
337
|
+
"VCU7652142": "HmIP-SRD.json",
|
|
338
|
+
"VCU7807849": "HmIPW-DRBL4.json",
|
|
339
|
+
"VCU7808411": "HmIP-eTRV-B1.json",
|
|
340
|
+
"VCU7935803": "HMIP-WRC2.json",
|
|
341
|
+
"VCU7981740": "HmIP-SRH.json",
|
|
342
|
+
"VCU8063453": "HmIP-STH.json",
|
|
343
|
+
"VCU8066814": "RPI-RF-MOD.json",
|
|
344
|
+
"VCU8126977": "HmIP-MOD-OC8.json",
|
|
345
|
+
"VCU8205532": "HmIP-SCTH230.json",
|
|
346
|
+
"VCU8249617": "HmIP-ASIR-2.json",
|
|
347
|
+
"VCU8255833": "HmIP-STHO-A.json",
|
|
348
|
+
"VCU8333683": "HmIP-SWDM-B2.json",
|
|
349
|
+
"VCU8451105": "HmIPW-WTH.json",
|
|
350
|
+
"VCU8492627": "HB-UNI-Sensor1.json",
|
|
351
|
+
"VCU8537918": "HmIP-BROLL.json",
|
|
352
|
+
"VCU8539034": "HmIP-WRCR.json",
|
|
353
|
+
"VCU8585352": "HmIP-DRSI1.json",
|
|
354
|
+
"VCU8655720": "HmIP-CCU3.json",
|
|
355
|
+
"VCU8688276": "HmIP-eTRV-B.json",
|
|
356
|
+
"VCU9333179": "HmIP-ASIR.json",
|
|
357
|
+
"VCU9344471": "HmIP-SPI.json",
|
|
358
|
+
"VCU9628024": "HmIPW-FALMOT-C12.json",
|
|
359
|
+
"VCU9710932": "HmIP-SMI55.json",
|
|
360
|
+
"VCU9724704": "HmIP-DLD.json",
|
|
361
|
+
"VCU9834159": "HB-LC-Bl1PBU-FM.json",
|
|
362
|
+
"VCU9933791": "HmIPW-DRD3.json",
|
|
363
|
+
"VCU9981826": "HmIP-SFD.json"
|
|
364
|
+
}
|
|
@@ -35,15 +35,21 @@ import asyncio
|
|
|
35
35
|
from collections.abc import AsyncGenerator, Callable
|
|
36
36
|
import contextlib
|
|
37
37
|
import logging
|
|
38
|
-
from typing import Self, cast
|
|
38
|
+
from typing import Any, Self, cast
|
|
39
39
|
from unittest.mock import MagicMock, Mock, patch
|
|
40
40
|
|
|
41
41
|
from aiohttp import ClientSession
|
|
42
42
|
|
|
43
43
|
from aiohomematic.central import CentralConfig, CentralUnit
|
|
44
|
-
from aiohomematic.central.
|
|
44
|
+
from aiohomematic.central.integration_events import (
|
|
45
|
+
DataPointsCreatedEvent,
|
|
46
|
+
DeviceLifecycleEvent,
|
|
47
|
+
DeviceLifecycleEventType,
|
|
48
|
+
DeviceTriggerEvent,
|
|
49
|
+
SystemStatusEvent,
|
|
50
|
+
)
|
|
45
51
|
from aiohomematic.client import ClientConfig, InterfaceConfig
|
|
46
|
-
from aiohomematic.const import LOCAL_HOST,
|
|
52
|
+
from aiohomematic.const import LOCAL_HOST, Interface, OptionalSettings
|
|
47
53
|
from aiohomematic.interfaces.client import ClientProtocol
|
|
48
54
|
from aiohomematic_test_support import const
|
|
49
55
|
from aiohomematic_test_support.mock import SessionPlayer, get_client_session, get_mock, get_xml_rpc_proxy
|
|
@@ -82,20 +88,31 @@ class FactoryWithClient:
|
|
|
82
88
|
self.system_event_mock = MagicMock()
|
|
83
89
|
self.ha_event_mock = MagicMock()
|
|
84
90
|
self._event_bus_unsubscribe_callbacks: list[Callable[[], None]] = []
|
|
91
|
+
self._patches: list[Any] = []
|
|
85
92
|
|
|
86
|
-
def
|
|
87
|
-
"""Clean up all event bus subscriptions."""
|
|
93
|
+
def cleanup(self) -> None:
|
|
94
|
+
"""Clean up all patches and event bus subscriptions."""
|
|
88
95
|
for unsubscribe in self._event_bus_unsubscribe_callbacks:
|
|
89
96
|
unsubscribe()
|
|
90
97
|
self._event_bus_unsubscribe_callbacks.clear()
|
|
98
|
+
for p in self._patches:
|
|
99
|
+
p.stop()
|
|
100
|
+
self._patches.clear()
|
|
101
|
+
|
|
102
|
+
def cleanup_event_bus_subscriptions(self) -> None:
|
|
103
|
+
"""Clean up all event bus subscriptions. Deprecated: use cleanup() instead."""
|
|
104
|
+
self.cleanup()
|
|
91
105
|
|
|
92
106
|
async def get_default_central(self, *, start: bool = True) -> CentralUnit:
|
|
93
107
|
"""Return a central based on give address_device_translation."""
|
|
94
108
|
central = await self.get_raw_central()
|
|
95
109
|
|
|
96
110
|
await self._xml_proxy.do_init()
|
|
97
|
-
patch("aiohomematic.client.ClientConfig._create_xml_rpc_proxy", return_value=self._xml_proxy)
|
|
98
|
-
patch("aiohomematic.central.CentralUnit._identify_ip_addr", return_value=LOCAL_HOST)
|
|
111
|
+
p1 = patch("aiohomematic.client.ClientConfig._create_xml_rpc_proxy", return_value=self._xml_proxy)
|
|
112
|
+
p2 = patch("aiohomematic.central.CentralUnit._identify_ip_addr", return_value=LOCAL_HOST)
|
|
113
|
+
p1.start()
|
|
114
|
+
p2.start()
|
|
115
|
+
self._patches.extend([p1, p2])
|
|
99
116
|
|
|
100
117
|
# Optionally patch client creation to return a mocked client
|
|
101
118
|
if self._do_mock_client:
|
|
@@ -112,7 +129,9 @@ class FactoryWithClient:
|
|
|
112
129
|
),
|
|
113
130
|
)
|
|
114
131
|
|
|
115
|
-
patch("aiohomematic.client.ClientConfig.create_client", _mocked_create_client)
|
|
132
|
+
p3 = patch("aiohomematic.client.ClientConfig.create_client", _mocked_create_client)
|
|
133
|
+
p3.start()
|
|
134
|
+
self._patches.append(p3)
|
|
116
135
|
|
|
117
136
|
if start:
|
|
118
137
|
await central.start()
|
|
@@ -138,21 +157,41 @@ class FactoryWithClient:
|
|
|
138
157
|
).create_central()
|
|
139
158
|
|
|
140
159
|
# Subscribe to events via event bus
|
|
141
|
-
def
|
|
142
|
-
"""Handle
|
|
160
|
+
def _device_lifecycle_event_handler(event: DeviceLifecycleEvent) -> None:
|
|
161
|
+
"""Handle device lifecycle events."""
|
|
162
|
+
self.system_event_mock(event)
|
|
163
|
+
|
|
164
|
+
def _data_points_created_event_handler(event: DataPointsCreatedEvent) -> None:
|
|
165
|
+
"""Handle data points created events."""
|
|
143
166
|
self.system_event_mock(event)
|
|
144
167
|
|
|
145
|
-
def
|
|
146
|
-
"""Handle
|
|
168
|
+
def _device_trigger_event_handler(event: DeviceTriggerEvent) -> None:
|
|
169
|
+
"""Handle device trigger events."""
|
|
170
|
+
self.ha_event_mock(event)
|
|
171
|
+
|
|
172
|
+
def _system_status_event_handler(event: SystemStatusEvent) -> None:
|
|
173
|
+
"""Handle system status events (issues, state changes)."""
|
|
147
174
|
self.ha_event_mock(event)
|
|
148
175
|
|
|
149
176
|
self._event_bus_unsubscribe_callbacks.append(
|
|
150
177
|
central.event_bus.subscribe(
|
|
151
|
-
event_type=
|
|
178
|
+
event_type=DeviceLifecycleEvent, event_key=None, handler=_device_lifecycle_event_handler
|
|
152
179
|
)
|
|
153
180
|
)
|
|
154
181
|
self._event_bus_unsubscribe_callbacks.append(
|
|
155
|
-
central.event_bus.subscribe(
|
|
182
|
+
central.event_bus.subscribe(
|
|
183
|
+
event_type=DataPointsCreatedEvent, event_key=None, handler=_data_points_created_event_handler
|
|
184
|
+
)
|
|
185
|
+
)
|
|
186
|
+
self._event_bus_unsubscribe_callbacks.append(
|
|
187
|
+
central.event_bus.subscribe(
|
|
188
|
+
event_type=DeviceTriggerEvent, event_key=None, handler=_device_trigger_event_handler
|
|
189
|
+
)
|
|
190
|
+
)
|
|
191
|
+
self._event_bus_unsubscribe_callbacks.append(
|
|
192
|
+
central.event_bus.subscribe(
|
|
193
|
+
event_type=SystemStatusEvent, event_key=None, handler=_system_status_event_handler
|
|
194
|
+
)
|
|
156
195
|
)
|
|
157
196
|
|
|
158
197
|
assert central
|
|
@@ -223,14 +262,14 @@ async def get_central_client_factory(
|
|
|
223
262
|
un_ignore_list=un_ignore_list,
|
|
224
263
|
)
|
|
225
264
|
central = await factory.get_default_central()
|
|
226
|
-
client = central.primary_client
|
|
265
|
+
client = central.client_coordinator.primary_client
|
|
227
266
|
assert client
|
|
228
267
|
try:
|
|
229
268
|
yield central, client, factory
|
|
230
269
|
finally:
|
|
231
|
-
factory.
|
|
270
|
+
factory.cleanup()
|
|
232
271
|
await central.stop()
|
|
233
|
-
await central.
|
|
272
|
+
await central.cache_coordinator.clear_all()
|
|
234
273
|
|
|
235
274
|
|
|
236
275
|
async def get_pydev_ccu_central_unit_full(
|
|
@@ -241,9 +280,9 @@ async def get_pydev_ccu_central_unit_full(
|
|
|
241
280
|
"""Create and yield central, after all devices have been created."""
|
|
242
281
|
device_event = asyncio.Event()
|
|
243
282
|
|
|
244
|
-
def
|
|
245
|
-
"""Handle
|
|
246
|
-
if event.
|
|
283
|
+
def device_lifecycle_event_handler(event: DeviceLifecycleEvent) -> None:
|
|
284
|
+
"""Handle device lifecycle events."""
|
|
285
|
+
if event.event_type == DeviceLifecycleEventType.CREATED:
|
|
247
286
|
device_event.set()
|
|
248
287
|
|
|
249
288
|
interface_configs = {
|
|
@@ -265,7 +304,7 @@ async def get_pydev_ccu_central_unit_full(
|
|
|
265
304
|
program_markers=(),
|
|
266
305
|
sysvar_markers=(),
|
|
267
306
|
).create_central()
|
|
268
|
-
central.event_bus.subscribe(event_type=
|
|
307
|
+
central.event_bus.subscribe(event_type=DeviceLifecycleEvent, event_key=None, handler=device_lifecycle_event_handler)
|
|
269
308
|
await central.start()
|
|
270
309
|
|
|
271
310
|
# Wait up to 60 seconds for the DEVICES_CREATED event which signals that all devices are available
|
|
@@ -42,6 +42,7 @@ import contextlib
|
|
|
42
42
|
import json
|
|
43
43
|
import logging
|
|
44
44
|
import os
|
|
45
|
+
import sys
|
|
45
46
|
from typing import Any, cast
|
|
46
47
|
from unittest.mock import MagicMock, Mock
|
|
47
48
|
import zipfile
|
|
@@ -186,7 +187,7 @@ def get_client_session( # noqa: C901
|
|
|
186
187
|
)
|
|
187
188
|
|
|
188
189
|
if method == _JsonRpcMethod.INTERFACE_SET_VALUE:
|
|
189
|
-
await self._central.data_point_event(
|
|
190
|
+
await self._central.event_coordinator.data_point_event(
|
|
190
191
|
interface_id=params[_JsonKey.INTERFACE],
|
|
191
192
|
channel_address=params[_JsonKey.ADDRESS],
|
|
192
193
|
parameter=params[_JsonKey.VALUE_KEY],
|
|
@@ -199,7 +200,7 @@ def get_client_session( # noqa: C901
|
|
|
199
200
|
channel_address = params[_JsonKey.ADDRESS]
|
|
200
201
|
values = params[_JsonKey.SET]
|
|
201
202
|
for param, value in values.items():
|
|
202
|
-
await self._central.data_point_event(
|
|
203
|
+
await self._central.event_coordinator.data_point_event(
|
|
203
204
|
interface_id=interface_id,
|
|
204
205
|
channel_address=channel_address,
|
|
205
206
|
parameter=param,
|
|
@@ -335,7 +336,7 @@ def get_xml_rpc_proxy( # noqa: C901
|
|
|
335
336
|
async def ping(self, callerId: str) -> None:
|
|
336
337
|
"""Answer ping with pong."""
|
|
337
338
|
if self._central:
|
|
338
|
-
await self._central.data_point_event(
|
|
339
|
+
await self._central.event_coordinator.data_point_event(
|
|
339
340
|
interface_id=callerId,
|
|
340
341
|
channel_address="",
|
|
341
342
|
parameter=Parameter.PONG,
|
|
@@ -347,17 +348,17 @@ def get_xml_rpc_proxy( # noqa: C901
|
|
|
347
348
|
) -> None:
|
|
348
349
|
"""Set a paramset."""
|
|
349
350
|
if self._central and paramset_key == ParamsetKey.VALUES:
|
|
350
|
-
interface_id = self._central.primary_client.interface_id # type: ignore[union-attr]
|
|
351
|
+
interface_id = self._central.client_coordinator.primary_client.interface_id # type: ignore[union-attr]
|
|
351
352
|
for param, value in values.items():
|
|
352
|
-
await self._central.data_point_event(
|
|
353
|
+
await self._central.event_coordinator.data_point_event(
|
|
353
354
|
interface_id=interface_id, channel_address=channel_address, parameter=param, value=value
|
|
354
355
|
)
|
|
355
356
|
|
|
356
357
|
async def setValue(self, channel_address: str, parameter: str, value: Any, rx_mode: Any | None = None) -> None:
|
|
357
358
|
"""Set a value."""
|
|
358
359
|
if self._central:
|
|
359
|
-
await self._central.data_point_event(
|
|
360
|
-
interface_id=self._central.primary_client.interface_id, # type: ignore[union-attr]
|
|
360
|
+
await self._central.event_coordinator.data_point_event(
|
|
361
|
+
interface_id=self._central.client_coordinator.primary_client.interface_id, # type: ignore[union-attr]
|
|
361
362
|
channel_address=channel_address,
|
|
362
363
|
parameter=parameter,
|
|
363
364
|
value=value,
|
|
@@ -545,15 +546,15 @@ def get_mock(
|
|
|
545
546
|
# Step 6: Copy non-mockable methods directly
|
|
546
547
|
# Some methods (like bound methods or special attributes) need to be copied
|
|
547
548
|
# directly rather than being mocked
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
549
|
+
for method_name in [
|
|
550
|
+
prop
|
|
551
|
+
for prop in _get_not_mockable_method_names(instance=instance, exclude_methods=exclude_methods)
|
|
552
|
+
if prop not in include_properties and prop not in kwargs and prop not in property_names
|
|
553
|
+
]:
|
|
554
|
+
try:
|
|
554
555
|
setattr(mock, method_name, getattr(instance, method_name))
|
|
555
|
-
|
|
556
|
-
|
|
556
|
+
except (AttributeError, TypeError) as exc:
|
|
557
|
+
_LOGGER.debug("Could not copy method %s to mock: %s", method_name, exc)
|
|
557
558
|
|
|
558
559
|
return mock
|
|
559
560
|
|
|
@@ -581,6 +582,26 @@ class SessionPlayer:
|
|
|
581
582
|
"""Initialize the session player."""
|
|
582
583
|
self._file_id = file_id
|
|
583
584
|
|
|
585
|
+
@classmethod
|
|
586
|
+
def clear_all(cls) -> None:
|
|
587
|
+
"""Clear all cached session data from all file IDs."""
|
|
588
|
+
cls._store.clear()
|
|
589
|
+
|
|
590
|
+
@classmethod
|
|
591
|
+
def clear_file(cls, *, file_id: str) -> None:
|
|
592
|
+
"""Clear cached session data for a specific file ID."""
|
|
593
|
+
cls._store.pop(file_id, None)
|
|
594
|
+
|
|
595
|
+
@classmethod
|
|
596
|
+
def get_loaded_file_ids(cls) -> list[str]:
|
|
597
|
+
"""Return list of currently loaded file IDs."""
|
|
598
|
+
return list(cls._store.keys())
|
|
599
|
+
|
|
600
|
+
@classmethod
|
|
601
|
+
def get_memory_usage(cls) -> int:
|
|
602
|
+
"""Return approximate memory usage of cached session data in bytes."""
|
|
603
|
+
return sys.getsizeof(cls._store)
|
|
604
|
+
|
|
584
605
|
@property
|
|
585
606
|
def _secondary_file_ids(self) -> list[str]:
|
|
586
607
|
"""Return the secondary store for the given file_id."""
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: aiohomematic-test-support
|
|
3
|
-
Version: 2025.12.
|
|
3
|
+
Version: 2025.12.42
|
|
4
4
|
Summary: Support-only package for AioHomematic (tests/dev). Not part of production builds.
|
|
5
5
|
Author-email: SukramJ <sukramj@icloud.com>
|
|
6
6
|
Project-URL: Homepage, https://github.com/SukramJ/aiohomematic
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
aiohomematic_test_support/__init__.py,sha256=_61m3I7tUF-q8k6-Vh3nz81vkCAY_W-UUcyhRrTeViw,1642
|
|
2
|
+
aiohomematic_test_support/const.py,sha256=tLyvqZJlaDCs1F2OBRnJ94hUB0pu7RKk--CQGlVC_58,6430
|
|
3
|
+
aiohomematic_test_support/factory.py,sha256=FoemfxruooVRViShZdW4uxHc09pCIUFSCG_goxvpVmg,12191
|
|
4
|
+
aiohomematic_test_support/helper.py,sha256=Ue2tfy10_fiuMjYsc1jYPvo5sEtMF2WVKjvLnTZ0TzU,1360
|
|
5
|
+
aiohomematic_test_support/mock.py,sha256=GhJjKXPIYwzmHanKQSEIjGb8-wuixa3n7cFW-m-oiKY,31097
|
|
6
|
+
aiohomematic_test_support/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
7
|
+
aiohomematic_test_support/data/device_translation.json,sha256=owHLpCGvtMJzfCMOMMgnn7-LgN-BMKSYzi4NKINw1WQ,13290
|
|
8
|
+
aiohomematic_test_support/data/full_session_randomized_ccu.zip,sha256=kKHMtJouCskAHkXaP1hHRSoWZO2cZDJ9P_EwuJuywJQ,733017
|
|
9
|
+
aiohomematic_test_support/data/full_session_randomized_pydevccu.zip,sha256=_QFWSP03dkiMFdD_w-R98DS6ur4PYDQXw-DCkbJEGg4,1293240
|
|
10
|
+
aiohomematic_test_support-2025.12.42.dist-info/METADATA,sha256=2h9S5x7EQqUEeN0oSnPGMuU8tYvv60HjCWP9hNiGe04,536
|
|
11
|
+
aiohomematic_test_support-2025.12.42.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
12
|
+
aiohomematic_test_support-2025.12.42.dist-info/top_level.txt,sha256=KmK-OiDDbrmawIsIgPWNAkpkDfWQnOoumYd9MXAiTHc,26
|
|
13
|
+
aiohomematic_test_support-2025.12.42.dist-info/RECORD,,
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
aiohomematic_test_support/__init__.py,sha256=hwFQdytuqaQAqUbDFz_hSF39zeCY1PW_vafTdwa-Qoo,1623
|
|
2
|
-
aiohomematic_test_support/const.py,sha256=YXN3FvZCqjxOaqCs0E7KTz2PUa1zONzS9-W_6YqJrPI,19755
|
|
3
|
-
aiohomematic_test_support/factory.py,sha256=E3tHyeIAO1Id1c0ODP7WnUs_XOgnt14bMzPyow5SEJc,10772
|
|
4
|
-
aiohomematic_test_support/helper.py,sha256=Ue2tfy10_fiuMjYsc1jYPvo5sEtMF2WVKjvLnTZ0TzU,1360
|
|
5
|
-
aiohomematic_test_support/mock.py,sha256=h7kL6R7IeZfRArZ7TXfVgX_O2GRC-7CQk9llysQczTI,30228
|
|
6
|
-
aiohomematic_test_support/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
7
|
-
aiohomematic_test_support/data/full_session_randomized_ccu.zip,sha256=kKHMtJouCskAHkXaP1hHRSoWZO2cZDJ9P_EwuJuywJQ,733017
|
|
8
|
-
aiohomematic_test_support/data/full_session_randomized_pydevccu.zip,sha256=_QFWSP03dkiMFdD_w-R98DS6ur4PYDQXw-DCkbJEGg4,1293240
|
|
9
|
-
aiohomematic_test_support-2025.12.23.dist-info/METADATA,sha256=4MzyPgvkaZ98FmvnyIaBgIjGw1Vc1gFDcu06LzacPMc,536
|
|
10
|
-
aiohomematic_test_support-2025.12.23.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
11
|
-
aiohomematic_test_support-2025.12.23.dist-info/top_level.txt,sha256=KmK-OiDDbrmawIsIgPWNAkpkDfWQnOoumYd9MXAiTHc,26
|
|
12
|
-
aiohomematic_test_support-2025.12.23.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|