From 3341eae670105c89080092c0d0cf87149fa09537 Mon Sep 17 00:00:00 2001
From: Michael Oborne <mich146@hotmail.com>
Date: Sat, 5 May 2012 21:54:53 +0800
Subject: [PATCH] APM Planner 1.1.80 hazy's lang mod more hud mods - shorten
 lines msi work + uploader

---
 .../ArdupilotMegaPlanner/ArdupilotMega.csproj |    2 +-
 Tools/ArdupilotMegaPlanner/Controls/HUD.cs    |    8 +-
 .../ConfigurationView/ConfigPlanner.cs        | 1097 ++++++++---------
 .../ConfigurationView/ConfigPlanner.resx      |    8 +-
 .../ConfigurationView/Setup.Designer.cs       |    6 +-
 .../Msi/googlecode_upload.py                  |  256 ++++
 Tools/ArdupilotMegaPlanner/Msi/installer.bat  |    8 +
 Tools/ArdupilotMegaPlanner/Msi/installer.wxs  |  405 +++---
 .../Properties/AssemblyInfo.cs                |    2 +-
 .../bin/Release/version.txt                   |    2 +-
 Tools/ArdupilotMegaPlanner/wix/Program.cs     |   53 +-
 11 files changed, 1081 insertions(+), 766 deletions(-)
 create mode 100644 Tools/ArdupilotMegaPlanner/Msi/googlecode_upload.py

diff --git a/Tools/ArdupilotMegaPlanner/ArdupilotMega.csproj b/Tools/ArdupilotMegaPlanner/ArdupilotMega.csproj
index 141329721..660aa3d65 100644
--- a/Tools/ArdupilotMegaPlanner/ArdupilotMega.csproj
+++ b/Tools/ArdupilotMegaPlanner/ArdupilotMega.csproj
@@ -152,7 +152,7 @@
     </Reference>
     <Reference Include="Microsoft.DirectX.DirectInput, Version=1.0.2902.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35">
       <SpecificVersion>False</SpecificVersion>
-      <Private>False</Private>
+      <Private>True</Private>
     </Reference>
     <Reference Include="Microsoft.Dynamic">
     </Reference>
diff --git a/Tools/ArdupilotMegaPlanner/Controls/HUD.cs b/Tools/ArdupilotMegaPlanner/Controls/HUD.cs
index 57df0acbd..fe38edf6d 100644
--- a/Tools/ArdupilotMegaPlanner/Controls/HUD.cs
+++ b/Tools/ArdupilotMegaPlanner/Controls/HUD.cs
@@ -810,8 +810,8 @@ namespace ArdupilotMega.Controls
 
                 //draw pitch           
 
