diff --git a/Tools/ArdupilotMegaPlanner/ArdupilotMega.csproj b/Tools/ArdupilotMegaPlanner/ArdupilotMega.csproj
index bd933de328..0ee135a3b6 100644
--- a/Tools/ArdupilotMegaPlanner/ArdupilotMega.csproj
+++ b/Tools/ArdupilotMegaPlanner/ArdupilotMega.csproj
@@ -172,15 +172,6 @@
False
..\..\..\..\..\..\..\Program Files (x86)\IronPython 2.7.1\IronPython-2.6.1\Microsoft.Scripting.ExtensionAttribute.dll
-
- ..\..\..\..\..\Desktop\DIYDrones\virtualglobebook-OpenGlobe-ddf1d7e\Source\Examples\Chapter13\ClipmapTerrainOnGlobe\bin\Debug\OpenGlobe.Core.dll
-
-
- ..\..\..\..\..\Desktop\DIYDrones\virtualglobebook-OpenGlobe-ddf1d7e\Source\Examples\Chapter13\ClipmapTerrainOnGlobe\bin\Debug\OpenGlobe.Renderer.dll
-
-
- ..\..\..\..\..\Desktop\DIYDrones\virtualglobebook-OpenGlobe-ddf1d7e\Source\Examples\Chapter13\ClipmapTerrainOnGlobe\bin\Debug\OpenGlobe.Scene.dll
-
False
..\..\..\..\..\Desktop\DIYDrones\virtualglobebook-OpenGlobe-ddf1d7e\ThirdParty\OpenTKGL4\Binaries\OpenTK\Release\OpenTK.dll
@@ -237,7 +228,9 @@
ResEdit.cs
-
+
+ Form
+
@@ -403,6 +396,9 @@
Camera.cs
+
+ georefimage.cs
+
ResEdit.cs
@@ -576,6 +572,9 @@
Always
Designer
+
+ Always
+
Always
diff --git a/Tools/ArdupilotMegaPlanner/GCSViews/FlightPlanner.cs b/Tools/ArdupilotMegaPlanner/GCSViews/FlightPlanner.cs
index bb08d54539..7404509b1e 100644
--- a/Tools/ArdupilotMegaPlanner/GCSViews/FlightPlanner.cs
+++ b/Tools/ArdupilotMegaPlanner/GCSViews/FlightPlanner.cs
@@ -19,6 +19,7 @@ using System.Reflection;
using System.ComponentModel;
using System.Threading;
using SharpKml.Base;
+using SharpKml.Dom;
@@ -658,19 +659,65 @@ namespace ArdupilotMega.GCSViews
void parser_ElementAdded(object sender, SharpKml.Base.ElementEventArgs e)
{
+ processKML(e.Element);
+ }
- SharpKml.Dom.Polygon polygon = e.Element as SharpKml.Dom.Polygon;
- if (polygon != null)
+ private void processKML(SharpKml.Dom.Element Element)
+ {
+ try
+ {
+ Console.WriteLine(Element.ToString() + " " + Element.Parent);
+ }
+ catch { }
+
+ SharpKml.Dom.Document doc = Element as SharpKml.Dom.Document;
+ SharpKml.Dom.Placemark pm = Element as SharpKml.Dom.Placemark;
+ SharpKml.Dom.Folder folder = Element as SharpKml.Dom.Folder;
+ SharpKml.Dom.Polygon polygon = Element as SharpKml.Dom.Polygon;
+ SharpKml.Dom.LineString ls = Element as SharpKml.Dom.LineString;
+
+ if (doc != null)
+ {
+ foreach (var feat in doc.Features)
{
- GMapPolygon kmlpolygon = new GMapPolygon(new List(), "kmlpolygon");
-
- foreach (var loc in polygon.OuterBoundary.LinearRing.Coordinates)
- {
- kmlpolygon.Points.Add(new PointLatLng(loc.Latitude,loc.Longitude));
- }
-
- kmlpolygons.Polygons.Add(kmlpolygon);
+ //Console.WriteLine("feat " + feat.GetType());
+ //processKML((Element)feat);
}
+ } else
+ if (folder != null )
+ {
+ foreach (Feature feat in folder.Features)
+ {
+ //Console.WriteLine("feat "+feat.GetType());
+ //processKML(feat);
+ }
+ }
+ else if (pm != null)
+ {
+
+ }
+ else if (polygon != null)
+ {
+ GMapPolygon kmlpolygon = new GMapPolygon(new List(), "kmlpolygon");
+
+ foreach (var loc in polygon.OuterBoundary.LinearRing.Coordinates)
+ {
+ kmlpolygon.Points.Add(new PointLatLng(loc.Latitude, loc.Longitude));
+ }
+
+ kmlpolygons.Polygons.Add(kmlpolygon);
+ }
+ else if (ls != null)
+ {
+ GMapRoute kmlroute = new GMapRoute(new List(), "kmlroute");
+
+ foreach (var loc in ls.Coordinates)
+ {
+ kmlroute.Points.Add(new PointLatLng(loc.Latitude, loc.Longitude));
+ }
+
+ kmlpolygons.Routes.Add(kmlroute);
+ }
}
private void ChangeColumnHeader(string command)
@@ -2792,9 +2839,9 @@ namespace ArdupilotMega.GCSViews
// this is a mono fix for the zoom bar
Console.WriteLine("panelmap "+panelMap.Size.ToString());
MainMap.Size = new Size(panelMap.Size.Width - 50,panelMap.Size.Height);
- trackBar1.Location = new Point(panelMap.Size.Width - 50,trackBar1.Location.Y);
+ trackBar1.Location = new System.Drawing.Point(panelMap.Size.Width - 50,trackBar1.Location.Y);
trackBar1.Size = new System.Drawing.Size(trackBar1.Size.Width, panelMap.Size.Height - trackBar1.Location.Y);
- label11.Location = new Point(panelMap.Size.Width - 50, label11.Location.Y);
+ label11.Location = new System.Drawing.Point(panelMap.Size.Width - 50, label11.Location.Y);
}
private void BUT_zoomto_Click(object sender, EventArgs e)
@@ -2828,11 +2875,17 @@ namespace ArdupilotMega.GCSViews
try
{
kmlpolygons.Polygons.Clear();
+ kmlpolygons.Routes.Clear();
+
+ string kml = new StreamReader(File.OpenRead(file)).ReadToEnd();
+
+ kml = kml.Replace("", "");
var parser = new SharpKml.Base.Parser();
- parser.ElementAdded += new EventHandler(parser_ElementAdded);
- parser.Parse(File.OpenRead(file));
+ parser.ElementAdded += parser_ElementAdded;
+ parser.ParseString(kml,true);
+
}
catch (Exception ex) { MessageBox.Show("Bad KML File :" + ex.ToString()); }
}
diff --git a/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.Designer.cs b/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.Designer.cs
index db612a34dd..9f9231c654 100644
--- a/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.Designer.cs
+++ b/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.Designer.cs
@@ -112,6 +112,7 @@
this.CHK_heli = new System.Windows.Forms.CheckBox();
this.RAD_aerosimrc = new System.Windows.Forms.RadioButton();
this.toolTip1 = new System.Windows.Forms.ToolTip(this.components);
+ this.RAD_JSBSim = new System.Windows.Forms.RadioButton();
((System.ComponentModel.ISupportInitialize)(this.currentStateBindingSource)).BeginInit();
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
@@ -692,10 +693,19 @@
this.RAD_aerosimrc.UseVisualStyleBackColor = true;
this.RAD_aerosimrc.CheckedChanged += new System.EventHandler(this.RAD_aerosimrc_CheckedChanged);
//
+ // RAD_JSBSim
+ //
+ resources.ApplyResources(this.RAD_JSBSim, "RAD_JSBSim");
+ this.RAD_JSBSim.Name = "RAD_JSBSim";
+ this.toolTip1.SetToolTip(this.RAD_JSBSim, resources.GetString("RAD_JSBSim.ToolTip"));
+ this.RAD_JSBSim.UseVisualStyleBackColor = true;
+ this.RAD_JSBSim.CheckedChanged += new System.EventHandler(this.RAD_JSBSim_CheckedChanged);
+ //
// Simulation
//
resources.ApplyResources(this, "$this");
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.Controls.Add(this.RAD_JSBSim);
this.Controls.Add(this.RAD_aerosimrc);
this.Controls.Add(this.CHK_heli);
this.Controls.Add(this.BUT_startxplane);
@@ -825,5 +835,6 @@
private System.Windows.Forms.CheckBox CHK_heli;
private System.Windows.Forms.RadioButton RAD_aerosimrc;
private System.Windows.Forms.ToolTip toolTip1;
+ private System.Windows.Forms.RadioButton RAD_JSBSim;
}
}
diff --git a/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.cs b/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.cs
index ddb1f67db9..8c1ef36029 100644
--- a/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.cs
+++ b/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.cs
@@ -22,7 +22,8 @@ namespace ArdupilotMega.GCSViews
UdpClient XplanesSEND;
UdpClient MavLink;
Socket SimulatorRECV;
- //TcpClient FlightGearSEND;
+ TcpClient JSBSimSEND;
+ UdpClient SITLSEND;
EndPoint Remote = (EndPoint)(new IPEndPoint(IPAddress.Any, 0));
byte[] udpdata = new byte[113 * 9 + 5]; // 113 types - 9 items per type (index+8) + 5 byte header
float[][] DATA = new float[113][];
@@ -246,7 +247,22 @@ namespace ArdupilotMega.GCSViews
}
else
{
- //SetupTcpFlightGear(); // old style
+ if (RAD_JSBSim.Checked)
+ {
+ System.Diagnostics.ProcessStartInfo _procstartinfo = new System.Diagnostics.ProcessStartInfo();
+ _procstartinfo.WorkingDirectory = Path.GetDirectoryName(Application.ExecutablePath);
+ _procstartinfo.Arguments = "--realtime --suspend --nice --simulation-rate=1000 --logdirectivefile=jsbsim/fgout.xml --script=jsbsim/rascal_test.xml";
+ _procstartinfo.FileName = "JSBSim.exe";
+ // Path.GetDirectoryName(Application.ExecutablePath) + Path.DirectorySeparatorChar +
+
+ _procstartinfo.UseShellExecute = true;
+
+ System.Diagnostics.Process.Start(_procstartinfo);
+
+ SITLSEND = new UdpClient(simIP, 5501);
+ }
+
+ SetupTcpJSBSim(); // old style
SetupUDPXplanes(); // fg udp style
SetupUDPMavLink(); // pass traffic - raw
}
@@ -560,14 +576,14 @@ namespace ArdupilotMega.GCSViews
if (hzcounttime.Second != DateTime.Now.Second)
{
- // Console.WriteLine("SIM hz {0}", hzcount);
+ //Console.WriteLine("SIM hz {0}", hzcount);
hzcount = 0;
hzcounttime = DateTime.Now;
}
- System.Threading.Thread.Sleep(5); // this controls send speed to sim
+ System.Threading.Thread.Sleep(1); // this controls send speed to sim
}
}
@@ -587,7 +603,25 @@ namespace ArdupilotMega.GCSViews
SimulatorRECV.Bind(ipep);
- OutputLog.AppendText("Listerning on port " + recvPort + " (sim->planner)\n");
+ OutputLog.AppendText("Listerning on port UDP " + recvPort + " (sim->planner)\n");
+ }
+
+ private void SetupTcpJSBSim()
+ {
+ try
+ {
+ JSBSimSEND = new TcpClient();
+ JSBSimSEND.Client.NoDelay = true;
+ JSBSimSEND.Connect(simIP, simPort);
+ OutputLog.AppendText("Sending to port TCP " + simPort + " (planner->sim)\n");
+
+ JSBSimSEND.Client.Send(System.Text.Encoding.ASCII.GetBytes("info\n"));
+
+ JSBSimSEND.Client.Send(System.Text.Encoding.ASCII.GetBytes("set attitude/phi-rad 0\n"));
+ JSBSimSEND.Client.Send(System.Text.Encoding.ASCII.GetBytes("set attitude/theta-rad 0\n"));
+ JSBSimSEND.Client.Send(System.Text.Encoding.ASCII.GetBytes("resume\n"));
+ }
+ catch { }
}
private void SetupUDPXplanes()
@@ -595,7 +629,7 @@ namespace ArdupilotMega.GCSViews
// setup sender
XplanesSEND = new UdpClient(simIP, simPort);
- OutputLog.AppendText("Sending to port " + simPort + " (planner->sim)\n");
+ OutputLog.AppendText("Sending to port UDP " + simPort + " (planner->sim)\n");
}
private void SetupUDPMavLink()
@@ -944,7 +978,7 @@ namespace ArdupilotMega.GCSViews
asp.airspeed = ((float)Math.Sqrt((yvec * yvec) + (xvec * xvec)));
}
- else if (receviedbytes > 0x100)
+ else if (receviedbytes == 408)
{
FGNetFDM fdm = new FGNetFDM();
@@ -997,7 +1031,7 @@ namespace ArdupilotMega.GCSViews
gps.v = ((float)Math.Sqrt((fdm.v_north * fdm.v_north) + (fdm.v_east * fdm.v_east)) * ft2m);
#endif
- asp.airspeed = fdm.vcas * kts2fps * ft2m;
+ asp.airspeed = fdm.vcas * ft2m;
}
else
{
@@ -1080,6 +1114,37 @@ namespace ArdupilotMega.GCSViews
return;
}
+ if (RAD_JSBSim.Checked && chkSensor.Checked)
+ {
+
+ byte[] sitlout = new byte[16 * 8 + 1 * 4]; // 16 * double + 1 * int
+ int a = 0;
+
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.latitude), a, sitlout, a, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.longitude), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.altitude), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.psi), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.v_north), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.v_east), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.A_X_pilot), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.A_Y_pilot), 0, sitlout, a += 8, 8);
+
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.A_Z_pilot), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.phidot), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.thetadot), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.psidot), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.phi), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.theta), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.psi), 0, sitlout, a += 8, 8);
+ Array.Copy(BitConverter.GetBytes((double)lastfdmdata.vcas), 0, sitlout, a += 8, 8);
+
+ Array.Copy(BitConverter.GetBytes((int)0x4c56414e), 0, sitlout, a += 8, 4);
+
+ SITLSEND.Send(sitlout, sitlout.Length);
+
+ return;
+ }
+
#if MAVLINK10
TimeSpan gpsspan = DateTime.Now - lastgpsupdate;
@@ -1354,7 +1419,7 @@ namespace ArdupilotMega.GCSViews
updateScreenDisplay(DATA[20][0] * deg2rad, DATA[20][1] * deg2rad, DATA[20][2] * .3048, DATA[18][1] * deg2rad, DATA[18][0] * deg2rad, DATA[19][2] * deg2rad, DATA[18][2] * deg2rad, roll_out, pitch_out, rudder_out, throttle_out);
}
- if (RAD_softFlightGear.Checked)
+ if (RAD_softFlightGear.Checked || RAD_JSBSim.Checked)
{
updateScreenDisplay(lastfdmdata.latitude, lastfdmdata.longitude, lastfdmdata.altitude * .3048, lastfdmdata.phi, lastfdmdata.theta, lastfdmdata.psi, lastfdmdata.psi, roll_out, pitch_out, rudder_out, throttle_out);
}
@@ -1392,6 +1457,23 @@ namespace ArdupilotMega.GCSViews
catch { }
}
+ //JSBSim
+
+ if (RAD_JSBSim.Checked)
+ {
+ roll_out = Constrain(roll_out * REV_roll, -1f, 1f);
+ pitch_out = Constrain(-pitch_out * REV_pitch, -1f,1f);
+ rudder_out = Constrain(rudder_out * REV_rudder, -1f, 1f);
+
+ throttle_out = Constrain(throttle_out, -0.0f, 1f);
+
+ string cmd = string.Format("set fcs/aileron-cmd-norm {0}\r\nset fcs/elevator-cmd-norm {1}\r\nset fcs/rudder-cmd-norm {2}\r\nset fcs/throttle-cmd-norm {3}\r\n",roll_out,pitch_out,rudder_out,throttle_out);
+
+ //Console.Write(cmd);
+ byte[] data = System.Text.Encoding.ASCII.GetBytes(cmd);
+ JSBSimSEND.Client.Send(data);
+ }
+
// Flightgear
if (RAD_softFlightGear.Checked)
@@ -1975,5 +2057,10 @@ namespace ArdupilotMega.GCSViews
RAD_softFlightGear.Checked = false;
}
}
+
+ private void RAD_JSBSim_CheckedChanged(object sender, EventArgs e)
+ {
+
+ }
}
}
\ No newline at end of file
diff --git a/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.resx b/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.resx
index 5d542ad283..9d99df9038 100644
--- a/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.resx
+++ b/Tools/ArdupilotMegaPlanner/GCSViews/Simulation.resx
@@ -144,7 +144,7 @@
$this
- 29
+ 30
True
@@ -171,7 +171,7 @@
$this
- 28
+ 29
True
@@ -198,7 +198,7 @@
$this
- 27
+ 28
100
@@ -225,10 +225,10 @@
99999
- 538, 36
+ 551, 36
- 92, 21
+ 79, 21
4
@@ -243,7 +243,7 @@
$this
- 26
+ 27
26, 13
@@ -261,7 +261,7 @@
ConnectComPort
- ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel5
@@ -294,7 +294,7 @@
$this
- 25
+ 26
67, 22
@@ -309,7 +309,7 @@
TXT_roll
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel2
@@ -330,7 +330,7 @@
TXT_pitch
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel2
@@ -351,7 +351,7 @@
TXT_heading
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel2
@@ -372,7 +372,7 @@
TXT_wpdist
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -396,7 +396,7 @@
TXT_bererror
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -417,7 +417,7 @@
TXT_alterror
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -438,7 +438,7 @@
TXT_lat
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel1
@@ -459,7 +459,7 @@
TXT_long
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel1
@@ -480,7 +480,7 @@
TXT_alt
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel1
@@ -504,14 +504,17 @@
SaveSettings
- ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
$this
- 24
+ 25
+
+ 301, 17
+
True
@@ -527,9 +530,6 @@
X-plane
-
- 301, 17
-
Can Do Plane/Quad with plugin
@@ -543,13 +543,13 @@
$this
- 23
+ 24
True
- 266, 40
+ 259, 40
73, 17
@@ -573,7 +573,7 @@
$this
- 22
+ 23
67, 24
@@ -588,7 +588,7 @@
TXT_servoroll
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel3
@@ -609,7 +609,7 @@
TXT_servopitch
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel3
@@ -630,7 +630,7 @@
TXT_servorudder
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel3
@@ -651,7 +651,7 @@
TXT_servothrottle
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel3
@@ -659,23 +659,11 @@
8
-
- 60, 3
-
-
- 59, 13
-
-
- 19
-
-
- Plane GPS
-
label4
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel1
@@ -683,23 +671,11 @@
0
-
- 7, 78
-
-
- 42, 13
-
-
- 18
-
-
- Altitude
-
label3
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel1
@@ -707,23 +683,11 @@
1
-
- 7, 52
-
-
- 54, 13
-
-
- 17
-
-
- Longitude
-
label2
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel1
@@ -731,23 +695,11 @@
2
-
- 7, 26
-
-
- 45, 13
-
-
- 16
-
-
- Latitude
-
label1
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel1
@@ -774,25 +726,109 @@
$this
- 21
+ 22
-
- 7, 100
+
+ 60, 3
-
- 28, 13
+
+ 59, 13
-
- 21
+
+ 19
-
- Yaw
+
+ Plane GPS
+
+
+ label4
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel1
+
+
+ 0
+
+
+ 7, 78
+
+
+ 42, 13
+
+
+ 18
+
+
+ Altitude
+
+
+ label3
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel1
+
+
+ 1
+
+
+ 7, 52
+
+
+ 54, 13
+
+
+ 17
+
+
+ Longitude
+
+
+ label2
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel1
+
+
+ 2
+
+
+ 7, 26
+
+
+ 45, 13
+
+
+ 16
+
+
+ Latitude
+
+
+ label1
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel1
+
+
+ 3
label30
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel2
@@ -800,20 +836,11 @@
0
-
- 67, 93
-
-
- 100, 20
-
-
- 20
-
TXT_yaw
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel2
@@ -821,23 +848,11 @@
1
-
- 60, 4
-
-
- 57, 13
-
-
- 19
-
-
- Plane IMU
-
label11
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel2
@@ -845,23 +860,11 @@
2
-
- 7, 77
-
-
- 47, 13
-
-
- 15
-
-
- Heading
-
label7
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel2
@@ -869,23 +872,11 @@
3
-
- 7, 52
-
-
- 31, 13
-
-
- 14
-
-
- Pitch
-
label6
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel2
@@ -893,23 +884,11 @@
4
-
- 7, 29
-
-
- 25, 13
-
-
- 13
-
-
- Roll
-
label5
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel2
@@ -936,8 +915,149 @@
$this
+ 21
+
+
+ 7, 100
+
+
+ 28, 13
+
+
+ 21
+
+
+ Yaw
+
+
+ label30
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel2
+
+
+ 0
+
+
+ 67, 93
+
+
+ 100, 20
+
+
20
+
+ TXT_yaw
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel2
+
+
+ 1
+
+
+ 60, 4
+
+
+ 57, 13
+
+
+ 19
+
+
+ Plane IMU
+
+
+ label11
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel2
+
+
+ 2
+
+
+ 7, 77
+
+
+ 47, 13
+
+
+ 15
+
+
+ Heading
+
+
+ label7
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel2
+
+
+ 3
+
+
+ 7, 52
+
+
+ 31, 13
+
+
+ 14
+
+
+ Pitch
+
+
+ label6
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel2
+
+
+ 4
+
+
+ 7, 29
+
+
+ 25, 13
+
+
+ 13
+
+
+ Roll
+
+
+ label5
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel2
+
+
+ 5
+
7, 27
@@ -954,7 +1074,7 @@
label8
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -978,7 +1098,7 @@
label9
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -1002,7 +1122,7 @@
label10
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -1010,23 +1130,11 @@
5
-
- 50, 8
-
-
- 83, 13
-
-
- 27
-
-
- Ardupilot Output
-
label16
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel3
@@ -1034,23 +1142,11 @@
0
-
- 10, 104
-
-
- 43, 13
-
-
- 26
-
-
- Throttle
-
label15
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel3
@@ -1058,23 +1154,11 @@
1
-
- 10, 78
-
-
- 28, 13
-
-
- 25
-
-
- Yaw
-
label14
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel3
@@ -1082,23 +1166,11 @@
2
-
- 10, 52
-
-
- 31, 13
-
-
- 24
-
-
- Pitch
-
label13
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel3
@@ -1106,23 +1178,11 @@
3
-
- 10, 27
-
-
- 25, 13
-
-
- 23
-
-
- Roll
-
label12
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel3
@@ -1149,25 +1209,133 @@
$this
- 19
+ 20
-
- 72, 104
+
+ 50, 8
-
- 34, 13
+
+ 83, 13
-
+
+ 27
+
+
+ Ardupilot Output
+
+
+ label16
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel3
+
+
+ 0
+
+
+ 10, 104
+
+
+ 43, 13
+
+
+ 26
+
+
+ Throttle
+
+
+ label15
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel3
+
+
+ 1
+
+
+ 10, 78
+
+
+ 28, 13
+
+
+ 25
+
+
+ Yaw
+
+
+ label14
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel3
+
+
+ 2
+
+
+ 10, 52
+
+
+ 31, 13
+
+
+ 24
+
+
+ Pitch
+
+
+ label13
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel3
+
+
+ 3
+
+
+ 10, 27
+
+
+ 25, 13
+
+
23
-
- Mode
+
+ Roll
+
+
+ label12
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel3
+
+
+ 4
label20
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -1175,23 +1343,11 @@
0
-
- 7, 104
-
-
- 25, 13
-
-
- 22
-
-
- WP
-
label19
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -1199,20 +1355,11 @@
1
-
- 112, 99
-
-
- 63, 20
-
-
- 21
-
TXT_control_mode
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -1220,20 +1367,11 @@
2
-
- 38, 98
-
-
- 28, 20
-
-
- 20
-
TXT_WP
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -1241,23 +1379,11 @@
3
-
- 50, 8
-
-
- 81, 13
-
-
- 19
-
-
- Autopilot Status
-
label18
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel4
@@ -1284,7 +1410,121 @@
$this
- 18
+ 19
+
+
+ 72, 104
+
+
+ 34, 13
+
+
+ 23
+
+
+ Mode
+
+
+ label20
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel4
+
+
+ 0
+
+
+ 7, 104
+
+
+ 25, 13
+
+
+ 22
+
+
+ WP
+
+
+ label19
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel4
+
+
+ 1
+
+
+ 112, 99
+
+
+ 63, 20
+
+
+ 21
+
+
+ TXT_control_mode
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel4
+
+
+ 2
+
+
+ 38, 98
+
+
+ 28, 20
+
+
+ 20
+
+
+ TXT_WP
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel4
+
+
+ 3
+
+
+ 50, 8
+
+
+ 81, 13
+
+
+ 19
+
+
+ Autopilot Status
+
+
+ label18
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel4
+
+
+ 4
535, 9
@@ -1302,13 +1542,13 @@
label17
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
$this
- 17
+ 18
13, 5
@@ -1329,7 +1569,7 @@
$this
- 16
+ 17
@@ -1354,11 +1594,176 @@
$this
- 15
+ 16
17, 17
+
+ label28
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel6
+
+
+ 0
+
+
+ label29
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel6
+
+
+ 1
+
+
+ label27
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel6
+
+
+ 2
+
+
+ label25
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel6
+
+
+ 3
+
+
+ TXT_throttlegain
+
+
+ System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ panel6
+
+
+ 4
+
+
+ label24
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel6
+
+
+ 5
+
+
+ label23
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel6
+
+
+ 6
+
+
+ label22
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel6
+
+
+ 7
+
+
+ label21
+
+
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
+
+
+ panel6
+
+
+ 8
+
+
+ TXT_ruddergain
+
+
+ System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ panel6
+
+
+ 9
+
+
+ TXT_pitchgain
+
+
+ System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ panel6
+
+
+ 10
+
+
+ TXT_rollgain
+
+
+ System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ panel6
+
+
+ 11
+
+
+ 382, 294
+
+
+ 178, 122
+
+
+ 30
+
+
+ panel6
+
+
+ System.Windows.Forms.Panel, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ $this
+
+
+ 15
+
126, 76
@@ -1375,7 +1780,7 @@
label28
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel6
@@ -1399,7 +1804,7 @@
label29
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel6
@@ -1423,7 +1828,7 @@
label27
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel6
@@ -1447,7 +1852,7 @@
label25
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel6
@@ -1495,7 +1900,7 @@
label24
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel6
@@ -1519,7 +1924,7 @@
label23
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel6
@@ -1543,7 +1948,7 @@
label22
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel6
@@ -1567,7 +1972,7 @@
label21
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
panel6
@@ -1647,27 +2052,6 @@
11
-
- 382, 294
-
-
- 178, 122
-
-
- 30
-
-
- panel6
-
-
- System.Windows.Forms.Panel, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- $this
-
-
- 14
-
508, 330
@@ -1684,19 +2068,19 @@
label26
- ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyLabel, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
$this
- 13
+ 14
True
- 456, 41
+ 471, 41
74, 17
@@ -1717,7 +2101,7 @@
$this
- 12
+ 13
Bottom, Left
@@ -1747,7 +2131,7 @@
$this
- 11
+ 12
Bottom, Left
@@ -1777,7 +2161,7 @@
$this
- 10
+ 11
Bottom, Left
@@ -1807,7 +2191,7 @@
$this
- 9
+ 10
Bottom, Left
@@ -1837,7 +2221,7 @@
$this
- 8
+ 9
566, 368
@@ -1855,13 +2239,13 @@
but_advsettings
- ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
$this
- 7
+ 8
True
@@ -1888,7 +2272,7 @@
$this
- 6
+ 7
True
@@ -1918,7 +2302,7 @@
$this
- 5
+ 6
NoControl
@@ -1939,13 +2323,13 @@
BUT_startfgquad
- ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
$this
- 4
+ 5
NoControl
@@ -1966,13 +2350,13 @@
BUT_startfgplane
- ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
$this
- 3
+ 4
NoControl
@@ -1993,13 +2377,13 @@
BUT_startxplane
- ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ ArdupilotMega.MyButton, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
$this
- 2
+ 3
True
@@ -2029,7 +2413,7 @@
$this
- 1
+ 2
True
@@ -2038,7 +2422,7 @@
NoControl
- 345, 40
+ 332, 40
79, 17
@@ -2062,6 +2446,42 @@
$this
+ 1
+
+
+ 301, 17
+
+
+ True
+
+
+ NoControl
+
+
+ 409, 40
+
+
+ 61, 17
+
+
+ 49
+
+
+ JSBSim
+
+
+ Can do Plane/Heli/Quads
+
+
+ RAD_JSBSim
+
+
+ System.Windows.Forms.RadioButton, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ $this
+
+
0
@@ -2095,6 +2515,6 @@
Simulation
- System.Windows.Forms.MyUserControl, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff91852278f5092c
+ System.Windows.Forms.MyUserControl, ArdupilotMegaPlanner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=38326cb7e06851fc
\ No newline at end of file
diff --git a/Tools/ArdupilotMegaPlanner/HUD.cs b/Tools/ArdupilotMegaPlanner/HUD.cs
index 58515757a5..370953dcde 100644
--- a/Tools/ArdupilotMegaPlanner/HUD.cs
+++ b/Tools/ArdupilotMegaPlanner/HUD.cs
@@ -243,19 +243,26 @@ namespace hud
starttime = DateTime.Now;
- if (opengl)
+ try
{
- MakeCurrent();
- GL.Clear(ClearBufferMask.ColorBufferBit);
+ if (opengl)
+ {
+ MakeCurrent();
+
+ GL.Clear(ClearBufferMask.ColorBufferBit);
+
+ }
+
+ doPaint(e);
+
+ if (opengl)
+ {
+ this.SwapBuffers();
+ }
}
-
- doPaint(e);
-
- if (opengl) {
- this.SwapBuffers();
- }
+ catch (Exception ex) { Console.WriteLine(ex.ToString()); }
count++;
diff --git a/Tools/ArdupilotMegaPlanner/Log.cs b/Tools/ArdupilotMegaPlanner/Log.cs
index 54fc20c46c..b45163c919 100644
--- a/Tools/ArdupilotMegaPlanner/Log.cs
+++ b/Tools/ArdupilotMegaPlanner/Log.cs
@@ -41,6 +41,7 @@ namespace ArdupilotMega
public Model model;
public string[] ntun;
public string[] ctun;
+ public int datetime;
}
enum serialstatus
@@ -364,16 +365,24 @@ namespace ArdupilotMega
{
try
{
- if (lastpos.X != 0 && oldlastpos != lastpos)
+ if (lastpos.X != 0 && oldlastpos.X != lastpos.X && oldlastpos.Y != lastpos.Y)
{
Data dat = new Data();
+ try
+ {
+ dat.datetime = int.Parse(lastline.Split(',', ':')[1]);
+ }
+ catch { }
+
runmodel = new Model();
runmodel.Location.longitude = lastpos.X;
runmodel.Location.latitude = lastpos.Y;
runmodel.Location.altitude = lastpos.Z;
+ oldlastpos = lastpos;
+
runmodel.Orientation.roll = double.Parse(items[1], new System.Globalization.CultureInfo("en-US")) / -100;
runmodel.Orientation.tilt = double.Parse(items[2], new System.Globalization.CultureInfo("en-US")) / -100;
runmodel.Orientation.heading = double.Parse(items[3], new System.Globalization.CultureInfo("en-US")) / 100;
@@ -398,9 +407,51 @@ namespace ArdupilotMega
List[] position = new List[200];
int positionindex = 0;
+ private void writeGPX(string filename)
+ {
+ System.Xml.XmlTextWriter xw = new System.Xml.XmlTextWriter(Path.GetDirectoryName(filename) + Path.DirectorySeparatorChar + Path.GetFileNameWithoutExtension(filename) + ".gpx",Encoding.ASCII);
+
+ xw.WriteStartElement("gpx");
+
+ xw.WriteStartElement("trk");
+
+ xw.WriteStartElement("trkseg");
+
+ DateTime start = new DateTime(DateTime.Now.Year,DateTime.Now.Month,DateTime.Now.Day,0,0,0);
+
+ foreach (Data mod in flightdata)
+ {
+ xw.WriteStartElement("trkpt");
+ xw.WriteAttributeString("lat",mod.model.Location.latitude.ToString());
+ xw.WriteAttributeString("lon", mod.model.Location.longitude.ToString());
+
+ xw.WriteElementString("ele", mod.model.Location.altitude.ToString());
+ xw.WriteElementString("time", start.AddMilliseconds(mod.datetime).ToString("yyyy-MM-ddTHH:mm:sszzzzzz"));
+ xw.WriteElementString("course", (mod.model.Orientation.heading).ToString());
+
+ xw.WriteElementString("roll", mod.model.Orientation.roll.ToString());
+ xw.WriteElementString("pitch", mod.model.Orientation.tilt.ToString());
+ //xw.WriteElementString("speed", mod.model.Orientation.);
+ //xw.WriteElementString("fix", mod.model.Location.altitude);
+
+ xw.WriteEndElement();
+ }
+
+ xw.WriteEndElement();
+ xw.WriteEndElement();
+ xw.WriteEndElement();
+
+ xw.Close();
+ }
private void writeKML(string filename)
{
+ try
+ {
+ writeGPX(filename);
+ }
+ catch { }
+
Color[] colours = { Color.Red, Color.Orange, Color.Yellow, Color.Green, Color.Blue, Color.Indigo, Color.Violet, Color.Pink };
AltitudeMode altmode = AltitudeMode.absolute;
diff --git a/Tools/ArdupilotMegaPlanner/MainV2.cs b/Tools/ArdupilotMegaPlanner/MainV2.cs
index d7b09349a4..b2644aeeb6 100644
--- a/Tools/ArdupilotMegaPlanner/MainV2.cs
+++ b/Tools/ArdupilotMegaPlanner/MainV2.cs
@@ -81,10 +81,6 @@ namespace ArdupilotMega
public MainV2()
{
- //new temp().ShowDialog();
- //return;
-
-
Form splash = new Splash();
splash.Show();
@@ -96,17 +92,8 @@ namespace ArdupilotMega
Application.DoEvents();
- //System.Threading.Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo("en-US");
- //System.Threading.Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo("en-US");
-
srtm.datadirectory = Path.GetDirectoryName(Application.ExecutablePath) + Path.DirectorySeparatorChar + "srtm";
- georefimage temp = new georefimage();
-
- //temp.dowork(244 + 60*60*24 * -1 );
-
- //return;
-
var t = Type.GetType("Mono.Runtime");
MONO = (t != null);
diff --git a/Tools/ArdupilotMegaPlanner/Properties/AssemblyInfo.cs b/Tools/ArdupilotMegaPlanner/Properties/AssemblyInfo.cs
index 60d13013cd..8940519010 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.0.0.0")]
-[assembly: AssemblyFileVersion("1.1.1")]
+[assembly: AssemblyFileVersion("1.1.2")]
[assembly: NeutralResourcesLanguageAttribute("")]
diff --git a/Tools/ArdupilotMegaPlanner/app.config b/Tools/ArdupilotMegaPlanner/app.config
index 0bd140011f..1eafff02a4 100644
--- a/Tools/ArdupilotMegaPlanner/app.config
+++ b/Tools/ArdupilotMegaPlanner/app.config
@@ -2,10 +2,6 @@
-
-
-
-
+
+
diff --git a/Tools/ArdupilotMegaPlanner/bin/Release/.gitignore b/Tools/ArdupilotMegaPlanner/bin/Release/.gitignore
index 022a200f68..b09e38ab43 100644
--- a/Tools/ArdupilotMegaPlanner/bin/Release/.gitignore
+++ b/Tools/ArdupilotMegaPlanner/bin/Release/.gitignore
@@ -1,3 +1 @@
-
-*.pdb
-*.xml
\ No newline at end of file
+*.pdb
\ No newline at end of file
diff --git a/Tools/ArdupilotMegaPlanner/bin/Release/ArdupilotMegaPlanner.application b/Tools/ArdupilotMegaPlanner/bin/Release/ArdupilotMegaPlanner.application
index 38c1663988..f0b8789864 100644
--- a/Tools/ArdupilotMegaPlanner/bin/Release/ArdupilotMegaPlanner.application
+++ b/Tools/ArdupilotMegaPlanner/bin/Release/ArdupilotMegaPlanner.application
@@ -4,14 +4,14 @@
-
+
- mN7pjMOs48ZdF2S8vaEAJbtq8b4=
+ +BB2J7z2to1UULmX82O0PxoC594=
diff --git a/Tools/ArdupilotMegaPlanner/bin/Release/ArdupilotMegaPlanner.exe.config b/Tools/ArdupilotMegaPlanner/bin/Release/ArdupilotMegaPlanner.exe.config
index 0bd140011f..1eafff02a4 100644
--- a/Tools/ArdupilotMegaPlanner/bin/Release/ArdupilotMegaPlanner.exe.config
+++ b/Tools/ArdupilotMegaPlanner/bin/Release/ArdupilotMegaPlanner.exe.config
@@ -2,10 +2,6 @@
-
-
-
-
+
+
diff --git a/Tools/ArdupilotMegaPlanner/bin/Release/jsbsim/fgout.xml b/Tools/ArdupilotMegaPlanner/bin/Release/jsbsim/fgout.xml
new file mode 100644
index 0000000000..ce92818c77
--- /dev/null
+++ b/Tools/ArdupilotMegaPlanner/bin/Release/jsbsim/fgout.xml
@@ -0,0 +1,2 @@
+
+
diff --git a/Tools/ArdupilotMegaPlanner/bin/Release/jsbsim/rascal_test.xml b/Tools/ArdupilotMegaPlanner/bin/Release/jsbsim/rascal_test.xml
new file mode 100644
index 0000000000..fab9436194
--- /dev/null
+++ b/Tools/ArdupilotMegaPlanner/bin/Release/jsbsim/rascal_test.xml
@@ -0,0 +1,33 @@
+
+
+
+
+
+ test ArduPlane using Rascal110 and JSBSim
+
+
+
+
+
+
+
+
+ simulation/notify-time-trigger
+
+
+ simulation/sim-time-sec le 0.01
+
+
+
+
+
+ simulation/sim-time-sec ge 0.01
+
+
+
+
+
+
diff --git a/Tools/ArdupilotMegaPlanner/georefimage.cs b/Tools/ArdupilotMegaPlanner/georefimage.cs
index 8c0abcae99..dca2fb0919 100644
--- a/Tools/ArdupilotMegaPlanner/georefimage.cs
+++ b/Tools/ArdupilotMegaPlanner/georefimage.cs
@@ -5,14 +5,26 @@ using System.Text;
using System.Drawing;
using System.Drawing.Imaging;
using System.IO;
+using System.Windows.Forms;
namespace ArdupilotMega
{
- class georefimage
+ class georefimage : Form
{
+ private OpenFileDialog openFileDialog1;
+ private MyButton BUT_browselog;
+ private MyButton BUT_browsedir;
+ private TextBox TXT_logfile;
+ private TextBox TXT_jpgdir;
+ private TextBox TXT_offsetseconds;
+ private MyButton BUT_doit;
+ private FolderBrowserDialog folderBrowserDialog1;
+ private Label label1;
+ private TextBox TXT_outputlog;
- public string logFile = "";
- public string dirWithImages = "";
+ internal georefimage() {
+ InitializeComponent();
+ }
DateTime getPhotoTime(string fn)
{
@@ -69,18 +81,18 @@ namespace ArdupilotMega
return list;
}
- public void dowork(float offsetseconds)
+ public void dowork(string logFile, string dirWithImages, float offsetseconds)
{
DateTime localmin = DateTime.MaxValue;
DateTime localmax = DateTime.MinValue;
DateTime startTime = DateTime.MinValue;
- logFile = @"C:\temp\farm 1-10-2011\100SSCAM\2011-10-01 11-48 1.log";
+ //logFile = @"C:\Users\hog\Pictures\farm 1-10-2011\100SSCAM\2011-10-01 11-48 1.log";
List list = readLog(logFile);
- dirWithImages = @"C:\temp\farm 1-10-2011\100SSCAM";
+ //dirWithImages = @"C:\Users\hog\Pictures\farm 1-10-2011\100SSCAM";
string[] files = Directory.GetFiles(dirWithImages);
@@ -91,6 +103,8 @@ namespace ArdupilotMega
sw.WriteLine("#longitude and latitude - in degrees");
sw.WriteLine("#name utc longitude latitude height");
+ int first = 0;
+
foreach (string file in files)
{
if (file.ToLower().EndsWith(".jpg"))
@@ -112,18 +126,33 @@ namespace ArdupilotMega
}
Console.WriteLine("min " + localmin + " max " + localmax);
+ TXT_outputlog.AppendText("Log min " + localmin + " max " + localmax + "\r\n");
}
-
+ TXT_outputlog.AppendText("Photo " + Path.GetFileNameWithoutExtension(file) + " time " + dt + "\r\n");
foreach (string[] arr in list)
{
+ Application.DoEvents();
+
DateTime crap = startTime.AddMilliseconds(int.Parse(arr[1])).AddSeconds(offsetseconds);
+
+ if (first == 0)
+ {
+ TXT_outputlog.AppendText("Photo " + Path.GetFileNameWithoutExtension(file) + " " + dt + " vs Log " + crap + "\r\n");
+
+ TXT_outputlog.AppendText("offset should be about " + (dt -crap).TotalSeconds + "\r\n");
+
+ first++;
+ }
+
Console.Write("ph " + dt + " log " + crap + " \r");
if (dt.Equals(crap))
{
+ TXT_outputlog.AppendText("MATCH Photo " + Path.GetFileNameWithoutExtension(file) + " " + dt + "\r\n");
+
sw2.WriteLine(Path.GetFileNameWithoutExtension(file) + " " + arr[5] + " " + arr[4] + " " + arr[7]);
sw.WriteLine(Path.GetFileNameWithoutExtension(file) + "\t" + crap.ToString("yyyy:MM:dd HH:mm:ss") +"\t"+ arr[5] + "\t" + arr[4] + "\t" + arr[7]);
sw.Flush();
@@ -141,6 +170,159 @@ namespace ArdupilotMega
sw2.Close();
sw.Close();
+ MessageBox.Show("Done");
+
+ }
+
+ private void InitializeComponent()
+ {
+ this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog();
+ this.BUT_browselog = new ArdupilotMega.MyButton();
+ this.BUT_browsedir = new ArdupilotMega.MyButton();
+ this.TXT_logfile = new System.Windows.Forms.TextBox();
+ this.TXT_jpgdir = new System.Windows.Forms.TextBox();
+ this.TXT_offsetseconds = new System.Windows.Forms.TextBox();
+ this.BUT_doit = new ArdupilotMega.MyButton();
+ this.folderBrowserDialog1 = new System.Windows.Forms.FolderBrowserDialog();
+ this.TXT_outputlog = new System.Windows.Forms.TextBox();
+ this.label1 = new System.Windows.Forms.Label();
+ this.SuspendLayout();
+ //
+ // openFileDialog1
+ //
+ this.openFileDialog1.FileName = "openFileDialog1";
+ //
+ // BUT_browselog
+ //
+ this.BUT_browselog.Location = new System.Drawing.Point(351, 12);
+ this.BUT_browselog.Name = "BUT_browselog";
+ this.BUT_browselog.Size = new System.Drawing.Size(75, 23);
+ this.BUT_browselog.TabIndex = 0;
+ this.BUT_browselog.Text = "Browse Log";
+ this.BUT_browselog.UseVisualStyleBackColor = true;
+ this.BUT_browselog.Click += new System.EventHandler(this.BUT_browselog_Click);
+ //
+ // BUT_browsedir
+ //
+ this.BUT_browsedir.Location = new System.Drawing.Point(351, 41);
+ this.BUT_browsedir.Name = "BUT_browsedir";
+ this.BUT_browsedir.Size = new System.Drawing.Size(75, 23);
+ this.BUT_browsedir.TabIndex = 1;
+ this.BUT_browsedir.Text = "Browse Directory";
+ this.BUT_browsedir.UseVisualStyleBackColor = true;
+ this.BUT_browsedir.Click += new System.EventHandler(this.BUT_browsedir_Click);
+ //
+ // TXT_logfile
+ //
+ this.TXT_logfile.Location = new System.Drawing.Point(28, 14);
+ this.TXT_logfile.Name = "TXT_logfile";
+ this.TXT_logfile.Size = new System.Drawing.Size(317, 20);
+ this.TXT_logfile.TabIndex = 2;
+ this.TXT_logfile.Text = "C:\\Users\\hog\\Pictures\\farm 1-10-2011\\100SSCAM\\2011-10-01 11-48 1.log";
+ //
+ // TXT_jpgdir
+ //
+ this.TXT_jpgdir.Location = new System.Drawing.Point(28, 43);
+ this.TXT_jpgdir.Name = "TXT_jpgdir";
+ this.TXT_jpgdir.Size = new System.Drawing.Size(317, 20);
+ this.TXT_jpgdir.TabIndex = 3;
+ this.TXT_jpgdir.Text = "C:\\Users\\hog\\Pictures\\farm 1-10-2011\\100SSCAM";
+ //
+ // TXT_offsetseconds
+ //
+ this.TXT_offsetseconds.Location = new System.Drawing.Point(180, 69);
+ this.TXT_offsetseconds.Name = "TXT_offsetseconds";
+ this.TXT_offsetseconds.Size = new System.Drawing.Size(100, 20);
+ this.TXT_offsetseconds.TabIndex = 4;
+ this.TXT_offsetseconds.Text = "-86156";
+ //
+ // BUT_doit
+ //
+ this.BUT_doit.Location = new System.Drawing.Point(194, 105);
+ this.BUT_doit.Name = "BUT_doit";
+ this.BUT_doit.Size = new System.Drawing.Size(75, 23);
+ this.BUT_doit.TabIndex = 5;
+ this.BUT_doit.Text = "Do It";
+ this.BUT_doit.UseVisualStyleBackColor = true;
+ this.BUT_doit.Click += new System.EventHandler(this.BUT_doit_Click);
+ //
+ // TXT_outputlog
+ //
+ this.TXT_outputlog.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
+ | System.Windows.Forms.AnchorStyles.Left)
+ | System.Windows.Forms.AnchorStyles.Right)));
+ this.TXT_outputlog.Location = new System.Drawing.Point(28, 144);
+ this.TXT_outputlog.Multiline = true;
+ this.TXT_outputlog.Name = "TXT_outputlog";
+ this.TXT_outputlog.ReadOnly = true;
+ this.TXT_outputlog.ScrollBars = System.Windows.Forms.ScrollBars.Both;
+ this.TXT_outputlog.Size = new System.Drawing.Size(398, 143);
+ this.TXT_outputlog.TabIndex = 6;
+ //
+ // label1
+ //
+ this.label1.AutoSize = true;
+ this.label1.Location = new System.Drawing.Point(94, 75);
+ this.label1.Name = "label1";
+ this.label1.Size = new System.Drawing.Size(78, 13);
+ this.label1.TabIndex = 7;
+ this.label1.Text = "Seconds offset";
+ //
+ // georefimage
+ //
+ this.ClientSize = new System.Drawing.Size(453, 299);
+ this.Controls.Add(this.label1);
+ this.Controls.Add(this.TXT_outputlog);
+ this.Controls.Add(this.BUT_doit);
+ this.Controls.Add(this.TXT_offsetseconds);
+ this.Controls.Add(this.TXT_jpgdir);
+ this.Controls.Add(this.TXT_logfile);
+ this.Controls.Add(this.BUT_browsedir);
+ this.Controls.Add(this.BUT_browselog);
+ this.Name = "georefimage";
+ this.ResumeLayout(false);
+ this.PerformLayout();
+
+ }
+
+ private void BUT_browselog_Click(object sender, EventArgs e)
+ {
+ openFileDialog1.Filter = "Logs|*.log";
+ openFileDialog1.ShowDialog();
+
+ if (File.Exists(openFileDialog1.FileName))
+ {
+ TXT_logfile.Text = openFileDialog1.FileName;
+ }
+ }
+
+ private void BUT_browsedir_Click(object sender, EventArgs e)
+ {
+ folderBrowserDialog1.ShowDialog();
+
+ if (folderBrowserDialog1.SelectedPath != "")
+ {
+ TXT_jpgdir.Text = folderBrowserDialog1.SelectedPath;
+ }
+ }
+
+ private void BUT_doit_Click(object sender, EventArgs e)
+ {
+ if (!File.Exists(TXT_logfile.Text))
+ return;
+ if (!Directory.Exists(TXT_jpgdir.Text))
+ return;
+ float seconds;
+ if (float.TryParse(TXT_offsetseconds.Text, out seconds) == false)
+ return;
+
+ BUT_doit.Enabled = false;
+ try
+ {
+ dowork(TXT_logfile.Text, TXT_jpgdir.Text, seconds);
+ }
+ catch { }
+ BUT_doit.Enabled = true;
}
}
}
diff --git a/Tools/ArdupilotMegaPlanner/georefimage.resx b/Tools/ArdupilotMegaPlanner/georefimage.resx
new file mode 100644
index 0000000000..cc04386061
--- /dev/null
+++ b/Tools/ArdupilotMegaPlanner/georefimage.resx
@@ -0,0 +1,126 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ 17, 17
+
+
+ 297, 17
+
+
\ No newline at end of file
diff --git a/Tools/ArdupilotMegaPlanner/temp.Designer.cs b/Tools/ArdupilotMegaPlanner/temp.Designer.cs
index 369fb59438..734a6833ad 100644
--- a/Tools/ArdupilotMegaPlanner/temp.Designer.cs
+++ b/Tools/ArdupilotMegaPlanner/temp.Designer.cs
@@ -44,7 +44,7 @@
this.BUT_geinjection = new ArdupilotMega.MyButton();
this.BUT_clearcustommaps = new ArdupilotMega.MyButton();
this.BUT_lang_edit = new ArdupilotMega.MyButton();
- this.myButton1 = new ArdupilotMega.MyButton();
+ this.BUT_georefimage = new ArdupilotMega.MyButton();
this.SuspendLayout();
//
// button1
@@ -175,7 +175,7 @@
//
// BUT_geinjection
//
- this.BUT_geinjection.Location = new System.Drawing.Point(190, 199);
+ this.BUT_geinjection.Location = new System.Drawing.Point(150, 229);
this.BUT_geinjection.Name = "BUT_geinjection";
this.BUT_geinjection.Size = new System.Drawing.Size(209, 40);
this.BUT_geinjection.TabIndex = 14;
@@ -185,7 +185,7 @@
//
// BUT_clearcustommaps
//
- this.BUT_clearcustommaps.Location = new System.Drawing.Point(405, 199);
+ this.BUT_clearcustommaps.Location = new System.Drawing.Point(365, 229);
this.BUT_clearcustommaps.Name = "BUT_clearcustommaps";
this.BUT_clearcustommaps.Size = new System.Drawing.Size(209, 40);
this.BUT_clearcustommaps.TabIndex = 15;
@@ -195,7 +195,7 @@
//
// BUT_lang_edit
//
- this.BUT_lang_edit.Location = new System.Drawing.Point(405, 138);
+ this.BUT_lang_edit.Location = new System.Drawing.Point(365, 164);
this.BUT_lang_edit.Name = "BUT_lang_edit";
this.BUT_lang_edit.Size = new System.Drawing.Size(75, 23);
this.BUT_lang_edit.TabIndex = 16;
@@ -203,22 +203,21 @@
this.BUT_lang_edit.UseVisualStyleBackColor = true;
this.BUT_lang_edit.Click += new System.EventHandler(this.BUT_lang_edit_Click);
//
- // myButton1
+ // BUT_georefimage
//
- this.myButton1.Location = new System.Drawing.Point(30, 174);
- this.myButton1.Name = "myButton1";
- this.myButton1.Size = new System.Drawing.Size(75, 23);
- this.myButton1.TabIndex = 17;
- this.myButton1.Text = "myButton1";
- this.myButton1.UseVisualStyleBackColor = true;
- this.myButton1.Click += new System.EventHandler(this.myButton1_Click);
+ this.BUT_georefimage.Location = new System.Drawing.Point(263, 164);
+ this.BUT_georefimage.Name = "BUT_georefimage";
+ this.BUT_georefimage.Size = new System.Drawing.Size(96, 23);
+ this.BUT_georefimage.TabIndex = 0;
+ this.BUT_georefimage.Text = "Geo ref images";
+ this.BUT_georefimage.Click += new System.EventHandler(this.BUT_georefimage_Click);
//
// temp
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(731, 281);
- this.Controls.Add(this.myButton1);
+ this.Controls.Add(this.BUT_georefimage);
this.Controls.Add(this.BUT_lang_edit);
this.Controls.Add(this.BUT_clearcustommaps);
this.Controls.Add(this.BUT_geinjection);
@@ -261,7 +260,7 @@
private MyButton BUT_geinjection;
private MyButton BUT_clearcustommaps;
private MyButton BUT_lang_edit;
- private MyButton myButton1;
+ private MyButton BUT_georefimage;
//private SharpVectors.Renderers.Forms.SvgPictureBox svgPictureBox1;
}
diff --git a/Tools/ArdupilotMegaPlanner/temp.cs b/Tools/ArdupilotMegaPlanner/temp.cs
index 53d44660f2..c59d018d59 100644
--- a/Tools/ArdupilotMegaPlanner/temp.cs
+++ b/Tools/ArdupilotMegaPlanner/temp.cs
@@ -14,11 +14,6 @@ using System.Net;
using GMap.NET.WindowsForms;
using GMap.NET.CacheProviders;
-using OpenGlobe.Core;
-using OpenGlobe.Renderer;
-using OpenGlobe.Scene;
-
-
namespace ArdupilotMega
{
public partial class temp : Form
@@ -867,222 +862,14 @@ namespace ArdupilotMega
Console.WriteLine("Removed {0} images",removed);
}
-
private void BUT_lang_edit_Click(object sender, EventArgs e)
{
new resedit.Form1().Show();
}
- GraphicsWindow _window;
- SceneState _sceneState;
- CameraLookAtPoint _lookCamera;
- CameraFly _flyCamera;
- ClearState _clearState;
- GlobeClipmapTerrain _clipmap;
- HeadsUpDisplay _hud;
- Font _hudFont;
- RayCastedGlobe _globe;
- ClearState _clearDepth;
- Ellipsoid _ellipsoid;
-
- private void myButton1_Click(object sender, EventArgs e)
+ private void BUT_georefimage_Click(object sender, EventArgs e)
{
-
-
- _window = Device.CreateWindow(800, 600, "Chapter 13: Clipmap Terrain on a Globe");
-
- _ellipsoid = Ellipsoid.Wgs84;
-
- WorldWindTerrainSource terrainSource = new WorldWindTerrainSource();
- GMapRestImagery imagery = new GMapRestImagery();
- _clipmap = new GlobeClipmapTerrain(_window.Context, terrainSource, imagery, _ellipsoid, 511);
- _clipmap.HeightExaggeration = 1.0f;
-
-
-
- IList gridResolutions = new List();
- gridResolutions.Add(new GridResolution(
- new Interval(0, 1000000, IntervalEndpoint.Closed, IntervalEndpoint.Open),
- new Vector2D(0.005, 0.005)));
- gridResolutions.Add(new GridResolution(
- new Interval(1000000, 2000000, IntervalEndpoint.Closed, IntervalEndpoint.Open),
- new Vector2D(0.01, 0.01)));
- gridResolutions.Add(new GridResolution(
- new Interval(2000000, 20000000, IntervalEndpoint.Closed, IntervalEndpoint.Open),
- new Vector2D(0.05, 0.05)));
- gridResolutions.Add(new GridResolution(
- new Interval(20000000, double.MaxValue, IntervalEndpoint.Closed, IntervalEndpoint.Open),
- new Vector2D(0.1, 0.1)));
-
-
-
- _sceneState = new SceneState();
- _sceneState.DiffuseIntensity = 0.90f;
- _sceneState.SpecularIntensity = 0.05f;
- _sceneState.AmbientIntensity = 0.05f;
- _sceneState.Camera.FieldOfViewY = Math.PI / 3.0;
-
- _clearState = new ClearState();
- _clearState.Color = Color.White;
-
- _sceneState.Camera.PerspectiveNearPlaneDistance = 0.000001 * _ellipsoid.MaximumRadius;
- _sceneState.Camera.PerspectiveFarPlaneDistance = 10.0 * _ellipsoid.MaximumRadius;
- _sceneState.SunPosition = new Vector3D(200000, 300000, 200000) * _ellipsoid.MaximumRadius;
-
- _lookCamera = new CameraLookAtPoint(_sceneState.Camera, _window, _ellipsoid);
- _lookCamera.Range = 1.5 * _ellipsoid.MaximumRadius;
-
- _globe = new RayCastedGlobe(_window.Context);
- _globe.Shape = _ellipsoid;
- Bitmap bitmap = new Bitmap("NE2_50M_SR_W_4096.jpg");
- _globe.Texture = Device.CreateTexture2D(bitmap, TextureFormat.RedGreenBlue8, false);
- //_globe.GridResolutions = new GridResolutionCollection(gridResolutions);
-
- _clearDepth = new ClearState();
- _clearDepth.Buffers = ClearBuffers.DepthBuffer | ClearBuffers.StencilBuffer;
-
- //_window.Keyboard.KeyDown += OnKeyDown;
-
- _window.Resize += OnResize;
- _window.RenderFrame += OnRenderFrame;
- _window.PreRenderFrame += OnPreRenderFrame;
-
- _hudFont = new Font("Arial", 16);
- _hud = new HeadsUpDisplay();
- _hud.Color = Color.Blue;
-
- //_flyCamera = new CameraFly(_sceneState.Camera, _window);
- //_flyCamera.MovementRate = 1200.0;
- //_flyCamera.InputEnabled = true;
-
- _sceneState.Camera.Target = new Vector3D(115, -35, 100.0);
-
- _window.Run(30);
-
-
+ new georefimage().Show();
}
-
- private void OnResize()
- {
- _window.Context.Viewport = new Rectangle(0, 0, _window.Width, _window.Height);
- _sceneState.Camera.AspectRatio = _window.Width / (double)_window.Height;
- }
-
- private void OnRenderFrame()
- {
- Context context = _window.Context;
- context.Clear(_clearState);
-
- _globe.Render(context, _sceneState);
-
- context.Clear(_clearDepth);
-
- _clipmap.Render(context, _sceneState);
-
- //_sceneState.Camera.Target = new Vector3D(115000, -350000, 100000.0);
-
- if (_hud != null)
- {
- //_hud.Render(context, _sceneState);
- }
- }
-
- private void OnPreRenderFrame()
- {
- Context context = _window.Context;
- _clipmap.PreRender(context, _sceneState);
- }
- }
-
-
- public class GMapRestImagery : RasterSource
- {
- GMapControl MainMap;
- public GMapRestImagery()
- {
- //_baseUri = baseUri;
-
- _levels = new RasterLevel[NumberOfLevels];
- _levelsCollection = new RasterLevelCollection(_levels);
-
- double deltaLongitude = LevelZeroDeltaLongitudeDegrees;
- double deltaLatitude = LevelZeroDeltaLatitudeDegrees;
- for (int i = 0; i < _levels.Length; ++i)
- {
- int longitudePosts = (int)Math.Round(360.0 / deltaLongitude) * TileLongitudePosts + 1;
- int latitudePosts = (int)Math.Round(180 / deltaLatitude) * TileLatitudePosts + 1;
- _levels[i] = new RasterLevel(this, i, _extent, longitudePosts, latitudePosts, TileLongitudePosts, TileLatitudePosts);
- deltaLongitude /= 2.0;
- deltaLatitude /= 2.0;
- }
-
- MainMap = new GMapControl();
- MainMap.MapType = GMap.NET.MapType.GoogleSatellite;
-
- MainMap.CacheLocation = Path.GetDirectoryName(Application.ExecutablePath) + "/gmapcache/";
- }
-
- public override GeodeticExtent Extent
- {
- get { return _extent; }
- }
-
- public int TileLongitudePosts
- {
- get { return 256; }
- }
-
- public int TileLatitudePosts
- {
- get { return 256; }
- }
-
- public override RasterLevelCollection Levels
- {
- get { return _levelsCollection; }
- }
-
- public override Texture2D LoadTileTexture(RasterTileIdentifier identifier)
- {
- //if (identifier.Level > 4)
- //return null;
- int level = identifier.Level; // 0 is -180 long
- int longitudeIndex = ((_levels[level].LongitudePosts / _levels[level].LongitudePostsPerTile) / 2 / 2) + identifier.X; // (_levels[level].LongitudePosts / _levels[level].LongitudePostsPerTile) -
- int latitudeIndex = identifier.Y; // (_levels[level].LatitudePosts / _levels[level].LatitudePostsPerTile) -
-
- int damn = (1 << level) - latitudeIndex - 1;
-
- Console.WriteLine(" z {0} lat {1} lon {2} ", level, damn, longitudeIndex);
-
- GMap.NET.PureImage img = MainMap.Manager.ImageCacheLocal.GetImageFromCache(GMap.NET.MapType.GoogleSatellite, new GMap.NET.GPoint(longitudeIndex, damn), level);
-
- Application.DoEvents();
-
- try
- {
- Bitmap bitmap = new Bitmap(new Bitmap(img.Data), 256, 256);
- Graphics e = Graphics.FromImage(bitmap);
- e.DrawString(level + " " +longitudeIndex + "," + damn, new Font("Arial", 20), Brushes.White, new PointF(0, 0));
-
- return Device.CreateTexture2DRectangle(bitmap, TextureFormat.RedGreenBlue8);
- }
- catch {
- try
- {
- return null;
- }
- catch { return null; }
- }
- }
-
- private Uri _baseUri;
- private GeodeticExtent _extent = new GeodeticExtent(-0, -90, 360, 90);
- private int _tilesLoaded;
- private RasterLevel[] _levels;
- private RasterLevelCollection _levelsCollection;
-
- private const int NumberOfLevels = 20;
- private const double LevelZeroDeltaLongitudeDegrees = 180;
- private const double LevelZeroDeltaLatitudeDegrees = 180;
}
}