Class DeviceBinaryMessageAttribute
Declares a binary message: fixed-size fields after optional leading bytes, such as a slave address and a function code. Numbers are big-endian unless BigEndian is false.
[AttributeUsage(AttributeTargets.Class, Inherited = false)]
public sealed class DeviceBinaryMessageAttribute : Attribute
- Inheritance
-
DeviceBinaryMessageAttribute
- Inherited Members
- Extension Methods
Constructors
DeviceBinaryMessageAttribute(params byte[])
Declares a binary message: fixed-size fields after optional leading bytes, such as a slave address and a function code. Numbers are big-endian unless BigEndian is false.
public DeviceBinaryMessageAttribute(params byte[] prefix)
Parameters
prefixbyte[]
Properties
BigEndian
Gets or sets whether multi-byte numbers are big-endian. Defaults to true.
public bool BigEndian { get; set; }
Property Value
Prefix
Gets the bytes every message of this type starts with.
public byte[] Prefix { get; }
Property Value
- byte[]