tdl-xoa-driver 1.5.1__py3-none-any.whl → 1.6.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 (110) hide show
  1. {tdl_xoa_driver-1.5.1.dist-info → tdl_xoa_driver-1.6.0.dist-info}/METADATA +1 -1
  2. {tdl_xoa_driver-1.5.1.dist-info → tdl_xoa_driver-1.6.0.dist-info}/RECORD +89 -88
  3. xoa_driver/__init__.py +2 -2
  4. xoa_driver/enums.py +10 -10
  5. xoa_driver/functions/anlt.py +60 -78
  6. xoa_driver/functions/cli/testbed_config.py +1 -1
  7. xoa_driver/functions/cmis/_replies.py +4 -4
  8. xoa_driver/functions/mgmt.py +206 -250
  9. xoa_driver/functions/tools.py +11 -6
  10. xoa_driver/internals/commands/c_commands.py +59 -0
  11. xoa_driver/internals/commands/enums.py +101 -90
  12. xoa_driver/internals/commands/m4_commands.py +25 -0
  13. xoa_driver/internals/commands/m4e_commands.py +6 -0
  14. xoa_driver/internals/commands/m_commands.py +51 -1
  15. xoa_driver/internals/commands/p4_commands.py +63 -1
  16. xoa_driver/internals/commands/p4e_commands.py +9 -0
  17. xoa_driver/internals/commands/p4g_commands.py +139 -0
  18. xoa_driver/internals/commands/p_commands.py +455 -61
  19. xoa_driver/internals/commands/pc_commands.py +9 -0
  20. xoa_driver/internals/commands/pd_commands.py +11 -0
  21. xoa_driver/internals/commands/pe_commands.py +27 -0
  22. xoa_driver/internals/commands/pec_commands.py +9 -0
  23. xoa_driver/internals/commands/ped_commands.py +23 -0
  24. xoa_driver/internals/commands/pef_commands.py +43 -0
  25. xoa_driver/internals/commands/pf_commands.py +11 -0
  26. xoa_driver/internals/commands/pl1_commands.py +315 -48
  27. xoa_driver/internals/commands/pl_commands.py +8 -0
  28. xoa_driver/internals/commands/pm_commands.py +11 -0
  29. xoa_driver/internals/commands/pp_commands.py +84 -27
  30. xoa_driver/internals/commands/pr_commands.py +25 -0
  31. xoa_driver/internals/commands/ps_commands.py +47 -1
  32. xoa_driver/internals/commands/pt_commands.py +15 -0
  33. xoa_driver/internals/commands/px_commands.py +180 -136
  34. xoa_driver/internals/commands/subtypes.py +4 -3
  35. xoa_driver/internals/core/transporter/protocol/payload/base_struct.py +1 -1
  36. xoa_driver/internals/hli/indices/macsecscs/base_macsecsc.py +41 -3
  37. xoa_driver/internals/hli/modules/modules_l23/family_combi.py +0 -64
  38. xoa_driver/internals/hli/modules/modules_l23/family_edun.py +0 -2
  39. xoa_driver/internals/hli/modules/modules_l23/{family_g.py → family_loki.py} +29 -1
  40. xoa_driver/internals/hli/modules/modules_l23/family_odin.py +412 -0
  41. xoa_driver/internals/hli/modules/modules_l23/{family_l.py → family_thor.py} +44 -0
  42. xoa_driver/internals/hli/ports/port_l23/chimera/port_chimera.py +3 -3
  43. xoa_driver/internals/hli/ports/port_l23/family_edun.py +9 -44
  44. xoa_driver/internals/hli/ports/port_l23/{family_l1.py → family_freya.py} +10 -45
  45. xoa_driver/internals/hli/ports/port_l23/{family_g.py → family_loki.py} +33 -32
  46. xoa_driver/internals/hli/ports/port_l23/family_odin.py +225 -0
  47. xoa_driver/internals/hli/ports/port_l23/family_thor.py +67 -0
  48. xoa_driver/internals/hli/ports/port_l23/layer1/anlt.py +512 -0
  49. xoa_driver/internals/hli/ports/port_l23/layer1/brr.py +26 -0
  50. xoa_driver/internals/hli/ports/port_l23/layer1/eye_diagram.py +71 -0
  51. xoa_driver/internals/hli/ports/port_l23/{pcs_pma_ijkl_chimera.py → layer1/impair.py} +7 -7
  52. xoa_driver/internals/hli/ports/port_l23/layer1/laser_power.py +28 -0
  53. xoa_driver/internals/hli/ports/port_l23/{family_e.py → layer1/lower_power.py} +1 -51
  54. xoa_driver/internals/hli/ports/port_l23/{freya_l1.py → layer1/medium.py} +38 -358
  55. xoa_driver/internals/hli/ports/port_l23/layer1/pcs_fec.py +219 -0
  56. xoa_driver/internals/hli/ports/port_l23/layer1/pma.py +43 -0
  57. xoa_driver/internals/hli/ports/port_l23/layer1/prbs.py +39 -0
  58. xoa_driver/internals/hli/ports/port_l23/layer1/preamble.py +25 -0
  59. xoa_driver/internals/hli/ports/port_l23/{fault_jkl.py → layer1/rs_fault.py} +2 -2
  60. xoa_driver/internals/hli/ports/port_l23/layer1/siv.py +69 -0
  61. xoa_driver/internals/hli/ports/port_l23/layer1_edun.py +103 -0
  62. xoa_driver/internals/hli/ports/port_l23/layer1_freya.py +103 -0
  63. xoa_driver/internals/hli/ports/port_l23/layer1_loki.py +74 -0
  64. xoa_driver/internals/hli/ports/port_l23/layer1_thor.py +70 -0
  65. xoa_driver/internals/hli/ports/port_l23/port_l23ve.py +4 -4
  66. xoa_driver/internals/hli/ports/port_l23/sec/__init__.py +0 -0
  67. xoa_driver/internals/hli/ports/port_l23/sec/macsec.py +108 -0
  68. xoa_driver/internals/hli/ports/port_l23/tcvr/__init__.py +0 -0
  69. xoa_driver/internals/hli/ports/port_l23/{bases/port_transceiver.py → tcvr/cmis.py} +4 -118
  70. xoa_driver/internals/hli/ports/port_l23/tcvr/transceiver.py +124 -0
  71. xoa_driver/internals/hli/ports/port_l23/trafficgen/__init__.py +0 -0
  72. xoa_driver/internals/hli/ports/port_l23/{bases → trafficgen}/port_l23.py +1 -1
  73. xoa_driver/internals/hli/ports/port_l23/{bases → trafficgen}/port_l23_genuine.py +5 -45
  74. xoa_driver/internals/hli/ports/port_l23/{bases/port_reception_statistics.py → trafficgen/port_rx_stats.py} +0 -21
  75. xoa_driver/internals/hli/ports/port_l23/{bases/port_transmission_statistics.py → trafficgen/port_tx_stats.py} +2 -22
  76. xoa_driver/internals/hli/ports/port_l23/trafficgen/runt.py +32 -0
  77. xoa_driver/internals/hli/testers/l23_tester.py +1 -3
  78. xoa_driver/internals/utils/indices/_interfaces.py +18 -6
  79. xoa_driver/internals/utils/indices/index_manager.py +8 -2
  80. xoa_driver/internals/utils/managers/ports_manager.py +5 -2
  81. xoa_driver/misc.py +6 -6
  82. xoa_driver/modules.py +31 -47
  83. xoa_driver/ports.py +10 -29
  84. xoa_driver/internals/hli/modules/modules_l23/family_d.py +0 -75
  85. xoa_driver/internals/hli/modules/modules_l23/family_e.py +0 -85
  86. xoa_driver/internals/hli/modules/modules_l23/family_f.py +0 -145
  87. xoa_driver/internals/hli/modules/modules_l23/family_h.py +0 -40
  88. xoa_driver/internals/hli/modules/modules_l23/family_i.py +0 -25
  89. xoa_driver/internals/hli/modules/modules_l23/family_j.py +0 -25
  90. xoa_driver/internals/hli/modules/modules_l23/family_k.py +0 -39
  91. xoa_driver/internals/hli/modules/modules_l23/family_m.py +0 -25
  92. xoa_driver/internals/hli/modules/modules_l23/family_n.py +0 -40
  93. xoa_driver/internals/hli/ports/port_l23/edun_l1.py +0 -181
  94. xoa_driver/internals/hli/ports/port_l23/family_combi.py +0 -37
  95. xoa_driver/internals/hli/ports/port_l23/family_d.py +0 -51
  96. xoa_driver/internals/hli/ports/port_l23/family_f.py +0 -151
  97. xoa_driver/internals/hli/ports/port_l23/family_h.py +0 -67
  98. xoa_driver/internals/hli/ports/port_l23/family_i.py +0 -84
  99. xoa_driver/internals/hli/ports/port_l23/family_j.py +0 -68
  100. xoa_driver/internals/hli/ports/port_l23/family_k.py +0 -73
  101. xoa_driver/internals/hli/ports/port_l23/family_l.py +0 -82
  102. xoa_driver/internals/hli/ports/port_l23/family_m.py +0 -29
  103. xoa_driver/internals/hli/ports/port_l23/pcs_pma_ghijkl.py +0 -369
  104. xoa_driver/internals/hli/ports/port_l23/pcs_pma_l.py +0 -78
  105. {tdl_xoa_driver-1.5.1.dist-info → tdl_xoa_driver-1.6.0.dist-info}/WHEEL +0 -0
  106. {tdl_xoa_driver-1.5.1.dist-info → tdl_xoa_driver-1.6.0.dist-info}/licenses/LICENSE +0 -0
  107. {tdl_xoa_driver-1.5.1.dist-info → tdl_xoa_driver-1.6.0.dist-info}/top_level.txt +0 -0
  108. /xoa_driver/internals/hli/modules/modules_l23/{family_l1.py → family_freya.py} +0 -0
  109. /xoa_driver/internals/hli/ports/port_l23/{bases → layer1}/__init__.py +0 -0
  110. /xoa_driver/internals/hli/ports/port_l23/{bases → trafficgen}/port_capture.py +0 -0