-                int lengthshort = this.Width / 12;
-                int lengthlong = this.Width / 8;
+                int lengthshort = this.Width / 14;
+                int lengthlong = this.Width / 10;
 
                 for (int a = -90; a <= 90; a += 5)
                 {
@@ -996,11 +996,11 @@ namespace ArdupilotMega.Controls
 
                 if (Math.Abs(_heading - _targetheading) < 4)
                 {
-                    drawstring(graphicsObject, (heading % 360).ToString("0").PadLeft(3), font, fontsize, Brushes.Green, headbg.Width / 2 - (fontsize * 1f), headbg.Bottom - 24 - (int)(fontoffset * 1.7));
+                    drawstring(graphicsObject, (heading % 360).ToString("0").PadLeft(3), font, fontsize, whiteBrush, headbg.Width / 2 - (fontsize * 1f), headbg.Bottom - 24 - (int)(fontoffset * 1.7));
                 }
                 else
                 {
-                    drawstring(graphicsObject, (heading % 360).ToString("0").PadLeft(3), font, fontsize, Brushes.Red, headbg.Width / 2 - (fontsize * 1f), headbg.Bottom - 24 - (int)(fontoffset * 1.7));
+                    drawstring(graphicsObject, (heading % 360).ToString("0").PadLeft(3), font, fontsize, whiteBrush, headbg.Width / 2 - (fontsize * 1f), headbg.Bottom - 24 - (int)(fontoffset * 1.7));
                 }
 
                 //                Console.WriteLine("HUD 0 " + (DateTime.Now - starttime).TotalMilliseconds + " " + DateTime.Now.Millisecond);
diff --git a/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/ConfigPlanner.cs b/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/ConfigPlanner.cs
index f1e880361..962672727 100644
--- a/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/ConfigPlanner.cs
+++ b/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/ConfigPlanner.cs
@@ -1,551 +1,550 @@
-using System;
-using System.Collections.Generic;
-using System.ComponentModel;
-using System.Drawing;
-using System.Data;
-using System.Globalization;
-using System.Linq;
-using System.Runtime.InteropServices;
-using System.Text;
-using System.Windows.Forms;
-using DirectShowLib;
-using ArdupilotMega.Controls.BackstageView;
-using ArdupilotMega.Controls;
-using ArdupilotMega.Utilities;
-using System.Threading;
-
-namespace ArdupilotMega.GCSViews.ConfigurationView
-{
-    public partial class ConfigPlanner : BackStageViewContentPanel
-    {
-        private bool startup = false;
-        List<CultureInfo> languages = new List<CultureInfo>();
-
-        public ConfigPlanner()
-        {
-            InitializeComponent();
-        }
-
-
-        private void BUT_videostart_Click(object sender, EventArgs e)
-        {
-            // stop first
-            BUT_videostop_Click(sender, e);
-
-            var bmp = (GCSViews.Configuration.GCSBitmapInfo)CMB_videoresolutions.SelectedItem;
-
-            try
-            {
-                MainV2.cam = new WebCamService.Capture(CMB_videosources.SelectedIndex, bmp.Media);
-
-                MainV2.cam.showhud = CHK_hudshow.Checked;
-
-                MainV2.cam.Start();
-
-                MainV2.config["video_options"] = CMB_videoresolutions.SelectedIndex;
-
-                BUT_videostart.Enabled = false;
-            }
-            catch (Exception ex) { CustomMessageBox.Show("Camera Fail: " + ex.Message); }
-
-        }
-
-        private void BUT_videostop_Click(object sender, EventArgs e)
-        {
-            BUT_videostart.Enabled = true;
-            if (MainV2.cam != null)
-            {
-                MainV2.cam.Dispose();
-                MainV2.cam = null;
-            }
-        }
-
-        private void CMB_videosources_MouseClick(object sender, MouseEventArgs e)
-        {
-            // the reason why i dont populate this list is because on linux/mac this call will fail.
-            WebCamService.Capture capt = new WebCamService.Capture();
-
-            List<string> devices = WebCamService.Capture.getDevices();
-
-            CMB_videosources.DataSource = devices;
-
-            capt.Dispose();
-        }
-
-        private void CMB_videosources_SelectedIndexChanged(object sender, EventArgs e)
-        {
-            int hr;
-            int count;
-            int size;
-            object o;
-            IBaseFilter capFilter = null;
-            ICaptureGraphBuilder2 capGraph = null;
-            AMMediaType media = null;
-            VideoInfoHeader v;
-            VideoStreamConfigCaps c;
-            List<GCSViews.Configuration.GCSBitmapInfo> modes = new List<GCSViews.Configuration.GCSBitmapInfo>();
-
-            // Get the ICaptureGraphBuilder2
-            capGraph = (ICaptureGraphBuilder2)new CaptureGraphBuilder2();
-            IFilterGraph2 m_FilterGraph = (IFilterGraph2)new FilterGraph();
-
-            DsDevice[] capDevices;
-            capDevices = DsDevice.GetDevicesOfCat(FilterCategory.VideoInputDevice);
-
-            // Add the video device
-            hr = m_FilterGraph.AddSourceFilterForMoniker(capDevices[CMB_videosources.SelectedIndex].Mon, null, "Video input", out capFilter);
-            try
-            {
-                DsError.ThrowExceptionForHR(hr);
-            }
-            catch (Exception ex)
-            {
-                CustomMessageBox.Show("Can not add video source\n" + ex.ToString());
-                return;
-            }
-
-            // Find the stream config interface
-            hr = capGraph.FindInterface(PinCategory.Capture, MediaType.Video, capFilter, typeof(IAMStreamConfig).GUID, out o);
-            DsError.ThrowExceptionForHR(hr);
-
-            IAMStreamConfig videoStreamConfig = o as IAMStreamConfig;
-            if (videoStreamConfig == null)
-            {
-                throw new Exception("Failed to get IAMStreamConfig");
-            }
-
-            hr = videoStreamConfig.GetNumberOfCapabilities(out count, out size);
-            DsError.ThrowExceptionForHR(hr);
-            IntPtr TaskMemPointer = Marshal.AllocCoTaskMem(size);
-            for (int i = 0; i < count; i++)
-            {
-                IntPtr ptr = IntPtr.Zero;
-
-                hr = videoStreamConfig.GetStreamCaps(i, out media, TaskMemPointer);
-                v = (VideoInfoHeader)Marshal.PtrToStructure(media.formatPtr, typeof(VideoInfoHeader));
-                c = (VideoStreamConfigCaps)Marshal.PtrToStructure(TaskMemPointer, typeof(VideoStreamConfigCaps));
-                modes.Add(new GCSViews.Configuration.GCSBitmapInfo(v.BmiHeader.Width, v.BmiHeader.Height, c.MaxFrameInterval, c.VideoStandard.ToString(), media));
-            }
-            Marshal.FreeCoTaskMem(TaskMemPointer);
-            DsUtils.FreeAMMediaType(media);
-
-            CMB_videoresolutions.DataSource = modes;
-
-            if (MainV2.getConfig("video_options") != "" && CMB_videosources.Text != "")
-            {
-                CMB_videoresolutions.SelectedIndex = int.Parse(MainV2.getConfig("video_options"));
-            }
-        }
-
-        private void CHK_hudshow_CheckedChanged(object sender, EventArgs e)
-        {
-            GCSViews.FlightData.myhud.hudon = CHK_hudshow.Checked;
-        }
-
-        private void CHK_enablespeech_CheckedChanged(object sender, EventArgs e)
-        {
-            MainV2.speechEnable = CHK_enablespeech.Checked;
-            MainV2.config["speechenable"] = CHK_enablespeech.Checked;
-            if (MainV2.speechEngine != null)
-                MainV2.speechEngine.SpeakAsyncCancelAll();
-        }
-
-        private void CMB_language_SelectedIndexChanged(object sender, EventArgs e)
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Drawing;
+using System.Data;
+using System.Globalization;
+using System.Linq;
+using System.Runtime.InteropServices;
+using System.Text;
+using System.Windows.Forms;
+using DirectShowLib;
+using ArdupilotMega.Controls.BackstageView;
+using ArdupilotMega.Controls;
+using ArdupilotMega.Utilities;
+using System.Threading;
+
+namespace ArdupilotMega.GCSViews.ConfigurationView
+{
+    public partial class ConfigPlanner : BackStageViewContentPanel
+    {
+        private bool startup = false;
+        List<CultureInfo> languages = new List<CultureInfo>();
+
+        public ConfigPlanner()
+        {
+            InitializeComponent();
+        }
+
+
+        private void BUT_videostart_Click(object sender, EventArgs e)
+        {
+            // stop first
+            BUT_videostop_Click(sender, e);
+
+            var bmp = (GCSViews.Configuration.GCSBitmapInfo)CMB_videoresolutions.SelectedItem;
+
+            try
+            {
+                MainV2.cam = new WebCamService.Capture(CMB_videosources.SelectedIndex, bmp.Media);
+
+                MainV2.cam.showhud = CHK_hudshow.Checked;
+
+                MainV2.cam.Start();
+
+                MainV2.config["video_options"] = CMB_videoresolutions.SelectedIndex;
+
+                BUT_videostart.Enabled = false;
+            }
+            catch (Exception ex) { CustomMessageBox.Show("Camera Fail: " + ex.Message); }
+
+        }
+
+        private void BUT_videostop_Click(object sender, EventArgs e)
+        {
+            BUT_videostart.Enabled = true;
+            if (MainV2.cam != null)
+            {
+                MainV2.cam.Dispose();
+                MainV2.cam = null;
+            }
+        }
+
+        private void CMB_videosources_MouseClick(object sender, MouseEventArgs e)
+        {
+            // the reason why i dont populate this list is because on linux/mac this call will fail.
+            WebCamService.Capture capt = new WebCamService.Capture();
+
+            List<string> devices = WebCamService.Capture.getDevices();
+
+            CMB_videosources.DataSource = devices;
+
+            capt.Dispose();
+        }
+
+        private void CMB_videosources_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            int hr;
+            int count;
+            int size;
+            object o;
+            IBaseFilter capFilter = null;
+            ICaptureGraphBuilder2 capGraph = null;
+            AMMediaType media = null;
+            VideoInfoHeader v;
+            VideoStreamConfigCaps c;
+            List<GCSViews.Configuration.GCSBitmapInfo> modes = new List<GCSViews.Configuration.GCSBitmapInfo>();
+
+            // Get the ICaptureGraphBuilder2
+            capGraph = (ICaptureGraphBuilder2)new CaptureGraphBuilder2();
+            IFilterGraph2 m_FilterGraph = (IFilterGraph2)new FilterGraph();
+
+            DsDevice[] capDevices;
+            capDevices = DsDevice.GetDevicesOfCat(FilterCategory.VideoInputDevice);
+
+            // Add the video device
+            hr = m_FilterGraph.AddSourceFilterForMoniker(capDevices[CMB_videosources.SelectedIndex].Mon, null, "Video input", out capFilter);
+            try
+            {
+                DsError.ThrowExceptionForHR(hr);
+            }
+            catch (Exception ex)
+            {
+                CustomMessageBox.Show("Can not add video source\n" + ex.ToString());
+                return;
+            }
+
+            // Find the stream config interface
+            hr = capGraph.FindInterface(PinCategory.Capture, MediaType.Video, capFilter, typeof(IAMStreamConfig).GUID, out o);
+            DsError.ThrowExceptionForHR(hr);
+
+            IAMStreamConfig videoStreamConfig = o as IAMStreamConfig;
+            if (videoStreamConfig == null)
+            {
+                throw new Exception("Failed to get IAMStreamConfig");
+            }
+
+            hr = videoStreamConfig.GetNumberOfCapabilities(out count, out size);
+            DsError.ThrowExceptionForHR(hr);
+            IntPtr TaskMemPointer = Marshal.AllocCoTaskMem(size);
+            for (int i = 0; i < count; i++)
+            {
+                IntPtr ptr = IntPtr.Zero;
+
+                hr = videoStreamConfig.GetStreamCaps(i, out media, TaskMemPointer);
+                v = (VideoInfoHeader)Marshal.PtrToStructure(media.formatPtr, typeof(VideoInfoHeader));
+                c = (VideoStreamConfigCaps)Marshal.PtrToStructure(TaskMemPointer, typeof(VideoStreamConfigCaps));
+                modes.Add(new GCSViews.Configuration.GCSBitmapInfo(v.BmiHeader.Width, v.BmiHeader.Height, c.MaxFrameInterval, c.VideoStandard.ToString(), media));
+            }
+            Marshal.FreeCoTaskMem(TaskMemPointer);
+            DsUtils.FreeAMMediaType(media);
+
+            CMB_videoresolutions.DataSource = modes;
+
+            if (MainV2.getConfig("video_options") != "" && CMB_videosources.Text != "")
+            {
+                CMB_videoresolutions.SelectedIndex = int.Parse(MainV2.getConfig("video_options"));
+            }
+        }
+
+        private void CHK_hudshow_CheckedChanged(object sender, EventArgs e)
+        {
+            GCSViews.FlightData.myhud.hudon = CHK_hudshow.Checked;
+        }
+
+        private void CHK_enablespeech_CheckedChanged(object sender, EventArgs e)
+        {
+            MainV2.speechEnable = CHK_enablespeech.Checked;
+            MainV2.config["speechenable"] = CHK_enablespeech.Checked;
+            if (MainV2.speechEngine != null)
+                MainV2.speechEngine.SpeakAsyncCancelAll();
+        }
+
+        private void CMB_language_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.instance.changelanguage((CultureInfo)CMB_language.SelectedItem);
+
+#if !DEBUG
+                MessageBox.Show("Please Restart the Planner");
+
+                Application.Exit();
+#endif
+        }
+
+        private void CMB_osdcolor_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            if (CMB_osdcolor.Text != "")
+            {
+                MainV2.config["hudcolor"] = CMB_osdcolor.Text;
+                GCSViews.FlightData.myhud.hudcolor = Color.FromKnownColor((KnownColor)Enum.Parse(typeof(KnownColor), CMB_osdcolor.Text));
+            }
+        }
+
+        private void CHK_speechwaypoint_CheckedChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config["speechwaypointenabled"] = ((CheckBox)sender).Checked.ToString();
+
+            if (((CheckBox)sender).Checked)
+            {
+                string speechstring = "Heading to Waypoint {wpn}";
+                if (MainV2.config["speechwaypoint"] != null)
+                    speechstring = MainV2.config["speechwaypoint"].ToString();
+                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
+                MainV2.config["speechwaypoint"] = speechstring;
+            }
+        }
+
+        private void CHK_speechmode_CheckedChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config["speechmodeenabled"] = ((CheckBox)sender).Checked.ToString();
+
+            if (((CheckBox)sender).Checked)
+            {
+                string speechstring = "Mode changed to {mode}";
+                if (MainV2.config["speechmode"] != null)
+                    speechstring = MainV2.config["speechmode"].ToString();
+                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
+                MainV2.config["speechmode"] = speechstring;
+            }
+        }
+
+        private void CHK_speechcustom_CheckedChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config["speechcustomenabled"] = ((CheckBox)sender).Checked.ToString();
+
+            if (((CheckBox)sender).Checked)
+            {
+                string speechstring = "Heading to Waypoint {wpn}, altitude is {alt}, Ground speed is {gsp} ";
+                if (MainV2.config["speechcustom"] != null)
+                    speechstring = MainV2.config["speechcustom"].ToString();
+                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
+                MainV2.config["speechcustom"] = speechstring;
+            }
+        }
+
+        private void BUT_rerequestparams_Click(object sender, EventArgs e)
+        {
+            if (!MainV2.comPort.BaseStream.IsOpen)
+                return;
+            ((MyButton)sender).Enabled = false;
+            try
+            {
+
+                MainV2.comPort.getParamList();
+
+
+
+
+            }
+            catch { CustomMessageBox.Show("Error: getting param list"); }
+
+
+            ((MyButton)sender).Enabled = true;
+            startup = true;
+
+            
+
+            startup = false;
+        }
+
+        private void CHK_speechbattery_CheckedChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config["speechbatteryenabled"] = ((CheckBox)sender).Checked.ToString();
+
+            if (((CheckBox)sender).Checked)
+            {
+                string speechstring = "WARNING, Battery at {batv} Volt";
+                if (MainV2.config["speechbattery"] != null)
+                    speechstring = MainV2.config["speechbattery"].ToString();
+                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
+                MainV2.config["speechbattery"] = speechstring;
+
+                speechstring = "9.6";
+                if (MainV2.config["speechbatteryvolt"] != null)
+                    speechstring = MainV2.config["speechbatteryvolt"].ToString();
+                Common.InputBox("Battery Level", "What Voltage do you want to warn at?", ref speechstring);
+                MainV2.config["speechbatteryvolt"] = speechstring;
+
+            }
+        }
+
+        private void BUT_Joystick_Click(object sender, EventArgs e)
+        {
+            Form joy = new JoystickSetup();
+            ThemeManager.ApplyThemeTo(joy);
+            joy.Show();
+        }
+
+        private void CMB_distunits_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config["distunits"] = CMB_distunits.Text;
+            MainV2.instance.ChangeUnits();
+        }
+
+        private void CMB_speedunits_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config["speedunits"] = CMB_speedunits.Text;
+            MainV2.instance.ChangeUnits();
+        }
+
+        private void CMB_rateattitude_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
+            MainV2.cs.rateattitude = byte.Parse(((ComboBox)sender).Text);
+
+            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.EXTRA1, MainV2.cs.rateattitude); // request attitude
+            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.EXTRA2, MainV2.cs.rateattitude); // request vfr
+        }
+
+        private void CMB_rateposition_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
+            MainV2.cs.rateposition = byte.Parse(((ComboBox)sender).Text);
+
+            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.POSITION, MainV2.cs.rateposition); // request gps
+        }
+
+        private void CMB_ratestatus_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
+            MainV2.cs.ratestatus = byte.Parse(((ComboBox)sender).Text);
+
+            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.EXTENDED_STATUS, MainV2.cs.ratestatus); // mode
+        }
+
+        private void CMB_raterc_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
+            MainV2.cs.raterc = byte.Parse(((ComboBox)sender).Text);
+
+            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.RC_CHANNELS, MainV2.cs.raterc); // request rc info 
+        }
+
+        private void CMB_ratesensors_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
+            MainV2.cs.ratesensors = byte.Parse(((ComboBox)sender).Text);
+
+            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.EXTRA3, MainV2.cs.ratesensors); // request extra stuff - tridge
+            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.RAW_SENSORS, MainV2.cs.ratesensors); // request raw sensor
+        }
+
+        private void CHK_mavdebug_CheckedChanged(object sender, EventArgs e)
+        {
+            MainV2.comPort.debugmavlink = CHK_mavdebug.Checked;
+        }
+
+        private void CHK_resetapmonconnect_CheckedChanged(object sender, EventArgs e)
+        {
+            MainV2.config[((CheckBox)sender).Name] = ((CheckBox)sender).Checked.ToString();
+        }
+
+        private void CHK_speechaltwarning_CheckedChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            MainV2.config["speechaltenabled"] = ((CheckBox)sender).Checked.ToString();
+
+            if (((CheckBox)sender).Checked)
+            {
+                string speechstring = "WARNING, low altitude {alt}";
+                if (MainV2.config["speechalt"] != null)
+                    speechstring = MainV2.config["speechalt"].ToString();
+                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
+                MainV2.config["speechalt"] = speechstring;
+
+                speechstring = "2";
+                if (MainV2.config["speechaltheight"] != null)
+                    speechstring = MainV2.config["speechaltheight"].ToString();
+                Common.InputBox("Min Alt", "What altitude do you want to warn at? (relative to home)", ref speechstring);
+                MainV2.config["speechaltheight"] = (double.Parse(speechstring) / MainV2.cs.multiplierdist).ToString(); // save as m
+
+            }
+        }
+
+        private void NUM_tracklength_ValueChanged(object sender, EventArgs e)
+        {
+            MainV2.config["NUM_tracklength"] = NUM_tracklength.Value.ToString();
+
+        }
+
+        private void CHK_loadwponconnect_CheckedChanged(object sender, EventArgs e)
+        {
+            MainV2.config["loadwpsonconnect"] = CHK_loadwponconnect.Checked.ToString();
+        }
+
+        private void CHK_GDIPlus_CheckedChanged(object sender, EventArgs e)
+        {
+            if (startup)
+                return;
+            CustomMessageBox.Show("You need to restart the planner for this to take effect");
+            MainV2.config["CHK_GDIPlus"] = CHK_GDIPlus.Checked.ToString();
+        }
+
+        private void ConfigPlanner_Load(object sender, EventArgs e)
+        {
+            startup = true;
+
+            // setup up camera button states
+            if (MainV2.cam != null)
+            {
+                BUT_videostart.Enabled = false;
+                CHK_hudshow.Checked = GCSViews.FlightData.myhud.hudon;
+            }
+            else
+            {
+                BUT_videostart.Enabled = true;
+            }
+
+            // setup speech states
+            if (MainV2.config["speechenable"] != null)
+                CHK_enablespeech.Checked = bool.Parse(MainV2.config["speechenable"].ToString());
+            if (MainV2.config["speechwaypointenabled"] != null)
+                CHK_speechwaypoint.Checked = bool.Parse(MainV2.config["speechwaypointenabled"].ToString());
+            if (MainV2.config["speechmodeenabled"] != null)
+                CHK_speechmode.Checked = bool.Parse(MainV2.config["speechmodeenabled"].ToString());
+            if (MainV2.config["speechcustomenabled"] != null)
+                CHK_speechcustom.Checked = bool.Parse(MainV2.config["speechcustomenabled"].ToString());
+            if (MainV2.config["speechbatteryenabled"] != null)
+                CHK_speechbattery.Checked = bool.Parse(MainV2.config["speechbatteryenabled"].ToString());
+            if (MainV2.config["speechaltenabled"] != null)
+                CHK_speechaltwarning.Checked = bool.Parse(MainV2.config["speechaltenabled"].ToString());
+
+            // this can't fail because it set at startup
+            NUM_tracklength.Value = int.Parse(MainV2.config["NUM_tracklength"].ToString());
+
+            // get wps on connect
+            if (MainV2.config["loadwpsonconnect"] != null)
+                CHK_loadwponconnect.Checked = bool.Parse(MainV2.config["loadwpsonconnect"].ToString());
+
+            // setup other config state
+            if (MainV2.config["CHK_resetapmonconnect"] != null)
+                CHK_resetapmonconnect.Checked = bool.Parse(MainV2.config["CHK_resetapmonconnect"].ToString());
+
+            CMB_rateattitude.Text = MainV2.cs.rateattitude.ToString();
+            CMB_rateposition.Text = MainV2.cs.rateposition.ToString();
+            CMB_raterc.Text = MainV2.cs.raterc.ToString();
+            CMB_ratestatus.Text = MainV2.cs.ratestatus.ToString();
+            CMB_ratesensors.Text = MainV2.cs.ratesensors.ToString();
+
+
+            if (MainV2.config["CHK_GDIPlus"] != null)
+                CHK_GDIPlus.Checked = bool.Parse(MainV2.config["CHK_GDIPlus"].ToString());
+
+            if (MainV2.config["CHK_maprotation"] != null)
+                CHK_maprotation.Checked = bool.Parse(MainV2.config["CHK_maprotation"].ToString());
+
+            //set hud color state
+            string hudcolor = (string)MainV2.config["hudcolor"];
+
+            CMB_osdcolor.DataSource = Enum.GetNames(typeof(KnownColor));
+            if (hudcolor != null)
+            {
+                int index = CMB_osdcolor.Items.IndexOf(hudcolor);
+                CMB_osdcolor.SelectedIndex = index;
+            }
+            else
+            {
+                int index = CMB_osdcolor.Items.IndexOf("White");
+                CMB_osdcolor.SelectedIndex = index;
+            }
+
+            // set distance/speed unit states
+            CMB_distunits.DataSource = Enum.GetNames(typeof(Common.distances));
+            CMB_speedunits.DataSource = Enum.GetNames(typeof(Common.speeds));
+
+            if (MainV2.config["distunits"] != null)
+                CMB_distunits.Text = MainV2.config["distunits"].ToString();
+            if (MainV2.config["speedunits"] != null)
+                CMB_speedunits.Text = MainV2.config["speedunits"].ToString();
+
+            // setup language selection
+            CultureInfo ci = null;
+            foreach (string name in new string[] { "en-US", "zh-Hans", "zh-TW", "ru-RU", "Fr", "Pl", "it-IT", "es-ES" })
+            {
+                ci = CultureInfoEx.GetCultureInfo(name);
+                if (ci != null)
+                    languages.Add(ci);
+            }
+
+            CMB_language.DisplayMember = "DisplayName";
+            CMB_language.DataSource = languages;
+            ci = Thread.CurrentThread.CurrentUICulture;
+            for (int i = 0; i < languages.Count; i++)
+            {
+                if (ci.IsChildOf(languages[i]))
+                {
+                    CMB_language.SelectedIndex = i;
+                    break;
+                }
+            }
+            //CMB_language.SelectedIndexChanged += CMB_language_SelectedIndexChanged;
+
+            startup = false;
+        }
+
+        private void CMB_osdcolor_DrawItem(object sender, DrawItemEventArgs e)
+        {
+            if (e.Index < 0)
+                return;
+
+            Graphics g = e.Graphics;
+            Rectangle rect = e.Bounds;
+            Brush brush = null;
+
+            if ((e.State & DrawItemState.Selected) == 0)
+                brush = new SolidBrush(CMB_osdcolor.BackColor);
+            else
+                brush = SystemBrushes.Highlight;
+
+            g.FillRectangle(brush, rect);
+
+            brush = new SolidBrush(Color.FromName((string)CMB_osdcolor.Items[e.Index]));
+
+            g.FillRectangle(brush, rect.X + 2, rect.Y + 2, 30, rect.Height - 4);
+            g.DrawRectangle(Pens.Black, rect.X + 2, rect.Y + 2, 30, rect.Height - 4);
+
+            if ((e.State & DrawItemState.Selected) == 0)
+                brush = new SolidBrush(CMB_osdcolor.ForeColor);
+            else
+                brush = SystemBrushes.HighlightText;
+            g.DrawString(CMB_osdcolor.Items[e.Index].ToString(),
+                CMB_osdcolor.Font, brush, rect.X + 35, rect.Top + rect.Height - CMB_osdcolor.Font.Height);
+        }
+
+        private void CMB_videosources_Click(object sender, EventArgs e)
+        {
+            // the reason why i dont populate this list is because on linux/mac this call will fail.
+            WebCamService.Capture capt = new WebCamService.Capture();
+
+            List<string> devices = WebCamService.Capture.getDevices();
+
+            CMB_videosources.DataSource = devices;
+
+            capt.Dispose();
+        }
+
+        private void CHK_maprotation_CheckedChanged(object sender, EventArgs e)
         {
             if (startup)
-                return;
-
-            MainV2.instance.changelanguage((CultureInfo)CMB_language.SelectedItem);
-
-#if !DEBUG
-                MessageBox.Show("Please Restart the Planner");
-
-                Application.Exit();
-#endif
-        }
-
-        private void CMB_osdcolor_SelectedIndexChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            if (CMB_osdcolor.Text != "")
-            {
-                MainV2.config["hudcolor"] = CMB_osdcolor.Text;
-                GCSViews.FlightData.myhud.hudcolor = Color.FromKnownColor((KnownColor)Enum.Parse(typeof(KnownColor), CMB_osdcolor.Text));
-            }
-        }
-
-        private void CHK_speechwaypoint_CheckedChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config["speechwaypointenabled"] = ((CheckBox)sender).Checked.ToString();
-
-            if (((CheckBox)sender).Checked)
-            {
-                string speechstring = "Heading to Waypoint {wpn}";
-                if (MainV2.config["speechwaypoint"] != null)
-                    speechstring = MainV2.config["speechwaypoint"].ToString();
-                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
-                MainV2.config["speechwaypoint"] = speechstring;
-            }
-        }
-
-        private void CHK_speechmode_CheckedChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config["speechmodeenabled"] = ((CheckBox)sender).Checked.ToString();
-
-            if (((CheckBox)sender).Checked)
-            {
-                string speechstring = "Mode changed to {mode}";
-                if (MainV2.config["speechmode"] != null)
-                    speechstring = MainV2.config["speechmode"].ToString();
-                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
-                MainV2.config["speechmode"] = speechstring;
-            }
-        }
-
-        private void CHK_speechcustom_CheckedChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config["speechcustomenabled"] = ((CheckBox)sender).Checked.ToString();
-
-            if (((CheckBox)sender).Checked)
-            {
-                string speechstring = "Heading to Waypoint {wpn}, altitude is {alt}, Ground speed is {gsp} ";
-                if (MainV2.config["speechcustom"] != null)
-                    speechstring = MainV2.config["speechcustom"].ToString();
-                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
-                MainV2.config["speechcustom"] = speechstring;
-            }
-        }
-
-        private void BUT_rerequestparams_Click(object sender, EventArgs e)
-        {
-            if (!MainV2.comPort.BaseStream.IsOpen)
-                return;
-            ((MyButton)sender).Enabled = false;
-            try
-            {
-
-                MainV2.comPort.getParamList();
-
-
-
-
-            }
-            catch { CustomMessageBox.Show("Error: getting param list"); }
-
-
-            ((MyButton)sender).Enabled = true;
-            startup = true;
-
-            
-
-            startup = false;
-        }
-
-        private void CHK_speechbattery_CheckedChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config["speechbatteryenabled"] = ((CheckBox)sender).Checked.ToString();
-
-            if (((CheckBox)sender).Checked)
-            {
-                string speechstring = "WARNING, Battery at {batv} Volt";
-                if (MainV2.config["speechbattery"] != null)
-                    speechstring = MainV2.config["speechbattery"].ToString();
-                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
-                MainV2.config["speechbattery"] = speechstring;
-
-                speechstring = "9.6";
-                if (MainV2.config["speechbatteryvolt"] != null)
-                    speechstring = MainV2.config["speechbatteryvolt"].ToString();
-                Common.InputBox("Battery Level", "What Voltage do you want to warn at?", ref speechstring);
-                MainV2.config["speechbatteryvolt"] = speechstring;
-
-            }
-        }
-
-        private void BUT_Joystick_Click(object sender, EventArgs e)
-        {
-            Form joy = new JoystickSetup();
-            ThemeManager.ApplyThemeTo(joy);
-            joy.Show();
-        }
-
-        private void CMB_distunits_SelectedIndexChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config["distunits"] = CMB_distunits.Text;
-            MainV2.instance.ChangeUnits();
-        }
-
-        private void CMB_speedunits_SelectedIndexChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config["speedunits"] = CMB_speedunits.Text;
-            MainV2.instance.ChangeUnits();
-        }
-
-        private void CMB_rateattitude_SelectedIndexChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
-            MainV2.cs.rateattitude = byte.Parse(((ComboBox)sender).Text);
-
-            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.EXTRA1, MainV2.cs.rateattitude); // request attitude
-            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.EXTRA2, MainV2.cs.rateattitude); // request vfr
-        }
-
-        private void CMB_rateposition_SelectedIndexChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
-            MainV2.cs.rateposition = byte.Parse(((ComboBox)sender).Text);
-
-            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.POSITION, MainV2.cs.rateposition); // request gps
-        }
-
-        private void CMB_ratestatus_SelectedIndexChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
-            MainV2.cs.ratestatus = byte.Parse(((ComboBox)sender).Text);
-
-            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.EXTENDED_STATUS, MainV2.cs.ratestatus); // mode
-        }
-
-        private void CMB_raterc_SelectedIndexChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
-            MainV2.cs.raterc = byte.Parse(((ComboBox)sender).Text);
-
-            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.RC_CHANNELS, MainV2.cs.raterc); // request rc info 
-        }
-
-        private void CMB_ratesensors_SelectedIndexChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config[((ComboBox)sender).Name] = ((ComboBox)sender).Text;
-            MainV2.cs.ratesensors = byte.Parse(((ComboBox)sender).Text);
-
-            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.EXTRA3, MainV2.cs.ratesensors); // request extra stuff - tridge
-            MainV2.comPort.requestDatastream((byte)ArdupilotMega.MAVLink.MAV_DATA_STREAM.RAW_SENSORS, MainV2.cs.ratesensors); // request raw sensor
-        }
-
-        private void CHK_mavdebug_CheckedChanged(object sender, EventArgs e)
-        {
-            MainV2.comPort.debugmavlink = CHK_mavdebug.Checked;
-        }
-
-        private void CHK_resetapmonconnect_CheckedChanged(object sender, EventArgs e)
-        {
-            MainV2.config[((CheckBox)sender).Name] = ((CheckBox)sender).Checked.ToString();
-        }
-
-        private void CHK_speechaltwarning_CheckedChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config["speechaltenabled"] = ((CheckBox)sender).Checked.ToString();
-
-            if (((CheckBox)sender).Checked)
-            {
-                string speechstring = "WARNING, low altitude {alt}";
-                if (MainV2.config["speechalt"] != null)
-                    speechstring = MainV2.config["speechalt"].ToString();
-                Common.InputBox("Notification", "What do you want it to say?", ref speechstring);
-                MainV2.config["speechalt"] = speechstring;
-
-                speechstring = "2";
-                if (MainV2.config["speechaltheight"] != null)
-                    speechstring = MainV2.config["speechaltheight"].ToString();
-                Common.InputBox("Min Alt", "What altitude do you want to warn at? (relative to home)", ref speechstring);
-                MainV2.config["speechaltheight"] = (double.Parse(speechstring) / MainV2.cs.multiplierdist).ToString(); // save as m
-
-            }
-        }
-
-        private void NUM_tracklength_ValueChanged(object sender, EventArgs e)
-        {
-            MainV2.config["NUM_tracklength"] = NUM_tracklength.Value.ToString();
-
-        }
-
-        private void CHK_loadwponconnect_CheckedChanged(object sender, EventArgs e)
-        {
-            MainV2.config["loadwpsonconnect"] = CHK_loadwponconnect.Checked.ToString();
-        }
-
-        private void CHK_GDIPlus_CheckedChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            CustomMessageBox.Show("You need to restart the planner for this to take effect");
-            MainV2.config["CHK_GDIPlus"] = CHK_GDIPlus.Checked.ToString();
-        }
-
-        private void ConfigPlanner_Load(object sender, EventArgs e)
-        {
-            startup = true;
-
-            // setup up camera button states
-            if (MainV2.cam != null)
-            {
-                BUT_videostart.Enabled = false;
-                CHK_hudshow.Checked = GCSViews.FlightData.myhud.hudon;
-            }
-            else
-            {
-                BUT_videostart.Enabled = true;
-            }
-
-            // setup speech states
-            if (MainV2.config["speechenable"] != null)
-                CHK_enablespeech.Checked = bool.Parse(MainV2.config["speechenable"].ToString());
-            if (MainV2.config["speechwaypointenabled"] != null)
-                CHK_speechwaypoint.Checked = bool.Parse(MainV2.config["speechwaypointenabled"].ToString());
-            if (MainV2.config["speechmodeenabled"] != null)
-                CHK_speechmode.Checked = bool.Parse(MainV2.config["speechmodeenabled"].ToString());
-            if (MainV2.config["speechcustomenabled"] != null)
-                CHK_speechcustom.Checked = bool.Parse(MainV2.config["speechcustomenabled"].ToString());
-            if (MainV2.config["speechbatteryenabled"] != null)
-                CHK_speechbattery.Checked = bool.Parse(MainV2.config["speechbatteryenabled"].ToString());
-            if (MainV2.config["speechaltenabled"] != null)
-                CHK_speechaltwarning.Checked = bool.Parse(MainV2.config["speechaltenabled"].ToString());
-
-            // this can't fail because it set at startup
-            NUM_tracklength.Value = int.Parse(MainV2.config["NUM_tracklength"].ToString());
-
-            // get wps on connect
-            if (MainV2.config["loadwpsonconnect"] != null)
-                CHK_loadwponconnect.Checked = bool.Parse(MainV2.config["loadwpsonconnect"].ToString());
-
-            // setup other config state
-            if (MainV2.config["CHK_resetapmonconnect"] != null)
-                CHK_resetapmonconnect.Checked = bool.Parse(MainV2.config["CHK_resetapmonconnect"].ToString());
-
-            CMB_rateattitude.Text = MainV2.cs.rateattitude.ToString();
-            CMB_rateposition.Text = MainV2.cs.rateposition.ToString();
-            CMB_raterc.Text = MainV2.cs.raterc.ToString();
-            CMB_ratestatus.Text = MainV2.cs.ratestatus.ToString();
-            CMB_ratesensors.Text = MainV2.cs.ratesensors.ToString();
-
-
-            if (MainV2.config["CHK_GDIPlus"] != null)
-                CHK_GDIPlus.Checked = bool.Parse(MainV2.config["CHK_GDIPlus"].ToString());
-
-            if (MainV2.config["CHK_maprotation"] != null)
-                CHK_maprotation.Checked = bool.Parse(MainV2.config["CHK_maprotation"].ToString());
-
-            //set hud color state
-            string hudcolor = (string)MainV2.config["hudcolor"];
-
-            CMB_osdcolor.DataSource = Enum.GetNames(typeof(KnownColor));
-            if (hudcolor != null)
-            {
-                int index = CMB_osdcolor.Items.IndexOf(hudcolor);
-                CMB_osdcolor.SelectedIndex = index;
-            }
-            else
-            {
-                int index = CMB_osdcolor.Items.IndexOf("White");
-                CMB_osdcolor.SelectedIndex = index;
-            }
-
-            // set distance/speed unit states
-            CMB_distunits.DataSource = Enum.GetNames(typeof(Common.distances));
-            CMB_speedunits.DataSource = Enum.GetNames(typeof(Common.speeds));
-
-            if (MainV2.config["distunits"] != null)
-                CMB_distunits.Text = MainV2.config["distunits"].ToString();
-            if (MainV2.config["speedunits"] != null)
-                CMB_speedunits.Text = MainV2.config["speedunits"].ToString();
-
-            // setup language selection
-            CultureInfo ci = null;
-            foreach (string name in new string[] { "en-US", "zh-Hans", "zh-TW", "ru-RU", "Fr", "Pl", "it-IT", "es-ES" })
-            {
-                ci = CultureInfoEx.GetCultureInfo(name);
-                if (ci != null)
-                    languages.Add(ci);
-            }
-
-            CMB_language.DisplayMember = "DisplayName";
-            CMB_language.DataSource = languages;
-            ci = Thread.CurrentThread.CurrentUICulture;
-            for (int i = 0; i < languages.Count; i++)
-            {
-                if (ci.IsChildOf(languages[i]))
-                {
-                    CMB_language.SelectedIndex = i;
-                    break;
-                }
-            }
-            //CMB_language.SelectedIndexChanged += CMB_language_SelectedIndexChanged;
-
-            startup = false;
-        }
-
-        private void CMB_osdcolor_DrawItem(object sender, DrawItemEventArgs e)
-        {
-            if (e.Index < 0)
-                return;
-
-            Graphics g = e.Graphics;
-            Rectangle rect = e.Bounds;
-            Brush brush = null;
-
-            if ((e.State & DrawItemState.Selected) == 0)
-                brush = new SolidBrush(CMB_osdcolor.BackColor);
-            else
-                brush = SystemBrushes.Highlight;
-
-            g.FillRectangle(brush, rect);
-
-            brush = new SolidBrush(Color.FromName((string)CMB_osdcolor.Items[e.Index]));
-
-            g.FillRectangle(brush, rect.X + 2, rect.Y + 2, 30, rect.Height - 4);
-            g.DrawRectangle(Pens.Black, rect.X + 2, rect.Y + 2, 30, rect.Height - 4);
-
-            if ((e.State & DrawItemState.Selected) == 0)
-                brush = new SolidBrush(CMB_osdcolor.ForeColor);
-            else
-                brush = SystemBrushes.HighlightText;
-            g.DrawString(CMB_osdcolor.Items[e.Index].ToString(),
-                CMB_osdcolor.Font, brush, rect.X + 35, rect.Top + rect.Height - CMB_osdcolor.Font.Height);
-        }
-
-        private void CMB_videosources_Click(object sender, EventArgs e)
-        {
-            // the reason why i dont populate this list is because on linux/mac this call will fail.
-            WebCamService.Capture capt = new WebCamService.Capture();
-
-            List<string> devices = WebCamService.Capture.getDevices();
-
-            CMB_videosources.DataSource = devices;
-
-            capt.Dispose();
-        }
-
-        private void CHK_maprotation_CheckedChanged(object sender, EventArgs e)
-        {
-            if (startup)
-                return;
-            MainV2.config["CHK_maprotation"] = CHK_maprotation.Checked.ToString();
-        }
-    }
-}
+                return;
+            MainV2.config["CHK_maprotation"] = CHK_maprotation.Checked.ToString();
+        }
+    }
+}
diff --git a/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/ConfigPlanner.resx b/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/ConfigPlanner.resx
index eb2fb0121..7836529e8 100644
--- a/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/ConfigPlanner.resx
+++ b/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/ConfigPlanner.resx
@@ -1268,7 +1268,7 @@
     <value>BUT_Joystick</value>
   </data>
   <data name="&gt;&gt;BUT_Joystick.Type" xml:space="preserve">
