Browse Source

use the correct reference time

Sven Czarnian 3 năm trước cách đây
mục cha
commit
3746301b0d
1 tập tin đã thay đổi với 2 bổ sung1 xóa
  1. 2 1
      aman/sys/aco/Node.py

+ 2 - 1
aman/sys/aco/Node.py

@@ -121,7 +121,7 @@ class Node:
                 nextWaypointIndex += 1
 
                 arrivalRoute[-1].FlightTime = timedelta(seconds = flightTimeSeconds)
-                arrivalRoute[-1].ETA = self.Inbound.ReportTime + arrivalRoute[-1].FlightTime
+                arrivalRoute[-1].ETA = self.PredictionTime + arrivalRoute[-1].FlightTime
                 arrivalRoute[-1].PTA = arrivalRoute[-1].ETA
                 arrivalRoute[-1].Altitude = currentPosition[0]
                 arrivalRoute[-1].IndicatedAirspeed = currentIAS
@@ -145,6 +145,7 @@ class Node:
                  navData : SctEseFormat, sequencingConfig : AirportSequencing):
         self.PredictedDistanceToIAF = inbound.Report.distanceToIAF
         self.PredictedCoordinate = [ inbound.CurrentPosition.latitude, inbound.CurrentPosition.longitude ]
+        self.PredictionTime = referenceTime
         self.ArrivalCandidates = {}
         self.Inbound = inbound