SendSalimaxStateAlarm added

This commit is contained in:
atef 2025-08-05 10:07:05 +02:00
parent 2c13e1a2a2
commit 5fd73f51cc
1 changed files with 6 additions and 3 deletions

View File

@ -101,9 +101,12 @@ public static class Program
var startTime = DateTime.Now;
Console.WriteLine("***************************** Reading Battery Data *********************************************");
Console.WriteLine(startTime.ToString("HH:mm:ss.fff"));
// the order matter of the next three lines
var statusrecord = ReadStatus();
SendSalimaxStateAlarm(GetSodiHomeStateAlarm(statusrecord),statusrecord);
await DataLogging(statusrecord, timestamp); // save a csv file locally
await SaveModbusTcpFile(statusrecord); // save the json file for modbuscTCP
@ -173,7 +176,7 @@ public static class Program
}
private static StatusMessage GetSalimaxStateAlarm(StatusRecord record)
private static StatusMessage GetSodiHomeStateAlarm(StatusRecord record)
{
var s3Bucket = Config.Load().S3?.Bucket;
@ -218,7 +221,7 @@ public static class Program
var returnedStatus = new StatusMessage
{
InstallationId = installationId,
Product = 3,
Product = 2,
Status = _sodistoreAlarmState,
Type = MessageType.AlarmOrWarning,
Alarms = alarmList,