faup1090: apply the same update rules to squawks/idents as to other data.
This commit is contained in:
parent
fb454c0a10
commit
7e003097a0
4
net_io.c
4
net_io.c
|
@ -1904,7 +1904,7 @@ static void writeFATSV()
|
||||||
p += snprintf(p, bufsize(p, end), "\taddrtype\t%s", addrtype_short_string(a->addrtype));
|
p += snprintf(p, bufsize(p, end), "\taddrtype\t%s", addrtype_short_string(a->addrtype));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (trackDataValidEx(&a->callsign_valid, now, 120000, SOURCE_MODE_S_CHECKED)) { // we accept quite old idents as they shouldn't change often
|
if (trackDataValidEx(&a->callsign_valid, now, 15000, SOURCE_MODE_S_CHECKED) && a->callsign_valid.updated > a->fatsv_last_emitted) {
|
||||||
p += snprintf(p, bufsize(p,end), "\tident\t%s", a->callsign);
|
p += snprintf(p, bufsize(p,end), "\tident\t%s", a->callsign);
|
||||||
switch (a->callsign_valid.source) {
|
switch (a->callsign_valid.source) {
|
||||||
case SOURCE_MODE_S:
|
case SOURCE_MODE_S:
|
||||||
|
@ -1928,7 +1928,7 @@ static void writeFATSV()
|
||||||
useful = 1;
|
useful = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (trackDataValidEx(&a->squawk_valid, now, 120000, SOURCE_MODE_S)) { // we accept quite old squawks as they shouldn't change often
|
if (trackDataValidEx(&a->squawk_valid, now, 15000, SOURCE_MODE_S) && a->squawk_valid.updated > a->fatsv_last_emitted) {
|
||||||
p += snprintf(p, bufsize(p,end), "\tsquawk\t%04x", a->squawk);
|
p += snprintf(p, bufsize(p,end), "\tsquawk\t%04x", a->squawk);
|
||||||
if (a->squawk_valid.source == SOURCE_TISB) {
|
if (a->squawk_valid.source == SOURCE_TISB) {
|
||||||
used_tisb = 1;
|
used_tisb = 1;
|
||||||
|
|
Loading…
Reference in a new issue