How to control GPIO of ARM on Zedboard
4 ビュー (過去 30 日間)
古いコメントを表示
Hi Paul,
I would like to control the GPIO of ARM on my Zedboard.
I would like to set one/some GPIO to be 1 or 0.
Which function should be called in Matlab? Is there any reference doc online?
Thanks and Best Regards,
Ardeal
回答 (1 件)
Paul
2018 年 11 月 5 日
There currently is no support for GPIOs on a Zedboard from the ARM.
LEDs and DIP switches are connected to the FPGA, you can assign them to an AXI-Lite port and access the data through the ARM using the HDL workflow advisor. Give a look at the following example to do that: Getting Started with Hardware-Software Co-Design Workflow for Xilinx Zynq Platform.
You can do the same using the Zynq Radio support package if you need to. The following example will help you following this workflow for an SDR application: HW/SW Co-Design Implementation of ADS-B Transmitter/Receiver Using Analog Devices AD9361/AD9364. If you mix it with the example above, you will be able to interact with the LEDs and DIP switches from the ARM.
It looks like you can also assign the Pmod connectors of the ZedBoard in step 1.3 of the HDL workflow advisor, but I have not used them. You can maybe give it a try if these are what you need.
3 件のコメント
Paul
2018 年 11 月 5 日
As mentioned, we are not supporting GPIOs for the ZedBoard from the ARM.
However, you can try to use the "execute" command of the "zynq" object to send remote commands to the target from a MATLAB script.
>> help zynq
Then find how to use the GPIO you need on the board. Some documentation migt help you doing this: Using the GPIO driver from User Space
On the target, you can turn on an LED this way for example:
zynq> echo 1 > /sys/class/leds/ld0\:red/brightness
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!