@@ -1,6 +1,5 @@
1
1
  from typing import TYPE_CHECKING
2
2
  from xoa_driver.internals.commands import (
3
- P_AUTONEGSELECTION, # questionable which ports are electrical
4
3
  P_LPENABLE,
5
4
  P_LPTXMODE,
6
5
  P_LPSTATUS,
@@ -12,9 +11,6 @@ from xoa_driver.internals.commands import (
12
11
  if TYPE_CHECKING:
13
12
  from xoa_driver.internals.core import interfaces as itf
14
13
 
15
- from .bases.port_l23_genuine import BasePortL23Genuine
16
-
17
-
18
14
  class LowPowerMode:
19
15
  """L23 port low power mode."""
20
16
 
@@ -58,50 +54,4 @@ class LowPowerMode:
58
54
  """EEE capabilities of the port.
59
55
 
60
56
  :type: P_LPSUPPORT
61
- """
62
-
63
-
64
- class FamilyE(BasePortL23Genuine):
65
- def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int) -> None:
66
- super().__init__(conn, module_id, port_id)
67
- self.autoneg_selection = P_AUTONEGSELECTION(conn, module_id, port_id)
68
- """L23 port's auto-negotiation selection.
69
-
70
- :type: P_AUTONEGSELECTION
71
- """
72
-
73
- self.eee = LowPowerMode(conn, module_id, port_id)
74
- """L23 port Low Power mode settings.
75
-
76
- :type: LowPowerMode
77
- """
78
-
79
-
80
- class POdin5G4S6PCU(FamilyE):
81
- """L23 port on Odin-5G-4S-6P-CU module.
82
- """
83
- ...
84
-
85
-
86
- class POdin10G5S6PCU(FamilyE):
87
- """L23 port on Odin-10G-5S-6P-CU module.
88
- """
89
- ...
90
-
91
-
92
- class POdin10G5S6PCU_b(FamilyE):
93
- """L23 port on Odin-10G-5S-6P-CU[b] module.
94
- """
95
- ...
96
-
97
-
98
- class POdin10G3S6PCU(FamilyE):
99
- """L23 port on Odin-10G-3S-6P-CU module.
100
- """
101
- ...
102
-
103
-
104
- class POdin10G3S2PCU(FamilyE):
105
- """L23 port on Odin-10G-3S-2P-CU module.
106
- """
107
- ...
57
+ """
@@ -2,95 +2,49 @@ from typing import (
2
2
  TYPE_CHECKING,
3
3
  Tuple,
4
4
  )
5
+ from typing import Self
5
6
  if TYPE_CHECKING:
6
7
  from xoa_driver.internals.core import interfaces as itf
7
8
  from xoa_driver.internals.commands import (
8
- PP_PRECODING,
9
- PP_PRECODINGSTATUS,
10
- PP_GRAYCODING,
11
- PL1_AUTONEGINFO,
12
- PL1_LINKTRAININFO,
13
- PL1_LOG,
14
- PL1_CFG_TMP,
15
- PL1_LINKTRAIN_CMD,
16
- PL1_CTRL,
17
- PL1_GET_DATA,
9
+ PP_PHYTXEQ,
10
+ PP_PHYRETUNE,
11
+ PP_PHYAUTOTUNE,
12
+ PP_PHYRXEQ,
18
13
  PL1_PHYTXEQ_LEVEL,
19
14
  PL1_PHYTXEQ_COEFF,
20
- PL1_AUTONEG_STATUS,
21
- PL1_AUTONEG_ABILITIES,
22
- PL1_PCS_VARIANT,
23
- PL1_AUTONEG_CONFIG,
24
- PL1_ANLT,
25
15
  PL1_PHYTXEQ,
26
- PL1_LINKTRAIN_CONFIG,
27
- PL1_LINKTRAIN_STATUS,
28
16
  PP_PHYRXEQ_EXT,
29
17
  PP_PHYRXEQSTATUS_EXT,
30
- PL1_CWE_CYCLE,
31
- PL1_CWE_ERR_SYM_INDICES,
32
- PL1_CWE_BIT_ERR_MASK,
33
- PL1_CWE_FEC_ENGINE,
34
- PL1_CWE_FEC_STATS,
35
- PL1_CWE_CONTROL,
36
- PL1_CWE_FEC_STATS_CLEAR,
37
- PL1_LT_PHYTXEQ_RANGE,
38
- PL1_LT_PHYTXEQ_RANGE_COEFF,
39
- PL1_PRESET_CONFIG,
40
- PL1_PRESET_CONFIG_COEFF,
41
- PL1_PRESET_CONFIG_LEVEL,
42
- PL1_PRESET_RESET,
43
- PP_PRBSTYPE,
44
- PL1_PNSWAP_RX,
45
- PL1_PNSWAP_TX,
46
- )
47
- from .pcs_pma_ghijkl import (
48
- Prbs,
18
+ P_EDUN_RX_STATUS,
49
19
  )
50
20
  from xoa_driver import enums
51
21
 
52
- class FreyaPMA:
53
- """Freya PMA"""
22
+ class BasicMedium:
23
+ """L23 high-speed port SerDes PHY configuration and status."""
54
24
 
55
25
  def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, serdes_xindex: int) -> None:
56
- self.precoding = PP_PRECODING(conn, module_id, port_id, serdes_xindex)
57
- """GET/SET Pre-Coding Configurations. (only for Freya)
26
+ self.tx_equalizer = PP_PHYTXEQ(conn, module_id, port_id, serdes_xindex)
27
+ """Equalizer settings of the on-board PHY in the TX direction.
58
28
 
59
- :type: PP_PRECODING
29
+ :type: PP_PHYTXEQ
60
30
  """
61
31
 
62
- self.graycoding = PP_GRAYCODING(conn, module_id, port_id, serdes_xindex)
63
- """GET/SET Gray-Coding Configurations. (only for Freya)
32
+ self.rx_equalizer = PP_PHYRXEQ(conn, module_id, port_id, serdes_xindex)
33
+ """Equalizer settings of the on-board PHY in the RX direction.
64
34
 
65
- :type: PP_GRAYCODING
35
+ :type: PP_PHYRXEQ
66
36
  """
67
37
 
68
- self.pn_swap_rx = PL1_PNSWAP_RX(conn, module_id, port_id, serdes_xindex)
69
- """GET/SET PN-Swap RX Configurations. (only for Freya)
70
-
71
- :type: PL1_PNSWAP_RX
72
- """
73
-
74
- self.pn_swap_tx = PL1_PNSWAP_TX(conn, module_id, port_id, serdes_xindex)
75
- """GET/SET PN-Swap TX Configurations. (only for Freya)
76
-
77
- :type: PL1_PNSWAP_TX
78
- """
79
-
80
- class FreyaSIV:
81
- """Freya Signal Integrity View"""
82
-
83
- def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, serdes_xindex: int) -> None:
84
- self.control = PL1_CTRL(conn, module_id, port_id, serdes_xindex, enums.Layer1Control.SAMPLED_SIGNAL_INTEGRITY_SCAN)
85
- """Control SIV scan. (only for Freya)
38
+ self.retune = PP_PHYRETUNE(conn, module_id, port_id, serdes_xindex)
39
+ """Retuning of the PHY.
86
40
 
87
- :type: PL1_CTRL
41
+ :type: PP_PHYRETUNE
88
42
  """
89
43
 
90
- self.data = PL1_GET_DATA(conn, module_id, port_id, serdes_xindex, enums.Layer1Control.SAMPLED_SIGNAL_INTEGRITY_SCAN)
91
- """Get SIV scan data. (only for Freya)
44
+ self.autotune = PP_PHYAUTOTUNE(conn, module_id, port_id, serdes_xindex)
45
+ """Autotune of the PHY.
92
46
 
93
- :type: PL1_GET_DATA
47
+ :type: PP_PHYAUTOTUNE
94
48
  """
95
49
 
96
50
  class FreyaTxTap:
@@ -115,6 +69,11 @@ class FreyaTxTap:
115
69
  :type: PL1_PHYTXEQ_COEFF
116
70
  """
117
71
 
72
+ class EdunTxTap(FreyaTxTap):
73
+ """Edun Tx Tap
74
+ """
75
+ pass
76
+
118
77
  class FreyaRxTapConfig:
119
78
  """Freya Rx Tap Configuration"""
120
79
 
@@ -430,6 +389,14 @@ class FreyaRxTap:
430
389
  """Freya Rx tap status
431
390
  """
432
391
 
392
+ class EdunRxTap:
393
+ """Edun Rx Tap
394
+ """
395
+ def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, serdes_xindex: int) -> None:
396
+ self.status = P_EDUN_RX_STATUS(conn, module_id, port_id, serdes_xindex)
397
+ """Freya Rx tap status
398
+ """
399
+
433
400
  class FreyaMedium:
