1
0
Fork 0
Commit graph

8 commits

Author SHA1 Message Date
Curtis L. Olson
1142bde5e9 Tomaskom writes:
I was playing with the target tracking and decided to fix an old bug that causes it to behave wrong at higher altitudes.

Background: the script continuously updates values in the autopilot to follow specified target aircraft (AI/MP). It is controlled directly through the property tree under /autopilot/target-tracking.

Issue: the script reads out true airspeed, but autopilot expects indicated airspeed. This is why at higher altitudes, the tracking always overshoots.

I fixed this by introducing an estimate on indicated airspeed of the target, using the ratio between local aircraft true and indicated airspeed.
I also fixed an issue where it ignored minimum speed setting and polished initialization by using props.globals.initNode() instead of dedicated presence check for every property (and also ensured the nodes have correct types, no more bool stored as double). And the last thing I changed was to increase the default tracking distance to a more sane value, with the original value of 0.05nm the tracking was unstable in heading with most aircraft and started oscillating.
With the changes I applied, the distance is now holding precisely at any altitude and with any winds.
2015-05-28 10:29:38 -05:00
ThorstenB
c26de5ce41 Only run target-tracker-timer when feature is enabled. 2011-03-27 21:02:26 +02:00
mfranz
9927e31504 - use "var" keywords everywhere
- bail out if there's no autopilot at all
2009-01-30 21:24:59 +00:00
curt
203c61aaa1 Minor cosmetic changes. 2007-05-15 16:07:15 +00:00
mfranz
4099269ab3 using printlog() wasn't a good idea, as we don't know if globals.nas was
already initialized. Commenting the messages out.
2006-08-17 18:56:22 +00:00
mfranz
4f90536ea6 shut up 2006-08-09 13:55:48 +00:00
curt
0ac3b042c2 Also set target true heading along with magnetic heading. 2006-07-26 14:43:22 +00:00
curt
3833703808 Rename to avoid "-" in class name. 2006-07-24 17:53:46 +00:00
Renamed from Nasal/track-target.nas (Browse further)