Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ASTERIX #34

Open
wants to merge 40 commits into
base: dev
Choose a base branch
from
Open

ASTERIX #34

wants to merge 40 commits into from

Conversation

k2fc
Copy link
Contributor

@k2fc k2fc commented Apr 23, 2023

This PR adds ASTERIX i/o support.

The following command line arguments are added:
--net-ai-port
--net-ao-port
--net-asterix-reduce

Additionally --net-connector has the following formats added:
asterix_in
asterix_out

Currently, only CAT021 (ADS-B) messages are supported. The following CAT021 items work:

Item Number Description Notes
10 Data Source Identification Hard Coded to output SAC=0 SIC=1. Discarded on input. Required field per Asterix spec
40 Target Report Descriptor
71 Time of Applicability for position Input only
130 Position in WGS-84 Coordinates Output and input
131 Position in WGS-84 Coordinates (High-Resolution) Input only
72 Time of Applicability for velocity Input only
150 Air Speed
151 True Airspeed
80 Target Address
73 Time of Message Reception of Position
74 Time of Message Reception of Velocity - High Precision Input Only
75 Time of Message Reception for Velocity
76 Time of Message Reception for Velocity – High Precision Input Only
140 Geometric Height
90 Quality Indicators I do not fully understand these, so it's probably not correct
210 MOPS Version I do not fully understand these, so it's probably not correct
70 Mode 3/A Code
230 Roll Angle
145 Flight Level
152 Magnetic Heading
200 Target Status I do not fully understand these, so it's probably not correct (especially Nav Modes)
155 Barometric Vertical Rate
157 Geometric Vertical Rate
160 Airborne Ground Vector
77 Time of Report Transmission
170 Target Identification (Callsign)
20 Emitter Category I do not fully understand this, so it's probably not correct
220 Met Information Ouput only. I tried to add COMM_B code to decode met information, but I have not decoded any. Unknown if this works. readsb can still continue to derive the met information on its own, but it won't be sent over ASTERIX.
8 Aircraft Operational Status I do not fully understand this. It may be correct, but I wouldn't bet money on it.
400 Receiver ID Output only. Only 8 bits are available. I simply took the last 8 bits of mm->receiverId... it should probably be a hash.

MLAT messages are not passed. I don't have access to MLAT data to work with, but MLAT data should be exchanged as CAT020.

Known issues

Most issues are caused by my lack of understanding on some of the internals.

  • Quality indicators seem to intermittently show up. When they do, they seem to match what my main instance of readsb (beast format) shows, but they quickly revert to n/a.
  • ADS-B version always shows as v15... not sure why.
  • I have seen TIS-B ground targets appear at ~1500ft intermittently, but haven't tracked down the cause yet.

k2fc added 30 commits March 29, 2023 13:16
successfully made plausible ASTERIX packets with position, time, altitude, vertical rates, address, and aircraft identification
@k2fc
Copy link
Contributor Author

k2fc commented Apr 23, 2023

@wiedehopf
Copy link
Owner

I will start looking at the overall diff of these changes once this PR doesn't change for a day or two.

Asterix seems like an overcomplicated badly documented protocol.

Also lol: NOTE: This edition is NOT backwards compatible
to category 021 edition 2.1 or earlier

I'm sorry i'm not enthusiastic about merging stuff but it's usually things i don't need / find interesting and that's just a chore.
I'll try though just don't expect this to happen quickly.
I don't have any big changes to readsb planned so ... at least rebasing shouldn't be much necessary for you and you can just continue to work based on your fork.

I suppose it might be worth to merge the basic skeleton ... i'll see about that the next couple days.

@wiedehopf
Copy link
Owner

So this kinda needs a rebase.
But i'll try and make a diff and just make one big patch i guess.

Is the merged version working for you?

@wiedehopf
Copy link
Owner

So i want this as one big commit i'm making right now.
It is just a diff from the current state.a
Plus some whitespace fixes (trailing space / indent).

I'll see how i can attribute you.
Will try just messing with a commit ;)

@wiedehopf
Copy link
Owner

https://github.com/wiedehopf/readsb/tree/asterix

Ok please test this, make a new branch on your side and make a new PR using this commit i made.
That should give you all the attribution properly.

I'll close this PR, feel free to just copy the text from the new PR.

@wiedehopf wiedehopf closed this Aug 12, 2023
@wiedehopf wiedehopf reopened this Aug 27, 2023
@wiedehopf
Copy link
Owner

@k2fc i'm trying to merge this but i'd like it to show properly on github that it was your PR ... but due to rebase and stuff anyhow it's complicated.
You mind getting that branch over to you? I can change the branch name if that's an issue.

@wiedehopf
Copy link
Owner

@k2fc This is merged, but it won't show as merged here as i wanted to flatten all the work in progress commits a bit.

Merged as: 8dfb94b

I tried to get you to pull that branch so i can just merge it and it shows as PR on here but there was no response.
If that's important to you, i can still make that happen.

@wiedehopf wiedehopf closed this Dec 29, 2023
@wiedehopf
Copy link
Owner

Keeping this PR open even though it's merged for some visibility of the feature :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants