An Arduino Based Vector Network Analyser


My first opportunity to experience first-hand the advantages of owning a network analyser  was when Charlie, M0PZT kindly brought his MFJ-259 Analyser over and we took a look at a Magnetic Loop antenna that I’d constructed. It was suddenly so very easy to see the tuning (frequency) range and SWR / Resistance measurements. As a result of this I started to look at the various “Analysers” that were on the market and it soon became clear that there were so many different options available and you could spend a lot of money if you bought an “off the shelf” unit.

The quandary I had was that my main interests are in the VHF-and-up bands, I wanted all the bells and whistles that an analyser could offer including the ability to do transmission line measurements etc. it needed to be portable (i.e. work without a PC) but also be able to produce all the fancy graphs when needed. Oh yes, and I didn’t want to spend a lot of money 🙂 The result of all of this was that I did spend my radio funds, but on VHF and above kit, and just kept looking for the ideal analyser… needless to say I couldn’t find anything, but things changed a few months back when I learnt about F4GOH’s VnArduino project.

Having read the write-up on the VnArduino I decided that it seemed to offer what I wanted, certainly in functionality, albeit its upper frequency limit is ~60MHz. Boards were available on eBay and the write-up suggested it would cost somewhere in the region of £60.00 to build. Like a lot of projects this figure invariably varies depending on the size and quality of your “junk / spares” box. 🙂

The various parts were all readily available, but like most things, if you’re willing to do your research and perhaps do a group buy, savings can be made. The parts were sourced over a period of several weeks and once construction was started everything went together quite quickly. It’s a fairly straightforward build, if you’re comfortable working with SMDs. In saying that, my unit didn’t quite work as it should first time.

There were three issues, but all fairly minor:

  1. The LCD display wasn’t working correctly. This was the first project that I had built using the I2C interface and it turned out that the LCD module I had purchased needed a change to the Arduino sketch (software) to make it work. The software expected an address of 0x27 which agreed with the seller’s description, but the display was actually 0x3F   The LCD config line needed changing to: LiquidCrystal_I2C lcd(0x3F, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE);
  2. Nothing happened when turning the rotary encoder. The one I used was faulty! Fortunately I had a second one (from the same supplier) and swapping them over fixed that problem.
  3. When scrolling through the menus each rotary encoder detent results in a jump of two options in the menu! To move just one step you need to turn the knob very slightly until the menu option changes. I changed the rotary encoder to a better quality device from a different manufacturer and found that the menu problem was fixed but the frequency would only change in one direction, you could increase the frequency but not come back down in frequency. I’ve been told that this is most likely due to bounce and more filtering is needed. For now I’ve swapped back and everything works fine apart from the slight double-hop quirk.

Here’s a photo of the partially completed board:

vnarduino_000

The most tricky part (for me) was fitting the AD8302, this has 14 closely spaced legs that need soldering in place. Once that’s done the rest is plain sailing 🙂 I chose to fit the hardest part first, certainly before assembling any of the parts on the top of the board.

I decided to house the various parts in what has become my standard enclosure for most of my projects… an Eddystone die-cast box.

vnarduino_012

I added three additional switches, one toggle and two momentary push-to-make button switches. The toggle switch is to turn the unit off when powered from an external battery source and the push buttons are to reset the Arduino and select the menu option (wired in parallel to the rotary encoder switch.)

Here’s the final unit in operation:

vnarduino_015

The VnArduino works really well in stand-alone mode. I simply power the unit from a low-cost USB power pack that’s normally used for recharging mobile phones etc. The Arduino software has a fairly intuitive menu that is navigated using the rotary and push switch functions of the rotary encoder. The standard amateur bands between 1 – 60MHz are predefined in the software and it’s very easy to check how an antenna performs on a particular band.

Where things get very interesting and the analyser becomes an even better tool is when it is used with a PC that is running the DL2SBA vna/J software. This software allows you to do so many more things and presents the results in graphical format that can be exported in various different file formats, e.g. PDF, CSV etc.

The following photos show some of the results obtained when checking my W3DZZ dipole and home made  MagLoop antennas:

g4hsk_80m_sweep_of_w3dzz

3 – 4MHz sweep of W3DZZ trapped dipole

VNA_Magnetic_Loop_10M_Sweep_a

Homebrew MagLoop on 10m

VNA_Magnetic_Loop_12M_Sweep_a

Homebrew MagLoop on 12m

Unlike the MFJ-259 the VnArduino is a two-port device and is able to do transmission line measurements. So it’s useful for checking such things as Low Pass Filters (LPFs), Quartz crystals and filters. The following photos show the characteristics of some LPFs that I constructed for use with the Ultimate3 QRSS beacon.

40m Low Pass Filter

80m Low Pass Filter

The VnArduino has proven to be very useful in checking the additional filters for the Ultimate3 QRSS beacon and some recent modifications made to a MagLoop antenna. I’m looking forward to the better weather when I can really start to experiment and perhaps improve the current HF antennas here at the home QTH and when out operating portable.

What’s next:

  • To resolve the issue of the “double-hop” when using the rotary encoder to scroll through the menus.
  • To test the Bluetooth functionality with a cheap Android Tablet.

Acknowledgements:

F4GOH:          For the VnArduino project and software.

DL2SBA:        For the excellent vna/J software