I am just a beginner in electronics, so please bear with me.

I am using a signal generator to get two channel output which are then fed to a FPGA based Mojo. The mojo is then connected to a computer which has a GUI, which shows me counts on two channels. The mojo has a 50 MHz clock cycle. The way it works is:

"The external signal from the signal generator is connected via BNC to 4 I/O pins on the FPGA. The signals that are captured are then digitized by Pulse Replicator Modules, which I think is also supposed to help in synchronization of external signal with the FPGA clock. The output signal is then sent to a comparator module which is like a 4-way AND gate;when the input is connected to the top-level Pin Register, an OR mask is used to hold a “1” on the channels the user wishes to ignore. "

Now, the problem is if I set my channel A to 10 MHz, my GUI shows that at least 100 counts are lost. Same for channel B. But, when it is a low frequency signal like let's say 5KHz, it shows 4999 and fluctuates around that value. What could possibly be the problem that I am losing counts? Is it because the clock cycles of the FPGA in the mojo and the signal generator asynchronous?

Edit: I have added how the signal is processed by the FPGA.

  • \$\begingroup\$ I am sorry for not clearing that up. Mojo is a FPGA development board by embedded micro. More here. embeddedmicro.com/products/mojo-v3 \$\endgroup\$ – Ufomammut Jul 13 '18 at 16:14
  • \$\begingroup\$ Please describe the method you are using to measure the frequency. For example, are you clocking the counter with the external signal? \$\endgroup\$ – crj11 Jul 13 '18 at 16:47
  • \$\begingroup\$ I did make some changes @crj11 \$\endgroup\$ – Ufomammut Jul 13 '18 at 17:50
  • 1
    \$\begingroup\$ 100 counts out of 10MHz amounts to 10ppm accuracy. You signal generator is probably more accurate than that, but I'm betting your FPGA crystal isn't. You might just be looking at a slight difference in reference frequency. \$\endgroup\$ – Cristobol Polychronopolis Jul 13 '18 at 17:57
  • \$\begingroup\$ what is a reference frequency? \$\endgroup\$ – Ufomammut Jul 13 '18 at 18:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.