1 Star 0 Fork 1

张艳军/MissionPlanner

forked from uav360/MissionPlanner 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
temp.cs 53.15 KB
一键复制 编辑 原始数据 按行查看 历史
Michael Oborne 提交于 2020-12-20 18:36 . Exception Handler
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394
using DotSpatial.Data;
using DotSpatial.Projections;
using DotSpatial.Symbology;
using GMap.NET;
using GMap.NET.MapProviders;
using GMap.NET.WindowsForms;
using log4net;
using Microsoft.Scripting.Utils;
using MissionPlanner.ArduPilot;
using MissionPlanner.Comms;
using MissionPlanner.Controls;
using MissionPlanner.GCSViews;
using MissionPlanner.GCSViews.ConfigurationView;
using MissionPlanner.GeoRef;
using MissionPlanner.Log;
using MissionPlanner.Maps;
using MissionPlanner.Swarm;
using MissionPlanner.Utilities;
using MissionPlanner.Warnings;
using resedit;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Drawing;
using System.Drawing.Imaging;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Net;
using System.Net.Sockets;
using System.Reflection;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Xml;
using System.Xml.Serialization;
using MissionPlanner.ArduPilot.Mavlink;
using static MissionPlanner.Utilities.Firmware;
using Formatting = Newtonsoft.Json.Formatting;
using ILog = log4net.ILog;
namespace MissionPlanner
{
public partial class temp : Form
{
private static readonly ILog log =
LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
private static MAVLinkSerialPort comport;
private static TcpListener listener;
private static TcpClient client;
public temp()
{
InitializeComponent();
Tracking.AddPage(
MethodBase.GetCurrentMethod().DeclaringType.ToString(),
MethodBase.GetCurrentMethod().Name);
}
//private static Factory factory;
//private static VideoPlayer player;
//private static Renderer renderer;
//private Media media;
private void temp_Load(object sender, EventArgs e)
{
}
private void BUT_geinjection_Click(object sender, EventArgs e)
{
var MainMap = new GMapControl();
MainMap.MapProvider = GoogleSatelliteMapProvider.Instance;
MainMap.CacheLocation = Settings.GetDataDirectory() +
"gmapcache" + Path.DirectorySeparatorChar;
var fbd = new FolderBrowserDialog();
try
{
fbd.SelectedPath = @"C:\Users\hog\Documents\albany 2011\New folder";
}
catch
{
}
if (fbd.ShowDialog() != DialogResult.OK)
return;
if (fbd.SelectedPath != "")
{
var files = Directory.GetFiles(fbd.SelectedPath, "*.jpg", SearchOption.AllDirectories);
var files1 = Directory.GetFiles(fbd.SelectedPath, "*.png", SearchOption.AllDirectories);
var origlength = files.Length;
Array.Resize(ref files, origlength + files1.Length);
Array.Copy(files1, 0, files, origlength, files1.Length);
foreach (var file in files)
{
log.Info(DateTime.Now.Millisecond + " Doing " + file);
var reg = new Regex(@"Z([0-9]+)\\([0-9]+)\\([0-9]+)");
var mat = reg.Match(file);
if (mat.Success == false)
continue;
var temp = 1 << int.Parse(mat.Groups[1].Value);
var pnt = new GPoint(int.Parse(mat.Groups[3].Value), int.Parse(mat.Groups[2].Value));
BUT_geinjection.Text = file;
BUT_geinjection.Refresh();
//MainMap.Projection.
var tile = new MemoryStream();
var Img = Image.FromFile(file);
Img.Save(tile, ImageFormat.Jpeg);
tile.Seek(0, SeekOrigin.Begin);
log.Info(pnt.X + " " + pnt.Y);
Application.DoEvents();
GMaps.Instance.PrimaryCache.PutImageToCache(tile.GetBuffer(), Custom.Instance.DbId, pnt,
int.Parse(mat.Groups[1].Value));
// Application.DoEvents();
}
}
MainMap.Dispose();
}
private void BUT_clearcustommaps_Click(object sender, EventArgs e)
{
var MainMap = new GMapControl();
MainMap.MapProvider = GoogleSatelliteMapProvider.Instance;
var removed = MainMap.Manager.PrimaryCache.DeleteOlderThan(DateTime.Now, Custom.Instance.DbId);
CustomMessageBox.Show("Removed " + removed + " images");
log.InfoFormat("Removed {0} images", removed);
MainMap.Dispose();
}
private void BUT_lang_edit_Click(object sender, EventArgs e)
{
new Form1().Show();
}
private void BUT_georefimage_Click(object sender, EventArgs e)
{
new Georefimage().Show();
}
private void BUT_follow_me_Click(object sender, EventArgs e)
{
var si = new FollowMe();
ThemeManager.ApplyThemeTo(si);
si.Show();
}
private void BUT_paramgen_Click(object sender, EventArgs e)
{
/*
if(MissionPlanner.Utilities.Update.dobeta)
ParameterMetaDataParser.GetParameterInformation(ConfigurationManager.AppSettings["ParameterLocationsBleeding"]);
else
ParameterMetaDataParser.GetParameterInformation(ConfigurationManager.AppSettings["ParameterLocations"]);
*/
// scan latest, and append older
ParameterMetaDataParser.GetParameterInformation(ConfigurationManager.AppSettings["ParameterLocationsBleeding"] + ";" + ConfigurationManager.AppSettings["ParameterLocations"]);
ParameterMetaDataRepositoryAPM.Reload();
}
private void myButton1_Click(object sender, EventArgs e)
{
new SerialOutputMD().Show();
}
private void but_osdvideo_Click(object sender, EventArgs e)
{
new OSDVideo().Show();
}
private void BUT_swarm_Click(object sender, EventArgs e)
{
new FormationControl().Show();
}
private void BUT_outputMavlink_Click(object sender, EventArgs e)
{
new SerialOutputPass().Show();
}
private void BUT_outputnmea_Click(object sender, EventArgs e)
{
new SerialOutputNMEA().Show();
}
private void BUT_followleader_Click(object sender, EventArgs e)
{
new FollowPathControl().Show();
}
private void BUT_sorttlogs_Click(object sender, EventArgs e)
{
var fbd = new FolderBrowserDialog();
fbd.SelectedPath = Settings.Instance.LogDir;
if (fbd.ShowDialog() == DialogResult.OK)
{
try
{
LogSort.SortLogs(Directory.GetFiles(fbd.SelectedPath, "*.tlog"));
}
catch
{
}
}
}
private void BUT_movingbase_Click(object sender, EventArgs e)
{
var si = new MovingBase();
ThemeManager.ApplyThemeTo(si);
si.Show();
}
private void but_getfw_Click(object sender, EventArgs e)
{
var basedir = Settings.GetDataDirectory() + "History";
Directory.CreateDirectory(basedir);
var fw = new Firmware();
var list = fw.getFWList();
var options = new optionsObject();
options.softwares = list;
var members = typeof(software).GetFields();
XmlWriterSettings settings = new XmlWriterSettings();
settings.IndentChars = " ";
settings.Indent = true;
settings.Encoding = Encoding.ASCII;
using (var xmlwriter = XmlWriter.Create(basedir + Path.DirectorySeparatorChar + @"firmware2.xml", settings))
{
for (int a = 0; a < options.softwares.Count; a++)
{
Loading.ShowLoading(((a - 1) / (float)list.Count) * 100.0 + "% " + options.softwares[a].name, this);
List<Task<bool>> tasklist = new List<Task<bool>>();
foreach (var field in members)
{
if (field.Name.ToLower().Contains("url"))
{
var url = field.GetValue(options.softwares[a]).ToString();
if (String.IsNullOrEmpty(url))
continue;
field.SetValue(options.softwares[a], new Uri(url).LocalPath.TrimStart('/', '\\'));
var task = Download.getFilefromNetAsync(url, basedir + new Uri(url).LocalPath);
tasklist.Add(task);
}
}
//Task.WaitAll(tasklist.ToArray());
}
XmlSerializer xms = new XmlSerializer(typeof(optionsObject), new Type[] { typeof(software) });
xms.Serialize(xmlwriter, options);
}
Loading.Close();
}
private void button3_Click(object sender, EventArgs e)
{
var frm = new WarningsManager();
frm.Show();
}
private void but_mavserialport_Click(object sender, EventArgs e)
{
if (comport != null)
{
comport.Close();
if (client != null && client.Connected)
{
client.Close();
}
if (listener != null)
{
listener.Stop();
}
return;
}
try
{
comport = new MAVLinkSerialPort(MainV2.comPort, MAVLink.SERIAL_CONTROL_DEV.GPS1);
if (listener != null)
{
listener.Stop();
listener = null;
}
listener = new TcpListener(IPAddress.Any, 500);
listener.Start();
listener.BeginAcceptTcpClient(DoAcceptTcpClientCallback, listener);
}
catch (Exception ex)
{
CustomMessageBox.Show(ex.ToString(), Strings.ERROR);
}
}
private void DoAcceptTcpClientCallback(IAsyncResult ar)
{
try
{
// Get the listener that handles the client request.
var listener = (TcpListener)ar.AsyncState;
listener.BeginAcceptTcpClient(DoAcceptTcpClientCallback, listener);
if (client != null && client.Connected)
return;
// End the operation and display the received data on
// the console.
using (
client = listener.EndAcceptTcpClient(ar))
{
var stream = client.GetStream();
if (!comport.IsOpen)
comport.Open();
while (client.Connected && comport.IsOpen)
{
while (stream.DataAvailable)
{
var data = new byte[4096];
try
{
var len = stream.Read(data, 0, data.Length);
comport.Write(data, 0, len);
}
catch
{
}
}
while (comport.BytesToRead > 0)
{
var data = new byte[4096];
try
{
var len = comport.Read(data, 0, data.Length);
stream.Write(data, 0, len);
}
catch
{
}
}
Thread.Sleep(1);
}
}
}
catch
{
}
}
private async void BUT_magfit2_Click(object sender, EventArgs e)
{
await MagCalib.ProcessLog(0).ConfigureAwait(false);
}
private void BUT_shptopoly_Click(object sender, EventArgs e)
{
using (var fd = new OpenFileDialog())
{
fd.Filter = "Shape file|*.shp";
var result = fd.ShowDialog();
var file = fd.FileName;
var pStart = new ProjectionInfo();
var pESRIEnd = KnownCoordinateSystems.Geographic.World.WGS1984;
var reproject = false;
if (File.Exists(file))
{
var prjfile = Path.GetDirectoryName(file) + Path.DirectorySeparatorChar +
Path.GetFileNameWithoutExtension(file) + ".prj";
if (File.Exists(prjfile))
{
using (
var re =
File.OpenText(Path.GetDirectoryName(file) + Path.DirectorySeparatorChar +
Path.GetFileNameWithoutExtension(file) + ".prj"))
{
pStart.ParseEsriString(re.ReadLine());
reproject = true;
}
}
var fs = FeatureSet.Open(file);
fs.FillAttributes();
var rows = fs.NumRows();
var dtOriginal = fs.DataTable;
for (var row = 0; row < dtOriginal.Rows.Count; row++)
{
var original = dtOriginal.Rows[row].ItemArray;
}
foreach (DataColumn col in dtOriginal.Columns)
{
Console.WriteLine(col.ColumnName + " " + col.DataType);
}
var a = 1;
var path = Path.GetDirectoryName(file);
foreach (var feature in fs.Features)
{
var sb = new StringBuilder();
sb.Append("#Shap to Poly - Mission Planner\r\n");
foreach (var point in feature.Coordinates)
{
if (reproject)
{
double[] xyarray = { point.X, point.Y };
double[] zarray = { point.Z };
Reproject.ReprojectPoints(xyarray, zarray, pStart, pESRIEnd, 0, 1);
point.X = xyarray[0];
point.Y = xyarray[1];
point.Z = zarray[0];
}
sb.Append(point.Y.ToString(CultureInfo.InvariantCulture) + "\t" +
point.X.ToString(CultureInfo.InvariantCulture) + "\r\n");
}
log.Info("writting poly to " + path + Path.DirectorySeparatorChar + "poly-" + a + ".poly");
File.WriteAllText(path + Path.DirectorySeparatorChar + "poly-" + a + ".poly", sb.ToString());
a++;
}
}
}
}
private void but_gimbaltest_Click(object sender, EventArgs e)
{
if (MainV2.comPort.BaseStream.IsOpen)
{
GimbalPoint.ProjectPoint(MainV2.comPort);
}
else
CustomMessageBox.Show(Strings.PleaseConnect, Strings.ERROR);
}
private void but_maplogs_Click(object sender, EventArgs e)
{
var fbd = new FolderBrowserDialog();
fbd.SelectedPath = Settings.Instance.LogDir;
if (fbd.ShowDialog() == DialogResult.OK)
{
LogMap.MapLogs(Directory.GetFiles(fbd.SelectedPath, "*.tlog", SearchOption.AllDirectories));
LogMap.MapLogs(Directory.GetFiles(fbd.SelectedPath, "*.bin", SearchOption.AllDirectories));
LogMap.MapLogs(Directory.GetFiles(fbd.SelectedPath, "*.log", SearchOption.AllDirectories));
}
}
private void butlogindex_Click(object sender, EventArgs e)
{
var form = new LogIndex();
form.Show();
}
private void but_structtest_Click(object sender, EventArgs e)
{
var array = new byte[100];
for (var l = 0; l < array.Length; l++)
{
array[l] = (byte)l;
}
var a = 0;
var start = DateTime.MinValue;
var end = DateTime.MinValue;
start = DateTime.Now;
for (a = 0; a < 1000000; a++)
{
var obj = (object)new MAVLink.mavlink_heartbeat_t();
MavlinkUtil.ByteArrayToStructure(array, ref obj, 6);
}
end = DateTime.Now;
Console.WriteLine("ByteArrayToStructure " + (end - start).TotalMilliseconds);
start = DateTime.Now;
for (a = 0; a < 1000000; a++)
{
var ans1 = MavlinkUtil.ByteArrayToStructureT<MAVLink.mavlink_heartbeat_t>(array, 6);
}
end = DateTime.Now;
Console.WriteLine("ByteArrayToStructureT<> " + (end - start).TotalMilliseconds);
start = DateTime.Now;
for (a = 0; a < 1000000; a++)
{
var ans2 = MavlinkUtil.ReadUsingPointer<MAVLink.mavlink_heartbeat_t>(array, 6);
}
end = DateTime.Now;
Console.WriteLine("ReadUsingPointer " + (end - start).TotalMilliseconds);
start = DateTime.Now;
for (a = 0; a < 1000000; a++)
{
var ans3 = MavlinkUtil.ByteArrayToStructureGC<MAVLink.mavlink_heartbeat_t>(array, 6);
}
end = DateTime.Now;
Console.WriteLine("ByteArrayToStructureGC " + (end - start).TotalMilliseconds);
}
private void but_armandtakeoff_Click(object sender, EventArgs e)
{
try
{
MainV2.comPort.setMode("Stabilize");
if (MainV2.comPort.doARM(true))
{
MainV2.comPort.setMode("GUIDED");
Thread.Sleep(300);
MainV2.comPort.doCommand((byte)MainV2.comPort.sysidcurrent, (byte)MainV2.comPort.compidcurrent, MAVLink.MAV_CMD.TAKEOFF, 0, 0, 0, 0, 0, 0, 10);
}
}
catch (Exception ex)
{
CustomMessageBox.Show(ex.ToString());
}
}
private void but_sitl_comb_Click(object sender, EventArgs e)
{
StreamCombiner.Connect += (mav, localsysid) =>
{
MainV2.instance.doConnect(mav, "preset",
localsysid.ToString());
MainV2.Comports.Add(mav);
};
StreamCombiner.Start();
}
private void but_injectgps_Click(object sender, EventArgs e)
{
new ConfigSerialInjectGPS().Show();
}
private void BUT_fft_Click(object sender, EventArgs e)
{
var fft = new fftui();
fft.Show();
}
private void but_reboot_Click(object sender, EventArgs e)
{
if (CustomMessageBox.Show("Are you sure?", "", MessageBoxButtons.YesNo) == (int)DialogResult.Yes)
MainV2.comPort.doReboot(false, true);
}
private void BUT_QNH_Click(object sender, EventArgs e)
{
var paramname = MainV2.comPort.MAV.param.ContainsKey("GND_ABS_PRESS") ? "GND_ABS_PRESS" : "BARO1_GND_PRESS";
var currentQNH = MainV2.comPort.GetParam(paramname).ToString();
if (InputBox.Show("QNH", "Enter the QNH in pascals (103040 = 1030.4 hPa)", ref currentQNH) ==
DialogResult.OK)
{
var newQNH = double.Parse(currentQNH);
MainV2.comPort.setParam((byte) MainV2.comPort.sysidcurrent, (byte) MainV2.comPort.compidcurrent,
paramname, newQNH);
}
}
private void but_trimble_Click(object sender, EventArgs e)
{
new Swarm.Sequence.LayoutEditor().Show();
}
private void myButton_vlc_Click(object sender, EventArgs e)
{
var render = new vlcrender();
var url = render.playurl;
if (InputBox.Show("enter url", "enter url", ref url) == DialogResult.OK)
{
render.playurl = url;
try
{
render.Start();
}
catch (Exception ex)
{
CustomMessageBox.Show(ex.ToString(), Strings.ERROR);
}
}
}
private void but_agemapdata_Click(object sender, EventArgs e)
{
var removed = ((PureImageCache)MyImageCache.Instance).DeleteOlderThan(DateTime.Now.AddDays(-30),
FlightData.instance.gMapControl1.MapProvider.DbId);
CustomMessageBox.Show("Removed " + removed + " images");
log.InfoFormat("Removed {0} images", removed);
}
private void myButton1_Click_2(object sender, EventArgs e)
{
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduCopter-2.8.1/ArduCopter/Parameters.pde"
, "ArduCopter2.8.1.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduCopter-2.9.1/ArduCopter/Parameters.pde"
, "ArduCopter2.9.1.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduCopter-3.0/ArduCopter/Parameters.pde"
, "ArduCopter3.0.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduCopter-3.1.5/ArduCopter/Parameters.pde"
, "ArduCopter3.1.5.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduCopter-3.2.1/ArduCopter/Parameters.pde"
, "ArduCopter3.2.1.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/Copter-3.3.2/ArduCopter/Parameters.cpp"
, "ArduCopter3.3.2.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/Copter-3.3/ArduCopter/Parameters.cpp"
, "ArduCopter3.3.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/Copter-3.4/ArduCopter/Parameters.cpp"
, "ArduCopter3.4.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/Copter-3.4.6/ArduCopter/Parameters.cpp"
, "ArduCopter3.4.6.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/Copter-3.5.0/ArduCopter/Parameters.cpp"
, "ArduCopter3.5.0.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/Copter-3.5.2/ArduCopter/Parameters.cpp"
, "ArduCopter3.5.2.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/Copter-3.5.4/ArduCopter/Parameters.cpp"
, "ArduCopter3.5.4.xml");
// plane
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-3.8.3/ArduPlane/Parameters.cpp"
, "ArduPlane3.8.3.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-3.7.1/ArduPlane/Parameters.cpp"
, "ArduPlane3.7.1.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-3.7.0/ArduPlane/Parameters.cpp"
, "ArduPlane3.7.0.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-3.6.0/ArduPlane/Parameters.cpp"
, "ArduPlane3.6.0.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-3.5.2/ArduPlane/Parameters.cpp"
, "ArduPlane3.5.2.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-3.3.0/ArduPlane/Parameters.pde"
, "ArduPlane3.3.0.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-3.2.2/ArduPlane/Parameters.pde"
, "ArduPlane3.2.2.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-3.1.0/ArduPlane/Parameters.pde"
, "ArduPlane3.1.0.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-3.0.3/ArduPlane/Parameters.pde"
, "ArduPlane3.0.3.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-2.78b/ArduPlane/Parameters.pde"
, "ArduPlane2.78b.xml");
ParameterMetaDataParser.GetParameterInformation(
"https://raw.githubusercontent.com/ArduPilot/ardupilot/ArduPlane-2.75/ArduPlane/Parameters.pde"
, "ArduPlane2.75.xml");
}
private void but_signkey_Click(object sender, EventArgs e)
{
var auth = new AuthKeys();
auth.Show();
}
private void but_optflowcalib_Click(object sender, EventArgs e)
{
var test = new Form();
var imagebox = new PictureBox();
imagebox.Dock = DockStyle.Fill;
imagebox.SizeMode = PictureBoxSizeMode.Zoom;
test.Controls.Add(imagebox);
test.Show();
var flow = new OpticalFlow(MainV2.comPort);
// disable on close form
test.Closed += (o, args) =>
{
flow.CalibrationMode(false);
flow.Close();
};
// enable calibration mode
flow.CalibrationMode(true);
// setup bitmap to screen
flow.newImage += (s, eh) => imagebox.Image = (Image)eh.Image.Clone();
}
private void myButton2_Click(object sender, EventArgs e)
{
var sp = new Sphere();
sp.Dock = DockStyle.Fill;
var frm = new Form();
frm.Controls.Add(sp);
frm.Show();
}
private async void but_gpsinj_Click(object sender, EventArgs e)
{
OpenFileDialog ofd = new OpenFileDialog();
ofd.Filter = "tlog|*.tlog";
ofd.ShowDialog();
SaveFileDialog sfd = new SaveFileDialog();
sfd.FileName = "output.dat";
var result = sfd.ShowDialog();
if (ofd.CheckFileExists && result == DialogResult.OK)
{
using (var st = sfd.OpenFile())
{
using (MAVLinkInterface mine = new MAVLinkInterface(ofd.OpenFile()))
{
mine.logreadmode = true;
while (mine.logplaybackfile.BaseStream.Position < mine.logplaybackfile.BaseStream.Length)
{
MAVLink.MAVLinkMessage packet = await mine.readPacketAsync().ConfigureAwait(true);
if (packet.msgid == (uint)MAVLink.MAVLINK_MSG_ID.GPS_INJECT_DATA)
{
var item = packet.ToStructure<MAVLink.mavlink_gps_inject_data_t>();
st.Write(item.data, 0, item.len);
}
else if (packet.msgid == (uint)MAVLink.MAVLINK_MSG_ID.GPS_RTCM_DATA)
{
var item = packet.ToStructure<MAVLink.mavlink_gps_rtcm_data_t>();
st.Write(item.data, 0, item.len);
}
}
}
}
}
}
private void but_followswarm_Click(object sender, EventArgs e)
{
new Swarm.WaypointLeader.WPControl().Show();
}
private void myButton3_Click(object sender, EventArgs e)
{
but_GDAL_Click(sender, e);
}
protected override void WndProc(ref Message m)
{
switch (m.Msg)
{
case 0x86: // WM_NCACTIVATE
var child = Control.FromHandle(m.LParam);
if (child is Form)
{
ThemeManager.ApplyThemeTo(child);
}
break;
}
base.WndProc(ref m);
}
private void but_GDAL_Click(object sender, EventArgs e)
{
FolderBrowserDialog fbd = new FolderBrowserDialog();
if (Directory.Exists(Settings.Instance["GDALImageDir"]))
fbd.SelectedPath = Settings.Instance["GDALImageDir"];
if (fbd.ShowDialog() == DialogResult.OK)
{
if (Directory.Exists(fbd.SelectedPath))
{
Settings.Instance["GDALImageDir"] = fbd.SelectedPath;
Utilities.GDAL.OnProgress += GDAL_OnProgress;
Utilities.GDAL.ScanDirectory(fbd.SelectedPath);
DTED.OnProgress += GDAL_OnProgress;
DTED.AddCustomDirectory(fbd.SelectedPath);
Loading.Close();
}
}
}
private void GDAL_OnProgress(double percent, string message)
{
Loading.ShowLoading((percent).ToString("0.0%") + " " + message, this);
}
private void but_sortlogs_Click(object sender, EventArgs e)
{
MissionPlanner.Log.LogSort.SortLogs(Directory.GetFiles(Settings.Instance.LogDir, "*.tlog",
SearchOption.AllDirectories), Settings.Instance.LogDir);
MissionPlanner.Log.LogSort.SortLogs(Directory.GetFiles(Settings.Instance.LogDir, "*.bin",
SearchOption.AllDirectories), Settings.Instance.LogDir);
MissionPlanner.Log.LogSort.SortLogs(Directory.GetFiles(Settings.Instance.LogDir, "*.log",
SearchOption.AllDirectories), Settings.Instance.LogDir);
}
private void but_logdlscp_Click(object sender, EventArgs e)
{
LogDownloadscp form = new LogDownloadscp();
form.Show();
}
private void but_td_Click(object sender, EventArgs e)
{
string path = "@SYS/threads.txt";
if (InputBox.Show("path", "path", ref path) == DialogResult.OK)
{
if (MainV2.comPort.BaseStream.IsOpen)
{
var mavftp = new MAVFtp(MainV2.comPort, (byte) MainV2.comPort.sysidcurrent,
(byte) MainV2.comPort.compidcurrent);
var st = mavftp.GetFile(path, new CancellationTokenSource(5000), true);
var output = Path.Combine(Settings.GetUserDataDirectory(), Path.GetFileName(path));
File.WriteAllBytes(output, st.GetBuffer());
}
}
}
private void but_dem_Click(object sender, EventArgs e)
{
UserControl ctl = new UserControl() { Width = 1100, AutoSize = true };
string line = "";
foreach (var item in GeoTiff.index)
{
//log.InfoFormat("Start Point ({0},{1},{2}) --> ({3},{4},{5})", item.i, item.j, item.k, item.x, item.y, item.z);
line += String.Format("{0} = {1} = {2}*{3} {4}\n", item.FileName, item.Area, item.width, item.height, item.bits,
item.xscale, item.yscale, item.zscale);
}
ctl.Controls.Add(new Label() { Text = line, AutoSize = true, Location = new Point(0, 30) });
var butt = new MyButton() { Text = "Open DEM Dir" };
butt.Click += (a, ev) =>
{
System.Diagnostics.Process.Start(@"C:\ProgramData\Mission Planner\srtm\");
};
ctl.Controls.Add(butt);
ctl.ShowUserControl();
}
private void but_gsttest_Click(object sender, EventArgs e)
{
System.Threading.ThreadPool.QueueUserWorkItem((a) =>
{
//GStreamer.test();
});
}
private void but_proximity_Click(object sender, EventArgs e)
{
new ProximityControl(MainV2.comPort.MAV).Show();
}
private void but_dashware_Click(object sender, EventArgs e)
{
OpenFileDialog ofd = new OpenFileDialog();
ofd.Filter = "bin|*.bin;*.BIN";
ofd.ShowDialog();
if (ofd.CheckFileExists)
{
string options = "GPS;ATT;NTUN;CTUN;MODE;BAT";
InputBox.Show("DashWare Types", "Enter Messages you want eg PARM;NTUN;CTUN", ref options);
var split = options.Split(new[] { ';' }, StringSplitOptions.RemoveEmptyEntries);
DashWare.Create(ofd.FileName, ofd.FileName + ".csv", split.Length > 0 ? split.ToList() : null);
}
}
private void but_mavinspector_Click(object sender, EventArgs e)
{
new MAVLinkInspector(MainV2.comPort).Show();
}
private void BUT_driverclean_Click(object sender, EventArgs e)
{
CleanDrivers.Clean();
}
private void but_blupdate_Click(object sender, EventArgs e)
{
if (CustomMessageBox.Show("Are you sure you want to upgrade the bootloader? This can brick your board",
"BL Update", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == (int) DialogResult.Yes)
if (CustomMessageBox.Show(
"Are you sure you want to upgrade the bootloader? This can brick your board, Please allow 5 mins for this process",
"BL Update", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == (int) DialogResult.Yes)
try
{
if (MainV2.comPort.doCommand((byte) MainV2.comPort.sysidcurrent,
(byte) MainV2.comPort.compidcurrent, MAVLink.MAV_CMD.FLASH_BOOTLOADER, 0, 0, 0, 0, 290876,
0, 0))
{
CustomMessageBox.Show("Upgraded bootloader");
}
else
{
CustomMessageBox.Show("Failed to upgrade bootloader");
}
}
catch (Exception ex)
{
CustomMessageBox.Show(ex.ToString(), Strings.ERROR);
}
}
private void but_3dmap_Click(object sender, EventArgs e)
{
var ogl = new OpenGLtest2();
var frm = ogl.ShowUserControl();
}
private void but_anonlog_Click(object sender, EventArgs e)
{
CustomMessageBox.Show("This is beta, please confirm the output file");
using (OpenFileDialog ofd = new OpenFileDialog())
{
ofd.Filter = "tlog or bin/log|*.tlog;*.bin;*.log";
if (ofd.ShowDialog() == DialogResult.OK)
{
var ext = Path.GetExtension(ofd.FileName).ToLower();
if (ext == ".bin")
ext = ".log";
using (SaveFileDialog sfd = new SaveFileDialog())
{
sfd.DefaultExt = ext;
sfd.FileName = Path.GetFileNameWithoutExtension(ofd.FileName) + "-anon" + ext;
if (sfd.ShowDialog() == DialogResult.OK)
{
Privacy.anonymise(ofd.FileName, sfd.FileName);
}
}
}
}
}
private void but_messageinterval_Click(object sender, EventArgs e)
{
var form = new Form();
FlowLayoutPanel flp = new FlowLayoutPanel();
flp.Dock = DockStyle.Fill;
flp.AutoSize = true;
ComboBox cmb = new ComboBox();
cmb.DataSource = Enum.GetNames(typeof(MAVLink.MAVLINK_MSG_ID)).ToSortedList((s, s1) => s.CompareTo(s1));
cmb.Width += 50;
Button but = new Button();
but.Text = "Set";
ComboBox cmbrate = new ComboBox();
cmbrate.DataSource = Enumerable.Range(1, 200).ToList();
but.Click += (o, args) =>
{
var rate = int.Parse(cmbrate.Text.ToString());
var value = Enum.Parse(typeof(MAVLink.MAVLINK_MSG_ID), cmb.Text.ToString());
try
{
MainV2.comPort.doCommand((byte) MainV2.comPort.sysidcurrent, (byte) MainV2.comPort.compidcurrent,
MAVLink.MAV_CMD.SET_MESSAGE_INTERVAL, (float) (int) value,
1 / (float) rate * 1000000.0f, 0, 0, 0, 0, 0);
}
catch (Exception ex)
{
CustomMessageBox.Show(ex.ToString(), Strings.ERROR);
}
};
Button but2 = new Button();
but2.Text = "Set All";
but2.Click += (o, args) =>
{
var rate = int.Parse(cmbrate.Text.ToString());
((IList)cmb.DataSource).ForEach(a =>
{
var value = Enum.Parse(typeof(MAVLink.MAVLINK_MSG_ID), a.ToString());
try
{
MainV2.comPort.doCommand((byte) MainV2.comPort.sysidcurrent, (byte) MainV2.comPort.compidcurrent,
MAVLink.MAV_CMD.SET_MESSAGE_INTERVAL, (float) (int) value,
1 / (float) rate * 1000000.0f, 0, 0, 0, 0, 0, false);
}
catch (Exception ex)
{
CustomMessageBox.Show(ex.ToString(), Strings.ERROR);
}
});
};
//cmb.SelectedIndexChanged += (o, args) => { MAVLink.MAVLINK_MSG_ID.GET_MESSAGE_INTERVAL };
form.Controls.Add(flp);
flp.Controls.Add(cmb);
flp.Controls.Add(cmbrate);
flp.Controls.Add(but);
flp.Controls.Add(but2);
form.Show(this);
}
private void BUT_xplane_Click(object sender, EventArgs e)
{
}
private void but_disablearmswitch_Click(object sender, EventArgs e)
{
if (CustomMessageBox.Show("Are you sure?", "", MessageBoxButtons.YesNo) == (int)DialogResult.Yes)
MainV2.comPort.setMode(
new MAVLink.mavlink_set_mode_t() { custom_mode = (MainV2.comPort.MAV.cs.sensors_enabled.motor_control == true && MainV2.comPort.MAV.cs.sensors_enabled.seen) ? 1u : 0u },
MAVLink.MAV_MODE_FLAG.SAFETY_ARMED);
}
private void but_hwids_Click(object sender, EventArgs e)
{
string value = "0";
if (InputBox.Show("hwid", "Enter the ID number", ref value, false, true) == DialogResult.OK)
{
StringBuilder sb = new StringBuilder();
var items = value.Split(new char[] { '\r', '\n' }, StringSplitOptions.RemoveEmptyEntries);
foreach (var item in items)
{
var items2 = item.Split(new char[] { ' ', '\t' });
foreach (var item2 in items2)
{
uint uintvalue = 0;
if (uint.TryParse(item2, out uintvalue))
{
Device.DeviceStructure test1 = new Device.DeviceStructure(uintvalue);
sb.AppendLine(item.Replace('\t', ' ') + " = " + test1.ToString());
}
}
}
CustomMessageBox.Show(sb.ToString());
}
}
private void but_packetbytes_Click(object sender, EventArgs e)
{
string input = "";
InputBox.Show("input", "enter the hex byte data", ref input, false, true);
var split = input.Replace("0x", ",").Split(new char[] { ',', ' ' }, StringSplitOptions.RemoveEmptyEntries);
var buffer = split.Select(a => Convert.ToByte(a, 16));
MAVLink.MavlinkParse parse = new MAVLink.MavlinkParse();
var packet = parse.ReadPacket(new MemoryStream(buffer.ToArray()));
CustomMessageBox.Show(packet?.ToString() +
"\n" + packet.ToJSON().WrapText(5, new[] { ',' }));
}
private void but_acbarohight_Click(object sender, EventArgs e)
{
var paramname = MainV2.comPort.MAV.param.ContainsKey("GND_ABS_PRESS") ? "GND_ABS_PRESS" : "BARO1_GND_PRESS";
var currentQNH = MainV2.comPort.GetParam(paramname).ToString();
//338.6388 pa => 100' = 30.48m
CustomMessageBox.Show("use at your own risk!!!");
NumericUpDown mavlinkNumericUpDown = new NumericUpDown();
mavlinkNumericUpDown.Minimum = -100;
mavlinkNumericUpDown.Maximum = 100;
mavlinkNumericUpDown.Padding = new Padding(20);
mavlinkNumericUpDown.ValueChanged += (o, args) =>
{
MainV2.comPort.setParam((byte)MainV2.comPort.sysidcurrent, (byte)MainV2.comPort.compidcurrent, paramname, (float)(double.Parse(currentQNH) + (double)mavlinkNumericUpDown.Value * 11.1));
};
mavlinkNumericUpDown.ShowUserControl();
}
private async void But_stayoutest_Click(object sender, EventArgs e)
{
var list = new List<Locationwp>();
var tl = (MainV2.comPort.MAV.cs.Location.gps_offset(-20, -25));
var tr = (MainV2.comPort.MAV.cs.Location.gps_offset(50, -25));
var br = (MainV2.comPort.MAV.cs.Location.gps_offset(50, 15));
var bl = (MainV2.comPort.MAV.cs.Location.gps_offset(-20, 15));
var cmd = MAVLink.MAV_CMD.FENCE_POLYGON_VERTEX_INCLUSION;
//MAVLink.mavlink_mission_request_int_t req = new MAVLink.mavlink_mission_request_int_t();
var frame = (byte)MAVLink.MAV_FRAME.GLOBAL_INT;
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = tl.Lat, lng = tl.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = tr.Lat, lng = tr.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = br.Lat, lng = br.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = bl.Lat, lng = bl.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = tl.Lat, lng = tl.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = tr.Lat, lng = tr.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = br.Lat, lng = br.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = bl.Lat, lng = bl.Lng });
tl = (MainV2.comPort.MAV.cs.Location.gps_offset(-40, -45));
tr = (MainV2.comPort.MAV.cs.Location.gps_offset(20, -45));
br = (MainV2.comPort.MAV.cs.Location.gps_offset(20, 20));
bl = (MainV2.comPort.MAV.cs.Location.gps_offset(-40, 20));
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = tl.Lat, lng = tl.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = tr.Lat, lng = tr.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = br.Lat, lng = br.Lng });
list.Add(new Locationwp() { alt = 0, frame = frame, id = (ushort)cmd, p1 = 4, lat = bl.Lat, lng = bl.Lng });
//mav_mission.upload(MainV2.comPort, MAVLink.MAV_MISSION_TYPE.FENCE, list);
var mission = await mav_mission.download(MainV2.comPort, MainV2.comPort.MAV.sysid, MainV2.comPort.MAV.compid, MAVLink.MAV_MISSION_TYPE.MISSION).ConfigureAwait(true);
var fence = await mav_mission.download(MainV2.comPort, MainV2.comPort.MAV.sysid, MainV2.comPort.MAV.compid, MAVLink.MAV_MISSION_TYPE.FENCE).ConfigureAwait(true);
var rally = await mav_mission.download(MainV2.comPort, MainV2.comPort.MAV.sysid, MainV2.comPort.MAV.compid, MAVLink.MAV_MISSION_TYPE.RALLY).ConfigureAwait(true);
}
private void but_lockup_Click(object sender, EventArgs e)
{
if (CustomMessageBox.Show("Lockup the autopilot??? this can cause a CRASH!!!!!!",
"Lockup", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == (int)DialogResult.Yes)
if (CustomMessageBox.Show("Lockup the autopilot??? this can cause a CRASH!!!!!!",
"Lockup", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == (int)DialogResult.Yes)
MainV2.comPort.doCommand(MainV2.comPort.MAV.sysid, MainV2.comPort.MAV.compid,
MAVLink.MAV_CMD.PREFLIGHT_REBOOT_SHUTDOWN,
42, 24, 71, 93, 0, 0, 0, false);
}
private void but_hexmavlink_Click(object sender, EventArgs e)
{
string input = "";
InputBox.Show("", "enter the hex value 'fd0500001a0c1'", ref input);
var packet = StringToByteArray(input);
var mavpacket = new MAVLink.MavlinkParse().ReadPacket(new MemoryStream(packet));
CustomMessageBox.Show(mavpacket.ToJSON(Formatting.Indented));
}
public static byte[] StringToByteArray(string hex)
{
return Enumerable.Range(0, hex.Length)
.Where(x => x % 2 == 0)
.Select(x => Convert.ToByte(hex.Substring(x, 2), 16))
.ToArray();
}
private void but_remotedflogger_Click(object sender, EventArgs e)
{
RemoteLog.StartRemoteLog(MainV2.comPort, (byte) MainV2.comPort.sysidcurrent,
(byte) MainV2.comPort.compidcurrent);
}
private void but_paramrestore_Click(object sender, EventArgs e)
{
CustomMessageBox.Show("This process make take a some time");
using (var ofd = new OpenFileDialog
{
AddExtension = true,
DefaultExt = ".param",
RestoreDirectory = true,
Filter = ParamFile.FileMask
})
{
var dr = ofd.ShowDialog();
if (dr == DialogResult.OK)
{
var param2 = ParamFile.loadParamFile(ofd.FileName);
ProgressReporterDialogue prd = new ProgressReporterDialogue();
prd.DoWork += dialogue =>
{
List<string> fails = new List<string>();
var set = 0;
var alreadyset = 0;
dialogue.UpdateProgressAndStatus(-1, "Get All by Name");
// prefeed
foreach (var d in param2)
{
MainV2.comPort.GetParam(MainV2.comPort.MAV.sysid, MainV2.comPort.MAV.compid, d.Key,
requireresponce: false);
}
dialogue.UpdateProgressAndStatus(-1, "Set Enable's");
// enables
foreach (var d in param2.Where(a=>a.Key.ToLower().Contains("enable")))
{
try
{
MainV2.comPort.setParam(MainV2.comPort.MAV.sysid, MainV2.comPort.MAV.compid, d.Key,
d.Value);
}
catch
{
}
}
foreach (var d in param2)
{
dialogue.UpdateProgressAndStatus(-1, "Set " + d.Key);
if (dialogue.doWorkArgs.CancelRequested)
{
dialogue.doWorkArgs.CancelAcknowledged = true;
return;
}
try
{
if (MainV2.comPort.MAV.param.ContainsKey(d.Key) &&
MainV2.comPort.MAV.param[d.Key].Value == d.Value)
{
alreadyset++;
continue;
}
MainV2.comPort.GetParam(MainV2.comPort.MAV.sysid, MainV2.comPort.MAV.compid, d.Key);
if (d.Key.ToLower().Contains("_id"))
MainV2.comPort.setParam(MainV2.comPort.MAV.sysid, MainV2.comPort.MAV.compid, d.Key,
0,
true);
MainV2.comPort.setParam(MainV2.comPort.MAV.sysid, MainV2.comPort.MAV.compid, d.Key,
d.Value,
true);
set++;
}
catch
{
fails.Add(d.Key);
}
}
if (fails.Count > 0)
CustomMessageBox.Show("Set " + set + " params \nAlready Set "
+ alreadyset + " params \nFailed to set "
+ fails.Aggregate((a, b) => a + "\n" + b));
else
CustomMessageBox.Show("Set " + set + " params \nAlready Set "
+ alreadyset + " params");
};
prd.RunBackgroundOperationAsync();
}
}
}
private void BUT_CoT_Click(object sender, EventArgs e)
{
new SerialOutputCoT().Show();
}
}
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/fremwork/MissionPlanner.git
git@gitee.com:fremwork/MissionPlanner.git
fremwork
MissionPlanner
MissionPlanner
master

搜索帮助

23e8dbc6 1850385 7e0993f3 1850385