Resolve issues encountered while using the hardware-software (HW/SW) co-design workflow.
In external mode, the Simulink® time counter does not increment. This problem can occur with a misconfigured loop scheduler.
Stop the model from running on the hardware. In these commands, replace
ModelName with the name of your Simulink model.
devzynq = zynq('linux','192.168.3.2','root','root','/tmp'); stop(devzynq,'ModelName')
Verify your choice of scheduler, frame sizes, and associated timeout values. If the ARM® software is not receiving schedule ticks from your source, the model cannot run. The transmit interrupt scheduler in particular can cause this behavior.
If your model is sensitive to the execution order of the blocks, the default Simulink ordering can cause unexpected behavior. For example, if your model requires the transmitter to start before the receiver and the default ordering starts the receiver first, unexpected behavior occurs.
Use the Simulink sorted order to specify priorities of the blocks. See Control and Display the Sorted Order (Simulink).
The model compiles, downloads to the hardware, starts running, and exits immediately.
Two different errors can cause this behavior:
You attached a Stop Simulation block to a transmitter or receiver overflow or underflow port, and an overflow or underflow occurred. Verify that your frame rates work without timeout failures in the context of the baseband sample rate and user logic functionality on the FPGA.
You did not load the required FPGA image into the hardware. The software attempts to read and write from addresses that correspond to the user logic IP core. If the core is not present, the processor stops.
codertarget.zynq.internal.setupTokens()throws an error
Code generation cannot proceed because the following file or folder could not be found: C:\ProgramData\MATLAB\SupportPackages\R2016b\toolbox\target\supportpackages \zynq\registry\thirdpartytools\thirdpartytools_win64.xml
This error occurs when third-party tools are not set up correctly.
Check the installation details on Installation for Hardware-Software Co-Design. Make sure that additional support packages are installed and configured as described in steps 4 and 5.
The build procedure for the software interface model fails with the following error:
rtiostream_utils.h: No such file or directory #include "rtiostream_utils.h" ^ compilation terminated. gmake: *** [rtiostream_interface.c.o] Error 1
Set the simulation mode of your model to
before building the model.
When running the model in external mode, the MATLAB® command window displays the following warning message.
Warning: No data has been selected for uploading
The warning indicates that the model does not contain a sink block to which external mode can send data.
You can disregard this warning. Alternatively, add a sink block and rerun the model.