Parameter Tuning with External Mode Simulation
This example shows how to run a Simulink® model in external mode on an ARM® Cortex®-A processor in a Xilinx® Zynq® platform.
Configure a Simulink® model to run as an external mode simulation. In an external mode simulation, the generated code runs on an ARM Cortex-A processor in a Xilinx Zynq platform. External mode enables you to accelerate the design process by tuning parameter values with the model running on hardware and without stopping the model. When you change parameter values from within Simulink, the modified parameter values are communicated to the hardware. The effects of the parameter tuning activity can be monitored by viewing algorithm signals on scopes or displays in the model. For more information on external mode simulation, see Host-Target Communication with External Mode Simulation.
Open and Run External Mode Model
1. Open the zynq_external_mode model.
The model is preconfigured to use the
Xilinx Zynq ZC702 evaluation kit hardware board.
2. On the Hardware tab of the Simulink Toolstrip, click Monitor & Tune to start the external mode simulation. You can stop the simulation at any time by clicking Monitor & Tune again.
3. After the model builds, deploys, and starts running on the connected Xilinx Zynq hardware board, you can double-click the Manual Switch block to change the input source. Open the Gain block to change the signal gain. Double-click on the Scope block to view the external mode simulation results.
For additional external mode simulation settings, open the External Mode Control Panel dialog box by clicking Control Panel on the Hardware tab.