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

New Channel: "Open Glider Network" / "GliderNet" #72

Closed
6 tasks done
TwinFan opened this issue Jan 20, 2019 · 3 comments
Closed
6 tasks done

New Channel: "Open Glider Network" / "GliderNet" #72

TwinFan opened this issue Jan 20, 2019 · 3 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@TwinFan
Copy link
Owner

TwinFan commented Jan 20, 2019

Current Situation / Problem
Limited GA, no glider coverage in LiveTraffic. GliderNet is not supported as a tracking data channel.

Suggested Solution
Support GliderNet, an open solution.

Benefits
A little increase in GA traffic, adding glide traffic.
Would make LiveTraffic interesting also for sailplane / glider sim pilots.

Additional context
While there are high-level APIs available they require pretty fat libraries to include, which I'm reluctant to do. However, there seem to be just standard request/reply possibilities, which would fit into the LiveTraffic design.

E.g. http://live.glidernet.org/lxml.php?a=1&b=51.7568&c=47.3490&d=15.0239&e=1.0054&z=2 returns something like

<markers>
<m a="48.517132,1.640970,_7a,a90b107a,149,16:41:23,31002,0,0,-0.1,1,LFFL,0,a90b107a"/>
<m a="47.448650,8.209450,SGI,HB-SGI,792,16:41:09,31016,120,178,-3.6,8,Bohlhof,4B302C,991d079d"/>
<m a="49.984921,11.642450,ZG,D-EFZG,476,17:05:53,29532,0,0,0.7,8,EDQD,3D146C,25200416"/>
<m a="50.352421,8.905480,_7e,82b8df7e,349,17:16:03,28922,170,185,-0.2,1,Nidda,0,82b8df7e"/>
<m a="49.602821,7.160050,_af,697429af,508,17:23:29,28476,155,93,-2.7,8,EDRG,0,697429af"/>
<m a="50.061871,11.287950,_00,e5f39900,1107,16:31:33,31592,6,178,1.2,1,EDER,0,e5f39900"/>
<m a="49.601021,8.351350,_59,70bac159,174,17:06:58,29467,63,94,-3.1,2,LuDaN,0,70bac159"/>
...
</markers>

Todos

  • Understand the format and how request/reply works
  • Design how the data fits into the LTFlightData model. This is not ICAO defined, we need to map and match it somehow to integrate with the existing LT world.
    • Allow other FD a/c keys than ICAO, e.g. FLARM id
    • Provide mapping from FLARM acft type to CSL models like we did for cars already.
  • Might need some adjustments to the flight model...gliders aren't Airbusses
  • Last but not least we need one or two reasonable CSL models to represent the found gliders.
@TwinFan TwinFan added the enhancement New feature or request label Jan 20, 2019
@TwinFan TwinFan mentioned this issue Jan 20, 2019
8 tasks
@TwinFan TwinFan changed the title New Channel: "GliderNet" New Channel: "Open Glider Network" / "GliderNet" Jan 20, 2019
@TwinFan TwinFan added this to the After 1.0 milestone Jan 20, 2019
@TwinFan
Copy link
Owner Author

TwinFan commented Jan 20, 2019

172MC has a glider, downloaded from X-Plane: ASK21

@TwinFan
Copy link
Owner Author

TwinFan commented Mar 17, 2019

Documentation for request/reply is rather thin. The following I consolidated from various sources:

A valid request is as stated here:

http://live.glidernet.org/lxml.php?a=1&b=51.7568&c=47.3490&d=15.0239&e=1.0054&z=2

The Python source code of an alternative OGN backend (the server answering the requests) gives away details of the request and reply format.

  • Request Format
show_offline = request.args.get('a', 0, type=int) == 1
    lat_max = request.args.get('b', 90, type=int)
    lat_min = request.args.get('c', -90, type=int)
    lon_max = request.args.get('d', 180, type=int)
    lon_min = request.args.get('e', -180, type=int)

And by trial and error I assume that z is a timezone to which the timestamps are to be converted. As LiveTraffic prefers ZULU/GMT anyway we just leave it out.

  • Reply Format
lines.append('<m a="{0:.7f},{1:.7f},{2},{3},{4},{5},{6},{7},{8},{9},{10},{11},{12},{13}"/>'
                     .format(aircraft_beacon.location.latitude,
                             aircraft_beacon.location.longitude,
                             competition,
                             registration,
                             aircraft_beacon.altitude,
                             utc_to_local(aircraft_beacon.timestamp).strftime("%H:%M:%S"),
                             elapsed_seconds,
                             int(aircraft_beacon.track),
                             int(aircraft_beacon.ground_speed),
                             int(aircraft_beacon.climb_rate*10)/10,
                             aircraft_beacon.aircraft_type,
                             aircraft_beacon.receiver_name,
                             address,
                             code))

Aircraft type is likely the FLARM type, field ACFT as in the FLARM specs.

TwinFan added a commit that referenced this issue Mar 17, 2019
Also prepares for other flight data / aircraft types like in OGN (#72)
@TwinFan TwinFan self-assigned this Mar 19, 2019
@TwinFan TwinFan modified the milestones: After 1.0, v1.20 Apr 5, 2019
@TwinFan TwinFan removed this from the v1.20 milestone Jun 26, 2019
@TwinFan
Copy link
Owner Author

TwinFan commented Aug 16, 2020

Sent a mail to contact [at] glidernet.org, asking permission to use the data.

@TwinFan TwinFan added this to the v2.x milestone Sep 8, 2020
TwinFan added a commit that referenced this issue Sep 8, 2020
New fields "key type", "category descr." in Aircraft List and A/C Info Wnd
TwinFan added a commit that referenced this issue Sep 14, 2020
8° bank angle for stopped Gliders, don't ignore empty OGN response fields
TwinFan added a commit that referenced this issue Sep 16, 2020
TwinFan added a commit that referenced this issue Sep 19, 2020
TwinFan added a commit to TwinFan/XPMP2 that referenced this issue Sep 20, 2020
TwinFan referenced this issue Sep 20, 2020
TwinFan added a commit that referenced this issue Oct 1, 2020
Preferred alternative to request/reply to live.glidernet.org
TwinFan added a commit that referenced this issue Oct 2, 2020
TwinFan added a commit that referenced this issue Oct 2, 2020
because MS Visual C++ did not properly align the bit field
TwinFan added a commit that referenced this issue Oct 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant