flightaware / beast-splitter

Utility that distributes Mode-S Beast output to multiple clients
BSD 2-Clause "Simplified" License
29 stars 9 forks source link

Suggestion: Add downsample filtering to selected outputs #1

Closed marcus-aa closed 6 years ago

marcus-aa commented 7 years ago

Nice utility!

When we need to transmit the data over internet as well as use it locally (for example for mlat-client), sending the complete ADSB stream over a WAN is often a waste of bandwidth. Mobile internet has limited data and some sites need to be reduced more than others. When receiver networks grow there is a general need to Iimit bandwidth. It would therefor be very useful to be able to use a so called downsample filter, individually configurable for each output.

We use this a lot when streaming AIS data which is very similar.

The downsample filter has a time setting, for example 2 seconds. When ICAO A has sent message type X, a timer starts that for n seconds prevents the same message type and ICAO to be transmitted again. This is kept track of for all combinations of ICAOs and message types.

This way no data is missed, it just appears with a lower update rate. It works very well with AIS and can save a lot of bandwidth. Messages that are sent seldom are not affected, but frequent messages are reduced considerably.

/M

mutability commented 7 years ago

I think that is better done as part of a separate utility; beast-splitter currently maintains no per-aircraft state.

marcus-aa commented 7 years ago

Maybe so, but it would be a logical point to do it, where the data is split up into different connections. Look at kplex for example, it does the same with NMEA messages.

The way it's done in AIS is not by keeping all the decoded data in a state table, just the originator address (MMSI/ICAO) and the message type (MSG/DF), and a timestamp. There is no need to store (or even decode) the rest of the data in the message. This seems to be very fast, and there is no need to re-construct messages from the table, just discard further messages until time has expired.

/M

mutability commented 7 years ago

If you can implement this so there's no overhead when no connections have this enabled, then I can look at merging that. beast-splitter mostly runs on low-CPU devices so the no overhead bit is important.

jeka27 commented 6 years ago

After planting, beast packets provide coordinates in both decimal form and CPR. At the beginning of taxiing, the coordinates are only visible in the CPR. Because of this, the "VRS" and FR24 do not show the aircraft "VRS" shows the aircraft only after take-off from the ground. when he lands, shows the full path with taxiing to the terminal. "FR24" during take-off also switches to another receiver.

mutability commented 6 years ago

This sounds like some unrelated issue, please open a new issue.

mutability commented 6 years ago

Going to close this old issue.