More progress on my Mac development path migration: I can now control Ifos slaves from my iMac. This is the culmination of a few related successes, and means
Related, but not specifically required for basic Ifos control via Modbus/Ruby:
There were a few things I had to do:
1) Install ruby-serialport. This is a gem now (that's cool), so installation was trivial. I had to update RubyGems first, though—the version installed by default was slightly too old:
=== 1.3.5 / 2009-07-21
Bug fixes:
* Fix use of prerelease gems.
* Gem.bin_path no longer escapes path with spaces. Bug #25935 and #26458.
Deprecation Notices:
* Bulk index update is no longer supported (the code currently remains, but not
the tests)
* Gem::manage_gems was removed in 1.3.3.
* Time::today was removed in 1.3.3.
------------------------------------------------------------------------------
RubyGems installed the following executables:
/usr/bin/gem18
RubyGems system software updated
peter@McMullen ~ $ sudo gem install ruby-serialport
Building native extensions. This could take a while...
Successfully installed ruby-serialport-0.7.0
1 gem installed
Installing ri documentation for ruby-serialport-0.7.0...
Installing RDoc documentation for ruby-serialport-0.7.0...
peter@McMullen ~ $
2) Include rubygems in modbus.rb. Not unexpected (and a small price to pay) now that we benefit from the new gem nature of serialport. Not much to the diff:
--- modbus.rb (revision 383) +++ modbus.rb (working copy) @@ -21,7 +21,8 @@ -Kernel::require "serialport" +require 'rubygems' +require 'serialport'
Now that I know can control Ifos from the Mac, I can start on the more difficult task of controlling it from the TINI.