EEVblog Electronics Community Forum

Products => Test Equipment => Topic started by: metebalci on February 27, 2021, 03:04:07 pm

Title: measuring freq response
Post by: metebalci on February 27, 2021, 03:04:07 pm
Is a two port VNA only option to measure freq response easily/automatically, eg drawing bode mag and phase plots, beyond 25Mhz or so ?
Title: Re: measuring freq response
Post by: Kleinstein on February 27, 2021, 03:42:58 pm
If one only need the magnitude and not the phase, a white noise source and spectrum analyser is an alternative method.

In the low frequency range, many lockin amplifiers can work as a VNA, with a little computer help to sweep the frequencies.

With not too high requirements a VNA can be get relatively cheap by now (e.g. as the nanovna and related). 
Title: Re: measuring freq response
Post by: metebalci on February 27, 2021, 03:58:19 pm

I like the idea of white noise + SA but I am looking for phase response as well.

I am wondering how it can be done up to lets say 1Ghz. The only options I could think of was using a signal generator which is also expensive for 1Ghz and an oscilloscope and automate the measurement, or use a VNA -which I havent used before but as far as I understand it is the only thing that I can use for this purpose-.

(I didnt know about lockin amplifiers, thanks for mentioning that)
Title: Re: measuring freq response
Post by: 2N3055 on February 27, 2021, 06:19:46 pm
Siglent scope/AWG pair can go up to 120MHz with their FRA, Omicron labs FRA can go to to 50 MHz.... There probably are some others that go over 25 Mhz, but not much.
Once you go over 25MHz things are getting tricky and it really has to be instrument that can properly calibrated,  de-embedded (meaning that measurement plane, point where measurenet is being performed,  is moved from instrument connectors to the end of cables where it is connected to DUT), so you get proper results.
Like Kleinstein said, you can buy nanoVNA very inexpensively, for more money you can get  DG8SAQ VNWA  and on and on..
But to simply answer your question, yes for what you asked for, you need some sort of VNA.
Title: Re: measuring freq response
Post by: metebalci on February 27, 2021, 07:17:45 pm
Thanks for the clarification about de-embedding. I actually come to this point while looking at/working on high speed opamps. So for example for LMH6702, the below figure is given. This is measured/can be measured only with a VNA-like device then.
Title: Re: measuring freq response
Post by: radiolistener on February 28, 2021, 10:01:43 pm
NWT allows to measure magnitude response within specified frequency range.
Title: Re: measuring freq response
Post by: nctnico on February 28, 2021, 10:07:53 pm
Thanks for the clarification about de-embedding. I actually come to this point while looking at/working on high speed opamps. So for example for LMH6702, the below figure is given. This is measured/can be measured only with a VNA-like device then.
The NanoVNA is a good option. Alternatively you can use an RF generator and spectrum analyser. You can let the RF generator step through frequencies to make a sweep and set the spectrum analyser to max hold. This is a slow process though; buying the NanoVNA to get started is a no-brainer. Even if it turns out you need better equipment the NanoVNA is cheap enough & a good tool to have around.
Title: Re: measuring freq response
Post by: 2N3055 on February 28, 2021, 11:08:04 pm
Thanks for the clarification about de-embedding. I actually come to this point while looking at/working on high speed opamps. So for example for LMH6702, the below figure is given. This is measured/can be measured only with a VNA-like device then.
The NanoVNA is a good option. Alternatively you can use an RF generator and spectrum analyser. You can let the RF generator step through frequencies to make a sweep and set the spectrum analyser to max hold. This is a slow process though; buying the NanoVNA to get started is a no-brainer. Even if it turns out you need better equipment the NanoVNA is cheap enough & a good tool to have around.

Scalar analysis is not good enough for him. He wants gain and phase to some quite high frequencies. So NanoVNA is cheapest that will do the job.
Title: Re: measuring freq response
Post by: metebalci on March 01, 2021, 01:28:49 am
Thanks, I think I will try NanoVNA, at least just to see.

I have the feeling that phase measurements are not used much beyond maybe a few Mhz (and then in RF, there are s parameters), is that really the case ? I studied EE (but have zero professional experience in analog circuit design after school) and as far as I remember phase response was always at hand both in theory, on paper and in simulations. I see it is mentioned rarely in the opamp datasheets I am looking (maybe just a coincidence). Is it because phase is more or less implied from the magnitude plot and/or it is implicitly told in explanations (for stability etc.) in the text ?

One reason of my curiosity about this is I find it strange that theoretically basic methods like mag/phase plots and differential measurements are so expensive to do after some Mhz.
Title: Re: measuring freq response
Post by: Kleinstein on March 01, 2021, 09:39:35 am
Traditionally phase measurements were expensive. However with modern instruments, there is not much sense in building a scalar network analyzer. The vector form is no longer significant more complicated and in many semi digital implementations it naturally comes out with the phase. There is not much gained by ignoring the phase data that are already there.

In theory the phase does not give much more information, as phase and amplitude part are linked. However practically it adds quite some uncertainty and noise using only one half, especially at the band ends. So measuring the phase is important, about as much as the amplitude. In some sense the phase can already see effects that would show up in the amplitude only 1 or 2 octaves higher.
For some the phase and amplitude as complex data can be confusing, but in some sense it even makes the math simpler.
Title: Re: measuring freq response
Post by: Berni on March 01, 2021, 10:56:51 am
Yep a NanoVNA is the cheapest way to do it.

Yes magnitude tends to be more interesting most of the time. When doing GHz level RF things a piece of cable becomes a phase shifter itself due to the amount of delay it introduces. This is also most of the reason why an open short load calibration is performed on VNAs before using them. A short piece of cable doesn't really affect the magnitude that much but it does affect the phase a lot.

So why go trough the trouble of calibration to get good phase numbers when magnitude is more interesting anyway? Well most of the extra math and processing that one would do on the results does require phase information. One of the most common of those being a smith chart. With correct phase you can see the exact resistance and reactance (often converted into farads or henries right on the screen so it becomes sort of a RF LCR meter) on the chart that is present at the port of your DUT, this would for example let you calculate a matching network for your DUT. If you want to import the DUT into a simulation you also need the phase. If you want to plot a TDR plot from it you also need phase.

Tho you might still be interested in the raw phase data if the DUT has something to do with phase, such as a adjustable phase shifter device.
Title: Re: measuring freq response
Post by: tggzzz on March 01, 2021, 11:09:26 am
If one only need the magnitude and not the phase, a white noise source and spectrum analyser is an alternative method.

Non-linearities will create intermodulation products, which complicates matters.
Title: Re: measuring freq response
Post by: metebalci on March 01, 2021, 03:43:02 pm
Thanks for all the info again, quite helpful.

Meanwhile I was looking at some SA/VNA products, how they work etc. (signalpath videos and some others). As far as I understand:

- Siglent SVA (two port VNA) has only one receiver/ADC and the input to actual RF input circuitry (which is normally a SA) actually switches internally between TG/RF output and RF input. Then I guess it calculates phase like how an oscilloscope calculates it. I assume their other products with VNA capability and also products of RIGOL with VNA capability has similar architecture, I am saying it because of their price.

- RS FPC1500 (one port VNA, one port scalar NA) on the other hand, has 2 receivers/ADC (but the one in input has 2 channels, so actually I should say 3 receivers I think), so I guess it simultaneously samples output, reflection and transmission, however, for some reason, it can only do scalar transmission measurement, I didnt understand if this is a hardware limitation or just a software limit/marketing decision.

- nanoVNA has one/3 channel ADC, so it is similar to FPC1500 (just for the sake of this comparison), but it can do vector reflection and transmission measurements in one direction/path.

- A proper VNA, RS ZNL etc., has 4 receivers, so it can measure reflection and transmission at both ports/in both directions simultaneously.

- maybe I should also mention there is Omicron Bode 100, which is I think -I didnt check all details- a VNA measuring only transmission in one path, to measure bode mag and phase plots, but only up to 50 Mhz.

I dont know if it is only me, but I wish there is a commercial not so high bandwidth (lets say 500M-1G) proper VNA product, something similar to DG8SAQ's VNWA that can be used standalone in a bench (not PC based). Everything in the market seems to start from 3Ghz and 10K$, Bode 100 is also 5K$.
Title: Re: measuring freq response
Post by: Berni on March 01, 2021, 07:02:55 pm
Yeah VNAs have always been rather expensive pieces of gear much like a lot of other fancy RF test equipment. But with VNAs the whole thing got worse because the used test equipment market loves the things, so the prices for even 30 year old dinosaurs are still really high. It's probably because these old things are still almost as capable as the modern stuff, and it is a very useful piece of gear for anyone that does a lot of RF work.

This is what makes the NanoVNA such an amazing thing. It's even more standalone than a real boatnahcor VNA since it can easily be battery powered by a single Li-Po cell while also being MUCH lighter to carry around. The latest V2 plus version of it covers 50kHz to 4.4GHz, so it covers all the common frequency the big boys do (and should also cover the needs of most users, its rare a home DIYer might need to go above 3GHz). All this while being really cheap. Okay it might not quite have the frequency stability and performance at very narrow sweeps and the dynamic range is not as good. But for like 90% of the stuff you would use a VNA for, it is perfectly good enugh. It might look like a toy on the outside, but is actually an incredibly capable piece of test gear.

But i will admit there is a certain level of appeal and satisfaction when you start up a big boatanchor of a piece of RF gear, the hefty fans starting up, the heavy chunky feel as you hook up your DUT to those large N or APC connectors. But so far you need pretty deep pockets to get one of your own. Hopefuly if the NanoVNA and similar get popular enugh the used market will slowly loose interest in these things and the prices can come down to something a home gamer might aford.
Title: Re: measuring freq response
Post by: Kleinstein on March 01, 2021, 07:11:45 pm
While the NonoVNA is cheap, one may still need some accessories, like extra cables, connectors and adapters, maybe a torque - wrench. The SMA cables are said to have a relatively limited lifetime, but they are still relatively cheap, though the prices can still add up.
Title: Re: measuring freq response
Post by: tautech on March 01, 2021, 08:17:12 pm
Thanks for the clarification about de-embedding. I actually come to this point while looking at/working on high speed opamps. So for example for LMH6702, the below figure is given. This is measured/can be measured only with a VNA-like device then.
(https://www.eevblog.com/forum/testgear/measuring-freq-response/?action=dlattach;attach=1183166)
To the -3dB point limit is possible with say SDS2104X Plus and a SDG2122X or SDG6022X using the scopes FRA/Bode plot feature returning amplitude and Phase results. SDS2104X Plus has an inbuilt 50 MHz AWG also.

wrt VNA's their low frequency floor can sometimes limit their capability for LF work whereas using a scope with FRA/Bode plot allows for LF FRA work.
Title: Re: measuring freq response
Post by: metebalci on March 01, 2021, 09:13:13 pm
@tautech, thanks, I guess one option can always be to control the signal generator and the scope and automate the measurement (even if there is no bode plot function, assuming scope can report the phase between two channels, I think it can be automated easily), but I guess it takes more time to complete a single measurement.

Is there a difference measuring this with a scope+signal generator vs. SA/TG/VNA in terms of the quality of the results ?
Title: Re: measuring freq response
Post by: tautech on March 01, 2021, 09:24:58 pm
With both methods in Siglents you can select the # of frequency steps for the sweep/span although a SA/VNA will always be much faster IME as the stimulus source is built into the instrument.
Amplitude accuracy of course is listed in datasheets.  ;)
Title: Re: measuring freq response
Post by: metebalci on March 01, 2021, 10:15:03 pm
@tautech, a question. In SVA datasheet, the dynamic range for SVA1015X is 80dB, but for SVA1032X it is 60dB. Is this correct or is it a typo ?
Title: Re: measuring freq response
Post by: tautech on March 01, 2021, 10:34:08 pm
https://siglentna.com/wp-content/uploads/dlm_uploads/2020/12/SVA1000X_DataSheet_DS0701X_E04B.pdf
P4
VNA mode dynamic range = 90 dB for all models.


P15: Calibration
                           SVA1015X      SVA1032X    SVA1075X
100 kHz ~ 10 MHz                        70 dB (typ.) 60 dB (typ.)
10 MHz ~ 1.5 GHz 80 dB (typ.)      80 dB (typ.) 90 dB (typ.)
1.5 GHz ~ 3.2 GHz                        80 dB (typ.) 90 dB (typ.)
3.2 GHz ~ 7.5 GHz                        80 dB (typ.)
Title: Re: measuring freq response
Post by: metebalci on March 01, 2021, 10:37:14 pm
I meant the calibration section but OK that is also fixed. Thanks.
Title: Re: measuring freq response
Post by: Berni on March 02, 2021, 06:44:56 am
@tautech, thanks, I guess one option can always be to control the signal generator and the scope and automate the measurement (even if there is no bode plot function, assuming scope can report the phase between two channels, I think it can be automated easily), but I guess it takes more time to complete a single measurement.

Is there a difference measuring this with a scope+signal generator vs. SA/TG/VNA in terms of the quality of the results ?

Well for one signal generators and scopes that do >1GHz are rather expensive bits of kit.

Sometimes it does make sense to go that route when you don't have a VNA for the job. I have a ancient 20GHz spectrum analyzer and RF synthesizer that i can hook together measure the magnitude response of something to 20 Gigs. An actual 20 GHz VNA would be like... holy shit expensive. Another example is when i need to look at the frequency response at low frequency, for that i used a MSOX3000 scope with its built in wavegen function. Set up the wavegen to do a sine FM sweep from say 1Khz to 10KHz in 200ms, set the scope to trigger from wavegen sweep start, set the timebase so that 200ms covers the whole screen, turn on peak detect, and wola. You have your scope showing magnitude versus frequency on the screen, all fast live updating as you poke your scope probe around.

But none of these methods actually measure phase, so its actually doing the job of a scalar network analyzer. Getting it to do phase is much more difficult. Firstly you need to use 2 channels on your scope, one looking at the stimulus signal other at the DUT output. Then you need to run the resulting waveform capture trough some math to extract the phase information and this usually means you need to use SCPI to pull raw data off it and have a python script or similar crunch the numbers, a few rare scopes out there can actually show a phase graph from a phase automesurement function. And even when you have that your phase reference is sitting at the scope terminals, so any phase you measure also includes the phase shift of cables used to hook all this up. At low frequency it doesn't matter but at GHz ranges the cable might add like +600° to your phase. So yeah... much much easier to just use an actual VNA.

While the NonoVNA is cheap, one may still need some accessories, like extra cables, connectors and adapters, maybe a torque - wrench. The SMA cables are said to have a relatively limited lifetime, but they are still relatively cheap, though the prices can still add up.

Well for a NanoVNA just buy some cheep chinese SMA to SMA adapters and keep those on the ports. The SMA connectors on the device itself are unlikely to be fancy high quality name brand SMAs anyway, so just wack on the cheep chinese adapters and don't worry about it. For being within a dB its fine.

Good VNA connectors and cables can indeed cost an arm and a leg, but only if you actually need the precision from them. We have an old HP boatnahcor HP VNA at work that constantly has a pair of SMA adapters sitting on it. The compact small flexible SMA cables are convenient to use, the adapters seen many many cycles over the years and they are still fine. And if they do get messed up we can just put brand new SMA adapters on it.
Title: Re: measuring freq response
Post by: metebalci on March 02, 2021, 01:08:33 pm
At low frequency it doesn't matter but at GHz ranges the cable might add like +600° to your phase. So yeah... much much easier to just use an actual VNA.

Yes, I was exactly thinking to use SCPI but you are obviously right that would also include the effects of the cables etc. Just to use the vocabulary, I think I can say, in order to "de-embed" the external effects, a VNA is a must.

Well for a NanoVNA just buy some cheep chinese SMA to SMA adapters and keep those on the ports. The SMA connectors on the device itself are unlikely to be fancy high quality name brand SMAs anyway, so just wack on the cheep chinese adapters and don't worry about it. For being within a dB its fine.

Good VNA connectors and cables can indeed cost an arm and a leg, but only if you actually need the precision from them. We have an old HP boatnahcor HP VNA at work that constantly has a pair of SMA adapters sitting on it. The compact small flexible SMA cables are convenient to use, the adapters seen many many cycles over the years and they are still fine. And if they do get messed up we can just put brand new SMA adapters on it.

Like you said, I think the calibration kits are from 10$ to 10K+$, is there a way to reasonably guess if one calibration kit would be good enough for a particular VNA ? I think almost all manufacturers are also selling their calibration kits, is it always the way to go, to get it from the manufacturer of the VNA ?