-    <value>ArdupilotMega.Controls.MyButton, ArdupilotMegaPlanner, Version=1.1.4507.18015, Culture=neutral, PublicKeyToken=null</value>
+    <value>ArdupilotMega.Controls.MyButton, ArdupilotMegaPlanner, Version=1.1.4498.31567, Culture=neutral, PublicKeyToken=null</value>
   </data>
   <data name="&gt;&gt;BUT_Joystick.Parent" xml:space="preserve">
     <value>$this</value>
@@ -1295,7 +1295,7 @@
     <value>BUT_videostop</value>
   </data>
   <data name="&gt;&gt;BUT_videostop.Type" xml:space="preserve">
-    <value>ArdupilotMega.Controls.MyButton, ArdupilotMegaPlanner, Version=1.1.4507.18015, Culture=neutral, PublicKeyToken=null</value>
+    <value>ArdupilotMega.Controls.MyButton, ArdupilotMegaPlanner, Version=1.1.4498.31567, Culture=neutral, PublicKeyToken=null</value>
   </data>
   <data name="&gt;&gt;BUT_videostop.Parent" xml:space="preserve">
     <value>$this</value>
@@ -1322,7 +1322,7 @@
     <value>BUT_videostart</value>
   </data>
   <data name="&gt;&gt;BUT_videostart.Type" xml:space="preserve">