434
401
  def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, serdes_xindex: int) -> None:
435
402
  self.tx = FreyaTxTap(conn, module_id, port_id, serdes_xindex)
@@ -438,299 +405,12 @@ class FreyaMedium:
438
405
  self.rx = FreyaRxTap(conn, module_id, port_id, serdes_xindex)
439
406
  """Freya Rx tap
440
407
  """
441
- self.siv = FreyaSIV(conn, module_id, port_id, serdes_xindex)
442
- """Freya Signal Integrity
443
- """
444
-
445
- class SerDesFreya:
446
- """L23 high-speed port SerDes configuration and status."""
447
-
448
- def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, serdes_xindex: int) -> None:
449
-
450
- self.prbs = Prbs(conn, module_id, port_id, serdes_xindex)
451
- """PRBS
452
- :type: Prbs
453
- """
454
408
 
455
- self.pma = FreyaPMA(conn, module_id, port_id, serdes_xindex)
456
- """Freya PMA
457
-
458
- :type: FreyaPMA
459
- """
460
-
461
- self.medium = FreyaMedium(conn, module_id, port_id, serdes_xindex)
462
- """Freya medium
463
-
464
- :type: FreyaMedium
465
- """
466
-
467
- self.lt = FreyaLinkTraining(conn, module_id, port_id, serdes_xindex)
468
- """Freya Link Training on serdes level
469
-
470
- :type: FreyaLinkTraining
471
- """
472
-
473
-
474
- class FreyaAutoNeg:
475
- """Freya Autoneg"""
476
-
477
- def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int) -> None:
478
- self.info = PL1_AUTONEGINFO(conn, module_id, port_id, 0)
479
- """Autoneg info
480
-
481
- :type: PL1_AUTONEGINFO
482
- """
483
-
484
- self.status = PL1_AUTONEG_STATUS(conn, module_id, port_id)
485
- """Autoneg status
486
-
487
- :type: PL1_AUTONEG_STATUS
488
- """
489
-
490
- self.abilities = PL1_AUTONEG_ABILITIES(conn, module_id, port_id)
491
- """Autoneg abilities
492
-
493
- :type: PL1_AUTONEG_ABILITIES
494
- """
495
-
496
- self.config = PL1_AUTONEG_CONFIG(conn, module_id, port_id)
497
- """Autoneg configuration
498
-
499
- :type: PL1_AUTONEG_CONFIG
500
- """
501
-
502
- class FreyaLinkTraining:
503
- """Freya Link Training on serdes level"""
504
-
409
+ class EdunMedium:
505
410
  def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, serdes_xindex: int) -> None:
