rsadsb / adsb_deku Goto Github PK
View Code? Open in Web Editor NEW✈️ Rust ADS-B decoder + tui radar application
License: MIT License
✈️ Rust ADS-B decoder + tui radar application
License: MIT License
28547 │ *8dace839f8132006005ab84f2dfa;
28548 │ hex: ace839 CRC: 000000 fixed bits: 0 decode: ok
28549 │ RSSI: -3.0 dBFS
28550 │ Score: 1800
28551 │ receiverTime: 14406049.00us
28552 │ systemTime: 1637757645.129s 07:40:45
28553 │ DF:17 AA:ACE839 CA:5 ME:F8132006005AB8
28554 │ Extended Squitter Aircraft operational status (airborne) (31/0)
28555 │ ICAO Address: ACE839 (adsb_icao)
28556 │ Air/Ground: airborne
28557 │ NIC-A: 1
28558 │ NIC-baro: 1
28559 │ NACp: 10
28560 │ GVA: 2
28561 │ SIL: 3 (p <= 0.00001%, per flight hour)
28562 │ SDA: 2
28563 │ Aircraft Operational Status:
28564 │ Version: 2
28565 │ Capability classes: 1090IN ARV TS UATIN
28566 │ Operational modes: SAF
28567 │ Heading ref dir: True heading
11671 │ 8dace839f8132006005ab84f2dfa
11672 │ Frame {
11673 │ df: ADSB(
11674 │ ADSB {
11675 │ capability: AG_AIRBORNE,
11676 │ icao: ICAO(
11677 │ [
11678 │ 172,
11679 │ 232,
11680 │ 57,
11681 │ ],
11682 │ ),
11683 │ me: AircraftOperationStatus(
11684 │ Airborne(
11685 │ OperationStatusAirborne {
11686 │ capability_class: CapabilityClassAirborne {
11687 │ reserved0: 0,
11688 │ acas: 0,
11689 │ cdti: 1,
11690 │ reserved1: 0,
11691 │ arv: 1,
11692 │ ts: 1,
11693 │ tc: 0,
11694 │ reserved2: 32,
11695 │ },
11696 │ operational_mode: OperationalMode {
11697 │ reserved: 0,
11698 │ tcas_ra_active: false,
11699 │ ident_switch_active: false,
11700 │ reserved_recv_atc_service: false,
11701 │ single_antenna_flag: true,
11702 │ system_design_assurance: 2,
11703 │ },
11704 │ reserved: 0,
11705 │ version_number: DOC9871AppendixC,
11706 │ nic_supplement_a: 1,
11707 │ navigational_accuracy_category: 10,
11708 │ geometric_vertical_accuracy: 2,
11709 │ source_integrity_level: 3,
11710 │ barometric_altitude_integrity: 1,
11711 │ horizontal_reference_direction: 0,
11712 │ sil_supplement: 0,
11713 │ reserved1: 0,
11714 │ },
11715 │ ),
11716 │ ),
11717 │ pi: ICAO(
11718 │ [
11719 │ 79,
11720 │ 45,
11721 │ 250,
11722 │ ],
11723 │ ),
11724 │ },
11725 │ ),
11726 │ crc: 0,
11727 │ }
11728 │ Extended Squitter Aircraft operational status (airborne)
11729 │ Address: ace839 (Mode S / ADS-B)
11730 │ Air/Ground: airborne
11731 │ Aircraft Operational Status:
11732 │ Version: 2
11733 │ Capability classes: CDTI ARV TS
11734 │ Operational modes: SAF SDA=2
11735 │ NIC-A: 1
11736 │ NACp: 10
11737 │ GVA: 2
11738 │ SIL: 3 (per hour)
11739 │ NICbaro: 1
11740 │ Heading reference: true north
9689294eed4a82444cd8f7a933ab
thread 'main' panicked at '[E] Assertion error: field subtype failed assertion: subtype == 1', apps/src/1090.rs:103:25
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
This is mostly so you can reload after quitting the radar
application
911c059d9805a452cf109f64924f
thread 'main' panicked at '[E] Parse error: Could not match enum variant id = 0 on enum `AirborneVelocitySubType`', apps/src/1090.rs:87:21
thread 'main' panicked at '[E] Parse error: Could not match enum variant id = 2 on enum `ControlField`', apps/src/1090.rs:47:23
Caused by
92A24528993C238900062053CDEF
In source code currently hard coded:
let original_scale = 1.2;
We still want the same scale as default, but make it a operator option.
?
key. Like the bottom
program.Instead of just changing the location when selecting an aircraft, keep moving lat/long along with aircraft until user uses: Enter, Left, Up, Down, Right keys.
Should be more like the ./dump1090 --interactive
display
fmt::Display not implemented
Caused by
96A6C24699141E0E8018074AA959
Frame {
df: TisB {
cf: TISB_DF17(
ADSB {
capability: AG_AIRBORNE,
icao: ICAO(
[
54,
18,
52,
],
),
me: Reserved,
pi: 15769800,
},
),
pi: ICAO(
[
116,
0,
192,
],
),
},
crc: 0,
}
Frame { df: TisB { cf: TISB_DF17(ADSB { capability: AG_AIRBORNE, icao: ICAO([54, 18, 52]), me: Reserved, pi: 15769800 }), pi: ICAO([116, 0, 192]) }, crc: 0 }
This should be less important if i wasn't using rc version of clap, but it would be good to make sure that the input to the programs remain the same from version to version.
This would not only display where a plane was seen, but how often a plane was seen in that location by changing the color of the display.
For this data:
8DA35EBC9B000024B00C0004E897
8DAB92A2593E0664204C69D8FE84
Extended Squitter Airborne position (barometric altitude)
Address: ab92a2 (Mode S / ADS-B)
Air/Ground: airborne
Altitude: 195200 ft barometric
CPR type: Airborne
CPR odd flag: odd
CPR latitude: (78352)
CPR longitude: (19561)
I think this aircraft was actually flying at about 10600 feet at the time:
Here's the message history for that aircraft leading up to that decode (the Short Air-Air Surveillance message decoding as being on the ground seems potentially suspicious?):
8DAB92A299105E93001486608C6D
Extended Squitter Airborne velocity over ground, subsonic
Address: ab92a2 (Mode S / ADS-B)
Air/Ground: airborne
GNSS delta: -125 ft
Heading: 149
Speed: 177 kt groundspeed
Vertical rate: 256 ft/min barometric
020007A0D08FF4
Short Air-Air Surveillance
ICAO Address: ab92a2 (Mode S / ADS-B)
Air/Ground: ground
5DAB92A2B04912
All Call Reply
ICAO Address: ab92a2 (Mode S / ADS-B)
Air/Ground: airborne
8DAB92A2593E0664204C69D8FE84
Extended Squitter Airborne position (barometric altitude)
Address: ab92a2 (Mode S / ADS-B)
Air/Ground: airborne
Altitude: 195200 ft barometric
CPR type: Airborne
CPR odd flag: odd
CPR latitude: (78352)
CPR longitude: (19561)
8da353c65881360d90a7bc9b1858
Extended Squitter Airborne position (barometric altitude)
Address: a353c6 (Mode S / ADS-B)
Air/Ground: airborne
Altitude: 24675 ft barometric
CPR type: Airborne
CPR odd flag: odd
CPR latitude: (67272)
CPR longitude: (42940)
a353c6: (Position { latitude: 33.64013671875, longitude: -125.04295349121094 }, 22625)
But that aircraft was closer to longitude -117 (screenshot may have been a few minutes after the decode above):
thread 'main' panicked at '[E] Not enough data, need 24 bits (or 3 bytes)', apps/src/1090.rs:47:23
Caused by
96130D9D910F86188A7A71EF6DCB
8bf10497c3e6a6291cfec0feaf12
thread 'main' panicked at '[E] Assertion error: field reserved failed assertion: reserved == 0', apps/src/1090.rs:101:25
dump1090-fa:
*a00017b010030a80f60000a0fc1e;
CRC: a6c756
RSSI: -9.4 dBFS
Score: 12 (UNRELIABLE_KNOWN)
Time: 50236182.08us
DF:20 addr:A6C756 FS:0 DR:0 UM:0 AC:6064 MB:10030A80F60000
Comm-B, Altitude Reply
Comm-B format: BDS1,0 Datalink capabilities
ICAO Address: A6C756 (Mode S / ADS-B)
Air/Ground: airborne?
Baro altitude: 37000 ft
adsb_deku:
a00017b010030a80f60000a0fc1e
Frame {
df: CommBAltitudeReply {
flight_status: NoAlertNoSPIAirborne,
dr: None,
um: UtilityMessage {
iis: 0,
ids: NoInformation,
},
alt: 36800,
mb: [
8,
1,
133,
64,
123,
0,
0,
],
parity: ICAO(
[
80,
126,
15,
],
),
},
crc: 10930006,
}
Comm-B Altitude Reply
data: [8, 1, 85, 40, 7b, 0, 0]
ICAO Address: 507e0f (Mode S / ADS-B)
*a000179f0000000000000019a524;
CRC: a6c756
RSSI: -9.9 dBFS
Score: 12 (UNRELIABLE_KNOWN)
Time: 54835314.25us
DF:20 addr:A6C756 FS:0 DR:0 UM:0 AC:6047 MB:00000000000000
Comm-B, Altitude Reply
Comm-B format: empty response
ICAO Address: A6C756 (Mode S / ADS-B)
Air/Ground: airborne?
Baro altitude: 36975 ft
*a020133810020a80f000007707ca;
CRC: a5fd2d
RSSI: -7.3 dBFS
Score: 12 (UNRELIABLE_KNOWN)
Time: 76604277.67us
DF:20 addr:A5FD2D FS:0 DR:4 UM:0 AC:4920 MB:10020A80F00000
Comm-B, Altitude Reply
Comm-B format: unknown format
ICAO Address: A5FD2D (Mode S / ADS-B)
Air/Ground: airborne?
Baro altitude: 30000 ft
thread 'main' panicked at '[E] Not enough data, need 8 bits (or 1 bytes)', apps/src/1090.rs:47:23
Caused by this frame:
96A082FB213B1CF2113820D6EDDF
/dev/ttyUSB0
)?A0001910204D7075D35820C25C0C
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: "Invalid altitude"', src/lib.rs:456:46
stack backtrace:
0: rust_begin_unwind
at /rustc/09c42c45858d5f3aedfa670698275303a3d19afa/library/std/src/panicking.rs:517:5
1: core::panicking::panic_fmt
at /rustc/09c42c45858d5f3aedfa670698275303a3d19afa/library/core/src/panicking.rs:101:14
2: core::result::unwrap_failed
at /rustc/09c42c45858d5f3aedfa670698275303a3d19afa/library/core/src/result.rs:1617:5
3: adsb_deku::Altitude::read
4: <adsb_deku::DF as deku::DekuRead>::read
5: <adsb_deku::Frame as deku::DekuContainerRead>::from_bytes
6: _1090::main
By the way, amazing work and it's awesome how quickly you're improving this code.
For example, reading the nmea messages from a device such as /dev/ttyUSB0
and using https://github.com/AeroRust/nmea to update the local lat/long.
thread 'main' panicked at '[E] Parse error: Could not match enum variant id = 4 on enum `ADSBVersion`', apps/src/1090.rs:72:21
Caused by
96A4D01FF900210600493075E234
Airplanes would be displayed with a custom color for different altitudes
Running 1090 on my local feed, I've run into this:
thread 'main' panicked at '[E] Parse error: Could not match enum variant id = 5 on enum `ControlField`', apps/src/1090.rs:47:23
An actual sample frame that caused this error:
95298FCA680946499671468C7ACA
I wasn't sure if you had access to real data frames of the types not handled by the parser, since things like TIS-B may not be used in all regions. Here in Los Angeles we see a lot of data that might be rare in other places. I'll open a few other issues for parse errors with frame specimens, but if you don't care or don't find it useful, feel free to close these.
For an actively seen aircraft, show its trace behind the plain (places in which the plane was seen before).
a227ed3417826515bebd01707629
:
'called `Result::unwrap()` on an `Err` value: Incomplete(NeedSize { bits: 8 })'
This isn't the primary point of this library, but I want to offer serialization as a feature since deku already adds this without development cost from us with the DekuWrite
Derive macro.
This would add tests, and derive under the feature deku_write
.
92ef92b301154cb9ab09466702c6
thread 'main' panicked at '[E] Parse error: Could not match enum variant id = 0 on enum `ME`', apps/src/1090.rs:74:21
*92ef92b301154cb9ab09466702c6;
CRC: 000000
RSSI: -25.0 dBFS
Score: 24 (DF18_UNKNOWN)
Time: 10550018865.25us
DF:18 AA:EF92B3 CF:2 ME:01154CB9AB0946
Extended Squitter (Non-Transponder) No position information (airborne or surface) (0) (reliable)
Other Address: EF92B3 (TIS-B, Mode A code and track file number)
Air/Ground: airborne?
Baro altitude: 3100 ft
NACp: 0
SIL: 0 (p > 0.1%, unknown type)
The tag exists, but not the associated release.
Kudos to your project !
Cheers
I have to run for much longer before I hit any decode error now.
8DA90A6E000000000000005CAB8B
thread 'main' panicked at '[E] Parse error: Could not match enum variant id = 0 on enum `ME`', apps/src/1090.rs:71:21
92479249fcb22e16fbdc3bac5b56
thread 'main' panicked at '[E] Parse error: Could not match enum variant id = 4 on enum `OperationStatus`', apps/src/1090.rs:100:25
thread 'main' panicked at '[E] Parse error: Could not match enum variant id = 1 on enum `ControlField`', apps/src/1090.rs:47:23
Caused by
91ADF9CEC11C0524407F11538EE5
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.