MIDI Control Surface library for Arduino
|
Go to the documentation of this file.
77 uint8_t mask = value >> 7;
78 uint8_t abs = (value + mask) ^ mask;
79 uint8_t sign = mask & 0b01000000;
80 return (abs & 0b00111111) | sign;
97 long thisDelta = constrain(delta, -15, 15);
Relative mode used by the Mackie Control Universal protocol.
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)
Encode negative MIDI CC values as 7-bit two's complement.
#define BEGIN_CS_NAMESPACE
static void send(long delta, MIDICNChannelAddress address)
MIDI_Interface & MIDI()
Get the MIDI interface of the Control Surface.
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.
A type-safe utility class for saving a MIDI address consisting of a 7-bit address,...
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.
Encode negative MIDI CC values by adding a fixed offset of .
static relativeCCmode mode
Relative mode in Tracktion.
Second relative mode in Reaper.
First relative mode in Reaper.
void sendCC(MIDICNChannelAddress address, uint8_t value)
Send a MIDI Control Change event.
Third relative mode in Reaper.
relativeCCmode
The encoding to use for relative control change value.
Encode negative MIDI CC values by using the most significant bit as a sign bit, and the six least sig...