1

I am testing my Microsemi FPGA with a NI myDAQ and am getting some strange waveforms. All that I am doing is inputting a 3Vpp square wave at 10kHz and expecting the same output since my code is just setting the output to the input (shown below). I've also included a picture of my input waveform before it is connected to the myDAQ and what it looks like after the myDAQ is connected.

module test( in_1, clk, out_1 );
input in_1, clk;
output out_1;

reg out_1;

//<statements>
always @(posedge clk)
begin
    out_1 <= in_1;
end

endmodule

Here is the input waveform when the myDAQ is not connected:

Here is the waveform when the myDAQ is connected. The top wave (green) is the input while the bottom wave (blue) is the output. Why is the input voltage dropping by almost 1V when the myDAQ is connected and why is the output wave dropping even lower than that? The original signal was 3Vpp so shouldn't the output be the same?

enter image description here

I know I should be using a real function generator with a real oscilloscope instead of a myDAQ, but I am not allowed in my lab right now because of the pandemic.

yer
  • 67
  • 2
  • 8
  • 1
    It looks like you have the volts per division set to 1 for the green trace and 2 for the blue trace. If you set them the same do you still see a problem? – The Photon Sep 05 '20 at 22:56
  • @ThePhoton Yes I still have the same problem. – yer Sep 05 '20 at 23:47
  • What circuit or instrument is generating the input signal? What input range are the MyDAQ inputs set to? – The Photon Sep 06 '20 at 03:12

1 Answers1

2

Why is the input voltage dropping by almost 1V when the myDAQ is connected and why is the output wave dropping even lower than that?

You haven't said what circuit or instrument is generating the input signal, so there's no way we can know that.

The original signal was 3Vpp so shouldn't the output be the same?

When you pass the signal into the FPGA it will be fully digitized. Any analog features in the signal (ripple on the high or low level, the actual voltage of the high and low levels, rise and fall times of the edges, etc) will not be reflected in the output.

The output voltage levels will depend on what IO standard you chose for the FPGA output buffer. They can be totally unrelated to what voltage levels and IO standard you used for the FPGA input.

The Photon
  • 126,425
  • 3
  • 159
  • 304
  • I have told you what is generating the input signal. It is a National Instruments myDAQ where I am using the function generator setting. The input waveform was set to a 3Vpp square wave at 10kHz with 0 DC offset. – yer Sep 06 '20 at 18:44
  • As a function generator, the myDAQ has a max frequency of 20kHz, 10Vpp amplitude max and -5V to +5V DC Offset range. – yer Sep 06 '20 at 18:46
  • @yer, if the MyDAQ is the function generator, how did you measure any waveform at all before you hooked up the MyDAQ? – The Photon Sep 06 '20 at 19:28