-    <value>ArdupilotMega.Controls.MyButton, ArdupilotMegaPlanner, Version=1.1.4507.18015, Culture=neutral, PublicKeyToken=null</value>
+    <value>ArdupilotMega.Controls.MyButton, ArdupilotMegaPlanner, Version=1.1.4498.31567, Culture=neutral, PublicKeyToken=null</value>
   </data>
   <data name="&gt;&gt;BUT_videostart.Parent" xml:space="preserve">
     <value>$this</value>
@@ -1397,6 +1397,6 @@
     <value>ConfigPlanner</value>
   </data>
   <data name="&gt;&gt;$this.Type" xml:space="preserve">
-    <value>ArdupilotMega.Controls.BackstageView.BackStageViewContentPanel, ArdupilotMegaPlanner, Version=1.1.4507.18015, Culture=neutral, PublicKeyToken=null</value>
+    <value>ArdupilotMega.Controls.BackstageView.BackStageViewContentPanel, ArdupilotMegaPlanner, Version=1.1.4498.31567, Culture=neutral, PublicKeyToken=null</value>
   </data>
 </root>
\ No newline at end of file
diff --git a/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/Setup.Designer.cs b/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/Setup.Designer.cs
index d37d804e8..329224c51 100644
--- a/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/Setup.Designer.cs
+++ b/Tools/ArdupilotMegaPlanner/GCSViews/ConfigurationView/Setup.Designer.cs
@@ -37,15 +37,15 @@
             this.backstageView.Dock = System.Windows.Forms.DockStyle.Fill;
             this.backstageView.Location = new System.Drawing.Point(0, 0);
             this.backstageView.Name = "backstageView";
-            this.backstageView.Size = new System.Drawing.Size(947, 506);
+            this.backstageView.Size = new System.Drawing.Size(1008, 506);
             this.backstageView.TabIndex = 0;
             // 
             // Setup
             // 
             this.Controls.Add(this.backstageView);
-            this.MinimumSize = new System.Drawing.Size(947, 506);
+            this.MinimumSize = new System.Drawing.Size(1000, 450);
             this.Name = "Setup";
-            this.Size = new System.Drawing.Size(947, 506);
+            this.Size = new System.Drawing.Size(1008, 506);
             this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.Setup_FormClosing);
             this.Load += new System.EventHandler(this.Setup_Load);
             this.ResumeLayout(false);