About the calibration kits, so the point is for them to have a precise spec, meaning RLC values, the distance if I say correct from the connector to the actual short/open etc., is that correct ? So skipping the very cheap ones, why is one calibration kit (much) better and (much) expensive than others if they are all individually measured ?
Title: Re: measuring freq response
Post by: nctnico on March 02, 2021, 02:55:44 pm
Usually the price goes up exponentially with the frequency. You can buy 1 meter SMA cables good for use up to 800/900 MHz for $5. A 1meter SMA cable good to about 3GHz costs around $35. Go up a few GHz more and the price goes up a few multiples again.

Still for a VNA that goes up to a GHz or so a cheap cal kit will do just fine. I have compared the 50 Ohm terminator that comes with the NanoVNA as load calibrator against some other (more expensive) SMA 50 Ohm terminators and it is fit for the purpose; the readings are the same (within the error tolerance).
Title: Re: measuring freq response
Post by: Berni on March 02, 2021, 04:52:10 pm
You can even make your own open short load calibration kits that are good enough.

I had a go at one that was popular online where you take some SMA connectors and turn them into diy cal standards. For the open you cut and grind away all of the pins on a SMA connector, for a short you turn the entire underside of the connector into a solid blob of solder(pro tip, you can wrap it in kapton tape to keep the solder neatly inside while filling it) and for the load you just take a 50 Ohm terminator or buy a few precision SMD resistors and solder them all in parallel in a star pattern onto the underside of the SMA connector, this divides down there inductance. I went to compare these cal standards to the actual proper ones on a proper HP VNA and they looked plenty good enough up to the 3GHz it goes to. So again unless you really need to work down in the 1/10ths of a dB you don't need the proper expensive call standards. The most important one is the load calibration standard, since that gives it the 50 Ohm that the VNA compares everything else to.

For cables, i wouldn't really worry up to 3GHz, as long as you use short <15cm long cables even cheap cables perform fine. Cheep Chinese SMA connectors on those cables also work fine enough. Using longer cables of >1m you do get a lot less loss at high freqencies. And yes once you go to 10GHz and above cables start costing 200$ and up for the cheep ones, SMA connectors turn into fancy 2.5mm RF connectors that need to be treated gently with the utmost care to preserve their performance. But if you can afford a 10GHz VNA then you can also afford a 10GHz cable.

All this RF stuff is made to look a lot scarrier than it actually is. You can play with low GHz figures on the cheep perfectly fine these days. PCB design for GHz RF is also not as hard as it sounds, just keep traces short and follow matched impedance rules to connect off the shelf RF building blocks in the form of ICs. The DIY stuff is usually not going after chasing top performance, so its a lot easier and you don't need the best RF test gear out there. Tho personally i don't quite have as much interest in RF, i like to toy around with it a bit because it looks like this whole new world of black magic, but i don't really build any major projects with it. If i need wireless communication il just buy a RF module and stick it on, perhaps runiing over to a VNA to tune an antenna for it and that's it.
Title: Re: measuring freq response
Post by: 2N3055 on March 02, 2021, 05:33:09 pm
More on the topic:

https://www.mariohellmich.de/projects/trl-cal/trl-cal.html (https://www.mariohellmich.de/projects/trl-cal/trl-cal.html)

affordable but quite good stuff, and some reading...

https://www.sdr-kits.net/calibration-information-for-DG8SAQ-VNWA-3-3EC (https://www.sdr-kits.net/calibration-information-for-DG8SAQ-VNWA-3-3EC)

and down the rabbit hole....

https://www.euramet.org/Media/news/I-CAL-GUI-012_Calibration_Guide_No._12.web.pdf (https://www.euramet.org/Media/news/I-CAL-GUI-012_Calibration_Guide_No._12.web.pdf)
Title: Re: measuring freq response
Post by: metebalci on March 02, 2021, 06:19:49 pm

Before I forget, I would like to thank you all for all the information you share, I learned a lot.

Meanwhile, I got a nanoVNA. I am still waiting for a few cables and adapters so I couldnt test much things yet, but I am already impressed with what I saw.

I mainly understand the point or difference about calibration kits. If I also understand correct, more expensive ones gives their LC characteristics in a polynomial model/fit (c0, c1, c2..) and their delay, loss etc. values. I saw a relatively cheap one (I think it was Rigol), it was saying all these values as 0, so I think this means it is an ideal thing, but naturally it is not, so that will cause some errors, and that is the difference. So I guess high quality calibration kit means to be close to ideal or maybe more correctly to be more close to its individually measured model, so the VNA can remove most of the error.

I am interested in stuff up to ~1 Ghz at the moment, so much easier and cheaper regarding to calibration, connectors and cables I guess.

Good you mentioned about PCB design. The actual reason I started questioning about these is I am working on some simple (opamp based at the moment) stuff but I would like to go as high frequency as possible (up to Ghz). Just by prototyping, manhattan style etc., what is the reasonable freq. I can go ? For example, with a high bw opamp (1Ghz+) in a voltage follower configuration, what freq. I can reach in a prototype ?

There is something else I wonder. Most of the simple VNAs or SAs with VNA features, can do s11 and s21 measurements, hence, if I am correct, they are called one path VNAs. The "big" VNAs are I think always two path, so they also measure s22 and s12. I understand this eliminates the need to reverse the DUT for measurements, but is there another benefit of this ?

Another question. I guess a differential amp has three ports, not two. So it cannot be measured with a two port VNA. Is there an approx. way or a workaround to accomplish this with two ports ?
Title: Re: measuring freq response
Post by: nctnico on March 02, 2021, 06:25:16 pm
I'd create a PCB for anything over 100MHz. But before that I'd simulate the circuit first. It may take a few iterations to get an HF circuit right. For testing a differential amplifier you can either use a balun to convert single ended to differential or connect one leg of the amplifier to ground.
Title: Re: measuring freq response
Post by: Berni on March 03, 2021, 06:51:18 am
Yep proper VNA cal standards are individually measured at the factory for the true response to allow you to correct its imperfections. But unless you are chasing every last fraction of a dB it doesn't matter.

You can go into the 100s of MHz using dead bug prototyping if you carefully lay out your wires, keep them tiny and short and use a copper clad board as a ground plane right under it. Tho you would probably want to do that under a microscope since the wires need to be tiny and short and the ICs that work at those speeds also tend to be tiny to minimize parasitics. But yeah with RF don't expect to get it right on the first try, things often need a bit of tweaking to work well.

The difference between such a single path and true dual path VNA is simply that the dual path one has an extra RF coupler on the other port and a relay to switch the couplers of the ports around. All it does is save you from having to unplug your DUT and plug it in backwards to get the reverse measurement. It's mostly a convenience thing (and helps a bit with accuracy since you don't mess with your setup mid measurement) but then again you often don't need the reverse measurement anyway. Heck sometimes you don't even need the 2nd channel at all. If you are tuning an antenna then you just use the 1st channel to look at reflections, when no power is reflecting back into the port then the antenna is perfectly tuned.

There are also 4 port VNAs that can measure more complex devices, but you probably won't ever need one. As nctnico said you can get a balun to turn the single ended port of your VNA into a set of differential ports. Do the open/short/load calibration on the other side of the balun and the VNA will de-embed it for you. Tho doing the thru calibration is a bit sticky since the diff signal can't be fed back into the VNA, but you could terminate the negative output and just feed the positive output in to get a rough cal.

Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 09:16:54 am
More on the topic:

https://www.mariohellmich.de/projects/trl-cal/trl-cal.html (https://www.mariohellmich.de/projects/trl-cal/trl-cal.html)

affordable but quite good stuff, and some reading...

https://www.sdr-kits.net/calibration-information-for-DG8SAQ-VNWA-3-3EC (https://www.sdr-kits.net/calibration-information-for-DG8SAQ-VNWA-3-3EC)

and down the rabbit hole....

https://www.euramet.org/Media/news/I-CAL-GUI-012_Calibration_Guide_No._12.web.pdf (https://www.euramet.org/Media/news/I-CAL-GUI-012_Calibration_Guide_No._12.web.pdf)

Thanks for the links, nice document@euramet.
Title: Re: measuring freq response
Post by: gf on March 03, 2021, 03:02:37 pm
Do the open/short/load calibration on the other side of the balun and the VNA will de-embed it for you.

... if the calibration standards (having e.g. male or female SMA connectors) are directly insertable on the balanced side of the balun, and the DUT is directly insertable at the balanced side of the balun as well. Then we had a well-defined calibration plane at the balanced side of the balun. But this would require that the DUT has a single SMA connector (with the same gender as the calibration standards) for a differential signal, which is IMO unusual. My feeling is that thing are pretty straightforward when the DUT is directly insertable at the calibration planes established with the standards, but complications arise when insertablitiy is not granted, so that additionally required adapters/fixtures cannot be implicitly de-embedded by the calibration, but must be de-embedded explicitly then.
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 09:24:23 pm
So here is my first try and some questions. I am trying to measure s21 of wideband (2.4Ghz) opamp (THS4302) on its own eval board between 1Mhz and 2Ghz. I am not particularly interested in THS4302, just using it as an example.

First some questions regarding to nanoVNA (particularly V2.2). It comes with M SOL and a F-F T for calibration. For calibration, I set the stimulus, connected two SMA cables that comes with it to Port 1 and 2. The problem is because SOL are all M, I used F-F T first and then used SOL for calibration on Port 1, and then connected the other cable which is connected to Port 2, and calibrated for T. Because DUT has F SMA connectors, I removed F-F T. I guess there is no other way (?) to do this properly until I get an F SOL kit. So I am damaging the calibration (not sure to what extent?) and I think I can use electrical delay option but not sure how to do properly yet, so the issues below can be related to that maybe, at least partially. I also know/learned that I am not measuring the opamp directly like this, since there is no calibration options on the board, so also not sure how this affects the results.

I didnt realize before (but I didnt check many wideband opamps, maybe that is common in this category), the datasheet of THS4302 is pretty nice, it even has all measured s parameters. You can look at the datasheet (https://www.ti.com/lit/ds/symlink/ths4302.pdf (https://www.ti.com/lit/ds/symlink/ths4302.pdf)) but quick summary and questions:

- the opamp has 14dB fixed gain, but I see ~9dB. what could be the reason ?
- the overall shape of logmag curve is I think not too bad, the opamp has 2.4G bandwidth and it looks like it is still within 2dB at 2Ghz.
- I dont get the phase curve, naturally it should not go down to -180, on the datasheet the arg s21 goes under -100 after 1.5Ghz. what could be the reason for this ?
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 09:27:48 pm
I'd create a PCB for anything over 100MHz. But before that I'd simulate the circuit first. It may take a few iterations to get an HF circuit right. For testing a differential amplifier you can either use a balun to convert single ended to differential or connect one leg of the amplifier to ground.

OK, so if I reach 100Mhz or so properly, I will be happy and if I cannot improve that I will move to PCB.
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 09:43:13 pm
The difference between such a single path and true dual path VNA is simply that the dual path one has an extra RF coupler on the other port and a relay to switch the couplers of the ports around. All it does is save you from having to unplug your DUT and plug it in backwards to get the reverse measurement. It's mostly a convenience thing (and helps a bit with accuracy since you don't mess with your setup mid measurement) but then again you often don't need the reverse measurement anyway. Heck sometimes you don't even need the 2nd channel at all. If you are tuning an antenna then you just use the 1st channel to look at reflections, when no power is reflecting back into the port then the antenna is perfectly tuned.

There are also 4 port VNAs that can measure more complex devices, but you probably won't ever need one. As nctnico said you can get a balun to turn the single ended port of your VNA into a set of differential ports. Do the open/short/load calibration on the other side of the balun and the VNA will de-embed it for you. Tho doing the thru calibration is a bit sticky since the diff signal can't be fed back into the VNA, but you could terminate the negative output and just feed the positive output in to get a rough cal.

I wish I could live only with s11, I arrived this point mostly because s21.

I did a first pass reading on some technical documents, but I am confused on something. So to measure s11 and s21, it is assumed a2=0, which means it is perfectly terminated. I think I understand then the dual operation is done in reverse path for s22 and s12 and then it is superposition to get s matrix. But I am only measuring forward path s11 and s21 and a2 is I guess not 0 (so b2 should be reflecting back from VNA?), and I guess a2 is not measured by one path devices (nanoVNA, Siglent SVA etc.). Is this somehow not important or eliminated by something or what am I missing ?

I understand roughly the model behind single port calibration with SOL, but didnt read much yet to understand how T is then used to calibrate s21 measurement. Maybe that is why I am confused for the topic above.

Thanks both for explaining the balun workaround.
Title: Re: measuring freq response
Post by: ogden on March 03, 2021, 10:09:47 pm
- the opamp has 14dB fixed gain, but I see ~9dB. what could be the reason ?
Could be overload of VNA input that could be solved with 20dB attenuator after amp?
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 10:14:59 pm
Do the open/short/load calibration on the other side of the balun and the VNA will de-embed it for you.

... if the calibration standards (having e.g. male or female SMA connectors) are directly insertable on the balanced side of the balun, and the DUT is directly insertable at the balanced side of the balun as well. Then we had a well-defined calibration plane at the balanced side of the balun. But this would require that the DUT has a single SMA connector (with the same gender as the calibration standards) for a differential signal, which is IMO unusual. My feeling is that thing are pretty straightforward when the DUT is directly insertable at the calibration planes established with the standards, but complications arise when insertablitiy is not granted, so that additionally required adapters/fixtures cannot be implicitly de-embedded by the calibration, but must be de-embedded explicitly then.

For this reason, I was planning to use M on one side, and F on the other side for the boards I was planning to prototype (both single ended not differential).
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 10:16:40 pm
First some questions regarding to nanoVNA (particularly V2.2). It comes with M SOL and a F-F T for calibration. For calibration, I set the stimulus, connected two SMA cables that comes with it to Port 1 and 2. The problem is because SOL are all M, I used F-F T first and then used SOL for calibration on Port 1, and then connected the other cable which is connected to Port 2, and calibrated for T. Because DUT has F SMA connectors, I removed F-F T. I guess there is no other way (?) to do this properly until I get an F SOL kit. So I am damaging the calibration (not sure to what extent?) and I think I can use electrical delay option but not sure how to do properly yet, so the issues below can be related to that maybe, at least partially. I also know/learned that I am not measuring the opamp directly like this, since there is no calibration options on the board, so also not sure how this affects the results.

I just tried better cables (DC-4Ghz) and better T (DC-18Ghz), the 180 deg shift point moved like 100Mhz to right but everything looks same.
Title: Re: measuring freq response
Post by: tautech on March 03, 2021, 10:17:52 pm
- the opamp has 14dB fixed gain, but I see ~9dB. what could be the reason ?
Could be overload of VNA input that could be solved with 20dB attenuator after amp?
Nah, scaling is wrong...2dB/div and a 9.75dB measurement  :wtf: and no mention of the stimulus setting.  :-//
Setup needs more attention I suspect.
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 10:31:43 pm
- the opamp has 14dB fixed gain, but I see ~9dB. what could be the reason ?
Could be overload of VNA input that could be solved with 20dB attenuator after amp?
Nah, scaling is wrong...2dB/div and a 9.75dB measurement  :wtf: and no mention of the stimulus setting.  :-//
Setup needs more attention I suspect.

I also thought it could be overload but I couldnt find the input output specs yet, I dont have an attenuator to try at the moment unfortunately. I found ADF4350 tw power setting, and decreased it (set=0, I think it means -4dBm then). The result is attached. I see it starts from 14dB now, but it falls rapidly. The phase response did not change.
Title: Re: measuring freq response
Post by: Kleinstein on March 03, 2021, 10:36:26 pm
The 14 dB gain from the THS4302 datasheet should be without thermination at the output. The 100 Ohms shown as load in the circuit should be 50 Ohms series termination (that should be in the real circuit) and 50 Ohms load / cable impedance. This would give about 6 db loss.

For cal set being all female: the reference plane for the 1 st port (excitation) is the male cable end. The reference plane for the input side would be the female side, either directly at the instrument, or with female-female adapter and cable.
Title: Re: measuring freq response
Post by: tautech on March 03, 2021, 10:41:46 pm
I see it starts from 14dB now, but it falls rapidly. The phase response did not change.
Take a step back from the instrument to fully comprehend what you see...most of it is staring right at you.
Your sweep is for 1 -2 GHz and the trace Ref levels are at 0 dB with a 2dB/div setting. Plonk a few markers down at various frequencies to get the full picture.

