Decode aircraft category, export in aircraft.json.

Closes .
This commit is contained in:
Oliver Jowett 2015-02-22 12:15:26 +00:00
parent 8fabfcb94f
commit 8f3be2cd79
5 changed files with 16 additions and 2 deletions

View file

@ -495,6 +495,11 @@ struct aircraft *trackUpdateFromMessage(struct modesMessage *mm)
a->vert_rate = mm->vert_rate;
}
// If a (new) category has been received, copy it to the aircraft structure
if (mm->bFlags & MODES_ACFLAGS_CATEGORY_VALID) {
a->category = mm->category;
}
// Update the aircrafts a->bFlags to reflect the newly received mm->bFlags;
a->bFlags |= mm->bFlags;