diff --git a/Tools/ArdupilotMegaPlanner/Msi/googlecode_upload.py b/Tools/ArdupilotMegaPlanner/Msi/googlecode_upload.py
new file mode 100644
index 000000000..16912361e
--- /dev/null
+++ b/Tools/ArdupilotMegaPlanner/Msi/googlecode_upload.py
@@ -0,0 +1,256 @@
+#!/usr/bin/env python
+#
+# Copyright 2006, 2007 Google Inc. All Rights Reserved.
+# Author: danderson@google.com (David Anderson)
+#
+# Script for uploading files to a Google Code project.
+#
+# This is intended to be both a useful script for people who want to
+# streamline project uploads and a reference implementation for
+# uploading files to Google Code projects.
+#
+# To upload a file to Google Code, you need to provide a path to the
+# file on your local machine, a small summary of what the file is, a
+# project name, and a valid account that is a member or owner of that
+# project.  You can optionally provide a list of labels that apply to
+# the file.  The file will be uploaded under the same name that it has
+# in your local filesystem (that is, the "basename" or last path
+# component).  Run the script with '--help' to get the exact syntax
+# and available options.
+#
+# Note that the upload script requests that you enter your
+# googlecode.com password.  This is NOT your Gmail account password!
+# This is the password you use on googlecode.com for committing to
+# Subversion and uploading files.  You can find your password by going
+# to http://code.google.com/hosting/settings when logged in with your
+# Gmail account. If you have already committed to your project's
+# Subversion repository, the script will automatically retrieve your
+# credentials from there (unless disabled, see the output of '--help'
+# for details).
+#
+# If you are looking at this script as a reference for implementing
+# your own Google Code file uploader, then you should take a look at
+# the upload() function, which is the meat of the uploader.  You
+# basically need to build a multipart/form-data POST request with the
+# right fields and send it to https://PROJECT.googlecode.com/files .
+# Authenticate the request using HTTP Basic authentication, as is
+# shown below.
+#
+# Licensed under the terms of the Apache Software License 2.0:
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+# Questions, comments, feature requests and patches are most welcome.
+# Please direct all of these to the Google Code users group:
+#  http://groups.google.com/group/google-code-hosting
+
+"""Google Code file uploader script.
+"""
+
+__author__ = 'danderson@google.com (David Anderson)'
+
+import httplib
+import os.path
+import optparse
+import getpass
+import base64
+import sys
+
+
+def upload(file, project_name, user_name, password, summary, labels=None):
+  """Upload a file to a Google Code project's file server.
+
+  Args:
+    file: The local path to the file.
+    project_name: The name of your project on Google Code.
+    user_name: Your Google account name.
+    password: The googlecode.com password for your account.
+              Note that this is NOT your global Google Account password!
+    summary: A small description for the file.
+    labels: an optional list of label strings with which to tag the file.
+
+  Returns: a tuple:
+    http_status: 201 if the upload succeeded, something else if an
+                 error occured.
+    http_reason: The human-readable string associated with http_status
+    file_url: If the upload succeeded, the URL of the file on Google
+              Code, None otherwise.
+  """
+  # The login is the user part of user@gmail.com. If the login provided
+  # is in the full user@domain form, strip it down.
+  if user_name.endswith('@gmail.com'):
+    user_name = user_name[:user_name.index('@gmail.com')]
+
+  form_fields = [('summary', summary)]
+  if labels is not None:
+    form_fields.extend([('label', l.strip()) for l in labels])
+
+  content_type, body = encode_upload_request(form_fields, file)
+
+  upload_host = '%s.googlecode.com' % project_name
+  upload_uri = '/files'
+  auth_token = base64.b64encode('%s:%s'% (user_name, password))
+  headers = {
+    'Authorization': 'Basic %s' % auth_token,
+    'User-Agent': 'Googlecode.com uploader v0.9.4',
+    'Content-Type': content_type,
+    }
+
+  server = httplib.HTTPSConnection(upload_host)
+  server.request('POST', upload_uri, body, headers)
+  resp = server.getresponse()
+  server.close()
+
+  if resp.status == 201:
+    location = resp.getheader('Location', None)
+  else:
+    location = None
+  return resp.status, resp.reason, location
+
+
+def encode_upload_request(fields, file_path):
+  """Encode the given fields and file into a multipart form body.
+
+  fields is a sequence of (name, value) pairs. file is the path of
+  the file to upload. The file will be uploaded to Google Code with
+  the same file name.
+
+  Returns: (content_type, body) ready for httplib.HTTP instance
+  """
+  BOUNDARY = '----------Googlecode_boundary_reindeer_flotilla'
+  CRLF = '\r\n'
+
+  body = []
+
+  # Add the metadata about the upload first
+  for key, value in fields:
+    body.extend(
+      ['--' + BOUNDARY,
+       'Content-Disposition: form-data; name="%s"' % key,
+       '',
+       value,
+       ])
+
+  # Now add the file itself
+  file_name = os.path.basename(file_path)
+  f = open(file_path, 'rb')
+  file_content = f.read()
+  f.close()
+
+  body.extend(
+    ['--' + BOUNDARY,
+     'Content-Disposition: form-data; name="filename"; filename="%s"'
+     % file_name,
+     # The upload server determines the mime-type, no need to set it.
+     'Content-Type: application/octet-stream',
+     '',
+     file_content,
+     ])
+
+  # Finalize the form body
+  body.extend(['--' + BOUNDARY + '--', ''])
+
+  return 'multipart/form-data; boundary=%s' % BOUNDARY, CRLF.join(body)
+
+
+def upload_find_auth(file_path, project_name, summary, labels=None,
+                     user_name=None, password=None, tries=3):
+  """Find credentials and upload a file to a Google Code project's file server.
+
+  file_path, project_name, summary, and labels are passed as-is to upload.
+
+  Args:
+    file_path: The local path to the file.
+    project_name: The name of your project on Google Code.
+    summary: A small description for the file.
+    labels: an optional list of label strings with which to tag the file.
+    config_dir: Path to Subversion configuration directory, 'none', or None.
+    user_name: Your Google account name.
+    tries: How many attempts to make.
+  """
+  if user_name is None or password is None:
+    from netrc import netrc
+    authenticators = netrc().authenticators("code.google.com")
+    if authenticators:
+      if user_name is None:
+        user_name = authenticators[0]
+      if password is None:
+        password = authenticators[2]
+
+  while tries > 0:
+    if user_name is None:
+      # Read username if not specified or loaded from svn config, or on
+      # subsequent tries.
+      sys.stdout.write('Please enter your googlecode.com username: ')
+      sys.stdout.flush()
+      user_name = sys.stdin.readline().rstrip()
+    if password is None:
+      # Read password if not loaded from svn config, or on subsequent tries.
+      print 'Please enter your googlecode.com password.'
+      print '** Note that this is NOT your Gmail account password! **'
+      print 'It is the password you use to access Subversion repositories,'
+      print 'and can be found here: http://code.google.com/hosting/settings'
+      password = getpass.getpass()
+
+    status, reason, url = upload(file_path, project_name, user_name, password,
+                                 summary, labels)
+    # Returns 403 Forbidden instead of 401 Unauthorized for bad
+    # credentials as of 2007-07-17.
+    if status in [httplib.FORBIDDEN, httplib.UNAUTHORIZED]:
+      # Rest for another try.
+      user_name = password = None
+      tries = tries - 1
+    else:
+      # We're done.
+      break
+
+  return status, reason, url
+
+
+def main():
+  parser = optparse.OptionParser(usage='googlecode-upload.py -s SUMMARY '
+                                 '-p PROJECT [options] FILE')
+  parser.add_option('-s', '--summary', dest='summary',
+                    help='Short description of the file')
+  parser.add_option('-p', '--project', dest='project',
+                    help='Google Code project name')
+  parser.add_option('-u', '--user', dest='user',
+                    help='Your Google Code username')
+  parser.add_option('-w', '--password', dest='password',
+                    help='Your Google Code password')
+  parser.add_option('-l', '--labels', dest='labels',
+                    help='An optional list of comma-separated labels to attach '
+                    'to the file')
+
+  options, args = parser.parse_args()
+
+  if not options.summary:
+    parser.error('File summary is missing.')
+  elif not options.project:
+    parser.error('Project name is missing.')
+  elif len(args) < 1:
+    parser.error('File to upload not provided.')
+  elif len(args) > 1:
+    parser.error('Only one file may be specified.')
+
+  file_path = args[0]
+
+  if options.labels:
+    labels = options.labels.split(',')
+  else:
+    labels = None
+
+  status, reason, url = upload_find_auth(file_path, options.project,
+                                         options.summary, labels,
+                                         options.user, options.password)
+  if url:
+    print 'The file was uploaded successfully.'
+    print 'URL: %s' % url
+    return 0
+  else:
+    print 'An error occurred. Your file was not uploaded.'
+    print 'Google Code upload server said: %s (%s)' % (reason, status)
+    return 1
+
+
+if __name__ == '__main__':
+  sys.exit(main())
diff --git a/Tools/ArdupilotMegaPlanner/Msi/installer.bat b/Tools/ArdupilotMegaPlanner/Msi/installer.bat
index dcececb61..7256e4d97 100644
--- a/Tools/ArdupilotMegaPlanner/Msi/installer.bat
+++ b/Tools/ArdupilotMegaPlanner/Msi/installer.bat
@@ -2,6 +2,8 @@
 
 wix.exe ..\bin\release\
 
+pause
+
 del installer.wixobj
 
 "%wix%\bin\candle" installer.wxs -ext WiXNetFxExtension -ext WixDifxAppExtension -ext WixUIExtension.dll -ext WixUtilExtension
@@ -12,5 +14,11 @@ del installer.wixobj
 
 "%wix%\bin\light" installer.wixobj "%wix%\bin\difxapp_x64.wixlib" -o MissionPlanner64.msi -ext WiXNetFxExtension -ext WixDifxAppExtension -ext WixUIExtension.dll -ext WixUtilExtension
 
+"C:\Program Files\7-Zip\7z.exe" a -tzip "Mission Planner.zip" ..\bin\release\*
+
 
 pause
+
+
+rem googlecode_upload.py -s "Mission Planner installer (32-bit)" -p ardupilot-mega -u meee146 MissionPlanner32.msi
+rem googlecode_upload.py -s "Mission Planner installer (64-bit)" -p ardupilot-mega -u meee146 MissionPlanner64.msi
\ No newline at end of file
diff --git a/Tools/ArdupilotMegaPlanner/Msi/installer.wxs b/Tools/ArdupilotMegaPlanner/Msi/installer.wxs
index 2263472dd..ef32e135d 100644
--- a/Tools/ArdupilotMegaPlanner/Msi/installer.wxs
+++ b/Tools/ArdupilotMegaPlanner/Msi/installer.wxs
@@ -2,14 +2,14 @@
 <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension" xmlns:difx="http://schemas.microsoft.com/wix/DifxAppExtension">
 
 
-    <Product Id="*" Name="APM Planner" Language="1033" Version="1.1.72" Manufacturer="Michael Oborne" UpgradeCode="{625389D7-EB3C-4d77-A5F6-A285CF99437D}">
+    <Product Id="*" Name="APM Planner" Language="1033" Version="1.1.79" Manufacturer="Michael Oborne" UpgradeCode="{625389D7-EB3C-4d77-A5F6-A285CF99437D}">
 
         <Package Description="APM Planner Installer" Comments="Apm Planner Installer" Manufacturer="Michael Oborne" InstallerVersion="200" Compressed="yes" />
 
 
 <Upgrade Id="{625389D7-EB3C-4d77-A5F6-A285CF99437D}">
-    <UpgradeVersion OnlyDetect="yes" Minimum="1.1.72" Property="NEWERVERSIONDETECTED" IncludeMinimum="no" />
-    <UpgradeVersion OnlyDetect="no" Maximum="1.1.72" Property="OLDERVERSIONBEINGUPGRADED" IncludeMaximum="no" />
+    <UpgradeVersion OnlyDetect="yes" Minimum="1.1.79" Property="NEWERVERSIONDETECTED" IncludeMinimum="no" />
+    <UpgradeVersion OnlyDetect="no" Maximum="1.1.79" Property="OLDERVERSIONBEINGUPGRADED" IncludeMaximum="no" />
 </Upgrade>
 
 <InstallExecuteSequence>
@@ -31,226 +31,231 @@
                             <Permission User="Everyone" GenericAll="yes" /> 
                         </CreateFolder>
                     </Component>
