@@ -1482,7 +1482,7 @@ def add_dual_interfaces(
1482
1482
tx_config ["interfaces" ][0 ]["name" ] = tx_nic_port_list [0 ]
1483
1483
1484
1484
# Configure RX host interface only
1485
- rx_config ["interfaces" ][0 ]["name" ] = rx_nic_port_list [1 ]
1485
+ rx_config ["interfaces" ][0 ]["name" ] = rx_nic_port_list [0 ]
1486
1486
1487
1487
if test_mode == "unicast" :
1488
1488
tx_config ["interfaces" ][0 ]["ip" ] = unicast_ip_dict ["tx_interfaces" ]
@@ -1673,20 +1673,27 @@ def execute_dual_test(
1673
1673
tx_config = config ["tx_config" ]
1674
1674
rx_config = config ["rx_config" ]
1675
1675
1676
+ tx_config_json = json .dumps (tx_config , indent = 4 )
1677
+ rx_config_json = json .dumps (rx_config , indent = 4 )
1678
+
1676
1679
# Log test start
1677
1680
logger .info (f"Starting dual RxTxApp test: { get_case_id ()} " )
1678
1681
log_to_file (f"Starting dual RxTxApp test: { get_case_id ()} " , tx_host , build )
1679
1682
log_to_file (f"Starting dual RxTxApp test: { get_case_id ()} " , rx_host , build )
1680
- log_to_file (f"TX config: { json . dumps ( tx_config , indent = 4 ) } " , tx_host , build )
1681
- log_to_file (f"RX config: { json . dumps ( rx_config , indent = 4 ) } " , rx_host , build )
1683
+ log_to_file (f"TX config: { tx_config_json } " , tx_host , build )
1684
+ log_to_file (f"RX config: { rx_config_json } " , rx_host , build )
1682
1685
1683
1686
# Prepare TX config
1687
+ tx_config_file = f"{ build } /tests/tx_config.json"
1684
1688
tx_f = tx_host .connection .path (build , "tests" , "tx_config.json" )
1685
- tx_f .write_text (tx_config , encoding = "utf-8" )
1689
+ tx_json_content = tx_config_json .replace ('"' , '\\ "' )
1690
+ tx_f .write_text (tx_json_content )
1686
1691
1687
1692
# Prepare RX config
1688
- rx_f = tx_host .connection .path (build , "tests" , "rx_config.json" )
1689
- rx_f .write_text (rx_config , encoding = "utf-8" )
1693
+ rx_config_file = f"{ build } /tests/rx_config.json"
1694
+ rx_f = rx_host .connection .path (build , "tests" , "rx_config.json" )
1695
+ rx_json_content = rx_config_json .replace ('"' , '\\ "' )
1696
+ rx_f .write_text (rx_json_content )
1690
1697
1691
1698
# Adjust test_time for high-res/fps/replicas
1692
1699
if (
@@ -1710,8 +1717,8 @@ def execute_dual_test(
1710
1717
if ptp :
1711
1718
base_command += " --ptp"
1712
1719
1713
- tx_command = f"{ base_command } --config_file { tx_config } "
1714
- rx_command = f"{ base_command } --config_file { rx_config } "
1720
+ tx_command = f"{ base_command } --config_file { tx_config_file } "
1721
+ rx_command = f"{ base_command } --config_file { rx_config_file } "
1715
1722
1716
1723
logger .info (f"TX Command: { tx_command } " )
1717
1724
logger .info (f"RX Command: { rx_command } " )
0 commit comments