Jump to content
  • 0

Phase detection of high-frequency signals on Zybo | High sampling ADCs or phase detection pmods?


RCB

Question

I am working towards a phase difference detection project to be developed on FPGA. I have Zybo Z7020 board. ADC sampling rate of 1 MSPS. My input signals are of frequency 5 MHz to 10 MHz. Zybo, unfortunately, is not equipped to sample such high frequency signals. I am unable to find external pmods or evaluation boards that can do phase detection (be it analog RF side or digital). Does anyone here have any suggestions for me to look up for? 

I'm also wondering if there could be any daughter boards that handle high frequency analog signals (ADC + mixers + filters (or) just ADCs) and hand over the digital data at a (programmable) lower frequency to the Zybo board. If none of the options work, I might painfully move on to a different FPGA evaluation board (Terasic + Intel) and development software (Quartus). Any suggestions/thoughts on different development board specifications with such support would also be really helpful! Thanks!  

If anyone here worked with NI PCI 5640R - how difficult is it to understand its programming for my application?

Link to comment
Share on other sites

7 answers to this question

Recommended Posts

  • 0
On 8/6/2021 at 5:05 PM, RCB said:

I am working towards a phase difference detection project to be developed on FPGA

Could you be a bit more generous in describing the goals of this project? Are the input signals related, and if so how? Are the input signals sinusoidal, clocks, digital..?

 

Edited by zygot
Link to comment
Share on other sites

  • 0
3 hours ago, zygot said:

Could you be a bit more generous in describing the goals of this project? Are the input signals related, and if so how? Are the input signals sinusoidal, clocks, digital..?

 

Input signals (2) are 5 MHz analog sinusoids - phase shifted. Project requires me to identify this phase difference between them + do some additional computations later.

I am open to suggestions. Here are two main paths that I focused my search toward - 

1) if there are daughter boards (RF, analog) that can do phase detection and give a digital output to read to the FPGA - would be ideal
2) if I need to interface high-sampling ADCs to sample the 5 MHz analog input and write phase detection logic on the FPGA - involved but I can try - most resources I looked online point FPGA for phase detection in digital domain

I currently have a Zybo 7020 board with sampling rate of 1 MSPS and on-board clock of 100 MHz - insufficient resources (workaround available with this board?). I am familiar with Xilinx environment and prefer to stick with it but open to options that meet my project goals. I would really appreciate your kind suggestions.

Edited by RCB
Link to comment
Share on other sites

  • 0

I would certainly agree with you that the 1 MHz XADC, or equivalent, found in modern FPGA deices is inadequate in terms of Fs.

Unfortunately, there aren't any low cost ( under $200 ) FPGA boards that support ADC or DAC conversion in the 100 MHz and higher Fs range. The Digilent ZMOD1410 dual ADC alone costs more that $200, but is the best low cost ADC module that you are likely to find. The question is what SYZYGY compatible FPGA platform do you want to use. Digilent offers two of them and Opal Kelly a couple as well.

Unless you are specifically required to implement the entire project as an embedded solution you don't need a ZYNQ based FPGA board. I would suggest that the non-ARM based FPGA platforms are the preferred choice, depending on your HDL skills. Certainly I'd go with something like the XME7320 and a ZMOD 1410. But, this isn't cheap. Terasic's DDC dual ADDC/DAC board on an Intel platform is a decent alternative and could be used with a number of HSMC equipped FPGA platforms. For low Fs applications I'd recommend staying away from the cheaper Terasic ADC boards because they aren't setup for dealing with low speed signalling. 

Since you mention unspecified additional calculations to be performed I'm guessing that direct signal conversion to digital is an imperative. Given the lack of low cost educational quality hardware available you might consider an FPGA board that isn't limited by 12-pin PMOD interfaces and designing you own ADC add-on board. That would certainly be an impressive implementation, but be careful as the circuitry between your ADC input pins and your signals can easily subvert accurate phase measurements. Seems like an expensive project requirement for a student funded exercise.... If this isn't an educational exercise then I'd be asking about the accuracy/resolution of the phase measurements as this could dictate hardware choices. Designing a solution to a problem that has poorly defined specifications is often a fool's enterprise.

[edit] I'm assuming a few things here; mostly that this is a student project. I can think of a few potential alternate ways to do this in the analog domain. Of course this depends on your measurement specifications. But it would simplify your signalling interface work and expense. For a student project you generally have to show some understanding of coursework preparation.

[edit2] I forgot all about FPGA instruments like the AD2 and RedPitya. In the latter case this is an open system that allows for real custom FPGA application development. It also happens to be ZYNQ based, if that's what you want. There are affordable versions with 2 channels of ADCs that might be suitable, though sample depth is limited. You might not require a lot of samples per cycle if you are smart about how you do you detection. Be prepared for a significant amount of software effort. If you can figure out how to integrate the hardware and software frameworks into your project this is probably the most cost effective platform available... at least to my knowledge. You'll need to be proficient in Linux, Verilog and System Verilog to complete a project in any sort of reasonable time frame.

