Open MacJayLee opened 18 hours ago
I'm not sure what you are doing, but it seems that you want to extract a position from a single ADS-B position report. As stated in your screenshot, the CPR algorithm needs at least two ADS-B position reports to decode latitude and longitude.
Check out this excellent book to see how it works: https://mode-s.org/decode/content/ads-b/3-airborne-position.html
I'm not sure what you are doing, but it seems that you want to extract a position from a single ADS-B position report. As stated in your screenshot, the CPR algorithm needs at least two ADS-B position reports to decode latitude and longitude.
Check out this excellent book to see how it works: https://mode-s.org/decode/content/ads-b/3-airborne-position.html
You are right , I try to extract from single msg , but if there were two msg , how can I judge the relationship of them? I mean if one of them is even , and ohter is odd ,but I am not sure that they are a pair . Could you please give me an example about raw report and code?
Check out our ExampleDecoder
Hi ! Show you the code
My raw msg is “8d4ca513587153a8184a2fb5adeb”
The resolved msg is " Extended Squitter Airborne position (barometric altitude)\n Address: 4ca513 (Mode S / ADS-B)\n Air/Ground: airborne\n Altitude: 21525 ft barometric\n CPR type: Airborne\n CPR odd flag: even\n CPR latitude: (119820)\n CPR longitude: (18991)\n"
But c0 is always null . Where is my problem? Could you please help me? Thanks anyway