[Company Logo Image]

                               

Sapia Incorporated            

  

Modbus Software Components for Developers

  Home Up Purchase Contact About Services Links

SMRN 

SMRN Download

 

   SMRN Modbus/RTU Master Control

 

SMRN can be used on a form as shown below, or optionally without a form.   At design time, you can access your Modbus device from SMRN's built-in Properties and Test pages. This makes start-up and troubleshooting a snap, all without writing a single line of code!  To further get you going quickly, SMRN also includes an extensive HTML help file and several example projects for VB.NET, C#.NET and C++.NET.

SMRN Can be used on a form or without a form

SMRN Appearance on a form

A powerful set of properties and methods are provided for configuring SMRN and for talking to slave devices at run-time.  Talking to a Modbus/RTU slave is as simple as calling a function with the necessary arguments.  SMRN automatically builds the command, appends a CRC, sends the command out the serial port, and receives and validates the response.  Your program just reads and writes simple 16-bit data values.  The example fragments below show just how easy it is to read holding registers from a Modbus/RTU slave. 

For Modbus devices that use floating point data, SMRN provides RegsToFloat( ) and FloatToRegs( ) conversion methods to handle the job.  These two methods convert two consecutive Input Registers or Holding Registers into a 32-bit, IEEE single precision floating point number, and vice-versa respectively.

Written in Managed C++ and some unmanaged C++ to interface to the Windows OS, SMRN is a real Windows Forms Control that inherits form System.Windows.Forms.UserControl and therefore has all of the usual user control properties and methods in addition to the Modbus specific ones of its own.


Example

[Visual Basic, C#, C++] The following example demonstrates how to read the values of the first six holding registers of slave device 20.

 

[Visual Basic]

Dim RegData(6) As Short     ' holding register data buffer

Dim Err As Short                 ' return error

Err = Me.SmrnControl1.MbReadHoldingRegs(20, 0, 6, RegData)

 

[C#]

short[] RegData = new short[ 6 ];

short Err = smrnControl1.MbReadHoldingRegs(20, 0, 6, RegData);

 

[C++]

short RegData __gc [] = new short __gc [ 6 ];

short Err = smrnControl1->MbReadHoldingRegs(20, 0, 6, RegData);


SMRN provides built-in Property and Test pages for configuration and testing on the development computer or optionally on the run-time computer.  Properties serve as variables for configuring the communications parameters of your PC’s serial port.  The figure below shows the Properties page and the communications properties that it contains.

SMRNCo4.jpg (21817 bytes)

SMRN Properties Page

 

The Test page provides access to the Modbus network and slave devices on the development computer or optionally on the run-time computer. This is convenient for testing out your serial port, network hardware and slave devices before writing any code.  All of the communications methods can be exercised from the Test page.  

 

 

SMRN Test Page

 


 

 

Supported Modbus Commands (decimal)

 

01 – Read Coil Status   (0x references)

02 – Read Input Status   (1x references)

03 – Read Holding Register(s)   (4x references)

04 – Read Input Register(s)   (3x references)

05 – Force Single Coil   (0x references)

06 – Preset Single Register   (4x references)

07 – Read Exception Status

15 – Force Multiple Coils   (0x references)

16 – Preset Multiple Registers   (4x references)

17 – Report Slave ID

 

 


New Version 1.3

Download SMRN Demo here

The SMRN Demo is a complete operating control that has a 90-minute time limit.  After 90 minutes, communication functions will be disabled.  Re-starting the application will initiate another 90-minute demonstration period.


Pricing

Model Description

Price*

SMRN-CD Modbus/RTU Windows Forms  Control for .NET 2003/2005, Single Development Site License (on CD-ROM)

$235

 

SMRN-OL Modbus/RTU Windows Forms  Control for .NET 2003/2005, Single Development Site License (on-line delivery)

$215

* Quantity 1 (US$).  For larger quantities, contact Sapia.

By purchasing a single development site license you may install SMRN and develop your  application with it on a single PC and distribute it with your compiled application program royalty free an unlimited number of times.  Please see the EULA included with the demo for complete licensing information.

 


                             

Send mail to webmaster@sapia-inc.com with questions or comments about this web site.
Copyright © 2008 Sapia, Incorporated
Last modified: July 19, 2008