diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..a82bb78
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1 @@
+/Matrix App/bin/
diff --git a/Arduino/LED_Matrix/Matrix Raspberry Pi Pico.py b/Arduino/LED_Matrix/Matrix Raspberry Pi Pico.py
new file mode 100644
index 0000000..2cf5b9b
--- /dev/null
+++ b/Arduino/LED_Matrix/Matrix Raspberry Pi Pico.py
@@ -0,0 +1,169 @@
+from time import sleep
+
+from machine import UART, Pin
+
+import array, time
+from machine import Pin
+import rp2
+
+# Configure the number of WS2812 LEDs.
+NUM_LEDS = 256
+PIN_NUM = 16
+brightness = 0.2
+
+@rp2.asm_pio(sideset_init=rp2.PIO.OUT_LOW, out_shiftdir=rp2.PIO.SHIFT_LEFT, autopull=True, pull_thresh=24)
+def ws2812():
+ T1 = 2
+ T2 = 5
+ T3 = 3
+ wrap_target()
+ label("bitloop")
+ out(x, 1) .side(0) [T3 - 1]
+ jmp(not_x, "do_zero") .side(1) [T1 - 1]
+ jmp("bitloop") .side(1) [T2 - 1]
+ label("do_zero")
+ nop() .side(0) [T2 - 1]
+ wrap()
+
+# Create the StateMachine with the ws2812 program, outputting on pin
+sm = rp2.StateMachine(0, ws2812, freq=8_000_000, sideset_base=Pin(PIN_NUM))
+
+# Start the StateMachine, it will wait for data on its FIFO.
+sm.active(1)
+
+# Display a pattern on the LEDs via an array of LED RGB values.
+global ar
+global leds
+global gif
+global currentFrame
+global delay
+
+##########################################################################
+
+def show():
+ for i in range(leds):
+ r = ar[i] >> 16
+ g = ar[i] >> 8 & 0xFF
+ b = ar[i] & 0xFF
+
+ r = r >> 1
+ g = g >> 1
+ b = b >> 1
+
+ ar[i] = r << 16 | g << 8 | b
+
+ sm.put(ar, 8)
+
+leds = 256 # number of leds
+uart = UART(0, 9600) # serial bluetooth
+led = Pin(25, Pin.OUT) # builtin LED
+ar = array.array("I", [0 for _ in range(NUM_LEDS)]) # color array
+gif = [array.array("I", [0 for _ in range(leds)]) for _ in range(1)]
+currentFrame = -1
+
+# gurantees that only N-bytes are read from the UART
+def readNBytes(n):
+ rawBytes = b''
+ bytesRead = 0
+ while True:
+ if uart.any():
+ rawBytes += uart.read(n - bytesRead)
+
+ bytesRead = len(rawBytes)
+
+ # not enough was read
+ if bytesRead < n:
+ continue
+ else:
+ return rawBytes
+
+while True:
+ led.low()
+ if uart.any() != 0:
+ opcode = uart.read(1)
+
+ print("Opcode: ", opcode)
+
+ if opcode == b'\x00':
+ width = readNBytes(1)[0]
+ height = readNBytes(1)[0]
+
+ if width <= 32 and height <= 32:
+ leds = width * height
+
+ ar = array.array("I", [0 for _ in range(leds)])
+ show()
+
+ elif opcode == b'\x02':
+ rawBytes = readNBytes(leds * 3);
+
+ for i in range(leds):
+ ar[i] = rawBytes[i * 3 + 1] << 16 | rawBytes[i * 3] << 8 | rawBytes[i * 3 + 2]
+
+ show()
+
+ currentFrame = -1
+
+ elif opcode == b'\x03':
+ r = readNBytes(1)
+ g = readNBytes(1)
+ b = readNBytes(1)
+
+ for i in range(leds):
+ ar[i] = g[0] << 16 | r[0] << 8 | b[0]
+
+ show()
+
+ elif opcode == b'\x04':
+
+ uart.write([75])
+
+ # [width] [height] [frames] [delay] [rgb-frames]
+ elif opcode == b'\x05':
+ gifDim = readNBytes(5)
+
+ delay = (gifDim[3] << 8) | gifDim[4]
+
+ print("w ", gifDim[0], " h ", gifDim[1], " f ", gifDim[2], " d ", delay)
+
+ leds = gifDim[0] * gifDim[1]
+ gif = [array.array("I", [0 for _ in range(leds)]) for _ in range(gifDim[2])]
+
+ for f in range(gifDim[2]):
+ frame = readNBytes(leds * 3)
+ print("frame read: ", f)
+ for i in range(leds):
+ gif[f][i] = frame[i * 3 + 1] << 16 | frame[i * 3] << 8 | frame[i * 3 + 2]
+ #uart.write(bytearray([91])) # synchronize
+
+ currentFrame = 0
+
+ print("Everything read")
+
+ # [Synchro-byte] [feature-flags] [Controller-Id]
+ #
+ # feature-flags:
+ # [Bit 7] = Bluetooth (true)
+ # [Bit 6] = USB (false)
+ # [Bit 0] = Upload (true)
+ #
+ elif opcode == b'\x06':
+ uart.write(b'\x5B\x81')
+ uart.write("RP2040 Micro python")
+
+ led.high()
+ uart.write(bytearray([75]))
+
+ elif currentFrame != -1:
+ print("showing")
+ for i in range(leds):
+ ar[i] = gif[currentFrame][i]
+
+ show()
+ currentFrame += 1
+
+ if (currentFrame >= len(gif)):
+ currentFrame = 0
+
+ time.sleep(delay * 1e-3)
+
diff --git a/Matrix App.sln.DotSettings.user b/Matrix App.sln.DotSettings.user
index 0094e3a..6a51cf7 100644
--- a/Matrix App.sln.DotSettings.user
+++ b/Matrix App.sln.DotSettings.user
@@ -1,8 +1,12 @@
False
False
- False
+ True
+
+ True
False
False
- True
- True
\ No newline at end of file
+ False
+ True
+ False
+ False
\ No newline at end of file
diff --git a/Matrix App/Defaults.cs b/Matrix App/Defaults.cs
index 5c19a2f..5ea6e2e 100644
--- a/Matrix App/Defaults.cs
+++ b/Matrix App/Defaults.cs
@@ -3,8 +3,6 @@ namespace Matrix_App
{
public static class Defaults
{
- public const int PortNameUpdateInterval = 5000;
-
public const int MatrixStartWidth = 16;
public const int MatrixStartHeight = 16;
public const int MatrixStartFrames = 1;
@@ -12,16 +10,11 @@ namespace Matrix_App
public const int MatrixLimitedWidth = 512;
public const int MatrixLimitedHeight = 512;
- public const int BaudRate = 48000;
-
- public const int ReadTimeoutMs = 5500;
- public const int WriteTimeoutMs = 5500;
-
- ///
- /// Total count of LEDs at start
- ///
- public static readonly int MATRIX_START_LED_COUNT = MatrixStartWidth * MatrixStartHeight * Bpp;
+ public const int BaudRate = 9600;
+ public const int ReadTimeoutMs = 20500;
+ public const int WriteTimeoutMs = 2500;
+
///
/// Number of Bytes Per Pixel: 3 cause Red (1 byte) + Blue (1 Byte) + Green (1 byte) = 3
///
@@ -30,7 +23,9 @@ namespace Matrix_App
public const int FilterPreviewWidth = 32;
public const int FilterPreviewHeight = 32;
+ public const int ArduinoSynchronizationByte = 91;
public const int ArduinoSuccessByte = 75;
+ public const int ArduinoErrorByte = 255;
public const int ArduinoCommandQueueSize = 2;
public const int ArduinoReceiveBufferSize = 1 + 1 + 1 + MatrixLimitedWidth * MatrixLimitedHeight;
@@ -43,6 +38,9 @@ namespace Matrix_App
public const byte OpcodeScale = 0;
public const byte OpcodeImage = 2;
public const byte OpcodeFill = 3;
- public static readonly byte OPCODE_CONFIG = 4;
+ public const byte OpcodePush = 5;
+
+ public const byte OpcodeInfo = 6;
+// public static readonly byte OpcodeConfig = 4;
}
}
\ No newline at end of file
diff --git a/Matrix App/Matrix App.csproj b/Matrix App/Matrix App.csproj
index 40e28fa..514f78d 100644
--- a/Matrix App/Matrix App.csproj
+++ b/Matrix App/Matrix App.csproj
@@ -8,6 +8,7 @@
MatrixIcon.ico
true
enable
+ latest
@@ -17,6 +18,8 @@
+
+
@@ -40,6 +43,9 @@
Form
+
+ Form
+
diff --git a/Matrix App/PregeneratedMods/MatrixGifGenerator.cs b/Matrix App/PregeneratedMods/MatrixGifGenerator.cs
index 5ecfc79..82fd6d5 100644
--- a/Matrix App/PregeneratedMods/MatrixGifGenerator.cs
+++ b/Matrix App/PregeneratedMods/MatrixGifGenerator.cs
@@ -1,6 +1,5 @@
using Matrix_App.PregeneratedMods;
using System;
-using System.Diagnostics;
using System.Drawing;
using System.Reflection;
using System.Threading;
diff --git a/Matrix App/adds/DirectBitmap.cs b/Matrix App/adds/DirectBitmap.cs
index 0069b62..f1e7f83 100644
--- a/Matrix App/adds/DirectBitmap.cs
+++ b/Matrix App/adds/DirectBitmap.cs
@@ -31,7 +31,7 @@ namespace Matrix_App
int index = x + (y * Width);
int col = colour.ToArgb();
- Bits[index] = col;
+ Bits[index] = col & 0x00FFFFFF;
}
public void SetImage(Bitmap image)
diff --git a/Matrix App/adds/PortCommandQueue.cs b/Matrix App/adds/PortCommandQueue.cs
index 1dd929d..d4fed9c 100644
--- a/Matrix App/adds/PortCommandQueue.cs
+++ b/Matrix App/adds/PortCommandQueue.cs
@@ -1,26 +1,23 @@
using System;
-using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Diagnostics;
-using System.IO;
using System.IO.Ports;
using System.Security.Permissions;
-using System.Text;
using System.Threading;
-
using static Matrix_App.Defaults;
-namespace Matrix_App
+namespace Matrix_App.adds
{
public class PortCommandQueue
{
private const string ThreadDeliverName = "Arduino Port Deliver Thread";
- private Queue byteWriteQueue = new Queue();
+ private readonly Queue byteWriteQueue = new();
+ private readonly Queue statusByteQueue = new();
- private Thread portDeliverThread;
+ private readonly Thread portDeliverThread;
- private SerialPort port;
+ private readonly SerialPort tx;
private bool running;
@@ -28,12 +25,15 @@ namespace Matrix_App
private volatile bool isPortValid;
- private readonly byte[] recived = new byte[ArduinoReceiveBufferSize];
+ private readonly byte[] received = new byte[ArduinoReceiveBufferSize];
private int mark;
-
- public PortCommandQueue(ref SerialPort port)
+
+ private volatile bool synchronized;
+ private bool updateRealtime;
+
+ public PortCommandQueue(ref SerialPort tx)
{
- this.port = port;
+ this.tx = tx;
portDeliverThread = new Thread(ManageQueue) { Name = ThreadDeliverName };
}
@@ -44,38 +44,66 @@ namespace Matrix_App
{
while (!kill)
{
- if (byteWriteQueue.Count <= 0) continue;
-
+ if (!isPortValid) continue;
+ if (byteWriteQueue.Count <= 0)
+ {
+ lock (byteWriteQueue)
+ {
+ Monitor.Wait(byteWriteQueue);
+ }
+ continue;
+ }
+
byte[] bytes;
+ int statusByte;
lock (byteWriteQueue)
{
bytes = byteWriteQueue.Dequeue();
+ statusByte = statusByteQueue.Dequeue();
}
- lock (port)
+ lock (tx)
{
- if (!isPortValid) continue;
+ var success = false;
+ var tryCounter = 0;
- port.Open();
- port.Write(bytes, 0, bytes.Length);
-
- int b;
- mark = 0;
- while((b = port.ReadByte()) != ArduinoSuccessByte)
+ do
{
- recived[mark++] = (byte) b;
- }
+ try
+ {
+ tx.Write(bytes, 0, bytes.Length);
- port.Close();
+ var b = ArduinoErrorByte;
+ var errorFlag = false;
+ mark = 0;
+ while (!errorFlag && (b = tx.ReadByte()) != statusByte)
+ {
+ received[mark++] = (byte) b;
+
+ errorFlag = b == ArduinoErrorByte;
+ }
+ synchronized = b == ArduinoSynchronizationByte;
+ success = !errorFlag;
+ Debug.WriteLine("===================> Com Success !");
+ }
+ catch (Exception e)
+ {
+ Debug.WriteLine("=============================> ERROR <=================================");
+ Debug.WriteLine(e.Message);
+ }
+
+ tryCounter++;
+ } while (!success && tryCounter < 3);
}
}
- } catch (ThreadInterruptedException)
+ }
+ catch (ThreadInterruptedException)
{
Thread.CurrentThread.Interrupt();
- }
+ }
}
- [SecurityPermissionAttribute(SecurityAction.Demand, ControlThread = true)]
+ [SecurityPermission(SecurityAction.Demand, ControlThread = true)]
public void Close()
{
try
@@ -93,24 +121,34 @@ namespace Matrix_App
{
// omit
}
+ finally
+ {
+ if (tx.IsOpen)
+ {
+ tx.Close();
+ }
+ }
}
- public void EnqueueArduinoCommand(params byte[] bytes)
+ private void EnqueueArduinoCommand(params byte[] bytes)
{
+ if (!updateRealtime && bytes[0] != ArduinoInstruction.OpcodeScale &&
+ bytes[0] != ArduinoInstruction.OpcodePush)
+ return;
+
if (!running)
{
running = true;
portDeliverThread.Start();
}
-
+
lock (byteWriteQueue)
{
- if (byteWriteQueue.Count < ArduinoCommandQueueSize)
+ Monitor.Pulse(byteWriteQueue);
+ if (byteWriteQueue.Count >= ArduinoCommandQueueSize) return;
+ lock (byteWriteQueue)
{
- lock (byteWriteQueue)
- {
- byteWriteQueue.Enqueue(bytes);
- }
+ byteWriteQueue.Enqueue(bytes);
}
}
}
@@ -121,6 +159,7 @@ namespace Matrix_App
Buffer.BlockCopy(data, 0, wrapper, 1, data.Length);
wrapper[0] = opcode;
+ statusByteQueue.Enqueue(ArduinoSuccessByte);
EnqueueArduinoCommand(wrapper);
}
@@ -132,11 +171,11 @@ namespace Matrix_App
}
}
- internal void WaitForLastDequeue()
+ public static void WaitForLastDequeue()
{
- int timeCount = 0;
+ var timeCount = 0;
+ var wait = true;
- bool wait = true;
while(wait)
{
timeCount++;
@@ -148,24 +187,66 @@ namespace Matrix_App
public byte[] GetLastData()
{
- return recived;
+ return received;
}
public void ValidatePort()
{
- isPortValid = true;
+ try
+ {
+ if (!tx.IsOpen)
+ {
+ tx.Open();
+ isPortValid = true;
+ }
+ }
+ catch (Exception e)
+ {
+ isPortValid = false;
+
+ Debug.WriteLine("Failed opening port: " + e.Message);
+ }
}
public void InvalidatePort()
{
isPortValid = false;
+ tx.Close();
}
+ ///
+ /// Returns last location of written byte in the received buffer.
+ /// Call clears the mark. Any other call will return 0, unless the mark has been
+ /// altered by reading new data from the serial port.
+ ///
+ ///
public int GetMark()
{
- int tmp = mark;
+ var tmp = mark;
mark = 0;
return tmp;
}
+
+ public void EnqueueArduinoCommandSynchronized(byte[] bytes)
+ {
+ statusByteQueue.Enqueue(ArduinoSynchronizationByte);
+ EnqueueArduinoCommand(bytes);
+
+ while (!synchronized)
+ {
+ }
+ Debug.WriteLine("======================> Synchronized!");
+ synchronized = false;
+ }
+
+ public void SetRealtimeUpdates(bool @checked)
+ {
+ updateRealtime = @checked;
+ }
+
+ public bool GetRealtimeUpdates()
+ {
+ return updateRealtime;
+ }
}
}
diff --git a/Matrix App/adds/ThreadQueue.cs b/Matrix App/adds/ThreadQueue.cs
index 26f71ef..bf06397 100644
--- a/Matrix App/adds/ThreadQueue.cs
+++ b/Matrix App/adds/ThreadQueue.cs
@@ -16,8 +16,6 @@ namespace Matrix_App
private volatile bool working;
private readonly int capacity;
-
- private static readonly AutoResetEvent ResetEvent = new AutoResetEvent(false);
public ThreadQueue(string name, int capacity)
{
@@ -66,14 +64,9 @@ namespace Matrix_App
}
else
{
- try
+ lock (taskQueue)
{
- ResetEvent.WaitOne(100);
- }
- catch (ThreadInterruptedException)
- {
- Thread.CurrentThread.Interrupt();
- return;
+ Monitor.Wait(taskQueue);
}
}
}
@@ -85,10 +78,11 @@ namespace Matrix_App
{
if (taskQueue.Count >= capacity)
return;
+
+ Monitor.Pulse(taskQueue);
working = true;
taskQueue.Enqueue(task);
- ResetEvent.Set();
}
}
@@ -99,8 +93,12 @@ namespace Matrix_App
public void Stop()
{
+ lock (taskQueue)
+ {
+ Monitor.Pulse(taskQueue);
+ }
+
running = false;
- ResetEvent.Set();
thread.Interrupt();
thread.Join(100);
diff --git a/Matrix App/bin/Debug/netcoreapp3.1/Bluetooth.dll b/Matrix App/bin/Debug/netcoreapp3.1/Bluetooth.dll
new file mode 100644
index 0000000..8b90ab2
Binary files /dev/null and b/Matrix App/bin/Debug/netcoreapp3.1/Bluetooth.dll differ
diff --git a/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.deps.json b/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.deps.json
index 8eccd65..3eb2dab 100644
--- a/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.deps.json
+++ b/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.deps.json
@@ -8,6 +8,8 @@
".NETCoreApp,Version=v3.1": {
"Matrix App/1.0.0": {
"dependencies": {
+ "Bluetooth": "1.0.0.2",
+ "System.Drawing.Common": "5.0.2",
"System.IO.Ports": "6.0.0-preview.5.21301.5",
"System.Management": "5.0.0"
},
@@ -15,7 +17,21 @@
"Matrix App.dll": {}
}
},
+ "Bluetooth/1.0.0.2": {
+ "dependencies": {
+ "Microsoft.Windows.SDK.Contracts": "10.0.19041.1",
+ "System.Runtime.InteropServices.WindowsRuntime": "4.3.0",
+ "System.Runtime.WindowsRuntime": "4.7.0"
+ },
+ "runtime": {
+ "lib/netstandard2.0/Bluetooth.dll": {
+ "assemblyVersion": "1.0.0.2",
+ "fileVersion": "1.0.0.2"
+ }
+ }
+ },
"Microsoft.NETCore.Platforms/5.0.0": {},
+ "Microsoft.NETCore.Targets/1.1.0": {},
"Microsoft.Win32.Registry/6.0.0-preview.5.21301.5": {
"dependencies": {
"System.Security.AccessControl": "6.0.0-preview.5.21301.5",
@@ -36,6 +52,31 @@
}
}
},
+ "Microsoft.Win32.SystemEvents/5.0.0": {
+ "dependencies": {
+ "Microsoft.NETCore.Platforms": "5.0.0"
+ },
+ "runtime": {
+ "lib/netstandard2.0/Microsoft.Win32.SystemEvents.dll": {
+ "assemblyVersion": "5.0.0.0",
+ "fileVersion": "5.0.20.51904"
+ }
+ },
+ "runtimeTargets": {
+ "runtimes/win/lib/netcoreapp3.0/Microsoft.Win32.SystemEvents.dll": {
+ "rid": "win",
+ "assetType": "runtime",
+ "assemblyVersion": "5.0.0.0",
+ "fileVersion": "5.0.20.51904"
+ }
+ }
+ },
+ "Microsoft.Windows.SDK.Contracts/10.0.19041.1": {
+ "dependencies": {
+ "System.Runtime.WindowsRuntime": "4.7.0",
+ "System.Runtime.WindowsRuntime.UI.Xaml": "4.6.0"
+ }
+ },
"runtime.linux-arm.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
"runtimeTargets": {
"runtimes/linux-arm/native/libSystem.IO.Ports.Native.so": {
@@ -88,6 +129,31 @@
}
}
},
+ "System.Drawing.Common/5.0.2": {
+ "dependencies": {
+ "Microsoft.Win32.SystemEvents": "5.0.0"
+ },
+ "runtime": {
+ "lib/netcoreapp3.0/System.Drawing.Common.dll": {
+ "assemblyVersion": "5.0.0.2",
+ "fileVersion": "5.0.421.11614"
+ }
+ },
+ "runtimeTargets": {
+ "runtimes/unix/lib/netcoreapp3.0/System.Drawing.Common.dll": {
+ "rid": "unix",
+ "assetType": "runtime",
+ "assemblyVersion": "5.0.0.2",
+ "fileVersion": "5.0.421.11614"
+ },
+ "runtimes/win/lib/netcoreapp3.0/System.Drawing.Common.dll": {
+ "rid": "win",
+ "assetType": "runtime",
+ "assemblyVersion": "5.0.0.2",
+ "fileVersion": "5.0.421.11614"
+ }
+ }
+ },
"System.IO.Ports/6.0.0-preview.5.21301.5": {
"dependencies": {
"Microsoft.Win32.Registry": "6.0.0-preview.5.21301.5",
@@ -141,6 +207,28 @@
}
}
},
+ "System.Runtime/4.3.0": {
+ "dependencies": {
+ "Microsoft.NETCore.Platforms": "5.0.0",
+ "Microsoft.NETCore.Targets": "1.1.0"
+ }
+ },
+ "System.Runtime.InteropServices.WindowsRuntime/4.3.0": {
+ "dependencies": {
+ "System.Runtime": "4.3.0"
+ }
+ },
+ "System.Runtime.WindowsRuntime/4.7.0": {
+ "dependencies": {
+ "Microsoft.NETCore.Platforms": "5.0.0"
+ }
+ },
+ "System.Runtime.WindowsRuntime.UI.Xaml/4.6.0": {
+ "dependencies": {
+ "Microsoft.NETCore.Platforms": "5.0.0",
+ "System.Runtime.WindowsRuntime": "4.7.0"
+ }
+ },
"System.Security.AccessControl/6.0.0-preview.5.21301.5": {
"dependencies": {
"System.Security.Principal.Windows": "6.0.0-preview.5.21301.5"
@@ -190,6 +278,13 @@
"serviceable": false,
"sha512": ""
},
+ "Bluetooth/1.0.0.2": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-dI5MtUEkDm2L81kHFeofWkpOvq7Yn2iNVl8dKa+DIeXhqHb9LrBSH7LpmaNOlZMLwQFDKageUpxV0w39GMeUag==",
+ "path": "bluetooth/1.0.0.2",
+ "hashPath": "bluetooth.1.0.0.2.nupkg.sha512"
+ },
"Microsoft.NETCore.Platforms/5.0.0": {
"type": "package",
"serviceable": true,
@@ -197,6 +292,13 @@
"path": "microsoft.netcore.platforms/5.0.0",
"hashPath": "microsoft.netcore.platforms.5.0.0.nupkg.sha512"
},
+ "Microsoft.NETCore.Targets/1.1.0": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-aOZA3BWfz9RXjpzt0sRJJMjAscAUm3Hoa4UWAfceV9UTYxgwZ1lZt5nO2myFf+/jetYQo4uTP7zS8sJY67BBxg==",
+ "path": "microsoft.netcore.targets/1.1.0",
+ "hashPath": "microsoft.netcore.targets.1.1.0.nupkg.sha512"
+ },
"Microsoft.Win32.Registry/6.0.0-preview.5.21301.5": {
"type": "package",
"serviceable": true,
@@ -204,6 +306,20 @@
"path": "microsoft.win32.registry/6.0.0-preview.5.21301.5",
"hashPath": "microsoft.win32.registry.6.0.0-preview.5.21301.5.nupkg.sha512"
},
+ "Microsoft.Win32.SystemEvents/5.0.0": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-Bh6blKG8VAKvXiLe2L+sEsn62nc1Ij34MrNxepD2OCrS5cpCwQa9MeLyhVQPQ/R4Wlzwuy6wMK8hLb11QPDRsQ==",
+ "path": "microsoft.win32.systemevents/5.0.0",
+ "hashPath": "microsoft.win32.systemevents.5.0.0.nupkg.sha512"
+ },
+ "Microsoft.Windows.SDK.Contracts/10.0.19041.1": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-sgDwuoyubbLFNJR/BINbvfSNRiglF91D+Q0uEAkU4ZTO5Hgbnu8+gA4TCc65S56e1kK7gvR1+H4kphkDTr+9bw==",
+ "path": "microsoft.windows.sdk.contracts/10.0.19041.1",
+ "hashPath": "microsoft.windows.sdk.contracts.10.0.19041.1.nupkg.sha512"
+ },
"runtime.linux-arm.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
"type": "package",
"serviceable": true,
@@ -246,6 +362,13 @@
"path": "system.codedom/5.0.0",
"hashPath": "system.codedom.5.0.0.nupkg.sha512"
},
+ "System.Drawing.Common/5.0.2": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-rvr/M1WPf24ljpvvrVd74+NdjRUJu1bBkspkZcnzSZnmAUQWSvanlQ0k/hVHk+cHufZbZfu7vOh/vYc0q5Uu/A==",
+ "path": "system.drawing.common/5.0.2",
+ "hashPath": "system.drawing.common.5.0.2.nupkg.sha512"
+ },
"System.IO.Ports/6.0.0-preview.5.21301.5": {
"type": "package",
"serviceable": true,
@@ -260,6 +383,34 @@
"path": "system.management/5.0.0",
"hashPath": "system.management.5.0.0.nupkg.sha512"
},
+ "System.Runtime/4.3.0": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-JufQi0vPQ0xGnAczR13AUFglDyVYt4Kqnz1AZaiKZ5+GICq0/1MH/mO/eAJHt/mHW1zjKBJd7kV26SrxddAhiw==",
+ "path": "system.runtime/4.3.0",
+ "hashPath": "system.runtime.4.3.0.nupkg.sha512"
+ },
+ "System.Runtime.InteropServices.WindowsRuntime/4.3.0": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-J4GUi3xZQLUBasNwZnjrffN8i5wpHrBtZoLG+OhRyGo/+YunMRWWtwoMDlUAIdmX0uRfpHIBDSV6zyr3yf00TA==",
+ "path": "system.runtime.interopservices.windowsruntime/4.3.0",
+ "hashPath": "system.runtime.interopservices.windowsruntime.4.3.0.nupkg.sha512"
+ },
+ "System.Runtime.WindowsRuntime/4.7.0": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-RQxUkf37fp7MSWbOfKRjUjyudyfZb2u79YY5i1s+d7vuD80A7kmr2YfefO0JprQUhanxSm8bhXigCVfX2kEh+w==",
+ "path": "system.runtime.windowsruntime/4.7.0",
+ "hashPath": "system.runtime.windowsruntime.4.7.0.nupkg.sha512"
+ },
+ "System.Runtime.WindowsRuntime.UI.Xaml/4.6.0": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-r4tNw5v5kqRJ9HikWpcyNf3suGw7DjX93svj9iBjtdeLqL8jt9Z+7f+s4wrKZJr84u8IMsrIjt8K6jYvkRqMSg==",
+ "path": "system.runtime.windowsruntime.ui.xaml/4.6.0",
+ "hashPath": "system.runtime.windowsruntime.ui.xaml.4.6.0.nupkg.sha512"
+ },
"System.Security.AccessControl/6.0.0-preview.5.21301.5": {
"type": "package",
"serviceable": true,
diff --git a/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.dll b/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.dll
index 6c13984..fbdb700 100644
Binary files a/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.dll and b/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.dll differ
diff --git a/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.pdb b/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.pdb
index 936ff43..e3ad152 100644
Binary files a/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.pdb and b/Matrix App/bin/Debug/netcoreapp3.1/Matrix App.pdb differ
diff --git a/Matrix App/bin/Debug/netcoreapp3.1/Microsoft.Win32.SystemEvents.dll b/Matrix App/bin/Debug/netcoreapp3.1/Microsoft.Win32.SystemEvents.dll
new file mode 100644
index 0000000..d62f333
Binary files /dev/null and b/Matrix App/bin/Debug/netcoreapp3.1/Microsoft.Win32.SystemEvents.dll differ
diff --git a/Matrix App/bin/Debug/netcoreapp3.1/System.Drawing.Common.dll b/Matrix App/bin/Debug/netcoreapp3.1/System.Drawing.Common.dll
new file mode 100644
index 0000000..6ab3e30
Binary files /dev/null and b/Matrix App/bin/Debug/netcoreapp3.1/System.Drawing.Common.dll differ
diff --git a/Matrix App/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp3.0/System.Drawing.Common.dll b/Matrix App/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp3.0/System.Drawing.Common.dll
new file mode 100644
index 0000000..8b95164
Binary files /dev/null and b/Matrix App/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp3.0/System.Drawing.Common.dll differ
diff --git a/Matrix App/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp3.0/Microsoft.Win32.SystemEvents.dll b/Matrix App/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp3.0/Microsoft.Win32.SystemEvents.dll
new file mode 100644
index 0000000..b5aa0c4
Binary files /dev/null and b/Matrix App/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp3.0/Microsoft.Win32.SystemEvents.dll differ
diff --git a/Matrix App/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp3.0/System.Drawing.Common.dll b/Matrix App/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp3.0/System.Drawing.Common.dll
new file mode 100644
index 0000000..b80b430
Binary files /dev/null and b/Matrix App/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp3.0/System.Drawing.Common.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/Matrix App.deps.json b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.deps.json
new file mode 100644
index 0000000..8eccd65
--- /dev/null
+++ b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.deps.json
@@ -0,0 +1,278 @@
+{
+ "runtimeTarget": {
+ "name": ".NETCoreApp,Version=v3.1",
+ "signature": ""
+ },
+ "compilationOptions": {},
+ "targets": {
+ ".NETCoreApp,Version=v3.1": {
+ "Matrix App/1.0.0": {
+ "dependencies": {
+ "System.IO.Ports": "6.0.0-preview.5.21301.5",
+ "System.Management": "5.0.0"
+ },
+ "runtime": {
+ "Matrix App.dll": {}
+ }
+ },
+ "Microsoft.NETCore.Platforms/5.0.0": {},
+ "Microsoft.Win32.Registry/6.0.0-preview.5.21301.5": {
+ "dependencies": {
+ "System.Security.AccessControl": "6.0.0-preview.5.21301.5",
+ "System.Security.Principal.Windows": "6.0.0-preview.5.21301.5"
+ },
+ "runtime": {
+ "lib/netstandard2.0/Microsoft.Win32.Registry.dll": {
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ }
+ },
+ "runtimeTargets": {
+ "runtimes/win/lib/netstandard2.0/Microsoft.Win32.Registry.dll": {
+ "rid": "win",
+ "assetType": "runtime",
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ }
+ }
+ },
+ "runtime.linux-arm.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "runtimeTargets": {
+ "runtimes/linux-arm/native/libSystem.IO.Ports.Native.so": {
+ "rid": "linux-arm",
+ "assetType": "native",
+ "fileVersion": "0.0.0.0"
+ }
+ }
+ },
+ "runtime.linux-arm64.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "runtimeTargets": {
+ "runtimes/linux-arm64/native/libSystem.IO.Ports.Native.so": {
+ "rid": "linux-arm64",
+ "assetType": "native",
+ "fileVersion": "0.0.0.0"
+ }
+ }
+ },
+ "runtime.linux-x64.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "runtimeTargets": {
+ "runtimes/linux-x64/native/libSystem.IO.Ports.Native.so": {
+ "rid": "linux-x64",
+ "assetType": "native",
+ "fileVersion": "0.0.0.0"
+ }
+ }
+ },
+ "runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "dependencies": {
+ "runtime.linux-arm.runtime.native.System.IO.Ports": "6.0.0-preview.5.21301.5",
+ "runtime.linux-arm64.runtime.native.System.IO.Ports": "6.0.0-preview.5.21301.5",
+ "runtime.linux-x64.runtime.native.System.IO.Ports": "6.0.0-preview.5.21301.5",
+ "runtime.osx-x64.runtime.native.System.IO.Ports": "6.0.0-preview.5.21301.5"
+ }
+ },
+ "runtime.osx-x64.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "runtimeTargets": {
+ "runtimes/osx-x64/native/libSystem.IO.Ports.Native.dylib": {
+ "rid": "osx-x64",
+ "assetType": "native",
+ "fileVersion": "0.0.0.0"
+ }
+ }
+ },
+ "System.CodeDom/5.0.0": {
+ "runtime": {
+ "lib/netstandard2.0/System.CodeDom.dll": {
+ "assemblyVersion": "5.0.0.0",
+ "fileVersion": "5.0.20.51904"
+ }
+ }
+ },
+ "System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "dependencies": {
+ "Microsoft.Win32.Registry": "6.0.0-preview.5.21301.5",
+ "runtime.native.System.IO.Ports": "6.0.0-preview.5.21301.5"
+ },
+ "runtime": {
+ "lib/netstandard2.0/System.IO.Ports.dll": {
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ }
+ },
+ "runtimeTargets": {
+ "runtimes/linux/lib/netstandard2.0/System.IO.Ports.dll": {
+ "rid": "linux",
+ "assetType": "runtime",
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ },
+ "runtimes/osx/lib/netstandard2.0/System.IO.Ports.dll": {
+ "rid": "osx",
+ "assetType": "runtime",
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ },
+ "runtimes/win/lib/netstandard2.0/System.IO.Ports.dll": {
+ "rid": "win",
+ "assetType": "runtime",
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ }
+ }
+ },
+ "System.Management/5.0.0": {
+ "dependencies": {
+ "Microsoft.NETCore.Platforms": "5.0.0",
+ "Microsoft.Win32.Registry": "6.0.0-preview.5.21301.5",
+ "System.CodeDom": "5.0.0"
+ },
+ "runtime": {
+ "lib/netstandard2.0/System.Management.dll": {
+ "assemblyVersion": "4.0.0.0",
+ "fileVersion": "5.0.20.51904"
+ }
+ },
+ "runtimeTargets": {
+ "runtimes/win/lib/netcoreapp2.0/System.Management.dll": {
+ "rid": "win",
+ "assetType": "runtime",
+ "assemblyVersion": "4.0.0.0",
+ "fileVersion": "5.0.20.51904"
+ }
+ }
+ },
+ "System.Security.AccessControl/6.0.0-preview.5.21301.5": {
+ "dependencies": {
+ "System.Security.Principal.Windows": "6.0.0-preview.5.21301.5"
+ },
+ "runtime": {
+ "lib/netstandard2.0/System.Security.AccessControl.dll": {
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ }
+ },
+ "runtimeTargets": {
+ "runtimes/win/lib/netstandard2.0/System.Security.AccessControl.dll": {
+ "rid": "win",
+ "assetType": "runtime",
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ }
+ }
+ },
+ "System.Security.Principal.Windows/6.0.0-preview.5.21301.5": {
+ "runtime": {
+ "lib/netstandard2.0/System.Security.Principal.Windows.dll": {
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ }
+ },
+ "runtimeTargets": {
+ "runtimes/unix/lib/netcoreapp2.1/System.Security.Principal.Windows.dll": {
+ "rid": "unix",
+ "assetType": "runtime",
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ },
+ "runtimes/win/lib/netcoreapp2.1/System.Security.Principal.Windows.dll": {
+ "rid": "win",
+ "assetType": "runtime",
+ "assemblyVersion": "6.0.0.0",
+ "fileVersion": "6.0.21.30105"
+ }
+ }
+ }
+ }
+ },
+ "libraries": {
+ "Matrix App/1.0.0": {
+ "type": "project",
+ "serviceable": false,
+ "sha512": ""
+ },
+ "Microsoft.NETCore.Platforms/5.0.0": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-VyPlqzH2wavqquTcYpkIIAQ6WdenuKoFN0BdYBbCWsclXacSOHNQn66Gt4z5NBqEYW0FAPm5rlvki9ZiCij5xQ==",
+ "path": "microsoft.netcore.platforms/5.0.0",
+ "hashPath": "microsoft.netcore.platforms.5.0.0.nupkg.sha512"
+ },
+ "Microsoft.Win32.Registry/6.0.0-preview.5.21301.5": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-qYLtJIAEJJmY2vXxlVO8x4uXfgq7DFOHjpmnHlLm7kmAvyNFckYY/Dx5CZythBXvI2/7sratbIGKqSTysfgZ8A==",
+ "path": "microsoft.win32.registry/6.0.0-preview.5.21301.5",
+ "hashPath": "microsoft.win32.registry.6.0.0-preview.5.21301.5.nupkg.sha512"
+ },
+ "runtime.linux-arm.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-VlGxrS0KZuoXA2zP/4JtcsnAUr66ivzLj2TdwXcaQ2vKTFOq9wCz7xYh08KvZVWXJKthpzhS+lWtdw/9vbVlgg==",
+ "path": "runtime.linux-arm.runtime.native.system.io.ports/6.0.0-preview.5.21301.5",
+ "hashPath": "runtime.linux-arm.runtime.native.system.io.ports.6.0.0-preview.5.21301.5.nupkg.sha512"
+ },
+ "runtime.linux-arm64.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-fN2ienMgX5Gl8rmmmTkCxEBeN+KMEwHkTIE+4bHIH0sgPZJqrGV7o7sjjivZlv95L64cF+a4UVlxGqiMVEN6Nw==",
+ "path": "runtime.linux-arm64.runtime.native.system.io.ports/6.0.0-preview.5.21301.5",
+ "hashPath": "runtime.linux-arm64.runtime.native.system.io.ports.6.0.0-preview.5.21301.5.nupkg.sha512"
+ },
+ "runtime.linux-x64.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-wLbxixueLlN1bT3tHi4bnXhyp2tuyJ92TBBBwW01YS4isxkLr8o4f2AGw8YbsF4y2Fgx8RRQiipkG1EFrZ7AKg==",
+ "path": "runtime.linux-x64.runtime.native.system.io.ports/6.0.0-preview.5.21301.5",
+ "hashPath": "runtime.linux-x64.runtime.native.system.io.ports.6.0.0-preview.5.21301.5.nupkg.sha512"
+ },
+ "runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-9Int9JpQ3quVnY3nsUFmrcanozIrEMFAydF+v8KmDwh0CtPb2AZLyyRtNEC3Z1WmoF8qf+T7jWwuPlrfl338dw==",
+ "path": "runtime.native.system.io.ports/6.0.0-preview.5.21301.5",
+ "hashPath": "runtime.native.system.io.ports.6.0.0-preview.5.21301.5.nupkg.sha512"
+ },
+ "runtime.osx-x64.runtime.native.System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-IhXEnQFgPxM/pUkEJkFBkr6XBkWFiuMGLlyl5BDG7LkJuGX4jAxJwL6n9Pue88ZyV45c0ajvuZOBnZJap+uIKA==",
+ "path": "runtime.osx-x64.runtime.native.system.io.ports/6.0.0-preview.5.21301.5",
+ "hashPath": "runtime.osx-x64.runtime.native.system.io.ports.6.0.0-preview.5.21301.5.nupkg.sha512"
+ },
+ "System.CodeDom/5.0.0": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-JPJArwA1kdj8qDAkY2XGjSWoYnqiM7q/3yRNkt6n28Mnn95MuEGkZXUbPBf7qc3IjwrGY5ttQon7yqHZyQJmOQ==",
+ "path": "system.codedom/5.0.0",
+ "hashPath": "system.codedom.5.0.0.nupkg.sha512"
+ },
+ "System.IO.Ports/6.0.0-preview.5.21301.5": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-9jguTG3uxGLvERVKV6w8ctcaYktBv8ssZgl6xm1hI89BBIaU6WwC2SQt9ur+TT8UMxdu9ZG+QQMbCJKEKv9dnQ==",
+ "path": "system.io.ports/6.0.0-preview.5.21301.5",
+ "hashPath": "system.io.ports.6.0.0-preview.5.21301.5.nupkg.sha512"
+ },
+ "System.Management/5.0.0": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-MF1CHaRcC+MLFdnDthv4/bKWBZnlnSpkGqa87pKukQefgEdwtb9zFW6zs0GjPp73qtpYYg4q6PEKbzJbxCpKfw==",
+ "path": "system.management/5.0.0",
+ "hashPath": "system.management.5.0.0.nupkg.sha512"
+ },
+ "System.Security.AccessControl/6.0.0-preview.5.21301.5": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-EA9ul7nGN8oggMvloILnR+wnrbgLNZZQBYHq5nEq/ixwnKLV3M3Tbd1Jbj8oGck3XMj0owq81e4Jxp3s0IMICw==",
+ "path": "system.security.accesscontrol/6.0.0-preview.5.21301.5",
+ "hashPath": "system.security.accesscontrol.6.0.0-preview.5.21301.5.nupkg.sha512"
+ },
+ "System.Security.Principal.Windows/6.0.0-preview.5.21301.5": {
+ "type": "package",
+ "serviceable": true,
+ "sha512": "sha512-ywwCqFAaRVbgqqORqYg8jdaX6NUEpzbuhxyUhAs+7mZ8AFAO4PzFYrZ5JPkYejXwougDldtbi0zOkk1lLzugLw==",
+ "path": "system.security.principal.windows/6.0.0-preview.5.21301.5",
+ "hashPath": "system.security.principal.windows.6.0.0-preview.5.21301.5.nupkg.sha512"
+ }
+ }
+}
\ No newline at end of file
diff --git a/Matrix App/bin/Release/netcoreapp3.1/Matrix App.dll b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.dll
new file mode 100644
index 0000000..ca9f89d
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/Matrix App.exe b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.exe
new file mode 100644
index 0000000..cccc9a8
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.exe differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/Matrix App.pdb b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.pdb
new file mode 100644
index 0000000..e54b10a
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.pdb differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/Matrix App.runtimeconfig.dev.json b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.runtimeconfig.dev.json
new file mode 100644
index 0000000..2d6cdd4
--- /dev/null
+++ b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.runtimeconfig.dev.json
@@ -0,0 +1,8 @@
+{
+ "runtimeOptions": {
+ "additionalProbingPaths": [
+ "C:\\Users\\SvenV\\.dotnet\\store\\|arch|\\|tfm|",
+ "C:\\Users\\SvenV\\.nuget\\packages"
+ ]
+ }
+}
\ No newline at end of file
diff --git a/Matrix App/bin/Release/netcoreapp3.1/Matrix App.runtimeconfig.json b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.runtimeconfig.json
new file mode 100644
index 0000000..4932b40
--- /dev/null
+++ b/Matrix App/bin/Release/netcoreapp3.1/Matrix App.runtimeconfig.json
@@ -0,0 +1,9 @@
+{
+ "runtimeOptions": {
+ "tfm": "netcoreapp3.1",
+ "framework": {
+ "name": "Microsoft.WindowsDesktop.App",
+ "version": "3.1.0"
+ }
+ }
+}
\ No newline at end of file
diff --git a/Matrix App/bin/Release/netcoreapp3.1/Microsoft.Win32.Registry.dll b/Matrix App/bin/Release/netcoreapp3.1/Microsoft.Win32.Registry.dll
new file mode 100644
index 0000000..58dd575
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/Microsoft.Win32.Registry.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/System.CodeDom.dll b/Matrix App/bin/Release/netcoreapp3.1/System.CodeDom.dll
new file mode 100644
index 0000000..873495d
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/System.CodeDom.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/System.IO.Ports.dll b/Matrix App/bin/Release/netcoreapp3.1/System.IO.Ports.dll
new file mode 100644
index 0000000..ec97c17
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/System.IO.Ports.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/System.Management.dll b/Matrix App/bin/Release/netcoreapp3.1/System.Management.dll
new file mode 100644
index 0000000..c3a0320
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/System.Management.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/System.Security.AccessControl.dll b/Matrix App/bin/Release/netcoreapp3.1/System.Security.AccessControl.dll
new file mode 100644
index 0000000..fc2b204
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/System.Security.AccessControl.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/System.Security.Principal.Windows.dll b/Matrix App/bin/Release/netcoreapp3.1/System.Security.Principal.Windows.dll
new file mode 100644
index 0000000..f00fa14
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/System.Security.Principal.Windows.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux-arm/native/libSystem.IO.Ports.Native.so b/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux-arm/native/libSystem.IO.Ports.Native.so
new file mode 100644
index 0000000..6a6d9d4
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux-arm/native/libSystem.IO.Ports.Native.so differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux-arm64/native/libSystem.IO.Ports.Native.so b/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux-arm64/native/libSystem.IO.Ports.Native.so
new file mode 100644
index 0000000..5458e8f
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux-arm64/native/libSystem.IO.Ports.Native.so differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux-x64/native/libSystem.IO.Ports.Native.so b/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux-x64/native/libSystem.IO.Ports.Native.so
new file mode 100644
index 0000000..b20adef
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux-x64/native/libSystem.IO.Ports.Native.so differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux/lib/netstandard2.0/System.IO.Ports.dll b/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux/lib/netstandard2.0/System.IO.Ports.dll
new file mode 100644
index 0000000..a0b6e96
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/linux/lib/netstandard2.0/System.IO.Ports.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/osx-x64/native/libSystem.IO.Ports.Native.dylib b/Matrix App/bin/Release/netcoreapp3.1/runtimes/osx-x64/native/libSystem.IO.Ports.Native.dylib
new file mode 100644
index 0000000..d949124
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/osx-x64/native/libSystem.IO.Ports.Native.dylib differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/osx/lib/netstandard2.0/System.IO.Ports.dll b/Matrix App/bin/Release/netcoreapp3.1/runtimes/osx/lib/netstandard2.0/System.IO.Ports.dll
new file mode 100644
index 0000000..153b0d7
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/osx/lib/netstandard2.0/System.IO.Ports.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.1/System.Security.Principal.Windows.dll b/Matrix App/bin/Release/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.1/System.Security.Principal.Windows.dll
new file mode 100644
index 0000000..be6dbef
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.1/System.Security.Principal.Windows.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netcoreapp2.0/System.Management.dll b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netcoreapp2.0/System.Management.dll
new file mode 100644
index 0000000..a3a1f45
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netcoreapp2.0/System.Management.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netcoreapp2.1/System.Security.Principal.Windows.dll b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netcoreapp2.1/System.Security.Principal.Windows.dll
new file mode 100644
index 0000000..f901c0b
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netcoreapp2.1/System.Security.Principal.Windows.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netstandard2.0/Microsoft.Win32.Registry.dll b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netstandard2.0/Microsoft.Win32.Registry.dll
new file mode 100644
index 0000000..732878a
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netstandard2.0/Microsoft.Win32.Registry.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.IO.Ports.dll b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.IO.Ports.dll
new file mode 100644
index 0000000..6ccae84
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.IO.Ports.dll differ
diff --git a/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.Security.AccessControl.dll b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.Security.AccessControl.dll
new file mode 100644
index 0000000..41106d5
Binary files /dev/null and b/Matrix App/bin/Release/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.Security.AccessControl.dll differ
diff --git a/Matrix App/forms/ColorWheel.Designer.cs b/Matrix App/forms/ColorWheel.Designer.cs
index 96fd3a0..c990bba 100644
--- a/Matrix App/forms/ColorWheel.Designer.cs
+++ b/Matrix App/forms/ColorWheel.Designer.cs
@@ -732,7 +732,6 @@ namespace Matrix_App
private void InitializeComponent()
{
components = new System.ComponentModel.Container();
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
}
}
}
diff --git a/Matrix App/forms/MatrixDesigner.Designer.cs b/Matrix App/forms/MatrixDesigner.Designer.cs
index 08597e4..1818706 100644
--- a/Matrix App/forms/MatrixDesigner.Designer.cs
+++ b/Matrix App/forms/MatrixDesigner.Designer.cs
@@ -1,5 +1,6 @@
using System.IO.Ports;
using System.Drawing;
+using System.Windows.Forms;
namespace Matrix_App
{
@@ -35,7 +36,7 @@ namespace Matrix_App
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MatrixDesignerMain));
- this.Ports = new System.Windows.Forms.ComboBox();
+ this.Ports = new System.Windows.Forms.Button();
this.Modus = new System.Windows.Forms.TabControl();
this.tabPage1 = new System.Windows.Forms.TabPage();
this.groupBox3 = new System.Windows.Forms.GroupBox();
@@ -82,6 +83,7 @@ namespace Matrix_App
this.DragDropButton = new System.Windows.Forms.Button();
matrixView = new Matrix_App.Matrix();
this.panel3 = new System.Windows.Forms.Panel();
+ this.PushButton = new Button();
this.Modus.SuspendLayout();
this.tabPage1.SuspendLayout();
this.groupBox3.SuspendLayout();
@@ -107,13 +109,20 @@ namespace Matrix_App
//
// Ports
//
- this.Ports.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.Ports.Location = new System.Drawing.Point(62, 130);
this.Ports.Name = "Ports";
this.Ports.Size = new System.Drawing.Size(163, 23);
this.Ports.TabIndex = 0;
- this.Ports.SelectedIndexChanged += new System.EventHandler(this.Ports_SelectedIndexChanged);
- //
+ this.Ports.Click += PortsOnClick;
+ this.Ports.Text = "Settings";
+ //
+ // Push Button
+ //
+ this.PushButton.Location = new Point(3, 481 + 113 + 8);
+ this.PushButton.Size = new Size(216, 23 + 6);
+ this.PushButton.Text = "Push Animation";
+ this.PushButton.Click += PushButtonOnClick;
+ //
// Modus
//
this.Modus.Controls.Add(this.tabPage1);
@@ -345,7 +354,7 @@ namespace Matrix_App
this.matrixHeight.Size = new System.Drawing.Size(163, 23);
this.matrixHeight.TabIndex = 1;
this.matrixHeight.Value = new decimal(new int[] {
- Defaults.MatrixStartHeight,
+ 16,
0,
0,
0});
@@ -377,6 +386,7 @@ namespace Matrix_App
// Zeichnen
//
this.Zeichnen.BackColor = System.Drawing.Color.Transparent;
+ this.Zeichnen.Controls.Add(this.PushButton);
this.Zeichnen.Controls.Add(this.groupBox2);
this.Zeichnen.Controls.Add(this.groupBox1);
this.Zeichnen.Controls.Add(this.Clear);
@@ -550,6 +560,7 @@ namespace Matrix_App
this.fill.TabIndex = 7;
this.fill.Text = "Fill";
this.fill.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
+
this.fill.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.fill.UseVisualStyleBackColor = true;
this.fill.Click += new System.EventHandler(this.DrawFill_Click);
@@ -559,7 +570,7 @@ namespace Matrix_App
this.ZeichnenFarbRad.BackColor = System.Drawing.SystemColors.Control;
this.ZeichnenFarbRad.Location = new System.Drawing.Point(8, 12);
this.ZeichnenFarbRad.Name = "ZeichnenFarbRad";
- this.ZeichnenFarbRad.Size = new System.Drawing.Size(209, 214);
+ this.ZeichnenFarbRad.Size = new System.Drawing.Size(209, 209);
this.ZeichnenFarbRad.TabIndex = 0;
//
// pregeneratedMods
@@ -737,7 +748,7 @@ namespace Matrix_App
#endregion
- private System.Windows.Forms.ComboBox Ports;
+ private System.Windows.Forms.Button Ports;
private System.Windows.Forms.TabControl Modus;
private System.Windows.Forms.TabPage tabPage1;
private System.Windows.Forms.TabPage Zeichnen;
@@ -784,6 +795,7 @@ namespace Matrix_App
private System.Windows.Forms.Label label7;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.GroupBox groupBox3;
+ private System.Windows.Forms.Button PushButton;
}
}
diff --git a/Matrix App/forms/MatrixDesigner.cs b/Matrix App/forms/MatrixDesigner.cs
index 6c5bad6..4fa26ac 100644
--- a/Matrix App/forms/MatrixDesigner.cs
+++ b/Matrix App/forms/MatrixDesigner.cs
@@ -2,53 +2,52 @@
#define DEBUG_ENABLED
using System;
-using System.Collections.Generic;
using System.Diagnostics;
-using System.Diagnostics.CodeAnalysis;
using System.Drawing;
-using System.Linq;
-using System.Windows.Forms;
-using System.IO.Ports;
-using System.Timers;
using System.Drawing.Imaging;
using System.IO;
-using System.Management;
-using System.Text.RegularExpressions;
-
+using System.IO.Ports;
+using System.Timers;
+using System.Windows.Forms;
+using Matrix_App.adds;
+using Matrix_App.forms;
+using Matrix_App.Properties;
+using Matrix_App.Themes;
using static Matrix_App.Defaults;
using static Matrix_App.ArduinoInstruction;
using static Matrix_App.Utils;
-using Matrix_App.Themes;
using Timer = System.Timers.Timer;
namespace Matrix_App
{
public partial class MatrixDesignerMain : Form
{
+ private void PortsOnClick(object? sender, EventArgs e)
+ {
+ new Settings(ref commandQueue, ref port);
+ }
+
#region Private-Members
///
- /// Port update Timer
- /// Reloads available port names at consecutive rates
+ /// Port update Timer
+ /// Reloads available port names at consecutive rates
///
- private Timer? portNameUpdater;
private Timer? delay;
- private static SerialPort _port = new SerialPort();
-
- private uint portNumber;
-
private bool runningGif;
- private readonly PortCommandQueue commandQueue = new PortCommandQueue(ref _port);
- private readonly Regex comRegex = new Regex(@"COM[\d]+");
+ private static SerialPort port = new();
+
+ private PortCommandQueue commandQueue = new(ref port);
+
///
- /// Gif like frame video buffer
+ /// Gif like frame video buffer
///
public static byte[][] gifBuffer = CreateImageRGB_NT(MatrixStartWidth, MatrixStartHeight, MatrixStartFrames);
- public static readonly ThreadQueue IMAGE_DRAWER = new ThreadQueue("Matrix Image Drawer", 4);
-
+ public static readonly ThreadQueue IMAGE_DRAWER = new("Matrix Image Drawer", 4);
+
#endregion
#region Setup
@@ -61,7 +60,7 @@ namespace Matrix_App
matrixView.Instance(this);
// Generate filter access buttons
MatrixGifGenerator.GenerateBaseUi(pregeneratedModsBase, matrixView, this);
-
+
Init();
// apply light-mode by default
new LightMode().ApplyTheme(this);
@@ -71,12 +70,6 @@ namespace Matrix_App
private void Init()
{
- // Create port name update timer
- portNameUpdater = new Timer(PortNameUpdateInterval);
- portNameUpdater.Elapsed += UpdatePortNames;
- portNameUpdater.AutoReset = true;
- portNameUpdater.Enabled = true;
-
// create gif playback timer
delay = new Timer((int) Delay.Value);
delay.Elapsed += Timelineupdate;
@@ -86,42 +79,42 @@ namespace Matrix_App
ZeichnenFarbRad.handler = ColorWheel_Handler!;
// setup port settings
- _port.BaudRate = BaudRate;
- _port.ReadTimeout = ReadTimeoutMs;
- _port.WriteTimeout = WriteTimeoutMs;
+ port.BaudRate = BaudRate;
+ port.ReadTimeout = ReadTimeoutMs;
+ port.WriteTimeout = WriteTimeoutMs;
+ port.Parity = Parity.None;
+ port.DataBits = 8;
+ port.StopBits = StopBits.One;
// setup matrix
AdjustMatrixTable();
// search for initial ports
- GatherPortNames();
+ //GatherPortNames();
HideEasterEgg();
}
private void HideEasterEgg()
{
- if (((int) DateTime.Now.DayOfWeek) != 3)
+ if (DateTime.Now.DayOfWeek != DayOfWeek.Wednesday)
return;
-
+
if (new Random().Next(0, 9) >= 1)
return;
-
- using (Bitmap wednesdayFrog = new Bitmap(Properties.Resources.Frosch))
+
+ using (Bitmap wednesdayFrog = new(Resources.Frosch))
{
matrixWidth.Value = wednesdayFrog.Width;
matrixHeight.Value = wednesdayFrog.Height;
ResizeGif();
-
+
for (var x = 0; x < wednesdayFrog.Width; x++)
+ for (var y = 0; y < wednesdayFrog.Height; y++)
{
- for (var y = 0; y < wednesdayFrog.Height; y++)
- {
- var pixel = wednesdayFrog.GetPixel(x, y);
+ var pixel = wednesdayFrog.GetPixel(x, y);
- matrixView.SetPixelNoRefresh(x, y, pixel);
-
- }
+ matrixView.SetPixelNoRefresh(x, y, pixel);
}
}
@@ -133,164 +126,31 @@ namespace Matrix_App
#region UI-Methods
#region Port-ComboBox
- ///
- /// Updates the port names to newest available ports.
- /// Called by .
- ///
- ///
- ///
- private void UpdatePortNames(object source, ElapsedEventArgs e)
- {
- if (Ports.InvokeRequired)
- {
- // invoke on the combo-boxes thread
- Ports.Invoke(new Action(GatherPortNames));
- }
- else
- {
- // run on this thread
- GatherPortNames();
- }
- }
- ///
- /// Gathers all available ports and sets them to the combobox
- ///
- [SuppressMessage("ReSharper", "CoVariantArrayConversion", Justification = "Never got an exception, so seems to be just fine")]
- private void GatherPortNames()
- {
- var ports = SerialPort.GetPortNames();
- // save previously selected
- var selected = this.Ports.SelectedItem;
- // get device names from ports
- var newPorts = GetDeviceNames(ports);
- // add virtual port
- newPorts.AddLast("Virtual-Unlimited (COM257)");
-
- // search for new port
- foreach (var newPort in newPorts)
- {
- // find any new port
- var found = Ports.Items.Cast