In this example, you will add the AXI GPIO, AXI Timer, the interrupt instantiated in the fabric, and the EMIO interface. You will then validate the fabric additions.
Open the Vivado design created in Example 1: Creating a New Embedded Project with Zynq SoC:
Launch the AMD Vivado™ IDE.
Under the Recent Projects column, click the edt_zc702 design that you created in Example 1: Creating a New Embedded Project with Zynq SoC.
In Flow Navigator window, click Open Block Design under IP Integrator.
Add the AXI GPIO and AXI Timer IP:
In the Diagram window, right-click in the blank space and select Add IP.
In the search box, type AXI GPIO and double-click the AXI GPIO IP to add it to the block design. The AXI GPIO IP block appears in the Diagram window.
In the Diagram window, right-click in the blank space and select Add IP.
In the search box, type AXI Timer and double-click the AXI Timer IP to add it to the block design. The AXI Timer IP block appears in the Diagram view.
Enable the ZYNQ7 Processing System EMIO GPIO:
Double-click the ZYNQ7 Processing System IP block.
The Re-customize IP dialog box opens, as shown in the following figure.
Click MIO Configuration.
Expand I/O Peripherals→ GPIO and enable the EMIO GPIO (Width) check box.
Change the EMIO GPIO (Width) to 1.
Enable the ZYNQ7 Processing System interrupt:
Navigate to Interrupts → Fabric Interrupts → PL-PS Interrupt Ports.
Check the Fabric Interrupts box to enable PL to PS interrupts.
Check IRQ_F2P[15:0] to enable general interrupts. The CoreN_nFIQ signals are used for fast interrupt.
Click OK to accept the changes to the ZYNQ7 Processing System IP. The diagram looks like the following figure.
Connect the PL IPs:
Click the Run Connection Automation link at the top of the page to automate the connection process for the newly added IP blocks.
In the Run Connection Automation dialog box, select the check box next to All Automation, as shown in the following figure.
Click OK.
Upon completion, the updated diagram looks like the following figure.
Customize the AXI GPIO IP block:
Double-click the AXI GPIO IP block to customize it.
Under the Board page, make sure that both GPIO and GPIO2 are set to Custom.
Select the IP Configuration page. In the GPIO section, change the GPIO Width to 1 because you only need one GPIO port.
Ensure that All Inputs and All Outputs are both unchecked.
Click OK to accept the changes.
Connect interrupt signals:
Notice that the Interrupt port is not automatically connected to the AXI Timer IP Core. In the Block Diagram view, locate the IRQ_F2P[0:0] port on the ZYNQ7 Processing System.
Scroll your mouse over the connector port until the pencil button appears, then click the IRQ_F2P[0:0] port and drag to the interrupt output port on the axi_timer_0 to make a connection between the two ports.
Make the PS GPIO port external:
Notice that the ZYNQ7 Processing System GPIO_0 port is not connected. Right-click the GPIO_0 output port on the ZYNQ7 Processing System and select Make External.
The pins are external but do not have the required constraints for our board. To constrain your hardware pins to specific device locations, follow the steps below. These steps can be used for any manual pin placements.