32 lines
1012 B
C#
32 lines
1012 B
C#
using NLog;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using Xylem.Common.Hardware.Interfaces.Ports.PortCore;
|
|
using Xylem.Common.Utils.Logging;
|
|
|
|
namespace Xylem.Common.Hardware.Interfaces.Protocols.TransmitProtocol
|
|
{
|
|
public abstract class BaseTransmitProtocol : ITransmitProtocol
|
|
{
|
|
public readonly ILogger Logger;
|
|
|
|
protected BaseTransmitProtocol(String port)
|
|
{
|
|
Logger = NLogHelper.CreateOrGetMultiLogger(port, "COM", "TransmitProtocol", "COMBase", "BaseTransmitProtocol");
|
|
}
|
|
|
|
public abstract TransmitPortSettings GetTransmitPortSettings();
|
|
public abstract void SetResponseTimeout(Int32 responseTimeoutMs);
|
|
|
|
public abstract void SetDefaultResponseTimeout();
|
|
|
|
public abstract List<Byte> DecodeDataForPhysicalLayer(Byte command, Byte[] payload);
|
|
|
|
public abstract List<Byte> DecodeDataForLogicLayer(List<Byte> rawData);
|
|
|
|
public abstract List<byte> DecodeDataForPhysicalLayerUI1236(byte[] payload);
|
|
|
|
}
|
|
|
|
}
|