Specifying System Ports

Thesys_portpragma allows you to override the SDSoC system compiler port selection to choose the ACP or one of the AFI ports on the Zynq-7000 AP SoC Processing System (PS) to access the processor memory.

  1. You do not need to generate an SD card boot image to inspect the structure of the system generated by the SDx system compiler, so set project linker options to prevent generating the bit stream, boot image and build.
    1. Click on thelab3tab to select the SDx Project Settings.
    2. Deselect theGenerate bitstreamandGenerate SD card imagecheck boxes.
  2. Right-click on the top level folder for the project in Project Explorer and selectBuild Project.
  3. When the build completes, in theReportspanel, double-clickData Motion Network Reportto view the Data Motion Network report. The report contains a table describing the hardware/software connectivity for each hardware function.

    The right-most column (Connection) shows the type of DMA assigned to each input array of the matrix multiplier (AXIDMA_SIMPLE= simple DMA), and the Processing System 7 IP port used. The table below displays a partial view of thedata_motion.htmlfile, before adding thesys_portpragma.

  4. Addsys_portpragma.
    1. Double-clickmmultadd.hfile in the Project Explorer view, under thesrcfolder, to open the file in the source editor.
    2. Immediately preceding the declaration for themmultfunction, insert the following to specify a different system port for each of the input arrays.
      #pragma SDS data sys_port(A:ACP, B:AFI)
    3. Save the file.
  5. Right-click the top-level folder for the project and click onClean Projectin the menu.
  6. Right-click the top-level folder for the project and click onBuild Projectin the menu.
  7. When the build completes, click on the tab showing the Data Motion Network Report (data_motion.htmlfile).
  8. Click anywhere in the Data Motion Network Report pane and selectRefreshfrom the context menu.

    The connection column shows the system port assigned to each input/output array of the matrix multiplier.

  9. Delete the pragma#pragma SDS data sys_port(A:ACP, B:AFI)and save the file.