506
- self.cmd = PL1_LINKTRAIN_CMD(conn, module_id, port_id, serdes_xindex)
507
- """Link training command.
508
-
509
- :type: PP_LINKTRAIN
510
- """
511
-
512
- self.info = PL1_LINKTRAININFO(conn, module_id, port_id, serdes_xindex, 0)
513
- """Link training info.
514
-
515
- :type: PL1_LINKTRAININFO
516
- """
517
-
518
- self.status = PL1_LINKTRAIN_STATUS(conn, module_id, port_id, serdes_xindex)
519
- """Link training status.
520
-
521
- :type: PL1_LINKTRAIN_STATUS
411
+ self.tx = EdunTxTap(conn, module_id, port_id, serdes_xindex)
412
+ """Edun Tx tap
522
413
  """
523
-
524
- self.preset1 = FreyaLinkTrainingPreset(conn, module_id, port_id, serdes_xindex, enums.FreyaPresetIndex.PRESET1)
525
- """Link training preset 1
526
-
527
- :rtype: FreyaLinkTrainingPreset
528
- """
529
-
530
- self.preset2 = FreyaLinkTrainingPreset(conn, module_id, port_id, serdes_xindex, enums.FreyaPresetIndex.PRESET2)
531
- """Link training preset 2
532
-
533
- :rtype: FreyaLinkTrainingPreset
534
- """
535
-
536
- self.preset3 = FreyaLinkTrainingPreset(conn, module_id, port_id, serdes_xindex, enums.FreyaPresetIndex.PRESET3)
537
- """Link training preset 3
538
-
539
- :rtype: FreyaLinkTrainingPreset
540
- """
541
-
542
- self.preset4 = FreyaLinkTrainingPreset(conn, module_id, port_id, serdes_xindex, enums.FreyaPresetIndex.PRESET4)
543
- """Link training preset 4
544
-
545
- :rtype: FreyaLinkTrainingPreset
546
- """
547
-
548
- self.preset5 = FreyaLinkTrainingPreset(conn, module_id, port_id, serdes_xindex, enums.FreyaPresetIndex.PRESET5)
549
- """Link training preset 5
550
-
551
- :rtype: FreyaLinkTrainingPreset
552
- """
553
-
554
- self.preset_los = FreyaLinkTrainingPreset(conn, module_id, port_id, serdes_xindex, enums.FreyaPresetIndex.LOS)
555
- """Link training preset LOS
556
-
557
- :rtype: FreyaLinkTrainingPreset
414
+ self.rx = EdunRxTap(conn, module_id, port_id, serdes_xindex)
415
+ """Edun Rx tap
558
416
  """
