There are two problems that need addressing to make the accuracy as good as possible. The two areas to work on are -
-73 to -3 dBm
-3 to +13 dBm
If you look at the response plots for each frequency they are linear for the lower power range but the response drops off as you go higher in frequency. This was already understood. As you may be able to tell it's not quite a linear drop as you go higher in freq., but it's not too bad.
So for the lower range (-73 to -3) I picked one power level of -30 dBm (about mid-range). Then I plotted data for frequencies of 1, 30, 50, 100, 200, 300, 400, and 500 MHz "Legally" this AD8310 isn't rated over 440 MHz but I might be able to get away with it.
As suspected you can see a slight curve in the measured power as frequency increases (blue dashed line). I requested a linear "fit" from the calc software and got the green dashed line. I then applied a correction factor based on that equation to the measured data and got the solid green line (ideally we want -30 all the way across). It's obvious anyway that the linear equation will not take out the curve. I could tweak the equation a bit myself by eye and get a little better fit which wouldn't be that bad, but I wanted better.
I used online tools to get a quadratic equation (which is shown on the chart) from the measured data in the chart. When I applied a new correction factor from that equation I got an almost perfect fit (red line). The idea is, as I set a frequency with a rotary encoder, the reading will have a calculated correction applied on the fly. The encoder can be set via the pushbutton to either 5 or 25 MHz step.
So that will take care of the lower power correction. The higher power ranges add a different response. In addition to dropping with frequency it also changes with more power higher than ~ -3 dBm. As if that weren't enough, it's also exaggerated at frequencies over 300 MHz. So a different equation needs to be used.
I will change the correction calculation based on the raw output voltage from the AD8310. I chose 2.15 V as the point where the calculation for corr. factor will switch between the one for the lower power range to the one for the higher power range. You can see a slight improvement in the plots for the higher power ranges. It isn't perfect but it does enough to make the accuracy better than it would have been using the other equation.
All this is now in the software now and it is working. Now I want to pull the two OLEDs and get the new larger display going in the system. So I'll get back to formatting the display so it has all the info I want on it.