Sha256: 96d78ece9ae908118b2409cfc513e54d52a427c0f4bf54e5fe4c3eec89815b3e

Contents?: true

Size: 286 Bytes

Versions: 1

Compression:

Stored size: 286 Bytes

Contents

require 'json'

module Nerpin
  module Nrpn
    class Micron < Base
      def value(value)
        {
          :v0x06 => (value >= 0) ? value / 128 : 127 - (value.abs / 128),
          :v0x26 => (value >= 0) ? value % 128 : 128 - (value.abs % 128)
        }
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
nerpin-0.0.1 lib/nerpin/nrpn/micron.rb