Edited by zygot
Link to comment
Share on other sites

  • 0
9 hours ago, zygot said:

I would certainly agree with you that the 1 MHz XADC, or equivalent, found in modern FPGA deices is inadequate in terms of Fs.

Unfortunately, there aren't any low cost ( under $200 ) FPGA boards that support ADC or DAC conversion in the 100 MHz and higher Fs range. The Digilent ZMOD1410 dual ADC alone costs more that $200, but is the best low cost ADC module that you are likely to find. The question is what SYZYGY compatible FPGA platform do you want to use. Digilent offers two of them and Opal Kelly a couple as well.

Unless you are specifically required to implement the entire project as an embedded solution you don't need a ZYNQ based FPGA board. I would suggest that the non-ARM based FPGA platforms are the preferred choice, depending on your HDL skills. Certainly I'd go with something like the XME7320 and a ZMOD 1410. But, this isn't cheap. Terasic's DDC dual ADDC/DAC board on an Intel platform is a decent alternative and could be used with a number of HSMC equipped FPGA platforms. For low Fs applications I'd recommend staying away from the cheaper Terasic ADC boards because they aren't setup for dealing with low speed signalling. 

Since you mention unspecified additional calculations to be performed I'm guessing that direct signal conversion to digital is an imperative. Given the lack of low cost educational quality hardware available you might consider an FPGA board that isn't limited by 12-pin PMOD interfaces and designing you own ADC add-on board. That would certainly be an impressive implementation, but be careful as the circuitry between your ADC input pins and your signals can easily subvert accurate phase measurements. Seems like an expensive project requirement for a student funded exercise.... If this isn't an educational exercise then I'd be asking about the accuracy/resolution of the phase measurements as this could dictate hardware choices. Designing a solution to a problem that has poorly defined specifications is often a fool's enterprise.

[edit] I'm assuming a few things here; mostly that this is a student project. I can think of a few potential alternate ways to do this in the analog domain. Of course this depends on your measurement specifications. But it would simplify your signalling interface work and expense. For a student project you generally have to show some understanding of coursework preparation.

[edit2] I forgot all about FPGA instruments like the AD2 and RedPitya. In the latter case this is an open system that allows for real custom FPGA application development. It also happens to be ZYNQ based, if that's what you want. There are affordable versions with 2 channels of ADCs that might be suitable, though sample depth is limited. You might not require a lot of samples per cycle if you are smart about how you do you detection. Be prepared for a significant amount of software effort. If you can figure out how to integrate the hardware and software frameworks into your project this is probably the most cost effective platform available... at least to my knowledge. You'll need to be proficient in Linux, Verilog and System Verilog to complete a project in any sort of reasonable time frame.

I'm carefully reviewing your comments. Thank you for the wonderful support. This is not a coursework oriented project but a personal one but still as a student.

I am looking at resources that would contain details on interfacing external ADCs (zmod) - to analyze its complexity. RedPitaya board appears like an attractive choice too. 

" I can think of a few potential alternate ways to do this in the analog domain. Of course this depends on your measurement specifications. But it would simplify your signalling interface work and expense." - Can you share your suggestions on any daughter boards for doing it in the analog domain? (plus, reading their o/p to the FPGA dev board for additional processing). Measurement test specifications - I would like to create two sinusoids (5 MHz, phase differed) and compute their phase difference to the order of a degree. At this point, I am being childish and considering only the logic side of the implementation. Accuracy-wise I'd be happy with a degree rounded-off values for now. 

Link to comment
Share on other sites

  • 0

I love hearing about projects done for personal edification. The best engineers like doing engineering because they are curious and love the challenge.

I don't know of any add-on boards for doing what you want to do using analog circuitry.  But perhaps I could give you an idea or two to ponder without spoiling the adventure. Perhaps there are multiple paths to explore.

Let's say that you have two 5 MHz sine signals with a fixed phase offset between them. Thinking about them, as two separate signals suggests a straight-forward time domain analysis for phase detection using direct analog to digital conversion and some mathematical magic. But what if you choose to think about them as the product of a sine-wave generator driving a variable impedance load? One representing voltage and the other current at the load. If you think about them in that context, the thought of considering power as it relates to magnitude and phase offset might lead to an interesting approach. As long as you don't have to deal with instantaneous phase offset that 1 MHz Fs isn't looking so inadequate. Can the XADC and some analog manipulation get you phase detection to within +/- 1 degree? I doubt it, but I doubt that the brute-force approach and a pair of 100 MHz "14-bit" ADCs will either. But you can come up with a rough estimation of what it would take. Instead of expecting to hit the target on the first cut I'd suggest starting out with lower objectives and seeing how different approaches go. This is why, when doing experiments because you want to learn, the journey really can be more valuable that finding answers. Usually, along the way you find more questions to answer. Sometimes, these are more interesting than the original problem. Almost certainly the result of constructing experiments to solve problems makes your conceptualization of what's going on in the hardware less naive.

