mirror of
https://github.com/MistWeatherMedia/i2ME.git
synced 2026-11-28 22:30:55 -08:00
Create seperate UdpSender for priority messages
This commit is contained in:
1 parent
589378e699
commit
370d79a049
1 file changed
+5
-2
@@ -25,14 +25,17 @@ public class Program
|
||||
Log.Info("Starting i2ME...");
|
||||
|
||||
Config config = Config.Load();
|
||||
UdpSender sender = new UdpSender();
|
||||
UdpSender routineSender = new UdpSender(config.UnitConfig.I2MsgAddress, config.UnitConfig.RoutineMsgPort,
|
||||
config.UnitConfig.InterfaceAddress);
|
||||
UdpSender prioritySender = new UdpSender(config.UnitConfig.I2MsgAddress, config.UnitConfig.PriorityMsgPort,
|
||||
config.UnitConfig.InterfaceAddress);
|
||||
|
||||
Log.SetLogLevel(config.LogLevel);
|
||||
|
||||
string[] locations = { "USWA0028" };
|
||||
// string[] locations = await GetMachineLocations(config);
|
||||
|
||||
Task hourlyRecordGen = TimedTasks.HourlyRecordCollection(locations, sender);
|
||||
Task hourlyRecordGen = TimedTasks.HourlyRecordCollection(locations, routineSender);
|
||||
Task cleanTempDir = TimedTasks.CleanTempDirectory();
|
||||
await Task.WhenAll(hourlyRecordGen, cleanTempDir);
|
||||
|
||||
|
||||
Reference in new issue
Block a user