class Object

Public Instance Methods

to_hex(length = 8) click to toggle source

Converts an integer into a hex string with the specified length.

# File lib/hidapi/numeric_extensions.rb, line 6
def to_hex(length = 8)
  to_s(16).rjust(length, '0')
end