From ba6f4cb42f83f3742bc3d5824440a70e31889c25 Mon Sep 17 00:00:00 2001
From: curt <curt>
Date: Sun, 10 Jun 2007 15:58:50 +0000
Subject: [PATCH] Syd Adams:

Export ground speed to property system under /velocities.
---
 src/FDM/flight.cxx | 5 +++++
 src/FDM/flight.hxx | 1 +
 2 files changed, 6 insertions(+)

diff --git a/src/FDM/flight.cxx b/src/FDM/flight.cxx
index 1474b9746..248685ba0 100644
--- a/src/FDM/flight.cxx
+++ b/src/FDM/flight.cxx
@@ -363,6 +363,10 @@ FGInterface::bind ()
   fgTie("/orientation/yaw-rate-degps", this,
 	&FGInterface::get_Psi_dot_degps);
 
+                                // Ground speed knots
+  fgTie("/velocities/groundspeed-kt", this,
+        &FGInterface::get_V_ground_speed_kt);
+
 				// Calibrated airspeed
   fgTie("/velocities/airspeed-kt", this,
 	&FGInterface::get_V_calibrated_kts,
@@ -486,6 +490,7 @@ FGInterface::unbind ()
   fgUntie("/orientation/side-slip-deg");
   fgUntie("/orientation/alpha-deg");
   fgUntie("/velocities/airspeed-kt");
+   fgUntie("/velocities/groundspeed-kt");
   fgUntie("/velocities/mach");
   fgUntie("/velocities/speed-north-fps");
   fgUntie("/velocities/speed-east-fps");
diff --git a/src/FDM/flight.hxx b/src/FDM/flight.hxx
index f5533625c..3fdfbd1b2 100644
--- a/src/FDM/flight.hxx
+++ b/src/FDM/flight.hxx
@@ -792,6 +792,7 @@ public:
     // inline void set_V_inertial(double v) { v_inertial = v; }
 
     inline double get_V_ground_speed() const { return v_ground_speed; }
+    inline double get_V_ground_speed_kt() const { return v_ground_speed * SG_FEET_TO_METER * 3600 * SG_METER_TO_NM; }
 
     // inline double get_V_equiv() const { return v_equiv; }
     // inline void set_V_equiv( double v ) { v_equiv = v; }