Of course the phase response hasn't changed as it's the performance result of the DUT.
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 10:44:00 pm
The 14 dB gain from the THS4302 datasheet should be without thermination at the output. The 100 Ohms shown as load in the circuit should be 50 Ohms series termination (that should be in the real circuit) and 50 Ohms load / cable impedance. This would give about 6 db loss.

For cal set being all female: the reference plane for the 1 st port (excitation) is the male cable end. The reference plane for the input side would be the female side, either directly at the instrument, or with female-female adapter and cable.

There is an S-Parameter table on the datasheet (p6, I am running it also at Vs=5V), measured on the same board, it says S21 is ~14dB up to 1Ghz, then slowly decreases to ~12dB at 2 Ghz.

Not sure if I understand the cal part. Maybe I said it wrong, the cal set is male, that is why I need to use f-f thru to be able to use them at the end of cable (male) connected to Port 1. Then I remove f-f, and connect both cables to DUT (has female connectors like VNA).
Title: Re: measuring freq response
Post by: ogden on March 03, 2021, 10:45:31 pm
14dB is quite a gain. Even using pro VNA's you have to know what you are doing when measure active circuits. I am not sure those toy VNA's are up-to task in this case. Just my two cents.
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 10:49:10 pm
I see it starts from 14dB now, but it falls rapidly. The phase response did not change.
Take a step back from the instrument to fully comprehend what you see...most of it is staring right at you.
Your sweep is for 1 -2 GHz and the trace Ref levels are at 0 dB with a 2dB/div setting. Plonk a few markers down at various frequencies to get the full picture.

Of course the phase response hasn't changed as it's the performance result of the DUT.

Not sure I understand what you mean. The sweep is from 1MHz (not G) to 1GHz.  I dont think I need more markers, it is pretty clear, it starts around 14dB, which is aligned with datasheet, but falls much more rapidly (I think not surprising if the phase response measured is correct but that is the problem). I think the performance of DUT is pretty much clear from the datasheet, obviously there is something I either do wrong or I cannot do using nanoVNA or with cables or with calibration etc.
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 10:49:49 pm
14dB is quite a gain. Even using pro VNA's you have to know what you are doing when measure active circuits. I am not sure those toy VNA's are up-to task in this case. Just my two cents.

I should get an attenuator and re-try  :-+
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 10:53:49 pm
14dB is quite a gain. Even using pro VNA's you have to know what you are doing when measure active circuits. I am not sure those toy VNA's are up-to task in this case. Just my two cents.

Side note, ADF4350 output level was +5 dBm by default (I think), and I decreased it to -4 dBm already (I think), the manual is not very helpful unfortunately. I need to search a bit more info.
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 11:04:41 pm
14dB is quite a gain. Even using pro VNA's you have to know what you are doing when measure active circuits. I am not sure those toy VNA's are up-to task in this case. Just my two cents.
Side note, ADF4350 output level was +5 dBm by default (I think), and I decreased it to -4 dBm already (I think), the manual is not very helpful unfortunately. I need to search a bit more info.

I didnt check the schematic but according to block diagram (of nanoVNA v2) there is a AD8342 mixer, and its max RF input level is 12 dBm. So if I didnt damage it, with -4dBm tx output, I think it should be OK.
Title: Re: measuring freq response
Post by: gf on March 03, 2021, 11:07:28 pm
Note that any constant-time delay is equivalent to a phase shift which dependes linearly on frequency.
The measured S21 phase is only correct between the established calibration planes. But you did remove the f/f adapter after calibration.
Without de-embedding the removed f/f adapter (at least via electrical delay) you won't measure the correct S21 phase of the DUT, but there will be a (frequency-dependent) offset.
Another question is whether the specified phase is meant to be between between the SMA connectors of the board, or rather between input and output of the IC.
In the latter case you would also need to de-embed the on-board fixtures, from the SMA connectors to the amp.

EDIT: Btw, if you specify an electrical delay, the NanoVNA firmare applies it to both, S11 and S21. You cannot specify separate delays for port1 and port2.
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 11:29:35 pm
Note that any constant-time delay is equivalent to a phase shift which dependes linearly on frequency.
The measured S21 phase is only correct between the established calibration planes. But you did remove the f/f adapter after calibration.
Without de-embedding the removed f/f adapter (at least via electrical delay) you won't measure the correct S21 phase of the DUT, but there will be a (frequency-dependent) offset.
Another question is whether the specified phase is meant to be between between the SMA connectors of the board, or rather between input and output of the IC.
In the latter case you would also need to de-embed the on-board fixtures, from the SMA connectors to the amp.

EDIT: Btw, if you specify an electrical delay, the NanoVNA firmare applies it to both, S11 and S21. You cannot specify separate delays for port1 and port2.

Great, that is the answer I was looking for, thanks a lot. I set electrical delay to 165ps (I just heard somewhere f-f delay of T that comes with it is 165ps, but I used different f-f while calibrating, anyway), and the result is attached.

I am aware about the other issue, obviously I am measuring the board at best not the IC. It would be pretty blind at this point, but the datasheet has measurements on the same board (*), so I was thinking I should be able to achieve something similar at least in a proper setup.

* Just confused the part number :palm: I realized when double checking the datasheet, I have 4303 (not 4302), it has even more 20dB gain. The weird thing is s21(Ang) numbers on the datasheet, did they just wrote the freq instead of actual value or the value is almost same as the frequency ?!

Title: Re: measuring freq response
Post by: tautech on March 03, 2021, 11:38:52 pm
I see it starts from 14dB now, but it falls rapidly. The phase response did not change.
Take a step back from the instrument to fully comprehend what you see...most of it is staring right at you.
Your sweep is for 1 -2 GHz and the trace Ref levels are at 0 dB with a 2dB/div setting. Plonk a few markers down at various frequencies to get the full picture.

Of course the phase response hasn't changed as it's the performance result of the DUT.

Not sure I understand what you mean. The sweep is from 1MHz (not G) to 1GHz.
Sorry  :palm:

Still I have difficulty looking at the 2dB/div and the marker measurement not agreeing with the scaling.
Even you last pic shows this as wrong yet markers are somewhere in the right paddock that you'd expect.  :-//
Title: Re: measuring freq response
Post by: metebalci on March 03, 2021, 11:41:25 pm
Sorry  :palm:

Still I have difficulty looking at the 2dB/div and the marker measurement not agreeing with the scaling.
Even you last pic shows this as wrong yet markers are somewhere in the right paddock that you'd expect.  :-//

I dont see any problem. For logmag, the reference level is at 0 (this may not be the default, I played with it) and at the bottom of screen, 2dB/div, and marker is at div 6 so ~12dB and it says 12.13dB.
Title: Re: measuring freq response
Post by: tautech on March 03, 2021, 11:52:42 pm
Sorry  :palm:

Still I have difficulty looking at the 2dB/div and the marker measurement not agreeing with the scaling.
Even you last pic shows this as wrong yet markers are somewhere in the right paddock that you'd expect.  :-//

I dont see any problem. For logmag, the reference level is at 0 (this may not be the default, I played with it) and at the bottom of screen, 2dB/div, and marker is at div 6 so ~12dB and it says 12.13dB.
Sorry you are right. I didn't spot the Mag Log ref position way down at the foot of the display.  :palm:
Please carry on.
Title: Re: measuring freq response
Post by: gf on March 04, 2021, 12:38:29 am
The f-f adapter which came with my Nano is about 165ps too. But IIRC this was round trip (i.e. s11) delay. S21 delay is only one way.

You can estimate the delay of your adapter by removing it after calibration, keeping the port1 cable open, displaying S11 phase, and adjusting edelay until s11 phase becomes approximately a horizontal line, i.e. phase zero at all frequencies +/-noise.
Title: Re: measuring freq response
Post by: Berni on March 04, 2021, 06:55:01 am
Do be careful with measuring active amplifiers like that since the ports on a VNA can be fairly delicate while an amplifier might be capable of pushing damaging amount of power into them. Especially if you leave the output of the amplifier connected while messing with the connection of the input side of the amplifier, especially if a high power capable amplifier accidentally turns itself into a feedback oscillator. Same goes the other way around, some RF amplifiers (this opamp is not one of those) can also be pretty delicate and can be killed by driving a large signal into the input while the output is not terminated into 50 Ohm since the reflected power can damage the delicate RF transistors.

Its common to put external attenuators between the amplifier and VNA. This can be especially beneficial in the case of the NanoVNA due to not having built in switchable attenuators on its ports like a real VNA. This can help the NanoVNA better handle large input signals from amplifiers, or help the NanoVNA output a smaller stimulus signal to the input of the amplifier (In case it is a easily overloadable low power amplifier). The attenuator can just be calibrated out as part of the thru calibration.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 08:19:23 am
The f-f adapter which came with my Nano is about 165ps too. But IIRC this was round trip (i.e. s11) delay. S21 delay is only one way.

You can estimate the delay of your adapter by removing it after calibration, keeping the port1 cable open, displaying S11 phase, and adjusting edelay until s11 phase becomes approximately a horizontal line, i.e. phase zero at all frequencies +/-noise.

I will measure it, thanks for the hint.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 08:26:43 am
Do be careful with measuring active amplifiers like that since the ports on a VNA can be fairly delicate while an amplifier might be capable of pushing damaging amount of power into them. Especially if you leave the output of the amplifier connected while messing with the connection of the input side of the amplifier, especially if a high power capable amplifier accidentally turns itself into a feedback oscillator. Same goes the other way around, some RF amplifiers (this opamp is not one of those) can also be pretty delicate and can be killed by driving a large signal into the input while the output is not terminated into 50 Ohm since the reflected power can damage the delicate RF transistors.

Its common to put external attenuators between the amplifier and VNA. This can be especially beneficial in the case of the NanoVNA due to not having built in switchable attenuators on its ports like a real VNA. This can help the NanoVNA better handle large input signals from amplifiers, or help the NanoVNA output a smaller stimulus signal to the input of the amplifier (In case it is a easily overloadable low power amplifier). The attenuator can just be calibrated out as part of the thru calibration.

I actually had this in my mind, but gain=10 did not sound much, as it is not I think in a normal signal chain as a voltage gain, but obviously not thinking in terms of power and VNAs input, reflected power etc.

I didnt think the other way around that reflected signal might damage the DUT, thanks for pointing out.

I ordered an attenuator, I will try that probably tomorrow, hoping I neither damaged nanoVNA nor DUT yet.
Title: Re: measuring freq response
Post by: gf on March 04, 2021, 10:07:41 am
The f-f adapter which came with my Nano is about 165ps too. But IIRC this was round trip (i.e. s11) delay. S21 delay is only one way.

You can estimate the delay of your adapter by removing it after calibration, keeping the port1 cable open, displaying S11 phase, and adjusting edelay until s11 phase becomes approximately a horizontal line, i.e. phase zero at all frequencies +/-noise.

I will measure it, thanks for the hint.

Sorry, I think mixed up different adapters - the 165ps I had in mind were likely not for this f/f adapter.

Alternatively to phase you could also watch the S11 group delay (-> FORMAT -> DELAY) which is supposed to be 0 for each frequency at the calibration plane. But it is very noisy. In the phase display, I still can clearly recognize the difference (-> roughly 1ps) between Open standard attached vs. not attached to the calibrated female end of port1, despite noise, but in the group delay display this difference drowns in noise (at least visually). That's why I rather prefer phase as indicator when estimating the required edelay.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 06:52:42 pm

I am confused about two things regarding to calibration (for nanoVNA and also I think for Siglent SVA too, maybe in general for all one path VNAs I am not sure). I think I understand 1-port calibration, which is using SOL/SOM and it moves the calibration plane where this is done, e.g. if I do at port 1, the calibration plane is at port 1, or if I do this at the end of a cable, the plane is at the end of a cable so the effect of cables are removed/de-embedded.

Why do I not do the same for Port 2 also ? I think the answer is because one path device only measures s11 and s21 and the calibration of Port 2 like this is only required for reflection measurements. But I am not very happy with this answer, is that correct or is it the full story ? I see 2-port calibration is/can be done on true VNAs, I do not know exactly when it is or should be done.

The reason I ask above question is also because I realized I dont understand exactly what Thru calibration does. So I finished 1-port calibration at Port 1, and then I do a Thru calibration, as far as I understand, this is required for s21 measurement, and it is enough (enough meaning it is the full story, it is not an approximation but removes all errors for s21 measurement?). Obviously I cannot connect Port 1 to Port 2 directly, so a cable is used. So when I use this cable, where are the calibration planes ? Is Port 1 calibration plane at Port 1 and Port 2 calibration plane at the start of this cable (start meaning open end, the other end is connected to Port 2) ?
Title: Re: measuring freq response
Post by: Kleinstein on March 04, 2021, 07:03:34 pm
Both ports have there own calibration plane / point. For the 2nd port this is where it connects to the 1. port calibration plane.

The simple measurement does not correct all errors, but most. One effect likely not fully corrected is signal leakage from the ground link. At least in most instruments the ground of port 1 and 2 is connected and there can be some signal leakage on another way than the intended through.
The refelcted part back to port 1 may also interfere with the recieved signal of port 2. The instrument internal switches are usually not ideal, even if they try hard.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 07:11:23 pm
Both ports have there own calibration plane / point. For the 2nd port this is where it connects to the 1. port calibration plane.

The simple measurement does not correct all errors, but most. One effect likely not fully corrected is signal leakage from the ground link. At least in most instruments the ground of port 1 and 2 is connected and there can be some signal leakage on another way than the intended through.
The refelcted part back to port 1 may also interfere with the recieved signal of port 2. The instrument internal switches are usually not ideal, even if they try hard.

Just to repeat if I understand correct, so if I do one port calibration at Port 1, and then a thru calibration with a cable, then the port 1 calibration plane is at port 1, and port 2 calibration plane is at the Port 1 end of the cable where Port 2 is effectively connected to Port 1?

I saw in some VNA guides I think Agilent, there was something called isolation, and there Port 2 is also additionally calibrated with the load also (in addition to Port 1 and Thru calibration). I guess this is to improve it, but it is not supported by any non true VNA device I saw.
Title: Re: measuring freq response
Post by: tautech on March 04, 2021, 07:20:32 pm
Very simply VNA calibration can be likened to normalising a spectrum analyser but with Cal standards of SOLT.
Single port cals only require SOL but at the end of your cabling and adaptors right before the DUT.
For 2 port for VNA's that just provide the stimulus from one port the Through needs be placed where the DUT would be.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 07:31:40 pm
Very simply VNA calibration can be likened to normalising a spectrum analyser but with Cal standards of SOLT.
Single port cals only require SOL but at the end of your cabling and adaptors right before the DUT.
For 2 port for VNA's that just provide the stimulus from one port the Through needs be placed where the DUT would be.

I pretty much understood the procedure but trying to understand the reason behind.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 07:36:28 pm
Sorry, I think mixed up different adapters - the 165ps I had in mind were likely not for this f/f adapter.

Alternatively to phase you could also watch the S11 group delay (-> FORMAT -> DELAY) which is supposed to be 0 for each frequency at the calibration plane. But it is very noisy. In the phase display, I still can clearly recognize the difference (-> roughly 1ps) between Open standard attached vs. not attached to the calibrated female end of port1, despite noise, but in the group delay display this difference drowns in noise (at least visually). That's why I rather prefer phase as indicator when estimating the required edelay.

It was quite easy to check this in the phase display and like you said it is kinda impossible by looking at delay. I measured 93ps. Also like you said even 1ps has a visible effect.
Title: Re: measuring freq response
Post by: tautech on March 04, 2021, 07:36:49 pm
Very simply VNA calibration can be likened to normalising a spectrum analyser but with Cal standards of SOLT.
Single port cals only require SOL but at the end of your cabling and adaptors right before the DUT.
For 2 port for VNA's that just provide the stimulus from one port the Through needs be placed where the DUT would be.

I pretty much understood the procedure but trying to understand the reason behind.
Every fitting/cable beyond the physical port has an impact on measurements.
When I decided to get a Cal kit I got this one so to be the most convenient at the end of cabling:
https://www.siglenteu.com/accessory/f603me/ (https://www.siglenteu.com/accessory/f603me/)