-<Component Id="_comp1" Guid="ec36a99a-567a-401c-9b98-a26b885215b2">
-<File Id="_2" Source="..\bin\release\aerosim3.91.txt" />
-<File Id="_3" Source="..\bin\release\AeroSimRCAPMHil.zip" />
-<File Id="_4" Source="..\bin\release\alglibnet2.dll" />
-<File Id="_5" Source="..\bin\release\ArduCopter-sitl.exe" />
-<File Id="_6" Source="..\bin\release\arducopter-xplane.zip" />
-<File Id="_7" Source="..\bin\release\ArduCopter.exe" />
-<File Id="_8" Source="..\bin\release\ArduCopterConfig.xml" />
-<File Id="_9" Source="..\bin\release\ArduinoCPP.exe" />
-<File Id="_10" Source="..\bin\release\ArduinoCPP.exe.config" />
-<File Id="_11" Source="..\bin\release\ArduinoCPP.pdb" />
-<File Id="_12" Source="..\bin\release\ArdupilotMegaPlanner.exe" />
-<File Id="_13" Source="..\bin\release\ArdupilotMegaPlanner.exe.config" />
-<File Id="_14" Source="..\bin\release\ArdupilotMegaPlanner.pdb" />
-<File Id="_15" Source="..\bin\release\ArduPlane-sitl.exe" />
-<File Id="_16" Source="..\bin\release\ArduPlane.exe" />
-<File Id="_17" Source="..\bin\release\block_plane_0.dae" />
-<File Id="_18" Source="..\bin\release\BSE.Windows.Forms.dll" />
-<File Id="_19" Source="..\bin\release\Core.dll" />
-<File Id="_20" Source="..\bin\release\cygwin1.dll" />
-<File Id="_21" Source="..\bin\release\dataflashlog.xml" />
-<File Id="_22" Source="..\bin\release\DirectShowLib-2005.dll" />
-<File Id="_23" Source="..\bin\release\eeprom.bin" />
-<File Id="_24" Source="..\bin\release\GMap.NET.Core.dll" />
-<File Id="_25" Source="..\bin\release\GMap.NET.WindowsForms.dll" />
-<File Id="_26" Source="..\bin\release\hud.html" />
-<File Id="_27" Source="..\bin\release\ICSharpCode.SharpZipLib.dll" />
-<File Id="_28" Source="..\bin\release\Ionic.Zip.Reduced.dll" />
-<File Id="_29" Source="..\bin\release\IronPython.dll" />
-<File Id="_30" Source="..\bin\release\IronPython.Modules.dll" />
-<File Id="_31" Source="..\bin\release\JSBSim.exe" />
-<File Id="_32" Source="..\bin\release\KMLib.dll" />
-<File Id="_33" Source="..\bin\release\log4net.dll" />
-<File Id="_34" Source="..\bin\release\mavcmd.xml" />
-<File Id="_35" Source="..\bin\release\MAVLink.xml" />
-<File Id="_36" Source="..\bin\release\MetaDataExtractor.dll" />
-<File Id="_37" Source="..\bin\release\Microsoft.DirectX.dll" />
-<File Id="_38" Source="..\bin\release\Microsoft.Dynamic.dll" />
-<File Id="_39" Source="..\bin\release\Microsoft.Scripting.Core.dll" />
-<File Id="_40" Source="..\bin\release\Microsoft.Scripting.Debugging.dll" />
-<File Id="_41" Source="..\bin\release\Microsoft.Scripting.dll" />
-<File Id="_42" Source="..\bin\release\Microsoft.Scripting.ExtensionAttribute.dll" />
-<File Id="_43" Source="..\bin\release\netDxf.dll" />
-<File Id="_44" Source="..\bin\release\OpenTK.dll" />
-<File Id="_45" Source="..\bin\release\OpenTK.GLControl.dll" />
-<File Id="_46" Source="..\bin\release\quadhil.xml" />
-<File Id="_47" Source="..\bin\release\serialsent.raw" />
-<File Id="_48" Source="..\bin\release\SharpKml.dll" />
-<File Id="_49" Source="..\bin\release\System.Data.SQLite.dll" />
-<File Id="_50" Source="..\bin\release\System.Speech.dll" />
-<File Id="_51" Source="..\bin\release\Updater.exe" />
-<File Id="_52" Source="..\bin\release\Updater.exe.config" />
-<File Id="_53" Source="..\bin\release\Updater.pdb" />
-<File Id="_54" Source="..\bin\release\version.exe" />
-<File Id="_55" Source="..\bin\release\version.txt" />
-<File Id="_56" Source="..\bin\release\ZedGraph.dll" />
+<Component Id="_comp1" Guid="62951b99-7e1b-421d-bab6-29a48c7b4600">
+<File Id="_2" Source="..\bin\release\.gdbinit" />
+<File Id="_3" Source="..\bin\release\.gitignore" />
+<File Id="_4" Source="..\bin\release\aerosim3.91.txt" />
+<File Id="_5" Source="..\bin\release\AeroSimRCAPMHil.zip" />
+<File Id="_6" Source="..\bin\release\alglibnet2.dll" />
+<File Id="_7" Source="..\bin\release\ArduCopter-sitl.exe" />
+<File Id="_8" Source="..\bin\release\arducopter-xplane.zip" />
+<File Id="_9" Source="..\bin\release\ArduCopter.exe" />
+<File Id="_10" Source="..\bin\release\ArduCopterConfig.xml" />
+<File Id="_11" Source="..\bin\release\ArduinoCPP.exe" />
+<File Id="_12" Source="..\bin\release\ArduinoCPP.exe.config" />
+<File Id="_13" Source="..\bin\release\ArduinoCPP.pdb" />
+<File Id="_14" Source="..\bin\release\ArdupilotMegaPlanner.exe" ><netfx:NativeImage Id="ngen_ArdupilotMegaPlannerexe"/> </File>
+<File Id="_15" Source="..\bin\release\ArdupilotMegaPlanner.exe.config" />
+<File Id="_16" Source="..\bin\release\ArdupilotMegaPlanner.pdb" />
+<File Id="_17" Source="..\bin\release\ArduPlane-sitl.exe" />
+<File Id="_18" Source="..\bin\release\ArduPlane.exe" />
+<File Id="_19" Source="..\bin\release\block_plane_0.dae" />
+<File Id="_20" Source="..\bin\release\BSE.Windows.Forms.dll" />
+<File Id="_21" Source="..\bin\release\Core.dll" />
+<File Id="_22" Source="..\bin\release\cygwin1.dll" />
+<File Id="_23" Source="..\bin\release\dataflashlog.xml" />
+<File Id="_24" Source="..\bin\release\DirectShowLib-2005.dll" />
+<File Id="_25" Source="..\bin\release\eeprom.bin" />
+<File Id="_26" Source="..\bin\release\GMap.NET.Core.dll" />
+<File Id="_27" Source="..\bin\release\GMap.NET.WindowsForms.dll" />
+<File Id="_28" Source="..\bin\release\hud.html" />
+<File Id="_29" Source="..\bin\release\ICSharpCode.SharpZipLib.dll" />
+<File Id="_30" Source="..\bin\release\Ionic.Zip.Reduced.dll" />
+<File Id="_31" Source="..\bin\release\IronPython.dll" />
+<File Id="_32" Source="..\bin\release\IronPython.Modules.dll" />
+<File Id="_33" Source="..\bin\release\JSBSim.exe" />
+<File Id="_34" Source="..\bin\release\KMLib.dll" />
+<File Id="_35" Source="..\bin\release\log4net.dll" />
+<File Id="_36" Source="..\bin\release\mavcmd.xml" />
+<File Id="_37" Source="..\bin\release\MAVLink.xml" />
+<File Id="_38" Source="..\bin\release\MetaDataExtractor.dll" />
+<File Id="_39" Source="..\bin\release\Microsoft.DirectX.dll" />
+<File Id="_40" Source="..\bin\release\Microsoft.Dynamic.dll" />
+<File Id="_41" Source="..\bin\release\Microsoft.Scripting.Core.dll" />
+<File Id="_42" Source="..\bin\release\Microsoft.Scripting.Debugging.dll" />
+<File Id="_43" Source="..\bin\release\Microsoft.Scripting.dll" />
+<File Id="_44" Source="..\bin\release\Microsoft.Scripting.ExtensionAttribute.dll" />
+<File Id="_45" Source="..\bin\release\netDxf.dll" />
+<File Id="_46" Source="..\bin\release\OpenTK.Compatibility.dll" />
+<File Id="_47" Source="..\bin\release\OpenTK.Compatibility.pdb" />
+<File Id="_48" Source="..\bin\release\OpenTK.Compatibility.xml" />
+<File Id="_49" Source="..\bin\release\OpenTK.dll" />
+<File Id="_50" Source="..\bin\release\OpenTK.GLControl.dll" />
+<File Id="_51" Source="..\bin\release\quadhil.xml" />
+<File Id="_52" Source="..\bin\release\serialsent.raw" />
+<File Id="_53" Source="..\bin\release\SharpKml.dll" />
+<File Id="_54" Source="..\bin\release\System.Data.SQLite.dll" />
+<File Id="_55" Source="..\bin\release\System.Speech.dll" />
+<File Id="_56" Source="..\bin\release\Updater.exe" />
+<File Id="_57" Source="..\bin\release\Updater.exe.config" />
+<File Id="_58" Source="..\bin\release\Updater.pdb" />
+<File Id="_59" Source="..\bin\release\version.exe" />
+<File Id="_60" Source="..\bin\release\version.txt" />
+<File Id="_61" Source="..\bin\release\ZedGraph.dll" />
 </Component>
-<Directory Id="aircraft56" Name="aircraft">
-<Component Id="_comp57" Guid="ad402273-0ee6-4774-9d32-c6851f397edd">
-<File Id="_58" Source="..\bin\release\aircraft\placeholder.txt" />
+<Directory Id="aircraft61" Name="aircraft">
+<Component Id="_comp62" Guid="a477d29e-b85f-4d4a-ad83-db6f6ed29990">
+<File Id="_63" Source="..\bin\release\aircraft\placeholder.txt" />
 </Component>
-<Directory Id="arducopter58" Name="arducopter">
-<Component Id="_comp59" Guid="dba0cbb2-b6e5-446a-a279-5c5215cb9415">
-<File Id="_60" Source="..\bin\release\aircraft\arducopter\arducopter-set.xml" />
-<File Id="_61" Source="..\bin\release\aircraft\arducopter\arducopter.jpg" />
-<File Id="_62" Source="..\bin\release\aircraft\arducopter\arducopter.xml" />
-<File Id="_63" Source="..\bin\release\aircraft\arducopter\initfile.xml" />
-<File Id="_64" Source="..\bin\release\aircraft\arducopter\plus_quad2-set.xml" />
-<File Id="_65" Source="..\bin\release\aircraft\arducopter\plus_quad2.xml" />
-<File Id="_66" Source="..\bin\release\aircraft\arducopter\quad.nas" />
-<File Id="_67" Source="..\bin\release\aircraft\arducopter\README" />
+<Directory Id="arducopter63" Name="arducopter">
+<Component Id="_comp64" Guid="4e4be623-320d-4fba-b862-febf9a33ec59">
+<File Id="_65" Source="..\bin\release\aircraft\arducopter\arducopter-set.xml" />
+<File Id="_66" Source="..\bin\release\aircraft\arducopter\arducopter.jpg" />
+<File Id="_67" Source="..\bin\release\aircraft\arducopter\arducopter.xml" />
+<File Id="_68" Source="..\bin\release\aircraft\arducopter\initfile.xml" />
+<File Id="_69" Source="..\bin\release\aircraft\arducopter\plus_quad2-set.xml" />
+<File Id="_70" Source="..\bin\release\aircraft\arducopter\plus_quad2.xml" />
+<File Id="_71" Source="..\bin\release\aircraft\arducopter\quad.nas" />
+<File Id="_72" Source="..\bin\release\aircraft\arducopter\README" />
 </Component>
-<Directory Id="data67" Name="data">
-<Component Id="_comp68" Guid="4ad7018b-700d-4c21-a0df-830691c9e9f1">
-<File Id="_69" Source="..\bin\release\aircraft\arducopter\data\arducopter_half_step.txt" />
-<File Id="_70" Source="..\bin\release\aircraft\arducopter\data\arducopter_step.txt" />
-<File Id="_71" Source="..\bin\release\aircraft\arducopter\data\rw_generic_pylon.ac" />
+<Directory Id="data72" Name="data">
+<Component Id="_comp73" Guid="bed8830d-5a5d-4262-8ba5-e5abd1418127">
+<File Id="_74" Source="..\bin\release\aircraft\arducopter\data\arducopter_half_step.txt" />
+<File Id="_75" Source="..\bin\release\aircraft\arducopter\data\arducopter_step.txt" />
+<File Id="_76" Source="..\bin\release\aircraft\arducopter\data\rw_generic_pylon.ac" />
 </Component>
 </Directory>
-<Directory Id="Engines71" Name="Engines">
-<Component Id="_comp72" Guid="42d52dcf-ca6b-4d34-ba01-2d10198462f7">
-<File Id="_73" Source="..\bin\release\aircraft\arducopter\Engines\a2830-12.xml" />
-<File Id="_74" Source="..\bin\release\aircraft\arducopter\Engines\prop10x4.5.xml" />
+<Directory Id="Engines76" Name="Engines">
+<Component Id="_comp77" Guid="21fb9d57-cea0-4768-9011-5ffd1d707a76">
+<File Id="_78" Source="..\bin\release\aircraft\arducopter\Engines\a2830-12.xml" />
+<File Id="_79" Source="..\bin\release\aircraft\arducopter\Engines\prop10x4.5.xml" />
 </Component>
 </Directory>
-<Directory Id="Models74" Name="Models">
-<Component Id="_comp75" Guid="c1c7bb9f-d9ff-4efe-ad9a-d87dcf798f55">
-<File Id="_76" Source="..\bin\release\aircraft\arducopter\Models\arducopter.ac" />
-<File Id="_77" Source="..\bin\release\aircraft\arducopter\Models\arducopter.xml" />
-<File Id="_78" Source="..\bin\release\aircraft\arducopter\Models\plus_quad.ac" />
-<File Id="_79" Source="..\bin\release\aircraft\arducopter\Models\plus_quad2.ac" />
-<File Id="_80" Source="..\bin\release\aircraft\arducopter\Models\plus_quad2.xml" />
-<File Id="_81" Source="..\bin\release\aircraft\arducopter\Models\quad.3ds" />
-<File Id="_82" Source="..\bin\release\aircraft\arducopter\Models\shareware_output.3ds" />
-<File Id="_83" Source="..\bin\release\aircraft\arducopter\Models\Untitled.ac" />
-<File Id="_84" Source="..\bin\release\aircraft\arducopter\Models\Y6_test.ac" />
+<Directory Id="Models79" Name="Models">
+<Component Id="_comp80" Guid="0a0ef20a-ac2e-4031-b457-9bb589a68c1a">
+<File Id="_81" Source="..\bin\release\aircraft\arducopter\Models\arducopter.ac" />
+<File Id="_82" Source="..\bin\release\aircraft\arducopter\Models\arducopter.xml" />
+<File Id="_83" Source="..\bin\release\aircraft\arducopter\Models\plus_quad.ac" />
+<File Id="_84" Source="..\bin\release\aircraft\arducopter\Models\plus_quad2.ac" />
+<File Id="_85" Source="..\bin\release\aircraft\arducopter\Models\plus_quad2.xml" />
+<File Id="_86" Source="..\bin\release\aircraft\arducopter\Models\quad.3ds" />
+<File Id="_87" Source="..\bin\release\aircraft\arducopter\Models\shareware_output.3ds" />
+<File Id="_88" Source="..\bin\release\aircraft\arducopter\Models\Untitled.ac" />
+<File Id="_89" Source="..\bin\release\aircraft\arducopter\Models\Y6_test.ac" />
 </Component>
 </Directory>
 </Directory>
