Class: Vissen::Input::Message::ChannelMode

Inherits:
Base
  • Object
show all
Defined in:
lib/vissen/input/message/channel_mode.rb

Overview

From the MIDI Association:

This the same code as the Control Change (above), but implements Mode control and special message by using reserved controller numbers 120-127. The commands are:

  • All Sound Off (120) When All Sound Off is received all oscillators will turn off, and their volume envelopes are set to zero as soon as possible.
  • Reset All Controllers (121) When Reset All Controllers is received, all controller values are reset to their default values.
  • Local Control (122) When Local Control is Off, all devices on a given channel will respond only to data received over MIDI. Played data, etc. will be ignored. Local Control On restores the functions of the normal controllers.
  • All Notes Off (123..127) When an All Notes Off is received, all oscillators will turn off.

Constant Summary collapse

DATA_LENGTH =
2
STATUS =
0xB0

Constants included from Vissen::Input::Message

CHANNEL_MASK, STATUS_MASK

Instance Attribute Summary

Attributes included from Vissen::Input::Message

#data, #timestamp

Instance Method Summary collapse

Methods inherited from Base

[], create, factory, match, match?, matcher, #valid?

Methods included from Vissen::Input::Message

#channel, #fetch, #initialize, #status, #to_h, #valid?

Instance Method Details

#numberInteger

Returns the control number.

Returns:

  • (Integer)

    the control number.



33
34
35
# File 'lib/vissen/input/message/channel_mode.rb', line 33

def number
  data[1]
end