| 
   
    MIDI Control Surface library for Arduino 
   | 
 
 
 
 
Go to the documentation of this file.
  100         uint8_t mask = value >> 7;
 
  101         uint8_t abs = (value + mask) ^ mask;
 
  102         uint8_t sign = mask & 0b01000000;
 
  103         return (abs & 0b00111111) | sign;
 
  120             address = address + 1;
 
  124             long thisDelta = constrain(delta, -15, 15);
 
  
@ MACKIE_CONTROL_RELATIVE
Relative mode used by the Mackie Control Universal protocol.
 
A type-safe utility class for saving a MIDI address consisting of a 7-bit address,...
 
@ NEXT_ADDRESS
Encode negative MIDI CC values by incrementing the address if the number is negative,...
 
static uint8_t toBinaryOffset7bit(int8_t value)
Convert an 8-bit two's complement integer to a 7-bit integer with a binary offset of 64.
 
static void setMode(relativeCCmode mode)
Set the relative CC mode that's used.
 
@ TWOS_COMPLEMENT
Encode negative MIDI CC values as 7-bit two's complement.
 
@ KORG_KONTROL_INC_DEC_1
Korg KONTROL in Inc/Dec mode 1.
 
static void send(long delta, MIDIAddress address)
Send a relative CC message.
 
#define BEGIN_CS_NAMESPACE
 
static uint8_t toSignedMagnitude7bit(int8_t value)
Convert an 8-bit two's complement integer to 7-bit sign-magnitude format.
 
static uint8_t mapRelativeCC(int8_t value)
Convert an 8-bit two's complement integer to a 7-bit value to send over MIDI.
 
static uint8_t toTwosComplement7bit(int8_t value)
Convert an 8-bit two's complement integer to a 7-bit two's complement integer.
 
Control_Surface_ & Control_Surface
A predefined instance of the Control Surface to use in the Arduino sketches.
 
@ BINARY_OFFSET
Encode negative MIDI CC values by adding a fixed offset of .
 
static relativeCCmode mode
 
void sendCC(MIDIAddress address, uint8_t value)
Send a MIDI Control Change event.
 
Class that sends relative/incremental MIDI control change messages.
 
@ TRACKTION_RELATIVE
Relative mode in Tracktion.
 
@ REAPER_RELATIVE_2
Second relative mode in Reaper.
 
@ REAPER_RELATIVE_1
First relative mode in Reaper.
 
@ REAPER_RELATIVE_3
Third relative mode in Reaper.
 
relativeCCmode
The encoding to use for relative control change value.
 
@ SIGN_MAGNITUDE
Encode negative MIDI CC values by using the most significant bit as a sign bit, and the six least sig...