Class: Integer

Inherits:
Object
  • Object
show all
Defined in:
lib/rmodbus/ext.rb

Instance Method Summary collapse

Instance Method Details

#to_wordObject

Shortcut or turning an integer into a word



42
43
44
# File 'lib/rmodbus/ext.rb', line 42

def to_word
  [self].pack('n')
end