AFAIK they are made by Rosenberger for Siglent.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 07:57:53 pm
Here I think I have a reasonable result. So, I calibrated Port 1 using f-f adapter (SOL after f-f), and also did a Thru calibration using another cable coming from Port 2 and connected to f-f as well. Then, I measured the delay of this f-f adapter ~93ps. I then look at the board and distance from SMA to opamp is almost an inch, a very rough calculation (I think) gives something like 160ps/inch for the board, so for both sides (input, output) it is 320ps, minus 90, 230ps. I set this as electrical delay. I think the phase response will probably be aligned with the datasheet, the mag response is still falling too rapidly, and there is a bit ringing(?) after 1Ghz, but I guess this is a better measurement than yesterday. I dont know why there is that part at very low freq. maybe nanoVNA is not good at that much low end. I also still dont have an attenuator, I will try that hopefully tomorrow.
Title: Re: measuring freq response
Post by: gf on March 04, 2021, 07:58:41 pm
Why do I not do the same for Port 2 also ? I think the answer is because one path device only measures s11 and s21 and the calibration of Port 2 like this is only required for reflection measurements. But I am not very happy with this answer, is that correct or is it the full story ? I see 2-port calibration is/can be done on true VNAs, I do not know exactly when it is or should be done.

For a "full-blown" 2-port VNA the same is done for port 2 as well. But SOL does not make any sense on port 2 if port 2 cannot transmit and has no directional coupler to measure reflected power. Keep in mind that port2 of the Nano can only receive.

Quote
So when I use this cable, where are the calibration planes ? Is Port 1 calibration plane at Port 1 and Port 2 calibration plane at the start of this cable (start meaning open end, the other end is connected to Port 2) ?

Given that the included cal kit is male, and given that the NanoVNA firmware expects a zero-length-thru for calibration, this implies that the port1 calibration plane can only be established at a female connector, and the port2 calibration plane has to be a male connector. Then the (male) cal kit can be directly attached to the (female) port1 calibration plane, and mating the female port1 conenctor with the male port2 connector yields a zero-length-thru, establishing the port2 calibration plane at the male port2 connector then when the the thru-calibration is done.

Conclusion: On port 2 you must attach the cable in order to get a male endpoint. Port1 can bei either used directly (it is already female), or you attach the other cable + the f/f adapter to port1 (which also leads to a female endpoint). This is the configuration which can be calibrated out of te box with the included accessories. Hopefully the DUT has a male input and female output then, otherwise it is not insertable directly to the established calibration planes.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 08:01:43 pm
Hopefully the DUT has a male input and female output then, otherwise it is not insertable directly to the established calibration planes.

Unfortunately it is not, both ports are female. So I am using the electrical delay setting (or port extension I think is a more correct term?).

I actually do not understand why male cal kits seem to be more common/standard. As far as I see, DUTs usually have female ports, VNA has female ports, cables are m-m, so it is more normal to get female cal kits in my opinion.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 08:03:13 pm
Every fitting/cable beyond the physical port has an impact on measurements.
When I decided to get a Cal kit I got this one so to be the most convenient at the end of cabling:
https://www.siglenteu.com/accessory/f603me/ (https://www.siglenteu.com/accessory/f603me/)

AFAIK they are made by Rosenberger for Siglent.

If I decide to buy SVA (probably 1032x), I may probably get one of these.
Title: Re: measuring freq response
Post by: gf on March 04, 2021, 08:51:46 pm
Unfortunately it is not, both ports are female. So I am using the electrical delay setting (or port extension I think is a more correct term?).

Yes, if you need to add any adapters or fixtueres between calibration planes and DUT, then you need to de-embed them mathematically if your aim is to measure the DUT alone. Electrical delay (or port extension, or however you call it) is a simple de-embedding method which makes the assumption that the de-embedded network can be modeled as a perfect lossless transmission line with Z0=50 Ohm, so that its s-parameters can be calculated from a single delay parameter. This can be a good enough approximation (e.g. for the short 50 Ohm f-f adapter), but don't take it for granted in general. Anyway, edelay is the only de-embedding method available in the NanoVNA firmware. Anything beyond that needs to be calculated externally.

[ The same applies of course when an adapter is removed for the DUT measurement which was included in the calibration. ]

Btw, was 93ps the round-trip delay? Then one-way (for S21) is only 46.5ps.

You should also take a look at S11 to see how well the amplifier input is matched to a 50 Ohm source. Anything which is already reflected at the input won't appear at the output either.
Title: Re: measuring freq response
Post by: tautech on March 04, 2021, 08:53:55 pm
Every fitting/cable beyond the physical port has an impact on measurements.
When I decided to get a Cal kit I got this one so to be the most convenient at the end of cabling:
https://www.siglenteu.com/accessory/f603me/ (https://www.siglenteu.com/accessory/f603me/)

AFAIK they are made by Rosenberger for Siglent.

If I decide to buy SVA (probably 1032x), I may probably get one of these.
SVA1032X is what I have now after replacing the SVA1015X that we originally got. Cool bit of kit and I love the thing.  :)
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 09:04:29 pm
Btw, was 93ps the round-trip delay? Then one-way (for S21) is only 46.5ps.

You should also take a look at S11 to see how well the amplifier input is matched to a 50 Ohm source. Anything which is already reflected at the input won't appear at the output either.

93ps was the electrical delay I need to use to correct phase to 0. So since it is s11, I guess it is 2x of the actual length right ? so I should use the half. Actually with DUT, I checked other values and delays higher than 230ps was getting even better, so that can be definitely a reason.

Below I changed electrical delay to 275ps and added s11 smith chart to display.
Title: Re: measuring freq response
Post by: gf on March 04, 2021, 09:31:25 pm
93ps was the electrical delay I need to use to correct phase to 0. So since it is s11, I guess it is 2x of the actual length right ?

That is at least my understanding.

Quote
Below I changed electrical delay to 275ps and added s11 smith chart to display.

Better display return loss (s11 log magnitude).
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 09:46:18 pm
Better display return loss (s11 log magnitude).

It looks not good to me but I dont know what to expect also.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 09:57:56 pm
For a "full-blown" 2-port VNA the same is done for port 2 as well. But SOL does not make any sense on port 2 if port 2 cannot transmit and has no directional coupler to measure reflected power. Keep in mind that port2 of the Nano can only receive.

