FieldTalk Modbus Master Library for .NET
FieldTalk Modbus Master Library for .NET
Namespaces
FieldTalk.Modbus.Master
RegisterConverter Class
RegisterConverter Constructor
RegisterConverter Methods

# RegisterConverter Class

Helper class to convert common data types to Modbus registers and back.
Inheritance Hierarchy
System
Object
FieldTalk.Modbus.Master
RegisterConverter

Namespace: FieldTalk.Modbus.Master
Assembly: FieldTalk.Modbus.Master (in FieldTalk.Modbus.Master.dll) Version: 2.15.2-eval+3d8362b4bb861c05760d48b11d303e954bb8597c
Syntax
C#
VB
C++
Copy

    public class RegisterConverter

    Public Class RegisterConverter

    public ref class RegisterConverter

The RegisterConverter type exposes the following members.

Constructors

| Name | Description
--- | --- | ---
| RegisterConverter | Initializes a new instance of the RegisterConverter class

Top
Methods

| Name | Description
--- | --- | ---
| ToBits(Byte) | Unpack all the bits in a byte to a boolean array containing the bits
| ToBits( Byte ) | Unpack all the bits in an array of unsigned bytes to a boolean array containing the bits
| ToBits(SByte) | Unpack all the bits in a signed byte to a boolean array containing the bits
| ToBits( SByte ) | Unpack all the bits in an array of signed bytes to a boolean array containing the bits
| ToByte | Unpack 8 boolean values into an unsigned byte
| ToBytes | Pack an array of bits into an array of 8-bit unsigned bytes
| ToDouble | Cast four 16-bit register array elements to a 64-bit floating point value with little-endian word order
| ToInt16(Int32) | Cast a signed 32-bit value to a tuple of 16-bit register values
| ToInt16(Single) | Cast an 32-bit floating point value to a tuple of 16-bit register values
| ToInt16(UInt16) | Cast an unsigned 16-bit value to a 16-bit register value
| ToInt16(UInt32) | Cast an unsigned 32-bit value to a tuple of 16-bit register values
| ToInt16(Int32, Int16 , Int32) | Copies a signed 32-bit integer value into an array of 16-bit register values
| ToInt16(Single, Int16 , Int32) | Copies a 32-bit floating point value into an array of 16-bit register values
| ToInt16(String, Int32, Boolean) | Convert an ASCII string into an array of 16-bit Modbus registers
| ToInt16(UInt32, Int16 , Int32) | Copies an unsigned 32-bit integer value into an array of 16-bit register values
| ToInt32( Int16 ) | Cast a tuple of 16-bit registers to a signed 32-bit value
| ToInt32( Int16 , Int32) | Cast a tuple of 16-bit register array elements to a signed 32-bit value
| ToSByte | Unpack 8 boolean values into a igned byte
| ToSBytes | Pack an array of bits into an array of 8-bit signed bytes
| ToSingle( Int16 ) | Cast a tuple of 16-bit registers to a 32-bit floating point value
| ToSingle( Int16 , Int32) | Cast a tuple of 16-bit register array elements to a 32-bit floating point value with little-endian word order
| ToUInt16(Int16) | Cast a 16-bit register value to an unsigned 16-bit value
| ToUInt16( Int16 , Int32) | Cast a 16-bit register array element to an unsigned 16-bit value
| ToUInt32( Int16 ) | Cast a tuple of 16-bit registers to an unsigned 32-bit value
| ToUInt32( Int16 , Int32) | Cast a tuple of 16-bit register array elements to an unsigned 32-bit value

Top
Thread Safety
Static members of this type are safe for multi-threaded operations.
See Also

#### Reference

FieldTalk.Modbus.Master Namespace
FieldTalk Modbus Master Library for .NET
Library version 2.15.2