增强型 CPRI (eCPRI) 技术在赋能下一代 5G 无线应用中的作用正变得越来越重要。赛灵思 Radio over Ethernet Framer (RoE Framer) 核是一整套 eCPRI 和下一代前传接口 (Next Generation Fronthaul Interface, NGFI) 系统解决方案中不可或缺的一部分。
赛灵思专为此提供了仿真工程和硬件演示。本篇博文将帮助用户初始化仿真示例、分析波形中的仿真数据并展示如何使用测试激励文件演示文件来应用用户自己的配置。
RoE IP 提供了 2 个仿真流程示例:Block Automation 流程和 Open IP Example 流程。
该成帧器将环回到解帧器,并且可通过某些配置来观察到数据流。但由于此结果难以保证,因此数据流仿真应使用设计示例。
Block Automation 流程
1. 使用 Zynq UltraScale+ MPSoC 或 RFSoC 器件系列创建新的 Vivado 工程。
2. 创建新的块设计 (Block Design)

3.在块设计界面上添加 Radio Over Ethernet Framer。

4.运行首次块自动化设置 (Block Automation)。“当前无法添加仿真时钟 (Cannot add simulation clocks atthis time)”将灰显。

5.如果开发板类型为 ZCU102 或 ZCU111,那么生成的块设计将作为硬件演示设计。
现在,重新运行 Block Automation。

6.勾选“连接简单时钟以供仿真 (Connect simple clocks forsimulation)”

这样即可看到,时钟生成块已添加到其中,以提供激励:

7. 在“Sources”视图中,高亮 .bd 文件、右键单击,然后在完成第 2 次块自动化设置后创建 HDL 封装。

8.在“仿真源 (Simulation Sources)”下找到生成的封装文件,然后选中“设为顶层 (Set as Top)”

9.在 Flow Navigator 中,单击“运行仿真 (Run Simulation) -> 运行行为仿真 (Run Behavioral Simulation)”

10.在波形窗口中,您可在“Scope”视图中找到 roe_framer_0 模块,然后将所需信号添加到波形中。

11. 在 Tcl 控制台 (Tcl console) 中添加以下命令发出 3 个信号,以强制启动 RoE Framer:
restart add_force {/design_1_wrapper/design_1_i/datapath/framer_datapath/roe_framer_0/inst/roe_framer_top_i/fram_disable} -radix hex {0 0ns} add_force {/design_1_wrapper/gpio_cdc_dipstatus} -radix hex {00000000 0ns}add_force {/design_1_wrapper/design_1_i/ext_reset_in_1} -radix hex {1 0ns} run 20us
12.允许仿真运行 20us 并再次强制执行复位:
add_force {/design_1_wrapper/design_1_i/ext_reset_in_1} -radix hex {0 0ns} -cancel_after 40 run all
13.现在,您可在仿真中看到数据包传输行为。

注:消息接口即指向 Arm 处理器的路径,在仿真中并未显示。要查看此接口,只需在硬件中插入 ILA 即可
Open IP Example 流程
1.使用 Zynq UltraScale+ MPSoC 或 RFSoC 器件系列创建新的 Vivado 工程。
2.在 IP 目录 (IP Catalog) 中找到 Radio Over Ethernet Framer IP,单击它,然后单击“OK”。

3.单击“生成输出文件 (Generate Output Products)”中的“跳过 (Skip)”

4.右键单击 roe_framer IP,然后单击“打开 IP 设计示例 (Open IP Example Design)”:

5.此时仅添加 roe_radio_top 以将数据环回至 roe_framer,测试激励文件 demo_tb 则作为仿真源来添加。

6.在 Flow Navigator 中,单击“运行仿真 (Run Simulation) -> 运行行为仿真 (Run Behavioral Simulation)”

7.现在仿真已启动并正常运行,您可在波形中看到信号值。

使用测试激励文件演示文件来配置 ROE
测试激励文件演示文件中的 axi_read_basicExample 功能显示了 1 个基本示例。您可直接将其添加到初始流程中用于测试:

如果要控制 ROE 配置,则可使用测试激励文件演示文件中的 JTAG2AXI 块。
例如,如果要发射控制消息,则可写入寄存器 0xA0006008 并将消息类型设置为 #2。在以太网数据包报头中提供 eCPRI Ethertype (AEFE16) 值。

如需获取完整的寄存器映射,请访问RoE Secure Site
在波形中的 AXI4-Lite 接口上可观测到上述寄存器写入/读取行为:

Tcl console 还会打印输出所有寄存器值。

总结
鉴于您已了解如何生成仿真示例,现在您可决定哪个仿真示例最适合用作为您的起点,只有最合适的才是最好的。
下一篇博文《RoE 双演示其二 - 硬件》将提供有关如下几个方面的信息:包括如何使用 GitHub 无线应用来生成硬件演示、初探 xroe_apps API 以及运行 PTP 测试。
本文转载自:Xilinx技术社区