Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
RModBus - free implementation of ModBus protocol in pure Ruby
Pull request Compare This branch is even with flipback:rmodbus-0.5.

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
examples
lib
spec
.gitignore
AUTHORS
ChangeLog
LICENSE
README
Rakefile
rmodbus.gemspec

README

= RModBus

*RModBus* - free implementation of protocol ModBus.

== Features

* Support Ruby 1.8, Ruby 1.9
* Support TCP, RTU, RTU over TCP protocols
* Support client(master) and server(slave)
* Support functions:
  * 01 (0x01) Read Coils
  * 02 (0x02) Read Discrete Inputs
  * 03 (0x03) Read Holding Registers
  * 04 (0x04) Read Input Registers 
  * 05 (0x05) Write Single Coil
  * 06 (0x06) Write Single Register
  * 15 (0x0F) Write Multiple Coils
  * 16 (0x10) Write Multiple registers
  * 22 (0x16) Mask Write register 

== Installation

Download and install RModBus with the following

$ gem install --remote rmodbus

== Example

require 'rmodbus'

cl = ModBus::TCPClient.new('127.0.0.1', 8502, 1) do |cl|

  puts cl.read_holding_registers(0,4)

  cl.write_multiple_registers(0, [4,4,4])

end

== GitHub 

You can checkout source code from GitHub repositry 

$ git clone git://github.com/flipback/RModBus.git

== Reference 

Home page: http://rmodbus.heroku.com

RModBus project: http://rubyforge.org/projects/rmodbus

RModBud on GitHub: http://github.com/flipback/RModBus

ModBus community: http://www.modbus-ida.org
Something went wrong with that request. Please try again.