| 1234567891011121314151617181920212223242526272829303132333435 | using Houdar.Core.Communication.Transport;using Houdar.PLC.Driver.Simenss.Protocol.Common;namespace Houdar.PLC.Driver.Simenss.Protocol.Negotiate{    public class NegotiateRequestParams    {        public byte FunNegotiate { get; set; }        public byte Unknown { get; set; }        public ushort ParallelJobs1 { get; set; }        public ushort ParallelJobs2 { get; set; }        public ushort PduLength { get; set; }        public ushort PacketLength  = 0x08;        public void GetByteBuffer(ByteBuffer buffer)        {            buffer.Push(FunNegotiate);            buffer.Push(Unknown);            buffer.Push(ParallelJobs1);            buffer.Push(ParallelJobs2);            buffer.Push(PduLength);        }        public void Build(ushort pduRequest)        {            FunNegotiate = (byte)PduFuncType.PduNegotiate;            Unknown = 0x00;            ParallelJobs1 = 0x0001;            ParallelJobs2 = 0x0001;            PduLength = pduRequest;        }    }}
 |