Code:
// Number of digital inputs. Can be anywhere from 0 to 18.
#define NUM_DI 12
// Number of analogue inputs. Can be anywhere from 0 to 6.
#define NUM_AI 14
#ifdef MIDI_FIGHTER
#define MIDI_CHANNEL 3
// First note, starting from lower left button
#define NOTE NOTE_C2
// When mapping to a MIDI Fighter we need to skip a row of buttons. Set this from 0-3 to define which row to skip.
// Rows are ordered from bottom to top (same as the MIDI Fighter's button layout).
#define SKIP_ROW 2
// This pin order corresponds to the bottom left button being zero, increasing by one as we move from left to right, bottom to top
// 8 9 10 11
// 4 5 6 7
// 0 1 2 3
// This array size must match NUM_DI above.
#define DIGITAL_PIN_ORDER 10, 11, 12, 13, 6, 7, 8, 9, 2, 3, 4, 5
#else
#define MIDI_CHANNEL 1
// First note, starting from upper left button
#define NOTE NOTE_C0
// This pin order corresponds to the top left button being zero, increasing by one as we move from left to right, top to bottom
// 0 1 2 3
// 4 5 6 7
// 8 9 10 11
// This array size must match NUM_DI above.
#define DIGITAL_PIN_ORDER PIN_D0, PIN_D1, PIN_D4, PIN_D5, PIN_D7, PIN_E0, PIN_E1, PIN_C0, PIN_C1, PIN_B3, PIN_B2, PIN_B1
// #define DIGITAL_PIN_ORDER 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53
#endif
#define ANALOGUE_PIN_ORDER A0, A1, A2, A3, A4, A5, A6, aval1, aval2, aval3, aval4, aval5, aval6, aval7, aval8
I underlined and bolded the changes, also if you use any of the digital inputs listed in the code for the mux make sure to take them out of the code. So theoretically if you use those changes and add the code from the arduino forum it should work just fine.
Bookmarks