-<Directory Id="Rascal84" Name="Rascal">
-<Component Id="_comp85" Guid="9735238e-339f-420e-9821-4724c17039e8">
-<File Id="_86" Source="..\bin\release\aircraft\Rascal\Rascal-keyboard.xml" />
-<File Id="_87" Source="..\bin\release\aircraft\Rascal\Rascal-submodels.xml" />
-<File Id="_88" Source="..\bin\release\aircraft\Rascal\Rascal.xml" />
-<File Id="_89" Source="..\bin\release\aircraft\Rascal\Rascal110-JSBSim-set.xml" />
-<File Id="_90" Source="..\bin\release\aircraft\Rascal\Rascal110-JSBSim.xml" />
-<File Id="_91" Source="..\bin\release\aircraft\Rascal\Rascal110-splash.rgb" />
-<File Id="_92" Source="..\bin\release\aircraft\Rascal\README.Rascal" />
-<File Id="_93" Source="..\bin\release\aircraft\Rascal\reset_CMAC.xml" />
-<File Id="_94" Source="..\bin\release\aircraft\Rascal\thumbnail.jpg" />
+<Directory Id="Rascal89" Name="Rascal">
+<Component Id="_comp90" Guid="b00086cb-aa16-49dd-abfc-7842d5beb6c5">
+<File Id="_91" Source="..\bin\release\aircraft\Rascal\Rascal-keyboard.xml" />
+<File Id="_92" Source="..\bin\release\aircraft\Rascal\Rascal-submodels.xml" />
+<File Id="_93" Source="..\bin\release\aircraft\Rascal\Rascal.xml" />
+<File Id="_94" Source="..\bin\release\aircraft\Rascal\Rascal110-JSBSim-set.xml" />
+<File Id="_95" Source="..\bin\release\aircraft\Rascal\Rascal110-JSBSim.xml" />
+<File Id="_96" Source="..\bin\release\aircraft\Rascal\Rascal110-splash.rgb" />
+<File Id="_97" Source="..\bin\release\aircraft\Rascal\README.Rascal" />
+<File Id="_98" Source="..\bin\release\aircraft\Rascal\reset_CMAC.xml" />
+<File Id="_99" Source="..\bin\release\aircraft\Rascal\thumbnail.jpg" />
 </Component>
-<Directory Id="Dialogs94" Name="Dialogs">
-<Component Id="_comp95" Guid="f0b6ef61-b6cc-4d5a-8354-74b08e010ff1">
-<File Id="_96" Source="..\bin\release\aircraft\Rascal\Dialogs\config.xml" />
-<File Id="_97" Source="..\bin\release\aircraft\Rascal\Dialogs\config.xml.new" />
+<Directory Id="Dialogs99" Name="Dialogs">
+<Component Id="_comp100" Guid="2b05133b-0659-4a69-88c9-cb835e588555">
+<File Id="_101" Source="..\bin\release\aircraft\Rascal\Dialogs\config.xml" />
+<File Id="_102" Source="..\bin\release\aircraft\Rascal\Dialogs\config.xml.new" />
 </Component>
 </Directory>
-<Directory Id="Engines97" Name="Engines">
-<Component Id="_comp98" Guid="0c770102-701e-4f2c-9e29-7399484615a1">
-<File Id="_99" Source="..\bin\release\aircraft\Rascal\Engines\18x8.xml" />
-<File Id="_100" Source="..\bin\release\aircraft\Rascal\Engines\18x8.xml.new" />
-<File Id="_101" Source="..\bin\release\aircraft\Rascal\Engines\Zenoah_G-26A.xml" />
-<File Id="_102" Source="..\bin\release\aircraft\Rascal\Engines\Zenoah_G-26A.xml.new" />
+<Directory Id="Engines102" Name="Engines">
+<Component Id="_comp103" Guid="af25d31c-9ea3-47af-8b58-de2dedf2a64b">
+<File Id="_104" Source="..\bin\release\aircraft\Rascal\Engines\18x8.xml" />
+<File Id="_105" Source="..\bin\release\aircraft\Rascal\Engines\18x8.xml.new" />
+<File Id="_106" Source="..\bin\release\aircraft\Rascal\Engines\Zenoah_G-26A.xml" />
+<File Id="_107" Source="..\bin\release\aircraft\Rascal\Engines\Zenoah_G-26A.xml.new" />
 </Component>
 </Directory>
-<Directory Id="Models102" Name="Models">
-<Component Id="_comp103" Guid="b1b6e457-631f-4a1b-9147-bf398e803c03">
-<File Id="_104" Source="..\bin\release\aircraft\Rascal\Models\Rascal.rgb" />
-<File Id="_105" Source="..\bin\release\aircraft\Rascal\Models\Rascal.rgb.new" />
-<File Id="_106" Source="..\bin\release\aircraft\Rascal\Models\Rascal110-000-013.ac" />
-<File Id="_107" Source="..\bin\release\aircraft\Rascal\Models\Rascal110-000-013.ac.new" />
-<File Id="_108" Source="..\bin\release\aircraft\Rascal\Models\Rascal110.xml" />
-<File Id="_109" Source="..\bin\release\aircraft\Rascal\Models\Rascal110.xml.new" />
-<File Id="_110" Source="..\bin\release\aircraft\Rascal\Models\smoke.png" />
-<File Id="_111" Source="..\bin\release\aircraft\Rascal\Models\smoke.png.new" />
-<File Id="_112" Source="..\bin\release\aircraft\Rascal\Models\smokeW.xml" />
-<File Id="_113" Source="..\bin\release\aircraft\Rascal\Models\smokeW.xml.new" />
-<File Id="_114" Source="..\bin\release\aircraft\Rascal\Models\Trajectory-Marker.ac" />
-<File Id="_115" Source="..\bin\release\aircraft\Rascal\Models\Trajectory-Marker.ac.new" />
-<File Id="_116" Source="..\bin\release\aircraft\Rascal\Models\Trajectory-Marker.xml" />
-<File Id="_117" Source="..\bin\release\aircraft\Rascal\Models\Trajectory-Marker.xml.new" />
+<Directory Id="Models107" Name="Models">
+<Component Id="_comp108" Guid="59605c36-2f79-486a-9c12-0f66b1c896a2">
+<File Id="_109" Source="..\bin\release\aircraft\Rascal\Models\Rascal.rgb" />
+<File Id="_110" Source="..\bin\release\aircraft\Rascal\Models\Rascal.rgb.new" />
+<File Id="_111" Source="..\bin\release\aircraft\Rascal\Models\Rascal110-000-013.ac" />
+<File Id="_112" Source="..\bin\release\aircraft\Rascal\Models\Rascal110-000-013.ac.new" />
+<File Id="_113" Source="..\bin\release\aircraft\Rascal\Models\Rascal110.xml" />
+<File Id="_114" Source="..\bin\release\aircraft\Rascal\Models\Rascal110.xml.new" />
+<File Id="_115" Source="..\bin\release\aircraft\Rascal\Models\smoke.png" />
+<File Id="_116" Source="..\bin\release\aircraft\Rascal\Models\smoke.png.new" />
+<File Id="_117" Source="..\bin\release\aircraft\Rascal\Models\smokeW.xml" />
+<File Id="_118" Source="..\bin\release\aircraft\Rascal\Models\smokeW.xml.new" />
+<File Id="_119" Source="..\bin\release\aircraft\Rascal\Models\Trajectory-Marker.ac" />
+<File Id="_120" Source="..\bin\release\aircraft\Rascal\Models\Trajectory-Marker.ac.new" />
+<File Id="_121" Source="..\bin\release\aircraft\Rascal\Models\Trajectory-Marker.xml" />
+<File Id="_122" Source="..\bin\release\aircraft\Rascal\Models\Trajectory-Marker.xml.new" />
 </Component>
 </Directory>
-<Directory Id="Systems117" Name="Systems">
-<Component Id="_comp118" Guid="07ca2fcc-1f36-4a90-867e-9a5b2effbbd6">
-<File Id="_119" Source="..\bin\release\aircraft\Rascal\Systems\110-autopilot.xml" />
-<File Id="_120" Source="..\bin\release\aircraft\Rascal\Systems\110-autopilot.xml.new" />
-<File Id="_121" Source="..\bin\release\aircraft\Rascal\Systems\airdata.nas" />
-<File Id="_122" Source="..\bin\release\aircraft\Rascal\Systems\airdata.nas.new" />
-<File Id="_123" Source="..\bin\release\aircraft\Rascal\Systems\electrical.xml" />
-<File Id="_124" Source="..\bin\release\aircraft\Rascal\Systems\electrical.xml.new" />
-<File Id="_125" Source="..\bin\release\aircraft\Rascal\Systems\main.nas" />
-<File Id="_126" Source="..\bin\release\aircraft\Rascal\Systems\main.nas.new" />
-<File Id="_127" Source="..\bin\release\aircraft\Rascal\Systems\ugear.nas" />
+<Directory Id="Systems122" Name="Systems">
+<Component Id="_comp123" Guid="194d9022-9d67-457a-969e-ab0719d4f91a">
+<File Id="_124" Source="..\bin\release\aircraft\Rascal\Systems\110-autopilot.xml" />
+<File Id="_125" Source="..\bin\release\aircraft\Rascal\Systems\110-autopilot.xml.new" />
+<File Id="_126" Source="..\bin\release\aircraft\Rascal\Systems\airdata.nas" />
+<File Id="_127" Source="..\bin\release\aircraft\Rascal\Systems\airdata.nas.new" />
+<File Id="_128" Source="..\bin\release\aircraft\Rascal\Systems\electrical.xml" />
+<File Id="_129" Source="..\bin\release\aircraft\Rascal\Systems\electrical.xml.new" />
+<File Id="_130" Source="..\bin\release\aircraft\Rascal\Systems\main.nas" />
+<File Id="_131" Source="..\bin\release\aircraft\Rascal\Systems\main.nas.new" />
+<File Id="_132" Source="..\bin\release\aircraft\Rascal\Systems\ugear.nas" />
 </Component>
 </Directory>
 </Directory>
 </Directory>
-<Directory Id="Driver127" Name="Driver">
-<Component Id="_comp128" Guid="5797f8f3-d966-4875-a5f7-c75bcaf7254e">
-<File Id="_129" Source="..\bin\release\Driver\Arduino MEGA 2560.inf" />
-<File Id="_130" Source="..\bin\release\Driver\Arduino MEGA 2560.inf.new" />
+<Directory Id="Driver132" Name="Driver">
+<Component Id="_comp133" Guid="c9a68be1-02ec-4fae-889b-b6c63a529e96">
+<File Id="_134" Source="..\bin\release\Driver\Arduino MEGA 2560.inf" />
+<File Id="_135" Source="..\bin\release\Driver\Arduino MEGA 2560.inf.new" />
 </Component>
 </Directory>
-<Directory Id="es_ES130" Name="es-ES">
-<Component Id="_comp131" Guid="d96f8317-0a0a-402d-9450-52ed96582ba9">
-<File Id="_132" Source="..\bin\release\es-ES\ArdupilotMegaPlanner.resources.dll" />
+<Directory Id="es_ES135" Name="es-ES">
+<Component Id="_comp136" Guid="4a374854-caf4-4326-be93-abc459e95a47">
+<File Id="_137" Source="..\bin\release\es-ES\ArdupilotMegaPlanner.resources.dll" />
 </Component>
 </Directory>
-<Directory Id="fr132" Name="fr">
-<Component Id="_comp133" Guid="27919138-6492-4f44-a50e-1482c0c4846c">
-<File Id="_134" Source="..\bin\release\fr\ArdupilotMegaPlanner.resources.dll" />
+<Directory Id="fr137" Name="fr">
+<Component Id="_comp138" Guid="bcfeb5d5-1afc-484e-ac55-c521bf299a92">
+<File Id="_139" Source="..\bin\release\fr\ArdupilotMegaPlanner.resources.dll" />
 </Component>
 </Directory>
-<Directory Id="it_IT134" Name="it-IT">
-<Component Id="_comp135" Guid="f494900f-d167-416d-9e2e-25392641f148">
-<File Id="_136" Source="..\bin\release\it-IT\ArdupilotMegaPlanner.resources.dll" />
+<Directory Id="it_IT139" Name="it-IT">
+<Component Id="_comp140" Guid="c963d4a8-7e4e-4443-b8a5-8c573f1e34ee">
+<File Id="_141" Source="..\bin\release\it-IT\ArdupilotMegaPlanner.resources.dll" />
 </Component>
 </Directory>
-<Directory Id="jsbsim136" Name="jsbsim">
-<Component Id="_comp137" Guid="28d5005d-14cd-472f-a68d-a5e175ca1433">
-<File Id="_138" Source="..\bin\release\jsbsim\fgout.xml" />
-<File Id="_139" Source="..\bin\release\jsbsim\rascal_test.xml" />
+<Directory Id="jsbsim141" Name="jsbsim">
+<Component Id="_comp142" Guid="dc99f9c1-ce08-4ed1-a488-02c369254798">
+<File Id="_143" Source="..\bin\release\jsbsim\fgout.xml" />
+<File Id="_144" Source="..\bin\release\jsbsim\rascal_test.xml" />
 </Component>
 </Directory>