question also for @tautech. On SVA spec, it says it does Enhanced Response calibration. On an Agilent VNA manual page (http://ena.support.keysight.com/e5071c/manuals/webhelp/eng/index.htm#measurement/calibration/basic_calibrations/enhanced_response_calibration.htm (http://ena.support.keysight.com/e5071c/manuals/webhelp/eng/index.htm#measurement/calibration/basic_calibrations/enhanced_response_calibration.htm)) it describes the process, and it says for (optional) isolation (crosstalk), load is connected to both ports. On SVA manual (https://www.siglenteu.com/wp-content/uploads/dlm_uploads/2019/09/UserManual_UG0703P_E02A.pdf (https://www.siglenteu.com/wp-content/uploads/dlm_uploads/2019/09/UserManual_UG0703P_E02A.pdf)) I only see 1-port and response through calibration options. So:

- Is Enhanced Response calibration added later and not in manual yet ?
- This is effectively enhanced response calibration because port 2 on SVA is receive only ?
- Isolation is optional for Enhanced Response calibration term, so 1 port + response through is effectively enhanced response calibration without optional isolation ? (however isolation issue still exists because Port 1 is output and Port 2 is receiver for SVA too ?)

which one ?
Title: Re: measuring freq response
Post by: tautech on March 04, 2021, 10:31:04 pm
For a "full-blown" 2-port VNA the same is done for port 2 as well. But SOL does not make any sense on port 2 if port 2 cannot transmit and has no directional coupler to measure reflected power. Keep in mind that port2 of the Nano can only receive.

question also for @tautech. On SVA spec, it says it does Enhanced Response calibration. On an Agilent VNA manual page (http://ena.support.keysight.com/e5071c/manuals/webhelp/eng/index.htm#measurement/calibration/basic_calibrations/enhanced_response_calibration.htm (http://ena.support.keysight.com/e5071c/manuals/webhelp/eng/index.htm#measurement/calibration/basic_calibrations/enhanced_response_calibration.htm)) it describes the process, and it says for (optional) isolation (crosstalk), load is connected to both ports. On SVA manual (https://www.siglenteu.com/wp-content/uploads/dlm_uploads/2019/09/UserManual_UG0703P_E02A.pdf (https://www.siglenteu.com/wp-content/uploads/dlm_uploads/2019/09/UserManual_UG0703P_E02A.pdf)) I only see 1-port and response through calibration options. So:

- Is Enhanced Response calibration added later and not in manual yet ?
- This is effectively enhanced response calibration because port 2 on SVA is receive only ?
- Isolation is optional for Enhanced Response calibration term, so 1 port + response through is effectively enhanced response calibration without optional isolation ? (however isolation issue still exists because Port 1 is output and Port 2 is receiver for SVA too ?)

which one ?
gf is correct and for Enhanced Response is with using a Through to Port 2 for S21 measurements.
There are more advanced Cal settings in the SVA menus for this sort of work.

I should add I've only really dome single port VNA work with both the SVA's I've had.
Title: Re: measuring freq response
Post by: gf on March 04, 2021, 10:49:49 pm
and it says for (optional) isolation (crosstalk), load is connected to both ports.

AFAIK, the NanoVNA calibrates isolation too, but you don't need to connect a load to both ports. I think it is done automatically via internal switches. For this purpose no accurate standard is required, it is just about terminating the ports at all. Enhanced response can be enabled too in the calibration menu. My understanding is that source mismatch is compensated then. Load mismatch is still uncompensated. The latter would require full two-port one-path calibration and measurements, where the DUT needs to be flippled and measured twice. This is not supported by the NanoVNA firmware.

[ Btw, when I talk abuout NanoVNA, I mean the V2. ]
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 11:14:28 pm
and it says for (optional) isolation (crosstalk), load is connected to both ports.

AFAIK, the NanoVNA calibrates isolation too, but you don't need to connect a load to both ports. I think it is done automatically via internal switches. For this purpose no accurate standard is required, it is just about terminating the ports at all. Enhanced response can be enabled too in the calibration menu. My understanding is that source mismatch is compensated then. Load mismatch is still uncompensated. The latter would require full two-port one-path calibration and measurements, where the DUT needs to be flippled and measured twice. This is not supported by the NanoVNA firmware.

[ Btw, when I talk abuout NanoVNA, I mean the V2. ]

I was looking at more Agilent pdfs, there is a long basic one (https://www.keysight.com/upload/cmc_upload/All/BTB_Network_2005-1.pdf (https://www.keysight.com/upload/cmc_upload/All/BTB_Network_2005-1.pdf)), page 55 and 56. As far as I understand, similar to what you said, for load mismatch correction, a full 2 port calibration is required, from this I understand Port 2 should have a generator too, or maybe like you said DUT has to be flipped and this should somehow be combined.

However, it seems there is an approximate way to find load mismatch error term, just by using Thru after SOL. I think this is implemented in NanoVNA. This thread is quite informative: https://nanorfe.com/forum/Enhnanced-Response-for-S21-measurements.html (https://nanorfe.com/forum/Enhnanced-Response-for-S21-measurements.html)

However, crosstalk/isolation seems to be another thing and optional item, it is even possible to do full 2 port calibration without isolation. It seems nanoVNA v1 has a calibration option for this (https://nanovna.com/?page_id=2 (https://nanovna.com/?page_id=2)). I couldnt find this for nanoVNA v2, do you remember where did you see that ? I also have nanoVNA v2 (v2.2 specifically).
Title: Re: measuring freq response
Post by: gf on March 04, 2021, 11:22:58 pm
I couldnt find this for nanoVNA v2, do you remember where did you see that ? I also have nanoVNA v2 (v2.2 specifically).

In the source code of the firmware. There are CAL_ISOLN_OPEN and CAL_ISOLN_SHORT error terms calculated and apllied. I did not investigate the calculation details so far.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 11:25:32 pm
By the way, same Agilent pdf, because of load mismatch issue (I think), there are examples using an attenuator after the DUT output (both for T/R devices like nanoVNA and full two port VNAs), and there is a summary on page 65. Using attenuator seems to be a very good idea.
Title: Re: measuring freq response
Post by: gf on March 04, 2021, 11:28:56 pm
This is of course possible, but OTOH it reduces the dynamic range / SNR.
Title: Re: measuring freq response
Post by: metebalci on March 04, 2021, 11:32:28 pm
I couldnt find this for nanoVNA v2, do you remember where did you see that ? I also have nanoVNA v2 (v2.2 specifically).

In the source code of the firmware. There are CAL_ISOLN_OPEN and CAL_ISOLN_SHORT error terms calculated and apllied. I did not investigate the calculation details so far.

I just very quickly looked at, it seemed to me like when open and short calibrations are done on Port 1, Port 2 is also read to find leakage. Might be wrong, just my initial feeling.
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 01:22:43 pm
I got a 20dB attenuator, and also trying on another portable VNA which is a little better than nanoVNA I believe. Below is an output from that with 320ps electrical delay, and with the attenuator attached at the output. I calibrated Thru both with and without the attenuator, and the result is similar other than -20dB offset on mag. I am thinking it is better to do it with attenuator but which one is preferred ?

Comparing to nanoVNA I dont see the strange part in the low freq., all other seems to be similar. I still did not understand why I am seeing ~14dB since the opamp has 20dB fixed gain and also s-parameter measurements in the datasheet is also 20dB. @Kleinstein said something similar before, is that because the opamp has 49.9ohm output resistor in series to drive 50ohm line, and this is causing 6dB loss ? If so, they probably corrected this for the s-parameter table.

Other than 6dB, there is still the issue with actual 3dB cutoff point, it is supposed to be at 1.8Ghz, I measure it around 1.2Ghz. Also there is the problem of ringing, is that because of reflections ?
Title: Re: measuring freq response
Post by: Kleinstein on March 05, 2021, 01:52:11 pm
The 50 Ohms series termination and 50 Ohms load gives 6 dB attenuation - no question there. The reference circuit in the datasheet shows a 100 Ohms load and the output without termination - this indicates that the data-sheet number does not include the 6 dB attenuation.

The ringing part looks a little like interference with signal reflections at some point. This could be at the signal input or output, but also at the supplies. Insufficient supply decoupling could cause such ripple and also an earlier cut off.  Added attenuators could be better matched than the amplifier or VNA  and this way reduce reflections. Another way to test could be using a longer cable - this could change the delay and thus the position of the interference.
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 02:28:23 pm
The 50 Ohms series termination and 50 Ohms load gives 6 dB attenuation - no question there. The reference circuit in the datasheet shows a 100 Ohms load and the output without termination - this indicates that the data-sheet number does not include the 6 dB attenuation.

The ringing part looks a little like interference with signal reflections at some point. This could be at the signal input or output, but also at the supplies. Insufficient supply decoupling could cause such ripple and also an earlier cut off.  Added attenuators could be better matched than the amplifier or VNA  and this way reduce reflections. Another way to test could be using a longer cable - this could change the delay and thus the position of the interference.

6dB loss :-+

I have two more findings. One is the issue at the low frequency, I didnt check but around 1-100Mhz, is most probably due to overload. The output of this device is speced at max -5dBm, and input is +10dBm, since I have 14dB gain, I thought I can connect directly and when I do I see exactly like in nanoVNA with the problem in low freq. With attenuator (at input or output) this disappears.

Second, I tested the (20dB) attenuator both at input and output (of DUT). When it is at input, there is definitely less ringing/very visible ringing starts much later. Without attenuator, s11 logmag reaches almost -5dB for some frequencies, this is too high right ? With attenuator, it naturally decreases below -30dB.

If I want to measure s22, can I just connect Port 1 to output of DUT and check it, or no, is there something I need to be aware of ?

Title: Re: measuring freq response
Post by: gf on March 05, 2021, 05:40:19 pm
Second, I tested the (20dB) attenuator both at input and output (of DUT). When it is at input, there is definitely less ringing/very visible ringing starts much later. Without attenuator, s11 logmag reaches almost -5dB for some frequencies, this is too high right ? With attenuator, it naturally decreases below -30dB.

Is the port1 calibration plane established behind the attenuator?
Otherweise the attenuator is considered part of the DUT, and you measure mostly the S11 of the attenuator, and only a small fraction of the amp's S11.
An attenuator cannot be de-embedded by electrical delay only - it is not a lossless transmission line.
But even if the calibration plane were behind the attenuator, also consider that 2x20dB is quite some reduction of dynamic range for the signal reflected from the DUT. At least keep an eye on the noise level of the S11 readings then.

Quote
If I want to measure s22, can I just connect Port 1 to output of DUT and check it, or no, is there something I need to be aware of ?

Beware that you measure the output of an active deivce, so ensure that it does not output any power which could damage the VNA. Also take care of potential DC bias. The NanoVNA ports are AC coupled, but I don't know how much DC they can withstand. Terminate the DUT output with a 50 Ohm load when you measue S11, and vice versa terminate the DUT input when you measure S22.
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 06:55:25 pm
Second, I tested the (20dB) attenuator both at input and output (of DUT). When it is at input, there is definitely less ringing/very visible ringing starts much later. Without attenuator, s11 logmag reaches almost -5dB for some frequencies, this is too high right ? With attenuator, it naturally decreases below -30dB.

Is the port1 calibration plane established behind the attenuator?
Otherweise the attenuator is considered part of the DUT, and you measure mostly the S11 of the attenuator, and only a small fraction of the amp's S11.
An attenuator cannot be de-embedded by electrical delay only - it is not a lossless transmission line.
But even if the calibration plane were behind the attenuator, also consider that 2x20dB is quite some reduction of dynamic range for the signal reflected from the DUT. At least keep an eye on the noise level of the S11 readings then.

No, I put the attn after the calibration plane. Now, I tried to calibrate with it, but it seems I cannot, not sure maybe I am doing something wrong. I mean if I try, and then I try to validate short/open/load, and it is not correct, it is not a fixed point. I guess because it is 20dB.

I made a few more measurements.

- dut-s11: calibration at the cable, no attn, s11 of dut. This looks like there are too much reflection before lets say 1Ghz, no ? I am not sure what to expect here actually, I mean if it was a perfect match, this would be a flat and low line right, but how low. (I checked this with DUT powered on and off, and there is almost no change)

- dut-s22-off: I connected port 1 to output of DUT, but it is powered off. I dont know if this is a valid measurement.
- dut-s22-on: same as above, but DUT is powered on. Again, I dont know if this is a valid measurement, but it at least looks better than s11.

- s11-attn: s11 of attn alone. So answering my question for dut-s11, I guess this is a good s11 plot, almost flat below -30dB. So I am thinking there is an issue with s11 of DUT, possibly sth related to my measurement, or maybe sth related to DUT itself.
Title: Re: measuring freq response
Post by: gf on March 05, 2021, 07:48:17 pm
- dut-s11: calibration at the cable, no attn, s11 of dut. This looks like there are too much reflection before lets say 1Ghz, no ? I am not sure what to expect here actually, I mean if it was a perfect match, this would be a flat and low line right, but how low. (I checked this with DUT powered on and off, and there is almost no change)

You rather mean too much reflection at high frequencies?
Sure, -5dB means that ~1/3 of the power is reflected. Still 2/3 (or -1.65 dB) of the max. possible power enters the DUT.
Don't know either what to expect. At least S11 logmag curve is pretty smooth.

You could also take a look at the time domain to check if there are particular spatial locations with pronounced reflections.
On the NanoVNA select DISPLAY -> TRANSFORM -> BANDPASS, and turn on DISPLAY -> TRANSFORM -> TRANSFORM ON.
S11 trace format format -> LINEAR (but LOGMAG works too for bandpass mode)
The larger the span fstop - fstart, the better the time resolution.
[ If you want to do low pass mode, there are a few extra things to consider. ]
Don't know how to setup your other VNA correspondingly

EDIT: Thinking about it closer, you may not get sufficient resolution. Utilizing the full supported sweep range 50k-3GHz give 333ps resolution in bandpass mode and 167ps resolution in lowpass mode (on screen the steps are a bit finer, but only due to interpolation). Not sure whether this suffices to distinguish the input of the board and the IC input, If your other VNA supports higher frequencies, you can get a better resolution - granted that it supports TDR at all.

Quote
- s11-attn: s11 of attn alone. So answering my question for dut-s11, I guess this is a good s11 plot, almost flat below -30dB. So I am thinking there is an issue with s11 of DUT, possibly sth related to my measurement, or maybe sth related to DUT itself.

The attenuator is OK. Was it 50 Ohm terminated at the other end? If not, this may still slightly improve S11 a little bit further.
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 08:30:15 pm
- dut-s11: calibration at the cable, no attn, s11 of dut. This looks like there are too much reflection before lets say 1Ghz, no ? I am not sure what to expect here actually, I mean if it was a perfect match, this would be a flat and low line right, but how low. (I checked this with DUT powered on and off, and there is almost no change)

You rather mean too much reflection at high frequencies?
Sure, -5dB means that ~1/3 of the power is reflected. Still 2/3 (or -1.65 dB) of the max. possible power enters the DUT.
Don't know either what to expect. At least S11 logmag curve is pretty smooth.

Yes too much (I mean at least much more than low freq.) reflection at high freq. I mean this is supposed to be driven like this and the board trace etc. is all 50 ohm too. So I think I was expecting it to be not this high. I can probably ask this to TI forum, it is a TI eval board.

You could also take a look at the time domain to check if there are particular spatial locations with pronounced reflections.
On the NanoVNA select DISPLAY -> TRANSFORM -> BANDPASS, and turn on DISPLAY -> TRANSFORM -> TRANSFORM ON.
S11 trace format format -> LINEAR (but LOGMAG works too for bandpass mode)
The larger the span fstop - fstart, the better the time resolution.
[ If you want to do low pass mode, there are a few extra things to consider. ]
Don't know how to setup your other VNA correspondingly

EDIT: Thinking about it closer, you may not get sufficient resolution. Utilizing the full supported sweep range 50k-3GHz give 333ps resolution in bandpass mode and 167ps resolution in lowpass mode (on screen the steps are a bit finer, but only due to interpolation). Not sure whether this suffices to distinguish the input of the board and the IC input, If your other VNA supports higher frequencies, you can get a better resolution - granted that it supports TDR at all.

Quote
- s11-attn: s11 of attn alone. So answering my question for dut-s11, I guess this is a good s11 plot, almost flat below -30dB. So I am thinking there is an issue with s11 of DUT, possibly sth related to my measurement, or maybe sth related to DUT itself.

The attenuator is OK. Was it 50 Ohm terminated at the other end? If not, this may still slightly improve S11 a little bit further.

I was not sure how to use TDR, sure I can give it a try.

I measured the attenuator like a two port DUT, the other end was connected to Port 2, s21 was around -20dB as expected. I will check how it is when I directly terminate.
Title: Re: measuring freq response
Post by: gf on March 05, 2021, 08:42:43 pm
I measured the attenuator like a two port DUT, the other end was connected to Port 2, s21 was around -20dB as expected. I will check how it is when I directly terminate.

Then it was terminated anyway (even though not as perfect as possible). So don't expect significant difference then.
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 08:53:40 pm
93ps was the electrical delay I need to use to correct phase to 0. So since it is s11, I guess it is 2x of the actual length right ?

That is at least my understanding.

Multiple confusions on this. I was looking at the book high speed digital design and it says the round trip time is:

T = length * sqrt(LC)

sqrt(LC) = 1/(speed_of_light * velocity_factor)

T = length / (c * VF)

As common sense, I would also calculate the delay like this, wave slows down by VF and travels along the length, but the strange thing is it says this is round trip (because fwd and rev waves travel at the same time ?)

Meanwhile, the manual of the other pocket VNA I have says, for the electrical delay, you should use 2*L / (c*VF), so 2x of round trip calculation above, which sounds strange, I thought it is wrong, they might have put 2 in nominator instead of denominator.

Then I measured the length of f-f adapter I have, the one I was using yesterday, the dielectric part is is approx. 10mm, using the equations above, it is approx 48ps, approx. half of the electrical delay I was using yesterday that zeroes the phase when it is unplugged. So I think when electrical delay is changed like this to correct/zero the phase as you described, it is the correct value that should be used, it should not be half. If you calculate the round trip delay from the equations, then it is 2x of this. It doesnt make sense to me yet, I just wanted to share and I might be wrong somewhere.

Title: Re: measuring freq response
Post by: gf on March 05, 2021, 09:13:18 pm
93ps was the electrical delay I need to use to correct phase to 0. So since it is s11, I guess it is 2x of the actual length right ?

That is at least my understanding.

Multiple confusions on this. I was looking at the book high speed digital design and it says the round trip time is:

T = length * sqrt(LC)

sqrt(LC) = 1/(speed_of_light * velocity_factor)

T = length / (c * VF)

As common sense, I would also calculate the delay like this, wave slows down by VF and travels along the length, but the strange thing is it says this is round trip (because fwd and rev waves travel at the same time ?)

Meanwhile, the manual of the other pocket VNA I have says, for the electrical delay, you should use 2*L / (c*VF), so 2x of round trip calculation above, which sounds strange, I thought it is wrong, they might have put 2 in nominator instead of denominator.

Then I measured the length of f-f adapter I have, the one I was using yesterday, the dielectric part is is approx. 10mm, using the equations above, it is approx 48ps, approx. half of the electrical delay I was using yesterday that zeroes the phase when it is unplugged. So I think when electrical delay is changed like threflectedis to correct/zero the phase as you described, it is the correct value that should be used, it should not be half. If you calculate the round trip delay from the equations, then it is 2x of this. It doesnt make sense to me yet, I just wanted to share and I might be wrong somewhere.

My understanding is:
Compensate S11 with the round-trip delay, but compensate S21 with the one-way delay.
The EDELAY value selected in the NanaoVNA obviously acts as round trip delay for S11, and as one-way delay for S21.
I.e. in order to de-embed the f-f adapter, you need to set EDELAY=-96ps when you measure S11, and set EDELAY=-48ps when you measure S21.
Would this make sense?

[ I find it not comfortable, though, that a different EDELAY needs to be specified for measuring S11 and for S21. ]

EDIT: That's my feeling how the EDELAY value is interpreted by the NanoVNA. Other VNAs may have different conventions.
In fact one can see in the firmware source code that both S11 and S21 are multiplied by exp(j*omega*edelay).
It does not double edelay value for S11, although the reflected signal needs to travel forth and back through the port extension.
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 09:38:57 pm
You could also take a look at the time domain to check if there are particular spatial locations with pronounced reflections.
On the NanoVNA select DISPLAY -> TRANSFORM -> BANDPASS, and turn on DISPLAY -> TRANSFORM -> TRANSFORM ON.
S11 trace format format -> LINEAR (but LOGMAG works too for bandpass mode)
The larger the span fstop - fstart, the better the time resolution.
[ If you want to do low pass mode, there are a few extra things to consider. ]
Don't know how to setup your other VNA correspondingly

EDIT: Thinking about it closer, you may not get sufficient resolution. Utilizing the full supported sweep range 50k-3GHz give 333ps resolution in bandpass mode and 167ps resolution in lowpass mode (on screen the steps are a bit finer, but only due to interpolation). Not sure whether this suffices to distinguish the input of the board and the IC input, If your other VNA supports higher frequencies, you can get a better resolution - granted that it supports TDR at all.

I think I cannot see anything meaningful. I mean I only see an initial signal and then a flat line, I cannot distinguish anything in the first part.
Title: Re: measuring freq response
Post by: gf on March 05, 2021, 09:51:47 pm
I think I cannot see anything meaningful. I mean I only see an initial signal and then a flat line, I cannot distinguish anything in the first part.

EDIT: Eventually you are supposed to see a pulse at each location (time) where impedance changes.

I was already afraid that the resolution may not suffice. What is your sweep range? Use the largest you can (50k - 3G).
You can also try WINDOW -> MINIMUM, which uses a rectangular window instead of Kaiser.

EDIT: This makes the pulses narrower, but there will be some ringing then.

When you compare the open port1 cable and port1 connected to the DUT, is the peak at the same position, or maybe 1 time-step apart?
Lowpass mode doubles the time resulution to 6GSa/s (for a 0-3GHz swep range), and even allows to display an impedance profile over time, but there are some issues.

EDIT: You can reduce edelay to say -1ns to shift the pulse to the right, just for better visibility of the peak location.
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 10:08:06 pm
93ps was the electrical delay I need to use to correct phase to 0. So since it is s11, I guess it is 2x of the actual length right ?

That is at least my understanding.

Multiple confusions on this. I was looking at the book high speed digital design and it says the round trip time is:

T = length * sqrt(LC)

sqrt(LC) = 1/(speed_of_light * velocity_factor)

T = length / (c * VF)

As common sense, I would also calculate the delay like this, wave slows down by VF and travels along the length, but the strange thing is it says this is round trip (because fwd and rev waves travel at the same time ?)

Meanwhile, the manual of the other pocket VNA I have says, for the electrical delay, you should use 2*L / (c*VF), so 2x of round trip calculation above, which sounds strange, I thought it is wrong, they might have put 2 in nominator instead of denominator.

Then I measured the length of f-f adapter I have, the one I was using yesterday, the dielectric part is is approx. 10mm, using the equations above, it is approx 48ps, approx. half of the electrical delay I was using yesterday that zeroes the phase when it is unplugged. So I think when electrical delay is changed like this to correct/zero the phase as you described, it is the correct value that should be used, it should not be half. If you calculate the round trip delay from the equations, then it is 2x of this. It doesnt make sense to me yet, I just wanted to share and I might be wrong somewhere.

My understanding is:
Compensate S11 with the round-trip delay, but compensate S21 with the one-way delay.
The EDELAY value selected in the NanaoVNA obviously acts as round trip delay for S11, and as one-way delay for S21.
I.e. in order to de-embed the f-f adapter, you need to set EDELAY=-96ps when you measure S11, and set EDELAY=-48ps when you measure S21.
Would this make sense?

[ I find it not comfortable, though, that a different EDELAY needs to be specified for measuring S11 and for S21. ]

EDIT: That's my feeling how the EDELAY value is interpreted by the NanoVNA. Other VNAs may have different conventions.
In fact one can see in the firmware source code that both S11 and S21 are multiplied by exp(j*omega*edelay).
It does not double edelay value for S11, although the reflected signal needs to travel forth and back.

I usually look or find Keysight documents so it says when you set electrical delay, which is a single number, it affects all measurements in the same way. So if you set electrical delay to x, s11 is delayed x amount, s21 is also x amount. Port extension can be set differently for each port, so if you set port 1 extension to x and port 2 to y, then s11 is delayed by 2x and s21 by x+y. So what you say is you are effectively simulating port extension if you set different values of electrical delay for different measurements.

It is strange in nanoVNA this setting is under per trace options, but you cannot set it independently per trace/measurement, it is a single setting. So what you say makes sense, you use it as a port extension of 48ps for port 1 effectively if you manually change it.

My problem is what I see in the book, and what I calculate. If 48ns is a round trip, why we are using it as a single one direction delay. I have a problem with definition of round trip and propagation delay.

Title: Re: measuring freq response
Post by: gf on March 05, 2021, 10:27:24 pm
I usually look or find Keysight documents so it says when you set electrical delay, which is a single number, it affects all measurements in the same way. So if you set electrical delay to x, s11 is delayed x amount, s21 is also x amount. Port extension can be set differently for each port, so if you set port 1 extension to x and port 2 to y, then s11 is delayed by 2x and s21 by x+y. So what you say is you are effectively simulating port extension if you set different values of electrical delay for different measurements.

OK, then Keysight differentiates between the terms electrical delay and port extension, and it seems that edelay has the same meaning as on the NanoVNA.

Quote
My problem is what I see in the book, and what I calculate. If 48ns is a round trip, why we are using it as a single one direction delay. I have a problem with definition of round trip and propagation delay.

As you said yourself in a previous message, assuming a velocity of 2/3 light speed, 10mm do correspond to ~50ps. That's one way propagation delay for 10mm. But the S21 S11 delay you found by adjusting the edelay until phase becomes 0 was a round-trip delay (i.e. 2x one-way), because the wave needs to trave forwards and back to the sender before it can be measured as reflection.

EDIT: Corrected typo S11 vs S21
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 10:39:21 pm
As you said yourself in a previous message, assuming a velocity of 2/3 light speed, 10mm do correspond to ~50ps.

The problem is book says "the time required for one complete round trip is equal to ...". So I was thinking this value (~50ps) is 2x already. I am missing something somewhere obviously, maybe it is a typo in the book, need to search more.
Title: Re: measuring freq response
Post by: gf on March 05, 2021, 10:49:26 pm
The problem is book says "the time required for one complete round trip is equal to ...". So I was thinking this value (~50ps) is 2x already. I am missing something somewhere obviously, maybe it is a typo in the book, need to search more.

I think it must be a typo. If it were round trip, then 20mm / 50ps = 4*108m/s were faster than light speed. Cool if it were true 8)
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 10:57:48 pm
I think I cannot see anything meaningful. I mean I only see an initial signal and then a flat line, I cannot distinguish anything in the first part.

EDIT: Eventually you are supposed to see a pulse at each location (time) where impedance changes.

I was already afraid that the resolution may not suffice. What is your sweep range? Use the largest you can (50k - 3G).
You can also try WINDOW -> MINIMUM, which uses a rectangular window instead of Kaiser.

EDIT: This makes the pulses narrower, but there will be some ringing then.

When you compare the open port1 cable and port1 connected to the DUT, is the peak at the same position, or maybe 1 time-step apart?
Lowpass mode doubles the time resulution to 6GSa/s (for a 0-3GHz swep range), and even allows to display an impedance profile over time, but there are some issues.

EDIT: You can reduce edelay to say -1ns to shift the pulse to the right, just for better visibility of the peak location.

OK, so I did low pass impulse. I didnt change the scale or marker position to see difference, and also there is -1ns edelay just to see it better. On the dut image, if I set VF=1, the difference between the start of negative wave and the start of positive wave (looking at mm thing above) is around 60mm, even if I take half of this it is 30mm. The board is 32mm. How to interpret this ?

EDIT: and this was with window=normal, with minimum there is some ringing but these two waves are same.

Is distance to fault same thing as what we are doing here ?
Title: Re: measuring freq response
Post by: metebalci on March 05, 2021, 11:20:54 pm

This one is a DTF measurement from the other VNA @ 6Ghz. But the actual distances on the PCB is so short, so this doesnt make sense I think ?
Title: Re: measuring freq response
Post by: rfclown on March 06, 2021, 04:18:41 am
...So skipping the very cheap ones, why is one calibration kit (much) better and (much) expensive than others if they are all individually measured ?

I can only speak for my experience with older HP gear. The cal standards might have been individually measured (and polynomial model coefficents stored on a floppy disk which was shipped with the kit), but they are not used that way. Instead, when I turn on my HP8753D, I choose cal kit 85033D, and it loads the coefficients for that kit (or 85033C if I choose to use that one). It assumes that the measurements of the calibration pieces will fit the models of the published coefficients for that kit, which means that they were manufactured to tight enough mechanical tolerances to make that assumption. The broadband loads ARE very good broadband 50 ohms loads, but the opens and shorts are precise offsets from the reference plane with some known fringe reactance (not a perfect open and short at the reference plane) and the model reflects that. The unit measures the standards, and computes corrections factors based on the models of those standards. Garbage in, garbage out.

The instrument allows you to enter custom cal coefficents, but it is a sufficient enough pain that I don't do it. I pony up and spend the money for a cal kit, but I make my living from RF. I've not had my cal kits or VNAs calibrated. Instead, I occasionally (hardly ever, almost never) cal with one kit, and measure the other. The C and D kits have different reflection offsets, and I know what there are, so I know what the expected results should be. So far (knock on wood), I've gotten correct measurements.

VNAs measure ratios, not absolutes. You calibrate the instrument each time you use it. Your cal standards are very important. Your standards don't have to be perfect loads, opens and shorts, but they need to be what the instrument is expecting them to be.

I'm intrigued by the nanoVNA, but I've not gotten one since I have my 8753s (bought on eBay) which have served me well for many years. I bought them because that's what I had used for the previous 20+ years before I was laid off (long before the nanaVNA existed). If the nano lets you enter your cal standards as Sparameters, that would be a really useful feature. My HP8753s don't allow that. Your measurements are a function of your calibration. If your VNA is assuming perfect open, short and load standards, and your standards aren't, then your measurement accuracy is unknown.
Title: Re: measuring freq response
Post by: rfclown on March 06, 2021, 06:07:53 am
I just read through this whole thread (rather quickly though). Seems OP has learned alot and answered many of his own questions from reading. As far as calibration, as you seem to have already learned, it establishes a reference plane. That implies that the input and output planes can be mated together, which requires two different sex connectors. After calbiration, the VNA measures the s parameters of the device under test (DUT) inserted into the reference plane. So the proper way to do things is for your DUT to be insertable. As in your case (and in many cases) DUTs have two female connectors. Two common solutions:

1. Put a M-M adaptor on one port of your DUT to make it insertable. (I usually prefer this method)
2. Cheat, and use a F-F adaptor when doing the THROUGH cal. (this is commonly done, mostly because people don't know what else to do)

Then when measuring, you get:
#1 s parameters of the DUT plus the adapter. The adapter is just a small loss and a phase offset.
#2 incorrect s parameters. But depending on what you are measuring, might be ok (or might not)

Either way puts a phase offset into the measurement of the DUT. Depending on what you are trying to measure, it may or may not be an issue. You just want to understand what you are doing. If you are only interested in gain, it's a non-issue (just subtract the loss of the adaptor which is usually negligable). If you only need the correct impedance of the input, put the adapter on the output of the DUT, and it's a non-issue. If you really want to know the s parameters of just the DUT on the fixture, you have to somehow de-embed the fixture. If it's a good fixture with 50 ohm traces up to the DUT, you can use the delay or port extension features of your VNA to do that. Sometimes test boards of high frequency devices will include a second set of connectors which have just a through with the same length line minus the DUT.

I usually skip the isolation step in calibration.
Title: Re: measuring freq response
Post by: metebalci on March 06, 2021, 11:45:34 am
The instrument allows you to enter custom cal coefficents, but it is a sufficient enough pain that I don't do it. I pony up and spend the money for a cal kit, but I make my living from RF. I've not had my cal kits or VNAs calibrated. Instead, I occasionally (hardly ever, almost never) cal with one kit, and measure the other. The C and D kits have different reflection offsets, and I know what there are, so I know what the expected results should be. So far (knock on wood), I've gotten correct measurements.

VNAs measure ratios, not absolutes. You calibrate the instrument each time you use it. Your cal standards are very important. Your standards don't have to be perfect loads, opens and shorts, but they need to be what the instrument is expecting them to be.

Good you mentioned this, it was a point I wanted to ask. I definitely understand VNA (mostly?) measures ratios since s parameters are ratios. So the point of actually calibrating (not user calibration I mean at a calibration lab) a VNA is calibrating the absolute freq. accuracy I guess ? is there any other reason ?

I'm intrigued by the nanoVNA, but I've not gotten one since I have my 8753s (bought on eBay) which have served me well for many years. I bought them because that's what I had used for the previous 20+ years before I was laid off (long before the nanaVNA existed). If the nano lets you enter your cal standards as Sparameters, that would be a really useful feature. My HP8753s don't allow that. Your measurements are a function of your calibration. If your VNA is assuming perfect open, short and load standards, and your standards aren't, then your measurement accuracy is unknown.

Another good point, I was also thinking to ask. There are still I think many (mostly in US but  some in Europe too) 8753 series on eBay. Does it still make sense to buy one (I see them around 1500-2000 Euros including the S-parameter set) ? I am a bit scared that they are starting to be very old than just old, just in terms of probability of failure :) or is it better to just look for and pay more (at least 2x) to get a USB one ?

It is I think not possible to enter s-parameters of cal kits on the nanoVNA itself, but I think I saw it is possible on the PC software.
Title: Re: measuring freq response
Post by: metebalci on March 06, 2021, 12:08:49 pm
I just read through this whole thread (rather quickly though). Seems OP has learned alot and answered many of his own questions from reading. As far as calibration, as you seem to have already learned, it establishes a reference plane. That implies that the input and output planes can be mated together, which requires two different sex connectors. After calbiration, the VNA measures the s parameters of the device under test (DUT) inserted into the reference plane.

Yes, I indeed learned a lot in a week since I started this thread, by reading a lot of material, seeing it on nanoVNA and with the help of people here. I am quite fascinated by VNAs.

So the proper way to do things is for your DUT to be insertable. As in your case (and in many cases) DUTs have two female connectors. Two common solutions:

1. Put a M-M adaptor on one port of your DUT to make it insertable. (I usually prefer this method)
2. Cheat, and use a F-F adaptor when doing the THROUGH cal. (this is commonly done, mostly because people don't know what else to do)

Then when measuring, you get:
#1 s parameters of the DUT plus the adapter. The adapter is just a small loss and a phase offset.
#2 incorrect s parameters. But depending on what you are measuring, might be ok (or might not)

Either way puts a phase offset into the measurement of the DUT. Depending on what you are trying to measure, it may or may not be an issue. You just want to understand what you are doing. If you are only interested in gain, it's a non-issue (just subtract the loss of the adaptor which is usually negligable). If you only need the correct impedance of the input, put the adapter on the output of the DUT, and it's a non-issue. If you really want to know the s parameters of just the DUT on the fixture, you have to somehow de-embed the fixture. If it's a good fixture with 50 ohm traces up to the DUT, you can use the delay or port extension features of your VNA to do that.

I still find this insertable/non-insertable DUT issue strange and funny. Why at least simple DUTs not have different sex connectors ? For example the board I have, it is a very simple opamp eval board, what is wrong to put different sex connectors ? Is there a electrical/mechanical reason to put female connectors always on the devices and male connectors on the cables ? I am actually thinking always to use different sex connectors on the eval boards I will make.

I am still not 100% sure what I need (in terms of s21 mag only or phase too). It is funny how I reach to this point. First, since I know about the Bode plots, and the scope has Bode plot function, I was looking that, but it is up to 25 Mhz, and it can be done different ways up to maybe 100 Mhz or so, but not more. I was wondering how they measure this like I saw on the datasheets. Then I saw spectrum analyzers with TG. I was actually considering to buy RS FPC1500 (actually bought than cancelled), which can do s11 mag/phase but s21 mag only measurements. I didnt know and still dont know how much I need s21 phase -actually while playing with nanoVNA I used it, at least it is better to see it than not seeing it- but I just like the full idea of s-parameter measurements and VNAs, I think it has to be done all correctly anyway. I am still trying to understand how much it matters to have two path measurements so full s-parameters without reversing the DUT vs. one path measurements like with nanoVNA and any VNA like device lets say under 5K$.

Sometimes test boards of high frequency devices will include a second set of connectors which have just a through with the same length line minus the DUT.

I usually skip the isolation step in calibration.

Yes, I saw a few boards with a thru calibration on the PCB, definitely a great solution. Unfortunately the one I have does not have one.

Good to know your experience with isolation step. I also read in a few places that it is actually not recommended as a general step. I think only in certain cases it is beneficial, that is why probably it is optional, otherwise I think after doing a full 2-port calibration, it is not hard to just do one more step.
Title: Re: measuring freq response
Post by: ogden on March 06, 2021, 02:24:59 pm
Why at least simple DUTs not have different sex connectors? For example the board I have, it is a very simple opamp eval board, what is wrong to put different sex connectors ?

RF modules lay flat on a table only in the lab. In real-world equipment even small module like yours, it's SMA connector can't handle mechanical stress of direct attachment. So unless you are fixing bad design decisions, you usually have female SMA on modules to be used with male cable. Look into any hi-end VNA or SA and you will see exactly that (https://youtu.be/i2BU5sVgHvQ?t=1316).
Title: Re: measuring freq response
Post by: metebalci on March 06, 2021, 06:19:00 pm
Why at least simple DUTs not have different sex connectors? For example the board I have, it is a very simple opamp eval board, what is wrong to put different sex connectors ?

RF modules lay flat on a table only in the lab. In real-world equipment even small module like yours, it's SMA connector can't handle mechanical stress of direct attachment. So unless you are fixing bad design decisions, you usually have female SMA on modules to be used with male cable. Look into any hi-end VNA or SA and you will see exactly that (https://youtu.be/i2BU5sVgHvQ?t=1316).

Sure they are used in all kinds of environments. You mean a female connector can handle more stress than male connector ? For signal or electrical power, female is used for the driver/live contact and male is used for receiver right, for safety esp. for power. I understand that and in that sense it makes sense a VNA has female connectors on both ports since both can generate signal, but then for example why the RF input of SA or inputs of scope are always female connectors. I didnt get the reason behind this.
Title: Re: measuring freq response
Post by: metebalci on March 06, 2021, 06:44:15 pm
Coming back to my original question. So I just made a simple wideband (opamp is 1Ghz, no idea the limit of my build that is what I want to find) unity gain buffer on ground plane etc. I checked it up to 25Mhz with scope, it all looks OK. Now the question, what is the easiest way to analyze this with VNA ? or how should I create a simple but good enough fixture ? Is it the best (and only? proper) way to have SMA connectors also on the board or is there also another way -somehow connecting grabbers or sth like that to a cable terminated with SMA to connect VNA etc.- ? If SMA on PCB is the only way, do I need to worry about impedance matching if it is like 1-2cm away from the next node, up to 1GHz (my build is not going to survive that much anyway) ?
Title: Re: measuring freq response
Post by: rfclown on March 06, 2021, 07:05:05 pm

I still find this insertable/non-insertable DUT issue strange and funny. Why at least simple DUTs not have different sex connectors ? For example the board I have, it is a very simple opamp eval board, what is wrong to put different sex connectors ? Is there a electrical/mechanical reason to put female connectors always on the devices and male connectors on the cables ? I am actually thinking always to use different sex connectors on the eval boards I will make.

I am still not 100% sure what I need (in terms of s21 mag only or phase too). It is funny how I reach to this point. First, since I know about the Bode plots, and the scope has Bode plot function, I was looking that, but it is up to 25 Mhz, and it can be done different ways up to maybe 100 Mhz or so, but not more. I was wondering how they measure this like I saw on the datasheets. Then I saw spectrum analyzers with TG. I was actually considering to buy RS FPC1500 (actually bought than cancelled), which can do s11 mag/phase but s21 mag only measurements. I didnt know and still dont know how much I need s21 phase -actually while playing with nanoVNA I used it, at least it is better to see it than not seeing it- but I just like the full idea of s-parameter measurements and VNAs, I think it has to be done all correctly anyway. I am still trying to understand how much it matters to have two path measurements so full s-parameters without reversing the DUT vs. one path measurements like with nanoVNA and any VNA like device lets say under 5K$.
...

The usual case of having female connectors on the test boards is for convenience. We mostly use M-M cables. So we'll set up our VNA, or our signal generator and spectrum analyzer, and connect to the test board with M-M cables. For most cases, that's good enough. Most of the time we aren't interested in S21 phase. If I only want to see the gain response, I'll use the response cal function of my analyzer and not use a cal kit at all. (put input and output cables together (using F-F "bullet" if needed to cheat), hit response cal button, take measurement with DUT. Done.) I do the full 2 port cal only when I want to see the match to 50 ohms (return loss) or want to measure impedance (Zinput=50(1 S11)/(1-S11)).

I'm constantly throwing together small proto circuits. I usually put females on both sides, mainly because my pile of femaile SMA connectors is bigger than my male pile. I just grabbed a few boards sitting on top of my VNA (attached picture). The red one is something I got on eBay from a Greek seller to make test circuits. He sells a small array of boards with both male and femaile SMAs (VERY cheap connectors). The other two are things I threw together years ago. (none of which match my norm or both female SMAs). I bought the eBay boards to save time. I usually cut a blank board with an exacto, or highjak something from my scrap pile (like the other two boards in the photo).

If I didn't have a full two port analyzer, I could live with it. Turn the DUT around and make the other measurements. Most of the time, when I turn on my VNA, I want one of two things: S11 or gain (S21 magnitude). If it's only gain, I usually do a response cal. If I really need the two port S parameters of a device that's in the middle of a test board, it's work to get that. You have to de-embed from the fixture measurements.

VNAs are great, but they measure in a 50 ohm system. If your DUT isn't amenable to that, it might not be the right thing to use. If your DUT is 50 ohms in and out, you can see what you want right from the analyzer UI. If not, you have to put the S parameters into a simulator (like QUCS, HIGHLY recommened free tool) to see what you're looking for.
Title: Re: measuring freq response
Post by: rfclown on March 06, 2021, 07:55:53 pm
Coming back to my original question. So I just made a simple wideband (opamp is 1Ghz, no idea the limit of my build that is what I want to find) unity gain buffer on ground plane etc. I checked it up to 25Mhz with scope, it all looks OK. Now the question, what is the easiest way to analyze this with VNA ? or how should I create a simple but good enough fixture ? Is it the best (and only? proper) way to have SMA connectors also on the board or is there also another way -somehow connecting grabbers or sth like that to a cable terminated with SMA to connect VNA etc.- ? If SMA on PCB is the only way, do I need to worry about impedance matching if it is like 1-2cm away from the next node, up to 1GHz (my build is not going to survive that much anyway) ?

Easiest way is SMA connectors on the test board, and make 50 ohm microstrip lines to device. Online calculators can show you the width (a function of the dielectric constant and thickness). The reason it's the easiest is because your cal kit is probably SMA. If your cal kit was N, then the easiest would be N connectors on the board (big, heavy, yuck if you don't need it). Most cal kits are either SMA or N. (3.5mm mates with SMA, but is precision made and uses air dielectric).

Another way is pigtails. You calibrate to the end of two cables. Then put pigtails on the cables (SMA connector on one end, nothing on the other). Since the pigtails are 50 ohms, you can use the port extension (or electrical length, or whatever it's called on your VNA) to "dial out" the length of pigtail cables. They should then look like good open circuits on the VNA (a dot on the right hand side of the Smitch Chart when plotting S11 or S22). You have moved your reference plane to the end of the pigtails. Solder the pigtail ends to the points you want to measure. By dialing out the length, you have de-embeded the pigtails from the measurement mathematically in the VNA.

The thing to be careful of at high frequecies is keeping short ground and center coax connections to the board. It can be difficult. If using braided coax pigtails, the tendency is to make overly long connections which can throw off the results (it will be mostly adding a series inductance to the measurement). Doing it well can yield excellent results. I commonly do this to measure impedance of something on a PCB. One port cal, add pigtail, dial out length, break connection to point on PCB I want to measure, solder pigtail, measure S11, Z=50*(1+S11)/(1-S11).
Title: Re: measuring freq response
Post by: ogden on March 06, 2021, 08:19:23 pm
You mean a female connector can handle more stress than male connector?

No. I don't mean that. Direct connection of modules without cable in-between will mechanically stress SMA connection even in case of slightest flex of module mounts.

Quote
I understand that and in that sense it makes sense a VNA has female connectors on both ports since both can generate signal, but then for example why the RF input of SA or inputs of scope are always female connectors. I didnt get the reason behind this.

Male of female RF connectors have nothing to do with source or sink of the signal! Reason why female usually is on devices/modules - it is much easier to operate nut on the cable side than other way around. Isn't that obvious?
Title: Re: measuring freq response
Post by: metebalci on March 06, 2021, 08:25:15 pm
You mean a female connector can handle more stress than male connector?

No. I don't mean that. Direct connection of modules without cable in-between will mechanically stress SMA connection even in case of slightest flex of module mounts.

Quote
I understand that and in that sense it makes sense a VNA has female connectors on both ports since both can generate signal, but then for example why the RF input of SA or inputs of scope are always female connectors. I didnt get the reason behind this.

Male of female RF connectors have nothing to do with source or sink of the signal! Reason why female usually is on devices/modules - it is much easier to operate nut on the cable side than other way around. Isn't that obvious?

Not that obvious for someone having only a few BNCs  and no SMAs until recently. Thanks, that makes sense.
Title: Re: measuring freq response
Post by: metebalci on March 06, 2021, 08:53:31 pm
Easiest way is SMA connectors on the test board, and make 50 ohm microstrip lines to device. Online calculators can show you the width (a function of the dielectric constant and thickness). The reason it's the easiest is because your cal kit is probably SMA. If your cal kit was N, then the easiest would be N connectors on the board (big, heavy, yuck if you don't need it). Most cal kits are either SMA or N. (3.5mm mates with SMA, but is precision made and uses air dielectric).

Yes, I decided to standardize my setup to SMA, I think -not 100% sure- others like N, 3.5mm etc. are either high power, high precision or something like that and they seem to be bulky and/or expensive. I could have used BNC maybe since I dont expect to go beyond 2 Ghz at the moment but I see almost everything I look uses SMA so SMA is a go.

This is definitely way to go if I have PCBs manufactured but I think for prototyping it is a bit difficult maybe impossible at least for me to make a microstrip like this.

Another way is pigtails.

I didnt know it is called pigtail, thanks  :)

You calibrate to the end of two cables. Then put pigtails on the cables (SMA connector on one end, nothing on the other). Since the pigtails are 50 ohms, you can use the port extension (or electrical length, or whatever it's called on your VNA) to "dial out" the length of pigtail cables. They should then look like good open circuits on the VNA (a dot on the right hand side of the Smitch Chart when plotting S11 or S22). You have moved your reference plane to the end of the pigtails. Solder the pigtail ends to the points you want to measure. By dialing out the length, you have de-embeded the pigtails from the measurement mathematically in the VNA.

The thing to be careful of at high frequecies is keeping short ground and center coax connections to the board. It can be difficult. If using braided coax pigtails, the tendency is to make overly long connections which can throw off the results (it will be mostly adding a series inductance to the measurement). Doing it well can yield excellent results. I commonly do this to measure impedance of something on a PCB. One port cal, add pigtail, dial out length, break connection to point on PCB I want to measure, solder pigtail, measure S11, Z=50*(1+S11)/(1-S11).

I will try this.

I was just reading something from Agilent and there was a term I think it was connector match, meaning match from SMA connector to microstrip. I was also wondering this since I measure s11=-10dB@1Ghz and -5dB@2Ghz on the eval board. I dont know if this is normal or expected but it seems SMA to microstrip transition can be problematic. Is there a target figure for this ie there shouldnt be more than x amount of reflection there ? I guess pigtail has a benefit on this, since it is very direct.
Title: Re: measuring freq response
Post by: metebalci on March 06, 2021, 10:19:30 pm
You calibrate to the end of two cables. Then put pigtails on the cables (SMA connector on one end, nothing on the other). Since the pigtails are 50 ohms, you can use the port extension (or electrical length, or whatever it's called on your VNA) to "dial out" the length of pigtail cables. They should then look like good open circuits on the VNA (a dot on the right hand side of the Smitch Chart when plotting S11 or S22). You have moved your reference plane to the end of the pigtails. Solder the pigtail ends to the points you want to measure. By dialing out the length, you have de-embeded the pigtails from the measurement mathematically in the VNA.

The thing to be careful of at high frequecies is keeping short ground and center coax connections to the board. It can be difficult. If using braided coax pigtails, the tendency is to make overly long connections which can throw off the results (it will be mostly adding a series inductance to the measurement). Doing it well can yield excellent results. I commonly do this to measure impedance of something on a PCB. One port cal, add pigtail, dial out length, break connection to point on PCB I want to measure, solder pigtail, measure S11, Z=50*(1+S11)/(1-S11).

I will try this.

OK I tried it, and if I did this right, I am very impressed. I soldered the bare ends to the board and other ends is connected to other SMA cables which are connected to VNA ports. I did not have female-bare pigtails so I had to use two f-f adapters too. First it was not looking good, I realized I was measuring up to 2Ghz, so I decreased this to 500 Mhz and re-calibrated. s11 logmag looks even better to me than the eval board (but this is up to 500Mhz). I didnt understand yet why s11 phase starts from 180deg. It is a gain=1 buffer, so it should have s21=-6dB, opamp bandwidth is 1Ghz. On the datasheet it was mentioned there is an overshoot before cutoff, so I think s21 is increasing because of that. I also attached the board pic, all are mounted on a SOIC adapter board, opamp, input/output resistors, and decoupling caps. Grabbers are +5V and -5V supply. Does all look normal to you ? I was totally not expecting to measure this (almost flat response) up to 500 Mhz. I applied 1000ps electrical delay, I calculated this from the length of pigtails.
Title: Re: measuring freq response
Post by: tautech on March 06, 2021, 11:19:02 pm
 :)
There's that 15dB of gain you expected.
Title: Re: measuring freq response
Post by: rfclown on March 07, 2021, 03:50:55 am
OK I tried it, and if I did this right, I am very impressed. I soldered the bare ends to the board and other ends is connected to other SMA cables which are connected to VNA ports. I did not have female-bare pigtails so I had to use two f-f adapters too. First it was not looking good, I realized I was measuring up to 2Ghz, so I decreased this to 500 Mhz and re-calibrated. s11 logmag looks even better to me than the eval board (but this is up to 500Mhz). I didnt understand yet why s11 phase starts from 180deg. It is a gain=1 buffer, so it should have s21=-6dB, opamp bandwidth is 1Ghz. On the datasheet it was mentioned there is an overshoot before cutoff, so I think s21 is increasing because of that. I also attached the board pic, all are mounted on a SOIC adapter board, opamp, input/output resistors, and decoupling caps. Grabbers are +5V and -5V supply. Does all look normal to you ? I was totally not expecting to measure this (almost flat response) up to 500 Mhz. I applied 1000ps electrical delay, I calculated this from the length of pigtails.

Bravo! -30 dB input return loss is great.  :-+ This means that the reflected power is 1/1000 th of the input. When you have that, you don't care about the phase. You're really only interested in the phase of S11 if you are measuring the impedance. The OP amp has a high input impedance, so you are really only measuring that shunt 50 ohm input resistor (along with the extra wire lengths which I will get to next).

When you use the electrical delay function, it is TWICE the length of the cable (since it is a round trip delay). To illustrate I grabbed a pigtail and stripped the end similar to the one in your picture. Did a 1 port calibration to the end of a N-SMA adapter, then put the pigtail on the adatper. First picture shows a sweep to 1 GHz. The cable looks like a perfect open at low frequency, but traverses the outside edge of the Smith chart as the frequency goes higher. I can "dial out" the electrical legth of the cable with the delay function. I measured this pigtail to be 87mm, which for a velocity factor of 0.66 for the coax would give a delay of 439 psec. But I have to enter a delay of 836 psec to get the swept data to be a group of points clustered near the open point on the Smith chart (second picture). Why? Because the entered number is the round trip delay of the signal going to the end of the cable, then refecting back to the calibrated reference plane. At least that how the HP VNAs I use work (HP8753, E5071).

Now, about why your S21 data starts at -6dB at low frequencies, like you expect, but changes as you go higher. Looking at the same pigtail on the VNA, I sweep up to 8.5 GHz (third picture). What you are seeing is what that extra length of center conductor and ground braid look like. Not pretty. So your configuration is ok for lower frequencies, but if you want to measure what's really happening with your OP amp up to 1 GHz, you have to get rid of the "long" connections (at least to GHz signals). I know that those breakout PCBs are really handy, and you've done a good job with the placement of the supply bypass caps, but the long extension of the coax center, and the extra wire to the input (and same on the output) muddy things up. You are measuring what you have there. And like I say, it's great and fine at the lower frequencies.

I often start with a bare PCB. I'll use an exacto or dremel with a fine tip to cut pads, everything else is the ground plane. For this, it would only be +in, -in, +V, -V, out, and output resistor. Solder IC on pads. Solder input shunt resistor from +in pad to ground. This is where SMT really makes things easy, the part just bridges the gap of the pad cut. Cut pigtail center to as close as you can to the end; same for ground braid, short. Solder pigtail center and ground right at the IC input pad. Output resistor from IC out pad to resistor output pad. Solder output pigtail center right to that pad, and ground braid to ground right next to pad. Supply bypass caps from pads to ground.  Solder wires to +V and -V pads. The only thing left is the feedback connection. For your unity gain, I'd solder a wire as short as possible from out to -in. I'd just go over the top of the part. The idea is to keep all connections very short. If you do, it will be good to very high frequencies.
Title: Re: measuring freq response
Post by: rfclown on March 07, 2021, 04:25:37 am
This is definitely way to go if I have PCBs manufactured but I think for prototyping it is a bit difficult maybe impossible at least for me to make a microstrip like this.

Actually it isn't hard. Just cut straight lines with an exacto. Peel off copper strips (put some solder of the strip to remove and apply iron while pulling on metal, and it will peel off).

I was just reading something from Agilent and there was a term I think it was connector match, meaning match from SMA connector to microstrip. I was also wondering this since I measure s11=-10dB@1Ghz and -5dB@2Ghz on the eval board. I dont know if this is normal or expected but it seems SMA to microstrip transition can be problematic. Is there a target figure for this ie there shouldnt be more than x amount of reflection there ? I guess pigtail has a benefit on this, since it is very direct.

The launch isn't usually too much of an issue <= 2.4 GHz. The highest frequency circuits I've breadboaded are 5.8 GHz. At 5.8 GHz little things can bite you, but -10 dB S11 wouldn't be due to the connector unless it was a bad solder joint.

When you say you measure S11=-10 dB @ 1 GHz on the "eval board", is this the real TI eval board, or the board you show with pigtails in your picture? If it's from your picture, it's because that's the measurement of the "long" length from the center coax to the resistor plus the wire going to the OP amp. It isn't 50 ohms at high frequencies.
Title: Re: measuring freq response
Post by: tggzzz on March 07, 2021, 07:49:58 am
This is definitely way to go if I have PCBs manufactured but I think for prototyping it is a bit difficult maybe impossible at least for me to make a microstrip like this.

Actually it isn't hard. Just cut straight lines with an exacto. Peel off copper strips (put some solder of the strip to remove and apply iron while pulling on metal, and it will peel off)

You will probably want sharp edges for the microstrip lines, but for power and control it may be easier to use a spherical dremel to cut lines, e.g.
(https://entertaininghacks.files.wordpress.com/2020/07/ps-manhattan03-1.jpg)
(https://entertaininghacks.files.wordpress.com/2020/07/ps-manhattan04-1.jpg)

At high frequencies the glass fibre weave of FR4 can become visible.
Title: Re: measuring freq response
Post by: metebalci on March 07, 2021, 12:46:49 pm
Bravo! -30 dB input return loss is great.  :-+ This means that the reflected power is 1/1000 th of the input. When you have that, you don't care about the phase. You're really only interested in the phase of S11 if you are measuring the impedance. The OP amp has a high input impedance, so you are really only measuring that shunt 50 ohm input resistor (along with the extra wire lengths which I will get to next).

:) I was wondering what I should expect from s11 mag (more on this later regarding to TI eval board), so -30dB is a good one then.

When you use the electrical delay function, it is TWICE the length of the cable (since it is a round trip delay). To illustrate I grabbed a pigtail and stripped the end similar to the one in your picture. Did a 1 port calibration to the end of a N-SMA adapter, then put the pigtail on the adatper. First picture shows a sweep to 1 GHz. The cable looks like a perfect open at low frequency, but traverses the outside edge of the Smith chart as the frequency goes higher. I can "dial out" the electrical legth of the cable with the delay function. I measured this pigtail to be 87mm, which for a velocity factor of 0.66 for the coax would give a delay of 439 psec. But I have to enter a delay of 836 psec to get the swept data to be a group of points clustered near the open point on the Smith chart (second picture). Why? Because the entered number is the round trip delay of the signal going to the end of the cable, then refecting back to the calibrated reference plane. At least that how the HP VNAs I use work (HP8753, E5071).

:-+ Yes I learned a little bit about this in a previous experiment. I had s21 in my mind, so I actually calculated the delay from both pigtails (sum of both), and used that value directly since it is for s21. But the length of pigtails are almost same, so using the same value for s11 is not bad either.

Thanks a lot for measuring this and for the photos. I had no idea at 8.5Ghz how it would behave. The reason it is behaving good enough for 1GHz but not for 8.5Ghz, is it because the length of the imperfection we cause by using the bare end ? So the length of the bare end is OK for 1Ghz, but not for 8.5Ghz, too long for the wavelength@8.5 ?

Now, about why your S21 data starts at -6dB at low frequencies, like you expect, but changes as you go higher. Looking at the same pigtail on the VNA, I sweep up to 8.5 GHz (third picture). What you are seeing is what that extra length of center conductor and ground braid look like. Not pretty. So your configuration is ok for lower frequencies, but if you want to measure what's really happening with your OP amp up to 1 GHz, you have to get rid of the "long" connections (at least to GHz signals). I know that those breakout PCBs are really handy, and you've done a good job with the placement of the supply bypass caps, but the long extension of the coax center, and the extra wire to the input (and same on the output) muddy things up. You are measuring what you have there. And like I say, it's great and fine at the lower frequencies.

I think it is going to be a good 2nd attempt, trying to squeeze these things. I will try it next. By "long" connections, I guess you mean the bare part only, since the coax itself is fine, other than causing some delay.

I often start with a bare PCB. I'll use an exacto or dremel with a fine tip to cut pads, everything else is the ground plane. For this, it would only be +in, -in, +V, -V, out, and output resistor. Solder IC on pads. Solder input shunt resistor from +in pad to ground. This is where SMT really makes things easy, the part just bridges the gap of the pad cut. Cut pigtail center to as close as you can to the end; same for ground braid, short. Solder pigtail center and ground right at the IC input pad. Output resistor from IC out pad to resistor output pad. Solder output pigtail center right to that pad, and ground braid to ground right next to pad. Supply bypass caps from pads to ground.  Solder wires to +V and -V pads. The only thing left is the feedback connection. For your unity gain, I'd solder a wire as short as possible from out to -in. I'd just go over the top of the part. The idea is to keep all connections very short. If you do, it will be good to very high frequencies.

Just to give your context, this was my 2nd attempt on a ground plane, first time using SMD passive components and maybe 5th time using a SOIC part, so pretty new to small stuff. I played a bit with trying to cut bare PCB etc., I definitely need more practice on that. I wanted to minimize the number of potential places I can make mistake, since there are so many new things on this for me (using VNA, SMD parts, ground plane etc.), so I wanted to use an off the shelf adapter first, try the simplest possible circuit and asking every detail here.

About the feedback connection, this opamp has a FB pin (1) and it is just next to inverting input (2), very easy to make the connection for a simple buffer.
Title: Re: measuring freq response
Post by: metebalci on March 07, 2021, 01:17:15 pm
The launch isn't usually too much of an issue <= 2.4 GHz. The highest frequency circuits I've breadboaded are 5.8 GHz. At 5.8 GHz little things can bite you, but -10 dB S11 wouldn't be due to the connector unless it was a bad solder joint.

When you say you measure S11=-10 dB @ 1 GHz on the "eval board", is this the real TI eval board, or the board you show with pigtails in your picture? If it's from your picture, it's because that's the measurement of the "long" length from the center coax to the resistor plus the wire going to the OP amp. It isn't 50 ohms at high frequencies.

Good info again, thanks.

s11 = -10dB@1Ghz is the official TI eval board (THS4303EVM), it is a 20dB fixed gain opamp, and the eval board is really just that. I measured it again up to 2Ghz (opamp has bw=1.8Ghz), it is attached.
Title: Re: measuring freq response
Post by: rfclown on March 07, 2021, 09:20:01 pm
Looks like I was mistaken in thinking that the reason that the S11 became worse at high frequencies was mainly due to the extra "long" wire lengths. It is because the imput impedance of the part itself has that characteristic. At low frequencies the impedance is high enough that you are mainly measuring the shunt resistor, but at higher frequencies that isn't the case. See how the eval board has a 50 ohm microstrip right up to the input of the deviice. This is the best you can do. Same as if you could get your pigtail right up to the device. Turns out that this is what you get when you measure this device with a 50 ohm shunt resistor on the input.

The pictures that tggzzz shows are great examples of what you can do with bare PCB and dremel (or exacto). You see that you can mix and match SMT and leaded, whatever is most convenient for the connection. You'll find that SMT is usually the easier route. He shows another technique of having other small pieces of PCB as islands. You can also use the island approach to have a sub-circuits that can be changed later without re-doing the main board.
Title: Re: measuring freq response
Post by: tggzzz on March 07, 2021, 10:24:33 pm
The pictures that tggzzz shows are great examples of what you can do with bare PCB and dremel (or exacto). You see that you can mix and match SMT and leaded, whatever is most convenient for the connection. You'll find that SMT is usually the easier route. He shows another technique of having other small pieces of PCB as islands. You can also use the island approach to have a sub-circuits that can be changed later without re-doing the main board.

Glad you found them helpful.

Other old and new techniques shown here: https://entertaininghacks.wordpress.com/2020/07/22/prototyping-circuits-easy-cheap-fast-reliable-techniques/
Title: Re: measuring freq response
Post by: Kleinstein on March 07, 2021, 10:26:28 pm
The resistors R4 and R5 on the eval board look odd - a bit like grave stone orientation ?

It is normal to expect an increasing S11 with frequency, especially beyound the amplifiers BW. -10 dB is still not that bad.
Title: Re: measuring freq response
Post by: metebalci on March 07, 2021, 11:45:17 pm
Looks like I was mistaken in thinking that the reason that the S11 became worse at high frequencies was mainly due to the extra "long" wire lengths. It is because the imput impedance of the part itself has that characteristic. At low frequencies the impedance is high enough that you are mainly measuring the shunt resistor, but at higher frequencies that isn't the case. See how the eval board has a 50 ohm microstrip right up to the input of the deviice. This is the best you can do. Same as if you could get your pigtail right up to the device. Turns out that this is what you get when you measure this device with a 50 ohm shunt resistor on the input.

I think I should distinguish two cases, I have related but different questions for each:

1) TI eval board, TI CFB opamp. SMA input/output, microstrips to/from opamp. bw=1.8Ghz. gain=20dB. s11@1Ghz = -10dB. input impedance (datasheet) = 1.6Mohm // 1pF

Question for high s11, related to TI eval board: I tried to calculate the amount of reflection just using the numbers I have at hand (50 ohm source, 50 ohm shunt at opamp input, opamp input impedance). There is definitely be a reflection but I couldnt reach -10dB. Can someone calculate something close to this easily ? I am not questioning why input impedance is like this but it confuses me that 30% of input (-10dB?) is reflected at almost mid of bw. Is this normal ?

2) My build, AD VFB opamp. Pigtails. bw=1Ghz. gain=0dB. s11@500Ghz = -30dB. input resistance (datasheet) = 500Gohm, common mode capacitance = 1.3pF, differential mode = 0.1pF.

Question for your comment on the length of bare wire end of pigtail, related to my build: where would I see the effect of this bare length ? You showed an example for 8.5Ghz. So I guess this has a limit around that since there is a limit how short this can be. Do you mean above I probably will see the effect of input impedance of the device much sooner so the effect of pigtail is going to be negligible ?

Title: Re: measuring freq response
Post by: metebalci on March 07, 2021, 11:46:53 pm
Other old and new techniques shown here: https://entertaininghacks.wordpress.com/2020/07/22/prototyping-circuits-easy-cheap-fast-reliable-techniques/

Thanks for the link!
Title: Re: measuring freq response
Post by: rfclown on March 08, 2021, 04:01:55 am

I think I should distinguish two cases, I have related but different questions for each:

1) TI eval board, TI CFB opamp. SMA input/output, microstrips to/from opamp. bw=1.8Ghz. gain=20dB. s11@1Ghz = -10dB. input impedance (datasheet) = 1.6Mohm // 1pF

Question for high s11, related to TI eval board: I tried to calculate the amount of reflection just using the numbers I have at hand (50 ohm source, 50 ohm shunt at opamp input, opamp input impedance). There is definitely be a reflection but I couldnt reach -10dB. Can someone calculate something close to this easily ? I am not questioning why input impedance is like this but it confuses me that 30% of input (-10dB?) is reflected at almost mid of bw. Is this normal ?

2) My build, AD VFB opamp. Pigtails. bw=1Ghz. gain=0dB. s11@500Ghz = -30dB. input resistance (datasheet) = 500Gohm, common mode capacitance = 1.3pF, differential mode = 0.1pF.

Question for your comment on the length of bare wire end of pigtail, related to my build: where would I see the effect of this bare length ? You showed an example for 8.5Ghz. So I guess this has a limit around that since there is a limit how short this can be. Do you mean above I probably will see the effect of input impedance of the device much sooner so the effect of pigtail is going to be negligible ?

For the TI part, if I start with 1.6M//1pF then add a 50 ohms shunt, I calculate S11=-16 dB at 1 GHz. See TI.jpg.

For your part, if I start with 1.3pF shunt then add a 50 ohms shunt, I get the results shown in noL.jpg. If I add 2nH for both the coax center wire length and also for the wire up to the IC, I get the results shown in withL.jpg.

There is a free simulator that will do S parameter simulations (amoung other things) called QUCS. It is similar to Keysight's ADS. At my present job we only have one ADS license for several engineers. I often use QUCS just so I don't have to share the dongle.
Title: Re: measuring freq response
Post by: metebalci on March 08, 2021, 09:23:48 pm
For the TI part, if I start with 1.6M//1pF then add a 50 ohms shunt, I calculate S11=-16 dB at 1 GHz. See TI.jpg.

For your part, if I start with 1.3pF shunt then add a 50 ohms shunt, I get the results shown in noL.jpg. If I add 2nH for both the coax center wire length and also for the wire up to the IC, I get the results shown in withL.jpg.

There is a free simulator that will do S parameter simulations (amoung other things) called QUCS. It is similar to Keysight's ADS. At my present job we only have one ADS license for several engineers. I often use QUCS just so I don't have to share the dongle.

Thank you, I should have done this on SPICE instead of on paper. I downloaded QUCS, I will check.

I was wondering if the input impedance is such a limitation how such things work even at higher frequencies, then I saw a "proper" RF opamp, it says in/out is 50 ohms, so it seems like they are built like this not like the opamps I am using.

I have a basic (might be a stupid) question, maybe you and others were already saying this but I didnt get it. Lets take the TI amp above as example. I use it because I want 20dB (ok 14dB considering the output resistor) up to 1.8Ghz cutoff. Then there is -10dB reflection at 1Ghz. So only 90% of what I give reaches the opamp. Maybe the reflections go back and forth or not, I am not sure, but doesnt it mean the effective freq. response (of the opamp) is actually different now, and there is nothing I can do about it ? Can this be at least one of the reasons I am measuring the freq. response different than what is given in the datasheet ?

In other words, s21=b2/a1, if b1=0 then s21 should be as same as opamp's freq. response, but if b1>0 then b2'=gain*a1' where a1' < a1, so b2' < b2 also, and now measured s21'=b2'/a1 and s21' < s21. Is this one of the reasons whatever I measure as s21, when b1 > 0, will be smaller than the actual gain of the DUT ?
Title: Re: measuring freq response
Post by: rfclown on March 09, 2021, 01:13:04 am
Instead of answering your question directly, I'll take a step back. What is it that you are trying to do? (What is this circuit for?)

One of the issues here is that we are measuring in a 50 ohm system. If I was looking for a 20dB amplifier in a 50 ohm system, I wouldn't use an OP amp. I'd use a 50 ohm gain block ampliier. I'd go for instance to MiniCircuits. Go to their web page, look up gain block amplifiers, and in the search criteria select: SMT, Gain Block, F High 2000 MHz, Gain (dB) typ 20 dB. You'll be presented with 7 results. Biggest next question is max output (P1dB (dBm) typ). What do you need? In RF circuits, when some gain is needed, this type of amplifier is often used. You can get them in all kinds of frequency ranges and output powers.

With a gain block amplifier, it will work just like the datasheet says with 50 ohms in and out. It will need mainly a DC block in and out, and an RF choke (RFC) for the supply on the output. Done. On to the next part of the system.

If I was looking for something for a different application, say a video amplifier, I'd search for video amplifiers (this isn't something I've dealt with, so I would just have to look). After finding a component for the application, study the datasheets and app notes.
Title: Re: measuring freq response
Post by: metebalci on March 09, 2021, 07:47:57 am

(I forgot I posted this on test equipment board and it started to be more related to other boards, sorry for that)

My bad, I should have been more clear on the reason I am asking it that way. The actual application, amplifiers etc., was not my intention.

I would like to characterize a component or a simple circuit (for the sake of this post, I mean any two-port network actually). It can be a filter or an amplifier or something else. By characterize, I mean s11 and s21 (also s22 and s21 but I consider it can be done anyway by reversing it). I say in terms of s-parameters, because I realized (in the lifetime of this post) they give me what I was asking as freq. response etc. in the beginning. The DUT is like a gray box to me, I know a bit about it, but not everything. I probably have a SPICE simulation of it, but now I would like to see how well it actually matches to the simulation.

It is not 100% clear to me the transition between the methods to analyze non-RF (electrically short) and RF circuits. For example, in a SPICE simulation, I would just do an AC sweep without thinking about 50-ohms, reflections etc. Yes I still have to consider the input/output impedances and loading etc., but nothing like reflections. I think I am getting there, maybe around 50%-75%, but not 100% yet.

Not really asking anything here, I think I just need to study and experiment a little bit more to fill the gaps.
Title: Re: measuring freq response
Post by: gf on March 09, 2021, 10:29:39 am
Once you add transmission lines to the circuit, the spice simulation has to deal with reflexions as well. At microwave frequencies, simple lumped element models may no longer approximate the reality with sufficient accuracy, for instance every centimeter of wire connecting adjacent componets may no longer be negligible, but may need to be modeled as (possibly lossy and unmatched) transmission line between the components.

Measurement becomes difficult too. How would you create an almost ideal voltage or current source at several GHz? And how would you measure a no-load output voltage of the DUT at several GHz? It's simply impossible at high frequencies. Measuring S-parameters is quite doable up to many GHz, OTOH. If you want a Bode plot for a source and load of your choice, you can still calculate it from the measured S-parameters.

Spice may internally approximate a TL with lumped elements, too, but depending on the TL length and frequency of interest, this is not a single L/R/C/G then, but rather as sequence of many such elements (maybe tens or even hundrets).
Title: Re: measuring freq response
Post by: virtualparticles on March 09, 2021, 10:08:09 pm
Yep a NanoVNA is the cheapest way to do it.

A NanoVNA is indeed the cheapest way to do this but the phase measurement will not be accurate. The supplied calibration kit does not include the delays and the thru return loss is only about 15 dB. This means there will be an unknowable phase offset at any given frequency and Return loss will be accurate from about 0 dB down to -5 dB for +/- 3.3 dB accuracy. For any kind of accuracy, the NanoVNA is quite awful but it will give you a relative idea of what you're looking at.

Cheers,

Brian
Title: Re: measuring freq response
Post by: rfclown on March 10, 2021, 12:50:05 am
A NanoVNA is indeed the cheapest way to do this but the phase measurement will not be accurate. The supplied calibration kit does not include the delays and the thru return loss is only about 15 dB. This means there will be an unknowable phase offset at any given frequency and Return loss will be accurate from about 0 dB down to -5 dB for +/- 3.3 dB accuracy. For any kind of accuracy, the NanoVNA is quite awful but it will give you a relative idea of what you're looking at.

Cheers,

Brian

I guess I need to get one of these things to play with, but it's hard to imagine that it would be that bad. A thru cal is done by connecting mating connectors together. I see the nanaVNA has two female SMA connectors. So you attach a M-M SMA cable to one connector. The two ports you connect your DUT to are then the the end of the cable, and the other connector on the nanoVNA. When you do the thru, you connect the cable to the other port. If you cheat by putting a SMA bullet between two cables for the thru cal, your measurements still shouldn't be that bad (except for a delay offset). Unless you have broken cables. An SMA bullet itself will have a return loss better than -30 dB. The only thing that would throw things so far off is if the VNA's second port was not 50 ohms and the cal procedure is assuming it is. If that's the case, you could put an attenuator on the second port. That would cut your dynamic range, but give you accurate measurements.

ok. I just ordered a NanoVNA V2 S-A-A-2 from Nooelec. I'll see what it's good for.
Title: Re: measuring freq response
Post by: virtualparticles on March 10, 2021, 03:58:17 pm
A NanoVNA is indeed the cheapest way to do this but the phase measurement will not be accurate. The supplied calibration kit does not include the delays and the thru return loss is only about 15 dB. This means there will be an unknowable phase offset at any given frequency and Return loss will be accurate from about 0 dB down to -5 dB for +/- 3.3 dB accuracy. For any kind of accuracy, the NanoVNA is quite awful but it will give you a relative idea of what you're looking at.

Cheers,

Brian

I guess I need to get one of these things to play with, but it's hard to imagine that it would be that bad. A thru cal is done by connecting mating connectors together. I see the nanaVNA has two female SMA connectors. So you attach a M-M SMA cable to one connector. The two ports you connect your DUT to are then the the end of the cable, and the other connector on the nanoVNA. When you do the thru, you connect the cable to the other port. If you cheat by putting a SMA bullet between two cables for the thru cal, your measurements still shouldn't be that bad (except for a delay offset). Unless you have broken cables. An SMA bullet itself will have a return loss better than -30 dB. The only thing that would throw things so far off is if the VNA's second port was not 50 ohms and the cal procedure is assuming it is. If that's the case, you could put an attenuator on the second port. That would cut your dynamic range, but give you accurate measurements.

There are a number of factors which go into determining the accuracy of a VNA measurement. The +/- 3.3 dB accuracy for S11 measurements is quite real.

For S21 measurements, teh uncertainty is given by:

Delta-S21 = T + M + I + R

T is the residual transmission tracking error (dB)

(Residual means what's still there after calibration)

M is the error term due to mismatch (dB)

I is the error term due to isolation or crosstalk between ports 1 and 2 (dB)

and R represents random contributions (dB)

Isolation is the worst offender and is pretty awful on the Nano

Transmission Tracking is the next biggest contributor and is approximately equal to:

T = Mu1*M2 + Mu2 * M1

Where Mu1 is raw port 1 match, M2 is residual port 2 match (equal to raw match since Port 2 is not calibrated), Mu2 is the raw Port 2 match (Probably 15 dB at best) and M1 is the residual Port 1 match which can be no better than the calibration load which is 15 dB at best.

0.1778 * 0.1778 + 0.1778 * 0.1778 = 0.0632

T = 20Log(1-0.0632) = -0.567 dB

So about +/- 0.6 dB for S21 measurements until you approach the noise floor

The S21 reading will degrade rapidly as you read lower values due to the random contribution of the noise floor using Raleigh statistics.

The attached power point goes over this in a bit more detail.