FlightAware Discussions

gain settings

hello i’m looking for any info for the gain settings. and the command to adjust it… thanks… currently have piaware fully up to date and sharing. i want to adjust the gain settings to see if it helps my setup for distance… getting about 140miles out of it now, i want more…45ft mast with a pre amp and the recommended antenna per flightaware…

Search for user bellcountytx. He has his rpi1, no amp, FA antenna on a 40’ tower.
He gets 50% of his traffic from over 80NM.

Reducing cable/connector loss and noise can help. I have seen a lot of posts where a cheap amp and cantenna works well.

Antenna height will probably do the most good. Look at www.heywhatsthat.com for an indication of your possible range. Select “up in the air” then put in the altitude you want to look at.

The mutability version of dump1090 with 2.4mhz over scanning added 10-20% to my aircraft numbers.

First thing to do is go to the heywhatsthat site and put your location in. This will determine what the theoretical range you should be getting is, as restricted by the terrain. Details are in this thread: ads-b-flight-tracking-f21/what-is-the-maximum-range-i-can-get-t35912.html

If you are using dump1090-mutability, then you can adjust the gain by editing /etc/defaults/dump1090-mutability. The valid values for gain are:


0.0 0.9 1.4 2.7 3.7 7.7 8.7 12.5 14.4 15.7 16.6 19.7 20.7 22.9 25.4 28.0 29.7 32.8 33.8 36.4 37.2 38.6 40.2 42.1 43.4 43.9 44.5 48.0 49.6

You can also use “max”, and “agc”. Max is the same as 49.6, and agc will in practice give a slightly higher gain than can be set manually.

It is really a matter of experimenting to find out the gain setting that works best for you. If you have the collectd stats logging running then it makes it easier to see the effect as you adjust things - you need to make a change and leave it running for a period to see what the effect is. The raw message count doesn’t necessarily give the best performance indicator, since it will depend on how busy your site is and where the planes are in relation to you - next to a busy airport might have different results to being somewhere where most aircraft are at range and high altitude.

Unless you are able to get a significant number of messages at over -3dB using the manual gain settings, I would stick to a gain of -10 enabling automatic gain control at the amplifier inside of the dongle (as opposed to --enable-agc, which is fairly useless for what we’re doing). I also saw pretty large improvements in range using --fix, --aggressive, and --phase-enhance. Have you done any calibration on your RTL? You’ll see immediate improvements there as well if you haven’t.

You probably don’t want to be using that; it tends to produce garbage data.

(it is, in fact, disabled in newer dump1090-mutability builds for that reason)

So I’ve never been able to find the answer anywhere. What would bad data present itself as? Is there any real quantifiable measurement I can perform or that has been performed? Obviously trying to correct data based on some kind of best guess (using the parity bit?) can lead to bad data, but I believe the advantages outweigh the issue. It’s not like I see any noticeable change in bad messages or bad PI % in VRS.

And are you sure about it being disabled? I can see it in both the config file, and the default file with version 1.15

The problem is exactly that you cannot tell that it is bad data just by looking at it; it has passed the error detection/correction checks and appears valid. But the contents of the message will be bogus. (edit: do NOT, I repeat do NOT blow the hatch… Roger, hatch blown!)

The most common way this shows up is as hearing occasional messages with an improbable ICAO address (e.g. in an unallocated block). But it can also show up as one-off bad altitudes or positions or callsigns for a real aircraft.

You can quantify some of those types of error by looking at aircraft-with-only-one-message counts, or for position messages that fail the sanity checks; dump1090-mutabilty gives you stats for both. But it is generally a hard problem because you are looking for messages that are entirely valid according to the spec, but do not make physical sense; that requires that you have a good idea of what sort of data is “right” ahead of time.

Yes, I’m sure it’s disabled. I haven’t got around to disabling the config infrastructure for it.

What would be helpful (at least for me) is a how to /sticky on how to interpret the graphs to understand tuning the system for optimal results.

2 Likes

Thank you! I hadn’t considered using the single message aircraft rate in my experimentation. I guess since I’m running mutability now I’m not using it anyway :wink:

I run my pre-amped antenna at a reduced gain. Definitely helps increase the signal-to-noise ratio and allows you to squeeze out more range. I unplug the RPi and plug the amplified SDR directly into a laptop where I run RTL1090. Once up and running, open the SISEX page so you can see the signals in the time domain. While that is running you can go back to the main RTL1090 window and adjust the gain real-time (highlight drop down, up & down arrow). Watch the SISEX window to see the changes graphically and watch the fields on the bottom of the main window ==> message rate (xx/sec), threshold (THR). Play around with the gain until it seems to maximize the message rate. It’s a bit tough to attribute a message rate jump to the gain change or just the natural ups and downs from airplanes flying about, but it’ll get you in the ballpark. THR for me tends to fall around -82db with gains around 38.6 or 40.2. You can also see cell tower radio interference in the SISEX window which tends to show up as a diagonal pattern. Once you tune the gain where it ‘feels right’, take that value and configure your dump1090 with it.

One day I’ll have to do a nice writeup with screenshots for the masses.

Any idea what the colors in the SISEX window mean? I’m assuming I want the window to be mostly green. I definitely see that cell tower interference pattern. (even with the FA bandpass filter installed) Should I be configuring gain until it’s barely visible?

With AGC on the window is mostly red with yellow dots.

EDIT: Ok ok, I did what I should have done first and RTFM.

There’s a nice writeup of the SISEX tool here: http://rtl1090.web99.de/homepage/index.php?way=1&site=READOUT&DERNAME=SISEX&dm=rtl1090&USER=rtl1090&goto=1&XURL=rtl1090&WB=1&EXTRAX=X&PIDX=102753

As I understand it, I’m tweaking the settings so I see more “charachteristic replies” and less noise, as exemplified here:

Getting a good visual of the picture is a good starting point, but your ultimate target is message rate. The contrast and squelch will have a big impact on the visual picture and may mislead you. I’m always surprised with the difference between what my eyeballs see as a good SNR to what the RTL1090 can pick up. My SISEX screen will usually look fairly overwhelmed for maximum message rate. Just keep jumping between gain settings to see if you can pick a winner, then try the next pair, and so on. Once you pick a number, run it for a week and see how it compares to the previous week.

Ah, gotcha.

I have a “more better” LNA coming from ebay that will (theoretically) do a better job than the $20 RadioShack CATV amp i’m usually using. (But it goes to 3ghz, has a gain knob, and a red LED that really lends a sense of authority)

So I should probably wait until after I install the new amp before I do any real testing.

does the gain affect the RTL chip temperature?

That’s an interesting question. In my mind, it should, as the increase in gain may also increase current draw and therefore power dissipation. But I don’t know for sure.