I am having a strange problem with my Zedboard when I program it with SImulink. I am truing to implement SPWM and SVPWM with my board and I need to implmenet a sine wave as a reference signal for these PWM techniques. When I implement the Sine wave in the HDL part using the NCO block, both simulations and experimnetal results from zedbaord work perfectly and without the problem. However, when I put the Sine wave generator block in the DSP part (outside of the HDL part) the experimental results do not work as intended anymore. In this mode, the simulation results are still good but the output signals from the zedboard have a very low frequency and differ from the simulations. Based on my observation, the frequency of the Sine wave is divided by 160 when the Sine wave generator block is not the HDL part. For example, when I try to generate a 50 Hz Sine wave, the output of the first order signal in the Zedbaord is around (50/160) Hz. It seems that something is happening when the signals are trnsferred through the AXI4 channel. I have tried different sine wave generator blocks but all of them have the same problem and I only get the proper output in simulations. Does anyone know what could be my problem?
Thank you very much.