-<Directory Id="m3u139" Name="m3u">
-<Component Id="_comp140" Guid="84cd93b9-cc19-4436-8617-6462de04ee92">
-<File Id="_141" Source="..\bin\release\m3u\both.m3u" />
-<File Id="_142" Source="..\bin\release\m3u\GeoRefnetworklink.kml" />
-<File Id="_143" Source="..\bin\release\m3u\hud.m3u" />
-<File Id="_144" Source="..\bin\release\m3u\map.m3u" />
-<File Id="_145" Source="..\bin\release\m3u\networklink.kml" />
+<Directory Id="m3u144" Name="m3u">
+<Component Id="_comp145" Guid="95dbb094-3fe5-42e0-8673-2dde26523b72">
+<File Id="_146" Source="..\bin\release\m3u\both.m3u" />
+<File Id="_147" Source="..\bin\release\m3u\GeoRefnetworklink.kml" />
+<File Id="_148" Source="..\bin\release\m3u\hud.m3u" />
+<File Id="_149" Source="..\bin\release\m3u\map.m3u" />
+<File Id="_150" Source="..\bin\release\m3u\networklink.kml" />
 </Component>
 </Directory>
-<Directory Id="pl145" Name="pl">
-<Component Id="_comp146" Guid="bb8d116b-93d2-42a2-b792-97d4f0ba7916">
-<File Id="_147" Source="..\bin\release\pl\ArdupilotMegaPlanner.resources.dll" />
+<Directory Id="pl150" Name="pl">
+<Component Id="_comp151" Guid="42feaf8e-d93a-4483-a94c-c4a6e0ccfc0a">
+<File Id="_152" Source="..\bin\release\pl\ArdupilotMegaPlanner.resources.dll" />
 </Component>
 </Directory>
-<Directory Id="Resources147" Name="Resources">
-<Component Id="_comp148" Guid="7ea8725a-12b4-4420-8993-a572ba8a5125">
-<File Id="_149" Source="..\bin\release\Resources\MAVCmd.txt" />
-<File Id="_150" Source="..\bin\release\Resources\MAVCmd.txt.new" />
-<File Id="_151" Source="..\bin\release\Resources\Welcome_to_Michael_Oborne.rtf" />
-<File Id="_152" Source="..\bin\release\Resources\Welcome_to_Michael_Oborne.rtf.new" />
+<Directory Id="Resources152" Name="Resources">
+<Component Id="_comp153" Guid="d756f383-0b21-4479-8d84-b89db0e5ca07">
+<File Id="_154" Source="..\bin\release\Resources\MAVCmd.txt" />
+<File Id="_155" Source="..\bin\release\Resources\MAVCmd.txt.new" />
+<File Id="_156" Source="..\bin\release\Resources\Welcome_to_Michael_Oborne.rtf" />
+<File Id="_157" Source="..\bin\release\Resources\Welcome_to_Michael_Oborne.rtf.new" />
 </Component>
 </Directory>
-<Directory Id="ru_RU152" Name="ru-RU">
-<Component Id="_comp153" Guid="6960bab7-cc6b-4eaf-9ebb-2f26af194dbf">
-<File Id="_154" Source="..\bin\release\ru-RU\ArdupilotMegaPlanner.resources.dll" />
+<Directory Id="ru_RU157" Name="ru-RU">
+<Component Id="_comp158" Guid="5817d631-b389-4091-8db6-b291ff6b740b">
+<File Id="_159" Source="..\bin\release\ru-RU\ArdupilotMegaPlanner.resources.dll" />
 </Component>
 </Directory>
-<Directory Id="zh_Hans154" Name="zh-Hans">
-<Component Id="_comp155" Guid="bb5d655e-55ef-4d92-9e9c-6595387e27c9">
-<File Id="_156" Source="..\bin\release\zh-Hans\ArdupilotMegaPlanner.resources.dll" />
+<Directory Id="zh_Hans159" Name="zh-Hans">
+<Component Id="_comp160" Guid="cc8a053a-e626-43fe-9321-e3a8e982fed6">
+<File Id="_161" Source="..\bin\release\zh-Hans\ArdupilotMegaPlanner.resources.dll" />
 </Component>
 </Directory>
-<Directory Id="zh_TW156" Name="zh-TW">
-<Component Id="_comp157" Guid="509bcc10-ad13-46dc-917e-2086fe5bac44">
-<File Id="_158" Source="..\bin\release\zh-TW\ArdupilotMegaPlanner.resources.dll" />
+<Directory Id="zh_TW161" Name="zh-TW">
+<Component Id="_comp162" Guid="2f61e25e-f504-4666-93d2-568f162306c4">
+<File Id="_163" Source="..\bin\release\zh-TW\ArdupilotMegaPlanner.resources.dll" />
 </Component>
 </Directory>
 
@@ -292,27 +297,27 @@
             <ComponentRef Id="InstallDirPermissions" />
 
 <ComponentRef Id="_comp1" />
-<ComponentRef Id="_comp57" />
-<ComponentRef Id="_comp59" />
-<ComponentRef Id="_comp68" />
-<ComponentRef Id="_comp72" />
-<ComponentRef Id="_comp75" />
-<ComponentRef Id="_comp85" />
-<ComponentRef Id="_comp95" />
-<ComponentRef Id="_comp98" />
+<ComponentRef Id="_comp62" />
+<ComponentRef Id="_comp64" />
+<ComponentRef Id="_comp73" />
+<ComponentRef Id="_comp77" />
+<ComponentRef Id="_comp80" />
+<ComponentRef Id="_comp90" />
+<ComponentRef Id="_comp100" />
 <ComponentRef Id="_comp103" />
-<ComponentRef Id="_comp118" />
-<ComponentRef Id="_comp128" />
-<ComponentRef Id="_comp131" />
+<ComponentRef Id="_comp108" />
+<ComponentRef Id="_comp123" />
 <ComponentRef Id="_comp133" />
-<ComponentRef Id="_comp135" />
-<ComponentRef Id="_comp137" />
+<ComponentRef Id="_comp136" />
+<ComponentRef Id="_comp138" />
 <ComponentRef Id="_comp140" />
-<ComponentRef Id="_comp146" />
-<ComponentRef Id="_comp148" />
+<ComponentRef Id="_comp142" />
+<ComponentRef Id="_comp145" />
+<ComponentRef Id="_comp151" />
 <ComponentRef Id="_comp153" />
-<ComponentRef Id="_comp155" />
-<ComponentRef Id="_comp157" />
+<ComponentRef Id="_comp158" />
+<ComponentRef Id="_comp160" />
+<ComponentRef Id="_comp162" />
 
             
             <ComponentRef Id="ApplicationShortcut" />
@@ -333,7 +338,7 @@
     <Property Id="WIXUI_EXITDIALOGOPTIONALCHECKBOXTEXT" Value="Launch APM Planner" />
 
     <!-- Step 3: Include the custom action -->
-    <Property Id="WixShellExecTarget" Value="[#_12]" />
+    <Property Id="WixShellExecTarget" Value="[#_14]" />
     <CustomAction Id="LaunchApplication" 
         BinaryKey="WixCA" 
         DllEntry="WixShellExec"
diff --git a/Tools/ArdupilotMegaPlanner/Properties/AssemblyInfo.cs b/Tools/ArdupilotMegaPlanner/Properties/AssemblyInfo.cs
index 55c948c3a..c7eff29d4 100644
--- a/Tools/ArdupilotMegaPlanner/Properties/AssemblyInfo.cs
+++ b/Tools/ArdupilotMegaPlanner/Properties/AssemblyInfo.cs
@@ -34,5 +34,5 @@ using System.Resources;
 // by using the '*' as shown below:
 // [assembly: AssemblyVersion("1.0.*")]
 [assembly: AssemblyVersion("1.1.*")]
-[assembly: AssemblyFileVersion("1.1.79")]
+[assembly: AssemblyFileVersion("1.1.80")]
 [assembly: NeutralResourcesLanguageAttribute("")]
diff --git a/Tools/ArdupilotMegaPlanner/bin/Release/version.txt b/Tools/ArdupilotMegaPlanner/bin/Release/version.txt
index b0dfd7c8e..6ab9cd3b8 100644
--- a/Tools/ArdupilotMegaPlanner/bin/Release/version.txt
+++ b/Tools/ArdupilotMegaPlanner/bin/Release/version.txt
@@ -1 +1 @@
-1.1.4506.37964
\ No newline at end of file
+1.1.4508.31968
\ No newline at end of file
diff --git a/Tools/ArdupilotMegaPlanner/wix/Program.cs b/Tools/ArdupilotMegaPlanner/wix/Program.cs
index 532beab2b..9075e4622 100644
--- a/Tools/ArdupilotMegaPlanner/wix/Program.cs
+++ b/Tools/ArdupilotMegaPlanner/wix/Program.cs
@@ -5,6 +5,7 @@ using System.IO;
 using System.Windows.Forms;
 using System.Diagnostics;
 using System.Runtime.InteropServices;
+using System.Reflection;
 
 namespace wix
 {
@@ -76,8 +77,8 @@ namespace wix
             }
 
             string path = args[0];
-
-            string file = Path.GetDirectoryName(Application.ExecutablePath) + Path.DirectorySeparatorChar+ "installer.wxs";
+            //Path.GetDirectoryName(Application.ExecutablePath) + Path.DirectorySeparatorChar+ 
+            string file = "installer.wxs";
 
             sw = new StreamWriter(file);
 
@@ -110,6 +111,47 @@ namespace wix
             P.Start();
             */
             //Console.ReadLine();
+
+            string exepath = Path.GetFullPath(path) + Path.DirectorySeparatorChar + "ArdupilotMegaPlanner.exe";
+            string version = Assembly.LoadFile(exepath).GetName().Version.ToString();
+
+            System.Diagnostics.FileVersionInfo fvi = FileVersionInfo.GetVersionInfo(exepath);
+
+            StreamWriter st = new StreamWriter("create.bat", false);
+
+            st.WriteLine("del installer.wixobj");
+
+            st.WriteLine(@"""%wix%\bin\candle"" installer.wxs -ext WiXNetFxExtension -ext WixDifxAppExtension -ext WixUIExtension.dll -ext WixUtilExtension");
+
+            st.WriteLine(@"""%wix%\bin\light"" installer.wixobj ""%wix%\bin\difxapp_x86.wixlib"" -o MissionPlanner32-" + fvi.FileVersion + ".msi -ext WiXNetFxExtension -ext WixDifxAppExtension -ext WixUIExtension.dll -ext WixUtilExtension");
+
+            st.WriteLine(@"""%wix%\bin\light"" installer.wixobj ""%wix%\bin\difxapp_x64.wixlib"" -o MissionPlanner64-" + fvi.FileVersion + ".msi -ext WiXNetFxExtension -ext WixDifxAppExtension -ext WixUIExtension.dll -ext WixUtilExtension");
+
+            st.WriteLine(@"""C:\Program Files\7-Zip\7z.exe"" a -tzip -xr!*.log -xr!ArdupilotPlanner.log* -xr!*.tlog -xr!config.xml -xr!gmapcache -xr!eeprom.bin -xr!dataflash.bin -xr!*.new ""Mission Planner " + fvi.FileVersion + @".zip"" ..\bin\release\*");
+
+            st.WriteLine("pause");
+
+            st.WriteLine("googlecode_upload.py -s \"Mission Planner zip file, " + fvi.FileVersion + "\" -p ardupilot-mega \"Mission Planner " + fvi.FileVersion + @".zip""");
+
+            st.WriteLine("googlecode_upload.py -s \"Mission Planner installer (32-bit)\" -p ardupilot-mega MissionPlanner32-" + fvi.FileVersion + ".msi");
+            st.WriteLine("googlecode_upload.py -s \"Mission Planner installer (64-bit)\" -p ardupilot-mega MissionPlanner64-" + fvi.FileVersion + ".msi");
+
+
+            st.Close();
+
+            runProgram("create.bat");
+
+
+        }
+
+        static void runProgram(string run)
+        {
+            System.Diagnostics.Process P = new System.Diagnostics.Process();
+            P.StartInfo.FileName = run;
+
+//            P.StartInfo.WorkingDirectory = Path.GetDirectoryName(Application.ExecutablePath);
+            P.StartInfo.UseShellExecute = true;
+            P.Start();
         }
 
         static void header()
@@ -262,10 +304,15 @@ data = @"
                 if (filepath.ToLower().EndsWith("release\\config.xml") || filepath.ToLower().Contains("ardupilotplanner.log") || filepath.ToLower().Contains("dataflash.bin") || filepath.ToLower().Contains(".etag"))
                     continue;
                 no++;
-                sw.WriteLine("<File Id=\"_" + no + "\" Source=\"" + filepath + "\" />");
+                
 
                 if (filepath.EndsWith("ArdupilotMegaPlanner.exe")) {
                     mainexeid = "_" + no;
+
+                    sw.WriteLine("<File Id=\"_" + no + "\" Source=\"" + filepath + "\" ><netfx:NativeImage Id=\"ngen_ArdupilotMegaPlannerexe\"/> </File>");
+
+                } else {
+                    sw.WriteLine("<File Id=\"_" + no + "\" Source=\"" + filepath + "\" />");
                 }
             }
 
-- 
GitLab