Main Content

Create Model Using Simulink Templates

SoC Blockset™ Support Package for AMD FPGA and SoC Devices provides Simulink® model templates for working with an HDMI camera card. The templates provide a starting point to:

  • Design frame-based algorithms to run in Simulink.

  • Design pixel-streaming algorithms targeted to the FPGA

  • Design frame-based algorithms targeted to the ARM® processor.

  • Design combination hardware and software algorithms that use the FPGA and the ARM processor.

  • Design pixel-streaming algorithms targeted to the FPGA that use a frame buffer or AXI manager interface.

The templates require that you have the Computer Vision Toolbox™ product installed. The templates for software targeting also require Embedded Coder® and Embedded Coder Support Package for AMD SoC Devices.

Note

The templates use the Video Capture HDMI block and are meant for use with an HDMI FMC card. If you are using a MIPI® FMC card, you can replace the Video Capture HDMI block in some templates with the Video Capture MIPI block. To choose a template for use with a MIPI FMC card, consider these limitations.

  • The MIPI card reference design supports only RGB format.

  • For pixel-streaming design with MIPI, you must replace the blocks in the Conversion area with RGB Vector to Packed RGB and Packed RGB to RGB Vector blocks. You can copy these blocks from the Corner Detection with Zynq-Based Hardware and MIPI Sensor example.

  • The MIPI reference design supports a random access external memory interface but does not support a frame buffer external memory interface.

The templates show how to capture video from the hardware and convert video data to the required interfaces for the respective algorithm designs.

  1. Click the Simulink button, , or type simulink at the MATLAB® command prompt. If you already have Simulink open, click the arrow next to the New Model button, and select Model....

  2. On the Simulink start page, expand the SoC Blockset Support Package for AMD FPGA and SoC Devices section, and click the model template you want to open.

    SoC Blockset Support Package for AMD FPGA and SoC Devices template choices on the Simulink start page.

You can also create a model from one of these templates from the command line. For example:

new_system myVZmodel FromTemplate visionzynq_behavioral_Yonly.sltx
open_system myVZmodel
The table shows the model name for each template.

  
Frame-Based Design for Simulinkvisionzynq_behavioral_YCbCr.sltx
visionzynq_behavioral_RGB.sltx
visionzynq_behavioral_Yonly.sltx
Pixel-Streaming Design for FPGAvisionzynq_target_YCbCr.sltx
visionzynq_target_RGB.sltx
visionzynq_target_Yonly.sltx
Pixel-Streaming Design with Frame Buffervisionzynq_framebuffer_YCbCr.sltx
visionzynq_framebuffer_RGB.sltx
visionzynq_framebuffer_Yonly.sltx
Pixel-Streaming Design with External Memoryvisionzynq_AXImemory_YCbCr.sltx
visionzynq_AXImemory_RGB.sltx
visionzynq_AXImemory_Yonly.sltx
Frame-Based Design for ARM Processorvisionzynq_target_SW.sltx
Hardware-Software Co-Designvisionzynq_HWSW_target_HW.sltx
visionzynq_HWSW_target_SW.sltx

A new model, with the template contents and settings, opens in the Simulink Editor. Save the model.

Related Topics