Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

37 строки
1.4 KiB

  1. using Glorysoft.SECS.EQP.Common;
  2. using Glorysoft.SECS.EQP.Message;
  3. using Glorysoft.SECS.EQP.Utilities;
  4. using Glorysoft.SECSwell;
  5. using System;
  6. using System.Collections.Generic;
  7. namespace Glorysoft.SECS.EQP.Handlers
  8. {
  9. public class S5F1Handler : ISECSMessageHandler
  10. {
  11. public void Execute(SECSContext context, SECSTransaction trans, SECSErrors err, string errmsg)
  12. {
  13. try
  14. {
  15. SECSMessage primary = trans.Primary;
  16. var trans5 = context.GetTransaction(5, 1, "S5F1");
  17. trans5.Secondary = primary;
  18. context.ReplyMessage(trans);
  19. //EQPController.Current.SendS1f3Param(context.Name);
  20. //var trans13 = context.GetTransaction(1, 3, "S1F3");
  21. //var s1f3item = new S1F3Item() { SVIDs = new List<ushort> { 1, 2, 3 } };
  22. //foreach (var k in s1f3item.SVIDs)
  23. //{
  24. // trans13.Primary.Root.Add(SECSUtil.CreateSECSItem("SVID", eSECS_FORMAT.U2, k));
  25. //}
  26. //context.SendMessage(trans13);
  27. Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss.fff")}=>回复EQP S5F1[{context.Name}]并发送S1f3");
  28. }
  29. catch (Exception ex)
  30. {
  31. LoggerService.SECSLogger.Error(ex.Message);
  32. }
  33. }
  34. }
  35. }