Module Duplex.Message

The Message class is a container for messages, closely related to the ControlMap

See also: Duplex.ControlMap

Functions

__init (device) Initialize Message class
get_numeric_value () [Class] Retrieve the 'default', numeric value for a message v2: It's too obscure what this method does
__eq (other) [Class] Compare with another instance (only check for object identity)
__tostring () [Class] For debugging purposes

Fields

self.context (Duplex.Globals.DEVICE_MESSAGE) the message context
self.xarg (table) Param node attributes, derived from the control-map
self.device (Duplex.Device) reference to the originating device
self.value (table, number or string) the value for the chosen parameter the type of value depend on what type of parameter we are controlling: a slider would have a number, a label a string, xypad a pair of numbers
self.channel (int) the MIDI channel of the message, between 1-16 (derived from the value parameter in the control-map)
self.is_note_off (bool) distinguish between MIDI NOTE-ON/OFF events
self.is_virtual (bool) true when triggered from the virtual control surface
self.midi_msgs (table) the MIDI message payload (each entry a table of 3 bytes) this is either a copy of the message(s) we received from a MIDI controller, or a value being constructed by the virtual control surface
self.timestamp (number) set by os.clock()


Functions

__init (device)
Initialize Message class

Parameters:

  • device (Device)
get_numeric_value ()
[Class] Retrieve the 'default', numeric value for a message v2: It's too obscure what this method does

Returns:

    number or nil
__eq (other)
[Class] Compare with another instance (only check for object identity)

Parameters:

Returns:

    bool
__tostring ()
[Class] For debugging purposes

Fields

self.context
(Duplex.Globals.DEVICE_MESSAGE) the message context
self.xarg
(table) Param node attributes, derived from the control-map

See also:

self.device
(Duplex.Device) reference to the originating device
self.value
(table, number or string) the value for the chosen parameter the type of value depend on what type of parameter we are controlling: a slider would have a number, a label a string, xypad a pair of numbers
self.channel
(int) the MIDI channel of the message, between 1-16 (derived from the value parameter in the control-map)
self.is_note_off
(bool) distinguish between MIDI NOTE-ON/OFF events
self.is_virtual
(bool) true when triggered from the virtual control surface
self.midi_msgs
(table) the MIDI message payload (each entry a table of 3 bytes) this is either a copy of the message(s) we received from a MIDI controller, or a value being constructed by the virtual control surface
self.timestamp
(number) set by os.clock()
generated by LDoc 1.4.2