Skip to content

Commit

Permalink
bearing
Browse files Browse the repository at this point in the history
  • Loading branch information
jvde-github committed Jan 26, 2025
1 parent 263bbed commit aa089af
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
5 changes: 3 additions & 2 deletions HTML/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -978,23 +978,24 @@
class="mapcard-content-row shipcard-content-row shipcard-row-selected">
<div><span>Vert Rate</span><span id="shipcard_plane_vertrate">-</span></div>
<div><span>Altitude</span><span id="shipcard_plane_altitude">-</span></div>
<div><span>Bearing</span><span id="shipcard_plane_bearing">-</span></div>
</div>

<div onclick="shipcardselect(this)" data-context-type="plane"
class="mapcard-content-row shipcard-content-row shipcard-max-only">
<div><span>Last Signal</span><span id="shipcard_plane_last_signal">-</span></div>
<div><span>Messages</span><span id="shipcard_plane_messages">-</span></div>
<div><span>RSSI</span><span id="shipcard_plane_level">-</span></div>
<div><span>Receiver</span><span id="shipcard_plane_last_group"></span></div>
</div>
<div onclick="shipcardselect(this)" data-context-type="plane"
class="mapcard-content-row shipcard-content-row shipcard-row-selected">
<div><span>Downlink</span><span id="shipcard_plane_downlink">-</span></div>
<div><span>TC</span><span id="shipcard_plane_TC">-</span></div>
<div><span>RSSI</span><span id="shipcard_plane_level">-</span></div>
</div>

<div onclick="shipcardselect(this)" data-context-type="plane"
class="mapcard-content-row shipcard-content-row shipcard-row-selected">
<div><span>Receiver</span><span id="shipcard_plane_last_group"></span></div>
<div><span>Sources</span><span id="shipcard_plane_sources">-</span></div>
</div>

Expand Down
6 changes: 4 additions & 2 deletions HTML/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -2525,7 +2525,8 @@ async function fetchPlanes() {
"message_types",
"message_subtypes",
"group_mask",
"last_group"
"last_group",
"bearing"
];

planesDB = {};
Expand Down Expand Up @@ -4743,7 +4744,8 @@ function populatePlanecard() {

[
{ id: "heading", u: "&deg", d: 0 },
{ id: "level", u: "dB", d: 1 }
{ id: "level", u: "dB", d: 1 },
{ id: "bearing", u: "&deg", d: 0 }
].forEach((el) => (document.getElementById("shipcard_plane_" + el.id).innerHTML = plane[el.id] ? Number(plane[el.id]).toFixed(el.d) + " " + el.u : null));

updateShipcardTrackOption(card_mmsi);
Expand Down
3 changes: 2 additions & 1 deletion Tracking/PlaneDB.h
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,8 @@ class PlaneDB : public StreamIn<Plane::ADSB>
(plane.country_code[0] != ' ' ? "\"" + std::string(plane.country_code, 2) + "\"" : null_str) + comma +
(plane.distance != DISTANCE_UNDEFINED ? std::to_string(plane.distance) : null_str) + comma +
std::to_string(plane.message_types) + comma + std::to_string(plane.message_subtypes) +comma +
std::to_string(plane.group_mask) + comma + std::to_string(plane.last_group) +
std::to_string(plane.group_mask) + comma + std::to_string(plane.last_group) + comma +
(plane.angle != ANGLE_UNDEFINED ? std::to_string(plane.angle) : null_str) +
"]";

delim = comma;
Expand Down

0 comments on commit aa089af

Please sign in to comment.