header yl3akb

 navigation       SATURS
Portable, full 2-port 6 GHz VNA

30.09.2018:

This is the summary of my Vector Network Analyser (VNA) project which is finally in the condition like it was planned at the beginning - portable, standalone 2-port vector network analyser which covers frequencies from 1 MHz up to 6 GHz. Even though I have access to commercial VNAs, main motivation for doing this was personal learning of electronics, which in addition would result in useful instrument and I must say, I have not seen VNA device with similar combination of features, form-factor and cost yet.

Fig. 1. Portable, full 2-port 6 GHz VNA.

Here are the main features of this VNA project:

  • Frequency range: 1 MHz to 6 GHz

  • Full two-port VNA: both ports can function as transmitter and receiver which allows to measure all four S-parameters without physically switching the DUT

  • Above capability allows the implementation of standard VNA calibration procedures. Currently implemented procedures are 1-port OSL, 2-Port OSLT, 2-Port LMR16 and Transmission normalization for S21/S12. Industry standard models of calibration standards (separately for male and female connectors) are supported

  • Due to architecture of this VNA, only one S-parameter can be measured at the time. Separate 1-Port and 2-Port modes are implemented. In 1-Port mode only S11 or S22 is measured which allows for faster trace update. In 2-port mode trace is updated after all 4 parameters are measured successively

  • Currently two traces can be displayed simultaneously which can be set to combination any of four S-parameters and different data representations which includes: Log magnitude, Linear reflection coefficient, Impedance, VSWR, Phase, Group Delay. Trace display range and Ref. level can be changed for all formats

  • Time Domain(TD) function is available in 1-Port mode. Implemented TD modes: Band-Pass impulse, Low-Pass impulse ans Low-Pass step. It is possible to zoom and interpolate data in time axis for increased resolution

  • Smith chart display is available which can be displayed simultaneously with Cartesian traces

  • Two scrollable trace markers are available which includes 'Delta' function as well

  • User can save data to Micro-SD card. Available data formats are BMP screen-shots, S-parameters (S1P or S2P files) and OSLT calibration coefficients. SD card also contains description of calibration standard model coefficients.

  • Internal ('factory') calibration allows to do quick 1-Port/2-Port measurements without mechanical calibration

  • Zero span option allows to use VNA as simple signal generator (unfiltered and level uncalibrated). On-board step attenuator allows to change signal power in range of 31.75 dB with steps of 0.25 dB

  • All main settings, when changed, are automatically saved in on-board EEPROM

  • VNA is powered from single 3200 mA Li-Po cell or +5 to +12Vdc wall adapter and includes circuit for automatic battery charging. Approximate battery life ranges from 3 to 4 hours depending on measurement mode (on 1-Port mode one channel can be powered off). Current consumption is operational mode is ranges from 600 to 700 mA, but in sleep/power off mode less is than 100 uA

Fig. 2. Block diagram of VNA.


Fig. 3. Analog/RF module (left) and control/PSU board (right).

A little bit about architecture. While it is not the best architecture in the world - for example there are potential issues with port match differing at different Transmit-Receive (TR) switch positions, it is straight-forward and cost effective to implement. About signal generator part - although there are many different methods to generate both high and low frequencies, I chose the 'lazy' method and used separate PLLs for 'Low' (1 to 25 MHz) and 'High' (25 to 6000 MHz) frequency ranges. 'Low' range PLL is based on popular SI5351A, which is cheap and can generate multiple frequencies simultaneously which is exploited for second LO in this case. 'High' range is generated by MAX2871 which is cheapest PLL chip currently available, with built-in VCO and such wide frequency range. Nothing is filtered, because of non-zero IF frequencies (harmonics do not mix/alias to the same IF) and narrowband detection method. There is a small issue with harmonics of 'Low' band frequencies coinciding with second IF, but it is solved in software by appropriately shifting second LO when necessary.