559
-
560
- self.range = FreyaLinkTrainingRange(conn, module_id, port_id, serdes_xindex)
561
- """Link training tap range
562
-
563
- :rtype: FreyaLinkTrainingRange
564
- """
565
-
566
- self.initial_modulation = PL1_CFG_TMP(conn, module_id, port_id, 0, enums.Layer1ConfigType.LT_INITIAL_MODULATION)
567
- """Link training initial modulation
568
-
569
- :rtype: PL1_CFG_TMP
570
- """
571
-
572
- self.algorithm = PL1_CFG_TMP(conn, module_id, port_id, 0, enums.Layer1ConfigType.LT_TRAINING_ALGORITHM)
573
- """Link training algorithm
574
-
575
- :rtype: PL1_CFG_TMP
576
- """
577
-
578
- self.strict_mode = PL1_CFG_TMP(conn, module_id, port_id, 0, enums.Layer1ConfigType.ANLT_STRICT_MODE)
579
- """ANLT strict mode. In strict mode, errored framed will be ignored.
580
-
581
- :rtype: PL1_CFG_TMP
582
- """
583
-
584
-
585
- class FreyaANLT:
586
- """Freya port-level anlt. For per-serdes configuration and status, use serdes[x]
587
- """
588
- def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int) -> None:
589
- self.an = FreyaAutoNeg(conn, module_id, port_id)
590
- """Autoneg config and status
591
- """
592
- self.ctrl = PL1_ANLT(conn, module_id, port_id)
593
- """ANLT control
594
- """
595
- self.lt_config = PL1_LINKTRAIN_CONFIG(conn, module_id, port_id)
596
- """Port-level Link Training config
597
- """
598
- self.log = PL1_LOG(conn, module_id, port_id)
599
- """ANLT log
600
- """
601
- self.autorestart = PL1_CFG_TMP(conn, module_id, port_id, 0, enums.Layer1ConfigType.AUTO_LINK_RECOVERY)
602
- """ANLT Autorestart
603
- """
604
- self.allow_an_loopback = PL1_CFG_TMP(conn, module_id, port_id, 0, enums.Layer1ConfigType.AN_LOOPBACK)
605
- """ANLT Autorestart
606
- """
607
- self.send_empty_np = PL1_CFG_TMP(conn, module_id, port_id, 0, enums.Layer1ConfigType.AN_EMPTY_NP)
608
- """If the port should send Next Pages if they are empty.
609
- """
610
-
611
- class FreyaFecCodewordErrorInject:
612
- """Freya FEC Codeword Error Injection
613
- """
614
- def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int) -> None:
615
- self.cycle = PL1_CWE_CYCLE(conn, module_id, port_id)
616
- """FEC codeword error injection cycle.
617
- """
618
- self.err_symbols = PL1_CWE_ERR_SYM_INDICES(conn, module_id, port_id)
619
- """The positions of the errored symbols in errored codewords.
620
- """
621
- self.bit_err_mask = PL1_CWE_BIT_ERR_MASK(conn, module_id, port_id)
622
- """The bit error mask for the errored symbols.
623
- """
624
- self.engine = PL1_CWE_FEC_ENGINE(conn, module_id, port_id)
625
- """The FEC engines to use.
626
- """
627
- self.statistics = PL1_CWE_FEC_STATS(conn, module_id, port_id)
628
- """FEC error injection statistics
629
- """
630
- self.clear_stats = PL1_CWE_FEC_STATS_CLEAR(conn, module_id, port_id)
631
- """Clear FEC codeword injection stats
632
- """
633
- self.control = PL1_CWE_CONTROL(conn, module_id, port_id)
634
- """Control the FEC codeword error injection
635
- """
636
-
637
- class Layer1:
638
- def __init__(self, conn: "itf.IConnection", port) -> None:
639
- self.serdes: Tuple[SerDesFreya, ...] = tuple(
640
- SerDesFreya(conn, *port.kind, serdes_xindex=idx)
641
- for idx in range(port.info.capabilities.serdes_count)
642
- )
643
- self.anlt = FreyaANLT(conn, *port.kind)
644
- """Freya port-level anlt. For per-serdes configuration and status, use serdes[x]
645
- """
646
- self.pcs_variant = PL1_PCS_VARIANT(conn, *port.kind)
647
- """PCS variant configuration
648
- """
649
- self.fec_error_inject = FreyaFecCodewordErrorInject(conn, *port.kind)
650
- """FEC codeword error injection
651
- """
652
- self.prbs_config = PP_PRBSTYPE(conn, *port.kind)
653
- """PRBS configuration, including PRBS polynomial, invert mode, and statistic collection mode (for RX).
654
- """
655
-
656
- class FreyaLinkTrainingPreset:
657
- """Freya Link Training Preset"""
658
-
659
- def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, serdes_xindex: int, preset_index: enums.FreyaPresetIndex) -> None:
660
-
661
- self.native = PL1_PRESET_CONFIG(conn, module_id, port_id, serdes_xindex, preset_index)
662
- """Preset native values. (only for Freya)
663
-
664
- :type: PL1_PRESET_CONFIG
665
- """
666
-
667
- self.ieee = PL1_PRESET_CONFIG_COEFF(conn, module_id, port_id, serdes_xindex, preset_index)
668
- """Preset IEEE coefficient values. (only for Freya)
669
-
670
- :type: PL1_PRESET_CONFIG_COEFF
671
- """
672
-
673
- self.level = PL1_PRESET_CONFIG_LEVEL(conn, module_id, port_id, serdes_xindex, preset_index)
674
- """Preset mV/dB values. (only for Freya)
675
-
676
- :type: PL1_PRESET_CONFIG_LEVEL
677
- """
678
-
679
- self.reset = PL1_PRESET_RESET(conn, module_id, port_id, serdes_xindex, preset_index)
680
- """Reset preset to default. (only for Freya)
681
-
682
- :type: PL1_PRESET_RESET
683
- """
684
-
685
- class FreyaLinkTrainingRangeTap:
686
- """Freya Link Training Range Tap"""
687
-
688
- def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, serdes_xindex: int, tap_index: enums.FreyaTapIndex) -> None:
689
-
690
- self.native = PL1_LT_PHYTXEQ_RANGE(conn, module_id, port_id, serdes_xindex, tap_index)
691
- """Tap range native values. (only for Freya)
692
-
693
- :type: PL1_LT_PHYTXEQ_RANGE
694
- """
695
-
696
- self.ieee = PL1_LT_PHYTXEQ_RANGE_COEFF(conn, module_id, port_id, serdes_xindex, tap_index)
697
- """Tap range IEEE coefficient values. (only for Freya)
698
-
699
- :type: PL1_LT_PHYTXEQ_RANGE_COEFF
700
- """
701
-
702
-
703
- class FreyaLinkTrainingRange:
704
- """Freya Link Training Range"""
705
-
706
- def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, serdes_xindex: int) -> None:
707
-
708
- self.pre = FreyaLinkTrainingRangeTap(conn, module_id, port_id, serdes_xindex, enums.FreyaTapIndex.TAP0)
709
- """Pre tap range and response. (only for Freya)
710
-
711
- :type: FreyaLinkTrainingRangeTap
712
- """
713
-
714
- self.main = FreyaLinkTrainingRangeTap(conn, module_id, port_id, serdes_xindex, enums.FreyaTapIndex.TAP1)
715
- """Main tap range and response. (only for Freya)
716
-
717
- :type: FreyaLinkTrainingRangeTap
718
- """
719
-
720
- self.post = FreyaLinkTrainingRangeTap(conn, module_id, port_id, serdes_xindex, enums.FreyaTapIndex.TAP2)
721
- """Post tap range and response. (only for Freya)
722
-
723
- :type: FreyaLinkTrainingRangeTap
724
- """
725
-
726
- self.pre2 = FreyaLinkTrainingRangeTap(conn, module_id, port_id, serdes_xindex, enums.FreyaTapIndex.TAP3)
727
- """Pre2 tap range and response. (only for Freya)
728
-
729
- :type: FreyaLinkTrainingRangeTap
730
- """
731
-
732
- self.pre3 = FreyaLinkTrainingRangeTap(conn, module_id, port_id, serdes_xindex, enums.FreyaTapIndex.TAP4)
733
- """Pre3 tap range and response. (only for Freya)
734
-
735
- :type: FreyaLinkTrainingRangeTap
736
- """