| 12345678910111213141516171819202122232425262728293031 | using System;using Houdar.PLC.Driver.Simenss.Protocol.Common;using Houdar.PLC.Driver.Simenss.Protocol.Upload;namespace Houdar.PLC.Driver.Simenss.ProtocolHandle{    public class UploadStartHandle:IPacketHandle    {        public StartUploadRequest Request { get; set; }        public StartUploadResponse Response { get; set; }        public ResultCode ResultCode { get; set; }        public ushort BlockNum { get; set; }        public BlockType BlockType { get; set; }        public UploadStartHandle()        {            Request = new StartUploadRequest();        }        public void Handle(IIsoSender sender)        {            Request.BlockType = BlockType;            Request.BlockNum = BlockNum;            Response = sender.IsoSend<StartUploadRequest, StartUploadResponse>(Request);            ResultCode = Response.Header.Error;        }    }}
 |