¿ªÔÆÌåÓý

ctrl + shift + ? for shortcuts
© 2025 Groups.io

Re: NanoVNA-App in app calibration problem (bug?) #calibration #nanovna-app


 

On 3/5/23 3:23 PM, Roger Need via groups.io wrote:
OneOfEleven developed the NanoVNA App for personal use and after moving on to other projects kindly posted it as open source for the community to use and modify. Owen Duffy has created a fork of the OneOfEleven App and corrected some of the errors in the program especially on the info sidebar. I assume that he is reading (but unfortunately not posting) this thread because he has written a 3 part informative blog post on calibration in the NanoVNA App. Readers interested in this topic can use these links:
Part 1 -
Part 2 -
Part 3 -
In his discussion he shows that straight line interpolation can result in worse errors than using Cubic spline interpolation. The latter is used in NanoVNA App. He also states that when operating over a wide frequency band that more scan points is better.
With that in mind I did some more tests using a NanoVNA-H4 in standalone mode and with NanoVNA App OD12 and version 5.4 of NanoVNA Saver.
Calibration conditions
-----------------------------
1. In all cases the SOL was done at the end of 3M of RG-316 coaxial cable fitted with SMA male connectors on both ends. A SMA female was used with a pin header to do the SOL calibration. A 50 ohm 0805 SMD resistor was used as one of the cal loads. See attached photo. Sweep range was 50 kHz. to 900 MHz.
2. The NanoVNA was calibrated on the device using 401 scan points with the default bandwidth setting.
3. NanoVNA Saver was configured to use 401 scan points with 5 averaged sweeps for the calibration.
4. NanoVNA App OD12 was calibrated with 401 and 3201 scan points to see if more scan points made a difference. 8 traces were time averaged and trace smoothing set to 3.
Test Conditions
--------------------
A 75 ohm 0805 SMD resistor was used as the DUT and swept over the 50 kHz. to 900 MHZ. range. Note that interpolation was NOT required/used and scan point frequencies were the same as that done for calibration.
The NanoVNA Saver and NanoVNA Standalone DUT measurements were exported as a Touchstone s1p files and imported into NanoVNA app for comparison. The results are attached.
Observations
------------------
NanoVNA standalone and NanoVNA Saver both gave results that are consistent with what is expected for this DUT. NanoVNA app had a downward trend (for 401 and 3201 scanpoints) after 200 MHz. which is not correct.
Conclusions
----------------
My suspicion is that something is wrong with the implementation of the cubic spline interpolation in NanoVNA App. Perhaps DiSlord or Owen Duffy will consider adding linear interpolation as an option and removing or fixing the cubic spline interpolation.
Roger
A bit of a necro post here (for some reason, lots of groups.io messages are coming through a week late)).


Sweep range was 50 kHz. to 900 MHz. The NanoVNA was calibrated on the device using 401 scan points with the default bandwidth setting.
So the delta F between points is 900/400 or about 2.25 MHz.

This is sufficiently close that phase wraps aren't going to occur with a 3 meter long cable. At 900 MHz, lambda (free space) is .3333 meters. Velocity factor is 0.70 (depends on mfr, but close), so the "in cable" wavelength is 0.23 meters

that 3 meter cable is then 12.857 wavelengths long

At the next lower frequency step, 897.75, lambda is 0.334m, 0.2339m in cable, 12.825 wavelengths in the 3m cable. So the phase of the signal changes about 11.5 degrees.

I'm not sure that the interpolation algorithm cubic vs linear is the problem. It might depend on whether the underlying math is using cartesian (R+jI) or polar (mag, phase). interpolating between two points that are say (1.5 @ 357 degrees) and (1.2 @ 7 degrees) doesn't always come out right, if you're not careful about "going the right direction"

Join [email protected] to automatically receive all group messages.