That's just one thought. I'm sure that you can come up with others. 

There's always a brute-force approach to solving puzzles but sometimes the way that you think about them can lead to an elegant solution using low cost hardware. The point is that the obvious way to approach problems can involve considerable hardware complexity and cost but often there are ways to get around the expensive requirements and still get good enough results to meet your requirements. That's the joy and beauty of embedded design; doing in logic or with limited computational power what a computer does with MATLAB or expensive custom libraries.

I don't want to discourage you from taking the ADC route as there is a lot to learn about converters and fixed point math using logic. But, we all have budgets to consider. I'm assuming that 5-10 MHz is a fungible criteria. You can almost always scale down the initial specifications to fit a low hardware budget and still come up with an implementation to prove a solution concept. Two audio frequency sine waves would certainly require cheaper hardware. 

If you want to try building you own add-on circuitry to convert analog measurements to digital data the De0 Nano and Express PCB are easy to use to do almost anything. The De0 Nano has two 40-pin headers for expansion and while not the cheapest way to do you own PCB designs Express PCB, once you get used to its peculiarities, is pretty painless. It just doesn't work well for really high speed connectors and really small parts. You can get some decent ADCs from distributors that work in the 5-10 MHZ range, or perhaps used components to take an alternate route.

 

 

Edited by zygot
Link to comment
Share on other sites

  • 0
19 hours ago, zygot said:

I love hearing about projects done for personal edification. The best engineers like doing engineering because they are curious and love the challenge.

I don't know of any add-on boards for doing what you want to do using analog circuitry.  But perhaps I could give you an idea or two to ponder without spoiling the adventure. Perhaps there are multiple paths to explore.

Let's say that you have two 5 MHz sine signals with a fixed phase offset between them. Thinking about them, as two separate signals suggests a straight-forward time domain analysis for phase detection using direct analog to digital conversion and some mathematical magic. But what if you choose to think about them as the product of a sine-wave generator driving a variable impedance load? One representing voltage and the other current at the load. If you think about them in that context, the thought of considering power as it relates to magnitude and phase offset might lead to an interesting approach. As long as you don't have to deal with instantaneous phase offset that 1 MHz Fs isn't looking so inadequate. Can the XADC and some analog manipulation get you phase detection to within +/- 1 degree? I doubt it, but I doubt that the brute-force approach and a pair of 100 MHz "14-bit" ADCs will either. But you can come up with a rough estimation of what it would take. Instead of expecting to hit the target on the first cut I'd suggest starting out with lower objectives and seeing how different approaches go. This is why, when doing experiments because you want to learn, the journey really can be more valuable that finding answers. Usually, along the way you find more questions to answer. Sometimes, these are more interesting than the original problem. Almost certainly the result of constructing experiments to solve problems makes your conceptualization of what's going on in the hardware less naive.

That's just one thought. I'm sure that you can come up with others. 

There's always a brute-force approach to solving puzzles but sometimes the way that you think about them can lead to an elegant solution using low cost hardware. The point is that the obvious way to approach problems can involve considerable hardware complexity and cost but often there are ways to get around the expensive requirements and still get good enough results to meet your requirements. That's the joy and beauty of embedded design; doing in logic or with limited computational power what a computer does with MATLAB or expensive custom libraries.

I don't want to discourage you from taking the ADC route as there is a lot to learn about converters and fixed point math using logic. But, we all have budgets to consider. I'm assuming that 5-10 MHz is a fungible criteria. You can almost always scale down the initial specifications to fit a low hardware budget and still come up with an implementation to prove a solution concept. Two audio frequency sine waves would certainly require cheaper hardware. 

If you want to try building you own add-on circuitry to convert analog measurements to digital data the De0 Nano and Express PCB are easy to use to do almost anything. The De0 Nano has two 40-pin headers for expansion and while not the cheapest way to do you own PCB designs Express PCB, once you get used to its peculiarities, is pretty painless. It just doesn't work well for really high speed connectors and really small parts. You can get some decent ADCs from distributors that work in the 5-10 MHZ range, or perhaps used components to take an alternate route.

 

 

Thank you for the thoughtful reply @zygot! _/\_ 

I'm really impressed with the idea of Tayloe detector for IQ demodulation when I learned it first. Your suggestion in a similar line of thought appears equally impressive.  Thanks for the recommendation and for the push to keep looking for simpler answers! 

Yes, I will first try a small scale experiment with the Zybo I have - to get an idea on the resources required. I'll keep looking up for answers! Thank you so much!  

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...