CheckCmdRequest.cs 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. using Dfs.WayneChina.HengshanPayTerminal.Support;
  2. using Edge.Core.Parser.BinaryParser.Attributes;
  3. using System;
  4. using System.Collections.Generic;
  5. using System.Text;
  6. namespace Dfs.WayneChina.HengshanPayTerminal.MessageEntity.Incoming
  7. {
  8. /// <summary>
  9. /// Inquiry request from pump against system/EPS.
  10. /// 加油机查询命令Check_cmd,空闲时对后台发,命令字0x10.
  11. /// </summary>
  12. public class CheckCmdRequest : CardMessageBase
  13. {
  14. public CheckCmdRequest() : base(Command.Check_cmd)
  15. {
  16. }
  17. [Format(4, EncodingType.HexString, -90)]
  18. public string TerminalId { get; set; }
  19. /// <summary>
  20. /// Fueling point code, first byte is nozzle number, second pump number.
  21. /// 加油点,字节1为枪号,字节2为泵号。
  22. /// </summary>
  23. [Format(2, EncodingType.HexString, -89)]
  24. public string FPCode { get; set; }
  25. [Format(1, EncodingType.BIN, -88)]
  26. public byte WorkMode { get; set; }
  27. //public WorkMode WorkMode { get; set; }
  28. [Format(1, EncodingType.BIN, -87)]
  29. public byte DispenserState { get; set; }
  30. //public DispenserState DispenserState { get; set; }
  31. [Format(1, EncodingType.BIN, -86)]
  32. public int AuthState { get; set; }
  33. [Format(3, EncodingType.BIN, -85)]
  34. public int Amount { get; set; }
  35. [Format(3, EncodingType.BIN, -84)]
  36. public int Volume { get; set; }
  37. [Format(2, EncodingType.BIN, -83)]
  38. public int Price { get; set; }
  39. #region Specified but not appeared
  40. //probably these are used when it's a CNG/LNG pump
  41. public int ValveNo { get; set; }
  42. public int PressureValue { get; set; }
  43. public int FlowValue { get; set; }
  44. public int Temperature { get; set; }
  45. public byte LockState { get; set; }
  46. public FuelingPointCode FuelingPoint
  47. {
  48. get
  49. {
  50. return new FuelingPointCode
  51. {
  52. NozzleNo = FPCode.Substring(0, 2).ToByte(),
  53. PumpNo = FPCode.Substring(2, 2).ToByte()
  54. };
  55. }
  56. }
  57. #endregion
  58. }
  59. }