FPGA Capture capturing only few samples and repeating them continuously

Hello everyone,
I’ve been working on a design in Simulink using HDL Coder. The design includes a counter, which I’ve set as a test point and routed as FPGA Data Capture. I’m utilizing the HDL Workflow Advisor and using the supported Arty A7 FPGA as Target platform, where everything is integrated automatically. The Vivado project meets timing requirements, and the data capture window is configured to capture 4096 samples.
However, I’m encountering an issue: when I capture data (without any capture condition), I only see a few samples, and these samples are repeated continuously in the buffer. I’ve attached an image for reference. In the image, the signal tp_counter constantly cycles from 210 to 242 and then back to 210, filling the entire buffer with these repeated values.
In contrast, during simulation, this signal behaves as expected, counting from 0 to 999. This counter is also used to generate a PWM signal by comparing it with a duty cycle. The PWM signal is routed outside the FPGA, and I’ve verified with an oscilloscope that it operates at the desired frequency (equivalent to the counter cycling through the full range of 0-999).
Given this, I’m confident that the hardware is functioning correctly, and the issue seems isolated to the capture module, which appears to be capturing only 33 samples (from 210 to 242) and repeatedly filling the rest of the buffer with these samples until it reaches 4096.
Does anyone have an idea what might be causing this behavior?
Thanks in advance!
Best regards,
Alberto.

2 Comments

Hi again,
I’ve done some further testing and found something interesting: this issue only occurs when I select PL Ethernet as the communication method for FPGA Data Capture. When I switch to JTAG over USB, the data is captured correctly — I see the full counter range as expected, and there’s no repetition or truncation.
I’ve verified this behavior using both MATLAB R2024b and R2025a, and the issue is consistent across both versions. So it seems like the problem is somehow related to the use of Ethernet for data capture, rather than the design or the hardware itself.
Hope this additional detail helps narrow down the cause.
Best regards,
Alberto
Hello Alberto,
Thank you for identifying the issue. Please raise a technical support case so that we can provide you with the patch. A permanent fix will be included in the next update release.
Regards,
Parashurama

Sign in to comment.

Answers (0)

Categories

Find more on FPGA, ASIC, and SoC Development in Help Center and File Exchange

Products

Release

R2024b

Asked:

on 23 Jan 2025

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!