protected void SendSectAnsw(int version, int result) { Logger.Info <ScvManager>($"On {Id} (TXE {TxEnabled}) Sending SectAnsw Msg (Sequence {Sequence}, Version {version}, result {result}) ..."); var msg = SactaMsg.MsgToSacta(Cfg, SactaMsg.MsgType.SectAnswer, 0, Sequence, version, result).Serialize(); if (BroadMessage(msg)) { Sequence = Sequence >= 287 ? 0 : Sequence + 1; Logger.Info <ScvManager>($"On {Cfg.Id} SectAnswer Msg sended. (New Sequence {Sequence}, Version {version}, result {result})"); } }
protected void SendInit() { Logger.Info <ScvManager>($"On {Id} (TXE {TxEnabled}) Sending Init Msg ..."); var msg = SactaMsg.MsgToSacta(Cfg, SactaMsg.MsgType.Init, SactaMsg.InitId, 0).Serialize(); if (BroadMessage(msg)) { Sequence = 0; Logger.Info <ScvManager>($"On {Cfg.Id} Init Msg sended."); } }
protected void SendSectAsk() { Logger.Info <ScvManager>($"On {Id} (TXE {TxEnabled}) Sending SectAsk Msg (Sequence {Sequence}) ..."); var msg = SactaMsg.MsgToSacta(Cfg, SactaMsg.MsgType.SectAsk, 0, Sequence).Serialize(); if (BroadMessage(msg)) { Sequence = Sequence >= 287 ? 0 : Sequence + 1; Logger.Info <ScvManager>($"On {Cfg.Id} SectAsk Msg sended. (New Sequence {Sequence})"); } WhenSectorAsked = DateTime.Now; }
protected void SendPresence() { Logger.Info <ScvManager>($"On {Id} (TXE {TxEnabled}) Sending Presence Msg (Sequence {Sequence}) ..."); var msg = SactaMsg.MsgToSacta(Cfg, SactaMsg.MsgType.Presence, 0, Sequence).Serialize(); if (BroadMessage(msg)) { Sequence = Sequence >= 287 ? 0 : Sequence + 1; LastPresenceSended = DateTime.Now; Logger.Info <ScvManager>($"On {Cfg.Id} Presence Msg sended. (New Sequence {Sequence}) "); } }