Front-end of VNA is based on classic resistive bridge circuit, which allows to obtain wide frequency range, including low frequencies and compact form factor. I am aware of high performance solutions published like [1], but physical size of most of these solutions is too large for small portable VNA. Initially I planned to employ differential inputs of the LTC5510 mixers for direct connection to bridge differential coupled output like described in [2], but unfortunately during initial prototyping I found that reflection tracking and port match in such case has unacceptable performance dip (very poor tracking and port match) near 2 GHz region. It was solved only with inserting common mode choke between mixer and bridge. Here I have used low cost Pulse CX2156NL 1:1 transformer as choke even though it is specified only up to 2.7 GHz. It is clear that CX2156NL is not optimum choice in this case which is also evident in raw performance results (see next section), but currently I will rely on calibration and leave more optimum solution for future revisions. Solution with separate front-end mixers also has potentially lower leakage in comparison if receive channel switching were carried out at RF. It also reduces port match modulation when switching between port 1 and port 2 measurements.

Fig. 4. Front-end schematic and layout (only single channel is shown).


Raw performance

Good indication of raw VNA performance is error coefficients resulting from calibration procedure. Here I show amplitudes of reflection tracking (frequency response, e10_e01 & e23_e32), port match (e11 & e22) and directivity (e00 & e33) obtained with OSL calibration (see [3] for more info). About 8 dB reduction of tracking above 3 GHz is evident which may be explained with out-of-spec usage of CX2156NL transformer. Although overall results are quite average, they are consistent and without major performance dips. That concluded, usage without vector calibration would not be possible with current solution, but it would be done anyway.

Fig. 5. Single port error coefficients of port 1 (left) and port 2 (right).

This being 2-port VNA, very important parameter is leakage between the ports which directly limits the dynamic range. Leakage can be directly evaluated by looking at OSLT error coefficients e30 and e03 (see [3],[4] for more info). Transmission tracking errors e10_e32 and e23_01, obtained during 'Through' measurement, are also shown to better appreciate dynamic range. Here I approximate that dynamic range without leakage correction (for DUTs with no gain) is defined as log differences: e10_e32-e30 and e23_01-e03. Up to 2..3 GHz dynamic range at low-level side is limited by measurement noise floor (combination of ADC resolution, IF bandwidth, averaging) - approx. -4-(-80) = 76 dB range is obtained in case of 4x averaging and IF bandwidth of ~5 KHz (Fs = 5.2 MHz, Lfft = 1024). Above the ~2 GHz, leakage starts to dominate, which is very hard to avoid in case of closely spaced, single-board layout. But still, dynamic range better than 60 dB up to 3 Ghz and ~50 dB up to 6 GHz is obtained, which is also verified during calibrated measurements (See later).

Fig. 6. Transmission tracking errors for paths: S21 or e10_e32 (left) and S12 or e23_e01 (right).

Fig. 7. Leakage error terms for paths: S21 or e30 (left) and S12 or e03 (right) obtained with both ports terminated with 50 ohms. RBW~ 5 KHz and 4x averaging is applied.


User interface

Graphical user interface is based on STemWin library which is provided free for STM32 microcontrollers. Although I had option to use touch screen, with such small screen (3.2 inch, 320x240px) and cheap resistive touch panel, it would be pain to operate in my opinion so instead dedicated rotary encoder with push-switch and three push-buttons were used. Controls change function based on current menu - although it sounds complicated to operate the device with such small amount of buttons, after a getting a little accustomed, everything can be done very quick and easy.

Fig. 8. Available menus.


Calibration

Currently there are 4 calibration procedures implemented: 1-port OSL (based on [3]), 2-Port OSLT (based on [3],[4]), 2-Port LMR16 (based on [5]) and simple transmission normalization for S21/S12. In 1-port/OSL mode it is possible to apply port extension delay. Both OSLT and LMR16 methods includes option to calibrate leakage - in LMR16 case, even though this is the most time consuming procedure when used fully, when leakage option is turned off, only single Match and Through standard is required, resulting in relatively quick calibration, when full accuracy is not required. Calibration standards uses Agilent style model definitions described in [6]. Separate definitions are used for male and female standards and must be selected before doing calibration. Definitions are read from file on SD-card - example contents of which are shown here. These are the definitions for my standards - some of them are home-made and some of them are ordered from sdr-kits.net. Some parameters, especially for male standards are obtained by trial-and-error and/or guessed:

#Open (o): delay(ps) Z0(ohms) loss(GOhm/s) C0(e-15F) C1(e-27F) C2(e-36F) C3(e-45F)
#Short(s): delay(ps) Z0(ohms) loss(GOhm/s) L0(e-12H) L1(e-24H) L2(e-33H) L3(e-42H)
#Load (l): Z0(ohms) delay(ps) Zline(ohms) line_loss(GOhm/s) Cp(e-15F)
#Thru (t): delay(ps), Z0(ohms), loss(GOhm/s)
#Genders are for standard, not VNA port
#All delays are one-way
#
#SMA female:
fo 42.35 50 3.5 0.0 0.0 0.0 0.0
fs 26.92 50 3.5 0.0 0.0 0.0 0.0
fl 50.0 0.0 50 0.0 2.0
ft 42.43 50 3.5
#
#SMA male:
mo 41.0 50 3.5 60.0 0.0 0.0 0.0
ms 48.0 50 3.5 0.0 0.0 0.0 0.0
ml 50.0 0.0 50 0.0 1e-3
mt 62.0 50 1.439

Fig. 9. Calibration standards.

Of course, I still need to verify these standards against more accurate ones, because currently even after full calibration I get small systematic ripple at higher frequencies (above ~3 GHz) which I suspect is caused by inaccurate standard definitions.

Additionally, there is interesting mode implemented called 'T-Check', see: [7], which allows to directly evaluate 2-port calibration accuracy with help of 'T' adapter + 50 ohm parallel termination.

Fig. 10. Menus for calibration procedures.


Measurement examples

Lets look at some practical measurement examples. First example is home made L-band microstrip hairpin band-pass filter. OSLT calibration procedure with female standards were used with no leakage option and no averaging.

Fig. 10. This is how process of 2-port measurement looks like.

Fig. 11. Hairpin filter measurement results. Standalone VNA screenshot and plot of exported S parameters.

Here are the results of simple lumped 700 MHz low pass filter. It is surprising how degraded the response can get at higher frequencies due to parasitic effects of components

Fig. 12. Lumped element low pass filter.

Fig. 13. Standalone VNA screenshot and plot of exported S parameters.

Next some measurements of commercial components. OSLT and LMR16 calibration procedures are compared. In case of OSLT, female standards were used, but in case of LMR16 male standards were used - there is small difference in S11/S22 visible, which can be explained with SMA-SMA adapter used, which was not included in LMR16 calibration. Leakage calibration was carried out only in case of LMR16. It can be noticed that OSLT gives best results at low frequencies but at higher frequencies inaccuracies of calibration standards and leakage starts to become significant. LMR16 gives little more 'ripply' response even at low frequencies (it could again be cal standard model error - 'through' standard as known and unequal 'match' standards were used), but at higher frequencies it wins over the OSLT due to much better leakage handling.

Fig. 14. Measurement of MiniCircuits VAT-6+ 6 dB attenuator. Left - OSLT, Right - LMR16 calibration.

Fig. 15. Measurement of MiniCircuits VAT-30+ 30 dB attenuator. Left - OSLT, Right - LMR16 calibration.

Fig. 16. Measurement of MiniCircuits VLF-1800+ low pass filter. Left - OSLT, Right - LMR16 calibration.

Fig. 17. Measurement of MiniCircuits VBF-2360+ band pass filter. Left - OSLT, Right - LMR16 calibration.

Due to internal variable attenuator, it is possible to reduce generator signal level and measure active devices. For linear operation due to dynamic range of VNA receivers, input power (approx. generator output power, about -5dBm + gain of DUT) must not exceed ~+10 dBm. Here is the example of ~20 dB UHF amplifier based on MiniCircuits PGA-103+:

Fig. 18. Measurement of active device - amplifier.

Fig. 19. Standalone VNA screenshot and plot of exported S parameters.

Next to some 1-port measurement examples. Smith chart is enabled, which is optional of course. Even in case of 1-port (only 3 errors!), ripple in measurements is visible. Following picture shows measurement of open ended 6 dB attenuator. Trace should be smooth and no 'curls' in Smith chart should be visible.

Fig. 20. 1-Port measurement of open-ended 6 dB attenuator.

I believe that ripple is caused by inaccurate definitions of cal. standards, not VNA stability and repeatability. For example, following graphs shows measurement of standards used in OSL calibration - ideal, smooth response is obtained, as expected, so I conclude that measurements are repeatable and can be improved with better models of standards.

Fig. 21. Measurement of Open (left), Short (middle) and Load (right) standards used in OSL calibration. Nearly ideal response is obtained as expected (ignore calibration glitch at low frequency)

Here are some more 1-port measurement examples:

Fig. 22. Measurement of 100 pF 0603 SMD capacitor (left) and 100 nH 0402 SMD inductor (right). Components are soldered directly on female SMA connector

Fig. 23. Measurement of dual band (advertised as 144 MHz & 434 MHz) monopole antenna held in hand (left) and ~4 cm long coaxial cable with open end (right).

As last example 1-Port time domain function is demonstrated. This function is still in 'beta' stage, but it can already provide some good and interesting measurements. To demonstrate Low-Pass step mode which is most interesting, I made composite line from three coaxial cables of different characteristic impedance - RG-58 (50 ohm) + RG-180 (95 ohm) + RG-59 (75 ohm):

Fig. 24. Coaxial cable assembly for Time domain Low-pass mode test.

Fig. 25. Step response of cable assembly: 50 ohm + 95 ohm + 75 ohm + open. At marker M1 there is impedance step from 50 ohm to 95 ohm, next small down-going step represents transition from 95 ohm to 75 ohm, marker M2 is at open position. Blue trace is impulse response (log format).

Next pictures further demonstrates step response mode and its capability do show different loads along the transmission line:

Fig. 26. Step response of ~75 cm long coaxial cable with open end (left) and shorted end (right).

Fig. 27. Step response of ~75 cm long coaxial cable with 100 pF capacitor at the end (left) and 100 nH inductor at the end (right). Expected response is obtained in both cases - in case of capacitive load, at initial time moment it behaves as short and later as open, hence negative-going and then increasing response. Opposite is true for inductor.


Conclusions

Although not the most accurate and by no means replacement to commercial 2-port VNA, interesting and useful instrument is developed, which I actually use from time to time as compact, portable 'RF multimeter' for quick measurements. But most important benefit of this project for me is valuable practical and theoretical knowledge and improvement of skills in lot of branches of electronics obtained in the process of building such device. And its fun, of course! Regarding to next steps - It is clear that measurement accuracy can be improved with better calibration standards - I hope to get my hands on commercial SMA calibration kit in the near future to compare the results. Also, I can still think of a lot of improvements in hardware and software of this VNA, so I say again - to be continued...


TODO list & Known issues

  • Better bridge solution with wider band transformers needs to be implemented to improve raw performance above ~3 GHz.

  • Leakage above 3 GHz may be reduced with better layout.

  • Solution with receive IF switch (RX1/2 switch, see Fig.2) has potential issue in case of very reflective DUTs - when, for example, P2 is terminated and S21 is measured, small change in abs value of S21 is observed when P1 is open or terminated. In other words, good isolation of that switch is very important. This issue would affect performance at all frequencies, which is not observed, so I conclude that the issue is not that critical, but still it should be taken in to consideration in the future.

  • Power supply load switch for SD-card must be added because SD-card draws a few mA even if not used. Currently I remove the card when turning off the VNA to increase battery life.

  • USB port connected to STM32 USB pins is available which is not tested much (few tests with bootloader and CSD class, thats all). One useful feature would be USB SD-card reader, which would allow to export the data without removing the SD-card.


Files

  • RF module schematic: here
  • Control/PSU module schematic: here
  • RF module DipTrace project files: here
  • Control/PSU module DipTrace project files: here
  • Source code: on request


Literature
  1. N. Drobotun, P. Mikheev, A 300khz-13.5ghz directional bridge (2015), DOI: 10.1109/EuMC.2015.7345756
  2. G. Colman, J. Bauwelinck, J. Vandewege, DC-coupled directional bridge front-end for vector network analyzer receiver in GHz-range (2011), EICE Electronics Express 8(11):814-818, DOI: 10.1587/elex.8.814
  3. D. Rytting, An Analysis of Vector Measurement Accuracy Enhancement Techniques, Available: here
  4. D. Rytting, Network Analyzer Error Models and Calibration Methods, Available: here
  5. K. Silvonen, LMR 16-a self-calibration procedure for a leaky network analyzer (1997), IEEE Transactions on Microwave Theory and Techniques (Volume: 45, Issue: 7, Jul 1997), DOI: 10.1109/22.598439
  6. Agilent, Product Note 8510-5B: Agilent Specifying Calibration Standards for the Agilent 8510 Network Analyzer, Available: here
  7. R&S, Application Note 1EZ43_0E: T-Check Accuracy Test for Vector Network Analyzers utilizing a Tee-junction, Available: here