FlightAware Discussions

Thoughts on optimizing gain


#25

47, yes, Optimize gain had given me that number. Im running 4.5 now with the command.

And as far as different days, that is why Im going to leave it at its present setting. Im running the Flight aware Prostick with a flight aware filter on it. When I ran the scan program I still had several cell sigs on just the prostick and with the filter added it knocks them out. So the gain is needed to cover the losses.

For the last year Ive been running a close second to the nearest to me in plane count, but 100K plus less in messages. Was hoping this would help with that. He is about a mile or two from me.


#26

At least in regards to numbers, 4 to 5 percent strong signals seems to be my optimum.

Just trying one notch gain lower again but i think i miss a few signals through the forest that is on the hills in quite a good part of my horizon.


#27

What dongle / antenna are you running?


#28

Prostick with the Flight Aware Antenna. As I said above I also have the Flight Aware filter in because the prostick doesnt kill the local Cells, but the combo does.


#29

Yeah after looking at the rivaling station it seems you have a blind spot to the southwest and not as good reception to the far west over the pacific.

So while you see the same flights, he gets longer portions of the same flights increasing the position count.


#30

OrangePiPC / Armbian / dump1090-fa / FA 26" Antenna / FA Filter / Pro Stick (orange)

pi@orangepipc:~$ awk "$(cat /run/dump1090*/stats.json| grep total | sed 's/.*accepted":\[\([0-9]*\).*strong_signals":\([0-9]*\).*/BEGIN {printf "\\nPercentage of strong messages: %.3f \\n" , \2 * 100 \/ \1}/')"

Percentage of strong messages: 8.224
pi@orangepipc:~$

RPi Model2 / Raspbain Stretch / dump1090-mutability / Optimized Mag Mount on Cookie Can Lid / FA Filter / Pro Stick Plus (blue)

pi@raspberrypi:~ $ awk "$(cat /run/dump1090*/stats.json| grep total | sed 's/.*accepted":\[\([0-9]*\).*strong_signals":\([0-9]*\).*/BEGIN {printf "\\nPercentage of strong messages: %.3f \\n" , \2 * 100 \/ \1}/')"

Percentage of strong messages: 11.979
pi@raspberrypi:~ $

#31

Yay the ugly line is working :slight_smile:

Using sed search and replace to match the entire line producing the “items” \1 and \2, producing a string that is interpreted as an awk program.
Such unix, many shell!


#32

I knew it won’t work on my airspy setup, but it was tempting to run:

pi@pi_3:~ awk "(cat /run/dump1090*/stats.json| grep total | sed ‘s/.accepted":[([0-9]).strong_signals":([0-9]).*/BEGIN {printf “\nPercentage of strong messages: %.3f \n” , \2 * 100 / \1}/’)"

Percentage of strong messages: nan


#33

that is easily explained. I have a HILL directly to the west of me that peaks at 1000ft and Im at 512. Also to the SW is my Ham Radio Tower, so Im sure that it interferes with it.


#34

Yeah the other guy close to you is probably on top of that hill :slight_smile:

A position is basically generated for every plane every 5 or 10 seconds probably. You might receive more position reports from the aircraft but the count displayed in the FA stats doesn’t care.
So a similar amount of the number of planes and many more messages often means the stations with more positions can just see further / in all directions.


#35

I get Percentage of strong messages: 33.164. My gain is 49.6. If I up it to -10 my stats drop over the next few days. If I drop it to 48.0 or below my range drops a bit. I think I’ll test them again in due course.


#36

You are right next to an airport i gather? :slight_smile:

All depends what you want to see i guess.
If you want to properly look at traffic landing/departing Manchester airport you should probably turn the gain down quite a bit.

Except for the stats the range isn’t that important for the networks you feed as they most likely have good coverage of the high flying airplanes you receive at your max range anyway.

Did you just change gain/ restart dump1090 before taking that number?
Curious if my script is working fine now :confused:

If you don’t mind post the output of the following:

cat /run/dump1090*/stats.json | grep total

#37

I’m 20 or so miles from Manchester, and I have a FA external antenna indoors and a Uputronics SAW filtered preamp which increased range a lot. I’m not that bothered about traffic at the airport, I can see it all taking off and landing to around 400 feet anyway at which point it goes below the terrain.

I’m interested in seeing what it is I’m looking at in the air and it works fine for that. Also range is important to me as it interests me and from here I can see aircraft down to London, past the Isle of Man and up past Newcastle. It took some experimentation over a couple of weeks to find 49.6 as the optimum rtlsdr-gain. However I appreciate that time of year, etc can play a part in that.

Here’s the output from the command. Anything of interest there?

"total":{"start":1546520171.4,"end":1547406911.5,"local":{"samples_processed":2128151707648,"samples_dropped":0,"modeac":0,"modes":572455787,"bad":1096007095,"unknown_icao":3474469700,"accepted":[282802481,14143807],"signal":-4.6,"noise":-18.3,"peak_signal":-0.3,"strong_signals":93780193},"remote":{"modeac":0,"modes":1514859,"bad":0,"unknown_icao":0,"accepted":[1514859,0]},"cpr":{"surface":7303,"airborne":16042278,"global_ok":15430053,"global_bad":14217,"global_range":3292,"global_speed":4304,"global_skipped":25129,"local_ok":429012,"local_aircraft_relative":0,"local_receiver_relative":0,"local_skipped":176299,"local_range":49,"local_speed":13575,"filtered":19556},"altitude_suppressed":0,"cpu":{"demod":180006773,"reader":60786764,"background":7859570},"tracks":{"all":67689,"single_message":38242},"messages":298461147}

#38

No nothing interesting. Just wanted to confirm my command line worked correctly and manual calculation produces 31 percent as well :slight_smile:

The antenna being indoors explain why you need to crank up the gain so much to get range.
In some directions you get strong signals, in others they are very attenuated by walls and other stuff.

So you probably lose some aircraft because the signal is too strong, maybe even quite a bit away if they are in the right direction and altitude (less attenuation).

But if you prefer the range over missing out on some aircraft that’s your decision :slight_smile:
You could also run with a gain of 44 for a couple of days and see what changes.


#39

Overall with this setup (compared with everything before) I see many more aircraft, from those overhead to those those 150-200NM away. As you say some directions are better than others due to it being indoors. I hope to get this on the roof at some point. Thanks for the analysis command, it’s handy to have these saved for reference.


#40

I get the same error. Any Idea how to debug this?


#41

This command doesn’t work for any “external” receiver dump1090 is receiving data from.

Even the RSSI displayed on the local map isn’t accurate for airspy because it’s “adjusted” to behave the same as some other receiver.
But even when at 0 dBFS the airspy has a lot of headroom above.

So running 21 as gain should always be fine with the airspy because of the much bigger dynamic range.
Basically no need to worry about gain.
prog has said he will include a command line switch in the future to include a command line switch to actually have a real dBFS reading.


#42

I really need that command! There seems to be no other way of finding the correct gain.

If 21 is always best then I think we have a hardware problem because a gain larger than 21 would get even better results in some cases.


#43

A little explanation on dynamic range:

The receiver can hear “quiet” and “loud” signals alike. So you could turn up the “volume”, everything would be louder including the noise that is present anyway. You can only hear signals if they are above the noise. So if you already hear all signals above the noise you can’t improve.

The airspy devices have a much better dynamic range (more bits) than the other dongles.

But because the internal amplification is less an LNA is recommended for the airspy, because you can’t increase gain as much as with the other dongles. You could always get a two stage LNA like the rtl-sdr blog LNA but i doubt it would improve anything.


#44

I am no guru on this but I think you mix signal and signal/noise ratio. With a higher gain, I could make everything “louder”, including noise. But some signal that was below the “threshold of hearing” would become “audible” for the Airspy. You are correct this only makes sense if one does not introduce additional noise.