| 1234567891011121314151617181920212223242526272829303132333435363738394041 |
- using Edge.Core.Parser.BinaryParser.Attributes;
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- namespace ZhongSheng_NonIC_Pump
- {
- /// <summary>
- /// PC 发送开机命令给油机(在油机“授权加油模式”时使用)
- /// </summary>
- public class StartPumpRequest : MessageTemplateBase
- {
- public enum PresetType
- {
- /// <summary>
- /// 此时定量数额没有意义
- /// </summary>
- 随意加油 = 0x00,
- 定油量体积加油 = 0x01,
- 定金额加油 = 0x02,
- }
- [Format(1, EncodingType.BIN, 1)]
- public byte 枪号 { get; set; }
- [Format(1, EncodingType.BIN, 2)]
- public PresetType 定量类型 { get; set; }
- [Format(4, EncodingType.BIN, 3)]
- public int 定量数额 { get; set; }
- public StartPumpRequest(byte nozzleNumber, PresetType presetType, int presetAmount)
- {
- base.CommandCode = 0x35;
- this.枪号 = nozzleNumber;
- this.定量类型 = presetType;
- this.定量数额 = presetAmount;
- }
- }
- }
|