pavel-demin / red-pitaya-notes

Notes on the Red Pitaya Open Source Instrument
http://pavel-demin.github.io/red-pitaya-notes/
MIT License
337 stars 209 forks source link

Question: axis_red_pitaya_dac data rate #794

Closed Apollo3zehn closed 5 years ago

Apollo3zehn commented 5 years ago

Hi Pavel,

I have a question about your axis_red_pitaya_dac IP. When I simulate this IP in Vivado, I can see that the update rate of dac_dat is equal to the aclk input:

grafik

But according to the DAC datasheet, it should update with twice the clock in interleaved mode. So the data should update at the same rate as the ddr_clk (IQCLK) input.

grafik

So I would say this line of code should be changed to .C(ddr_clk), to ensure the correct data rate.

What dou think? Did I overlook somethink?

Thanks Vincent

pavel-demin commented 5 years ago

Thanks for checking the axis_red_pitaya_dac module.

What dou think? Did I overlook somethink?

Your simulated timing diagram shows the following:

So, your simulated timing diagram confirms that the axis_red_pitaya_dac module works correctly.

The internal DAC data registers (int_dat_a_reg and int_dat_b_reg) are connected to the output DDR register. The DDR register updates its output (dac_dat) on both the rising and falling edges of the aclk clock. So, dac_dat is update twice per the aclk clock period.

Apollo3zehn commented 5 years ago

You are right, I misinterpreted my simulation. Thanks for clarification :)