~ruther/qmk_firmware

cebc5688a09ce0fb9a6163dcea9155041ba89d5c — 3araht 4 years ago c8a5869
[Keyboard] add bandominedoni keyboard (#13116)

A keyboards/bandominedoni/bandominedoni.c => keyboards/bandominedoni/bandominedoni.c +151 -0
@@ 0,0 1,151 @@
/* Copyright 2021 3araht
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#include "bandominedoni.h"

#ifdef RGB_MATRIX_ENABLE

led_config_t g_led_config = {
    {
        {     75,     46,     45,     44,     43,     42, NO_LED }, \
        {     47,     48,     49,     50,     51,     52,     53 }, \
        {     60,     59,     58,     57,     56,     55,     54 }, \
        {     61,     62,     63,     64,     65,     66,     67 }, \
        {     74,     73,     72,     71,     70,     69,     68 }, \
        { NO_LED, NO_LED, NO_LED, NO_LED, NO_LED, NO_LED, NO_LED }, \
        {      7,      6,      4,      3,      2,      1,      5}, \
        {      8,      9,     10,     11,     12,     13,      0 }, \
        {     19,     18,     17,     16,     15,     14,     41 }, \
        {     20,     21,     22,     23,     24,     25,     40 }, \
        {     30,     29,     28,     27,     26,     39,     38 }, \
        {     31,     32,     33,     34,     35,     36,     37 }
    }, {
        { 145,  6 }, { 157,  5 }, { 153, 14 }, { 149, 22 }, { 145, 32 }, { 136, 35 }, { 139, 48 }, { 134, 61 },
        { 142, 60 }, { 148, 43 }, { 154, 29 }, { 158, 20 }, { 163, 12 }, { 168,  4 },
        { 178,  5 }, { 173, 12 }, { 168, 20 }, { 163, 28 }, { 157, 40 }, { 151, 55 },
        { 160, 52 }, { 166, 39 }, { 172, 28 }, { 177, 20 }, { 182, 13 }, { 188,  7 },
        { 192, 17 }, { 186, 23 }, { 181, 30 }, { 175, 39 }, { 169, 50 },
        { 178, 51 }, { 184, 41 }, { 190, 33 }, { 196, 27 },
        { 199, 37 }, { 193, 45 }, { 187, 53 },
        { 196, 56 }, { 202, 49 },
        { 205, 61 },
        { 202,  4 },
        {  84, 18 }, {  73, 13 }, {  62, 10 }, {  51,  8 }, {  39, 11 }, {  24, 22 },
        {  34, 19 }, {  45, 16 }, {  56, 16 }, {  66, 18 }, {  77, 22 }, {  87, 28 },
        {  92, 40 }, {  81, 32 }, {  71, 27 }, {  61, 24 }, {  51, 24 }, {  41, 24 }, {  30, 28 },
        {  24, 42 }, {  34, 37 }, {  44, 35 }, {  54, 34 }, {  64, 36 }, {  74, 38 }, {  84, 44 },
        {  87, 54 }, {  77, 49 }, {  67, 47 }, {  57, 45 }, {  47, 45 }, {  37, 48 }, {  27, 52 }, {  19, 56 },
    }, {
        4, 4, 4, 4, 4, 4, 4, 4,
        4, 4, 4, 4, 4, 4,
        4, 4, 4, 4, 4, 4,
        4, 4, 4, 4, 4, 4,
        4, 4, 4, 4, 4,
        4, 4, 4, 4,
        4, 4, 4,
        4, 4,
        4,
        4,
        4, 4, 4, 4, 4, 4,
        4, 4, 4, 4, 4, 4,
        4, 4, 4, 4, 4, 4, 4,
        4, 4, 4, 4, 4, 4, 4,
        4, 4, 4, 4, 4, 4, 4, 4
    }
};
#endif

#if defined(SPLIT_HAND_MATRIX_GRID)
static uint8_t peek_matrix_intersection(pin_t out_pin, pin_t in_pin) {
    setPinInputHigh(in_pin);
    setPinOutput(out_pin);
    writePinLow(out_pin);
    // It's almost unnecessary, but wait until it's down to low, just in case.
    wait_us(1);
    uint8_t pin_state = readPin(in_pin);
    // Set out_pin to a setting that is less susceptible to noise.
    setPinInputHigh(out_pin);
    matrix_io_delay();  // Wait for the pull-up to go HIGH.
    return pin_state;
}
#endif

//  Overriding is_keyboard_left() in qmk_firmware/quantum/split_common/split_util.c to limit the handedness check only once.
//  reason: bandoMIneDonI has no space on right hand side to use "SPLIT_HAND_MATRIX_GRID".
//          However, It enables to decide the handedness by the HW by adding one condition: "not to press any keys (especially r30) dusing startup."
bool is_keyboard_left(void) {
static enum { UNKNOWN, LEFT, RIGHT } hand_side = UNKNOWN;

    // only check once, as this is called often
    if (hand_side == UNKNOWN) {
#if defined(SPLIT_HAND_PIN)
        // Test pin SPLIT_HAND_PIN for High/Low, if low it's right hand
        setPinInput(SPLIT_HAND_PIN);
        hand_side = readPin(SPLIT_HAND_PIN) ? LEFT : RIGHT;
        return (hand_side == LEFT);
#elif defined(SPLIT_HAND_MATRIX_GRID)
#    ifdef SPLIT_HAND_MATRIX_GRID_LOW_IS_RIGHT
        hand_side = peek_matrix_intersection(SPLIT_HAND_MATRIX_GRID) ? LEFT : RIGHT;
        return (hand_side == LEFT);
#    else
        hand_side = peek_matrix_intersection(SPLIT_HAND_MATRIX_GRID) ? RIGHT : LEFT;
        return (hand_side == LEFT);
#    endif
#elif defined(EE_HANDS)
        hand_side = eeconfig_read_handedness() ? LEFT : RIGHT;
        return (hand_side == LEFT);
#elif defined(MASTER_RIGHT)
        hand_side = !is_keyboard_master() ? LEFT : RIGHT;
        return (hand_side == LEFT);
#endif
        hand_side = is_keyboard_master() ? LEFT : RIGHT;
        return (hand_side == LEFT);
    } else {
        return (hand_side == LEFT);
    }
}

#ifdef ENCODER_ENABLE
const uint16_t rt_matrix[2][2] = {
    {5, 5}, {5, 6}
};

bool encoder_update_kb(uint8_t index, bool clockwise) {
    if (index == 1) { /* An encoder on the right side */
        keypos_t key;
        int cw = 0;
        cw = clockwise ? 1 : 0;
        key.row = rt_matrix[cw][0];
        key.col = rt_matrix[cw][1];
        uint8_t layer = layer_switch_get_layer(key);
        uint16_t keycode = keymap_key_to_keycode(layer, key);
        keyrecord_t record;
        record.event.key = key;

        if (keycode < MI_ON){
            tap_code16(keycode);
        } else {
            record.event.pressed = true;
            process_midi(keycode, &record);
            wait_ms(TAP_CODE_DELAY);
            record.event.pressed = false;
            process_midi(keycode, &record);
        }

    }
    return true;
}
#endif  // ENCODER_ENABLE

A keyboards/bandominedoni/bandominedoni.h => keyboards/bandominedoni/bandominedoni.h +84 -0
@@ 0,0 1,84 @@
/* Copyright 2021 3araht
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#pragma once

#include "quantum.h"

/* This is a shortcut to help you visually see your layout.
 *
 * The first section contains all of the arguments representing the physical
 * layout of the board and position of the keys.
 *
 * The second converts the arguments into a two-dimensional array which
 * represents the switch matrix.
 */

//  oc: for Open Close selection pedal
//  fn: function layer

#define LAYOUT( \
              l00, l01, l02, l03, l04, \
      l10, l11, l12, l13, l14, l15, l16, \
         l20, l21, l22, l23, l24, l25, l26, \
      l30, l31, l32, l33, l34, l35, l36, \
    l40, l41, l42, l43, l44, l45, l46, l47,  \
    \
    oc,         r00, r01, r02, r03,         fn, \
             r10, r11, r12, r13, r14,      ccw, cw,\
           r20, r21, r22, r23, r24, r25, \
    r30, r31, r32, r33, r34, r35, r36, r37, \
      r40, r41, r42, r43, r44, r45, r46, r47, \
    r50, r51, r52, r53, r54, r55, r56, r57, r58 \
) { \
    {   l40,   l00,   l01,   l02,   l03,   l04, KC_NO }, \
    {   l10,   l11,   l12,   l13,   l14,   l15,   l16 }, \
    {   l20,   l21,   l22,   l23,   l24,   l25,   l26 }, \
    {   l30,   l31,   l32,   l33,   l34,   l35,   l36 }, \
    {   l41,   l42,   l43,   l44,   l45,   l46,   l47 }, \
    { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO,   ccw,    cw }, \
    {   r50,   r40,   r31,   r20,   r10,   r00,   r30 }, \
    {   r51,   r41,   r32,   r21,   r11,   r01,    oc }, \
    {   r52,   r42,   r33,   r22,   r12,   r02,    fn }, \
    {   r53,   r43,   r34,   r23,   r13,   r03,   r58 }, \
    {   r54,   r44,   r35,   r24,   r14,   r47,   r57 }, \
    {   r55,   r45,   r36,   r25,   r37,   r46,   r56 }  \
}

//  Uncomment below if a pedal used for Open/Close is normally-on type (such as Yamaha's.)
// #define PEDAL_NORMALLY_CLOSED

#ifdef PEDAL_NORMALLY_CLOSED
#   define MO_SWAP  MO(_OPEN)
#   define DF_SWAP  DF(_CLOSE)
#   define TG_SWAP  TG(_OPEN)
#else
#   define MO_SWAP  MO(_CLOSE)
#   define DF_SWAP  DF(_OPEN)
#   define TG_SWAP  TG(_CLOSE)
#endif

// Long press: go to _FN layer, tap: MUTE
#define FN_MUTE  LT(_FN, KC_MUTE)
#define DF_QWER  DF(_QWERTY)
#define MIS_EIS  LT(_MISC,KC_LANG2)
#define MIS_KAN  LT(_MISC,KC_LANG1)


//  Overriding is_keyboard_left() in qmk_firmware/quantum/split_common/split_util.c to limit the handedness check only once.
//  reason: bandoMIneDonI has no space on right hand side to use "SPLIT_HAND_MATRIX_GRID".
//          However, It enables to decide the handedness by the HW by adding one condition: "not to press any keys (especially r30) dusing startup."
bool is_keyboard_left(void);

A keyboards/bandominedoni/config.h => keyboards/bandominedoni/config.h +365 -0
@@ 0,0 1,365 @@
/* Copyright 2021 3araht
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
#pragma once

#include "config_common.h"

/* USB Device descriptor parameter */
#define VENDOR_ID    0xFEED
#define PRODUCT_ID   0xF4B5
#define DEVICE_VER   0x0001
#define MANUFACTURER 3araht
#define PRODUCT      bandominedoni

/* key matrix size */
#define MATRIX_ROWS 12
#define MATRIX_COLS 7

/*
 * Keyboard Matrix Assignments
 *
 * Change this to how you wired your keyboard
 * COLS: AVR pins used for columns, left to right
 * ROWS: AVR pins used for rows, top to bottom
 * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
 *                  ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
 *
 */
#define MATRIX_ROW_PINS { B5, B4, D7, F6, C6, D4 }
#define MATRIX_COL_PINS { D1, E6, F7, B1, B3, B2, D0 }
#define UNUSED_PINS

#define MASTER_RIGHT
#ifndef MASTER_RIGHT
//  SPLIT_HAND_MATRIX_GRID was initially designed to use with left hand side diode D35 mounted and not pressing K7 on the right hand side during boot. However when a USB cable is reconnected immediately, it fails. Decided to use "MASTER_RIGHT" to make it more reliable.
#   define SPLIT_HAND_MATRIX_GRID B5, D0
#endif

/* COL2ROW, ROW2COL */
#define DIODE_DIRECTION COL2ROW

/*
 * Split Keyboard specific options, make sure you have 'SPLIT_KEYBOARD = yes' in your rules.mk, and define SOFT_SERIAL_PIN.
 */
#define SOFT_SERIAL_PIN D2  // or D1, D2, D3, E6

//#define LED_NUM_LOCK_PIN B0
//#define LED_CAPS_LOCK_PIN B1
//#define LED_SCROLL_LOCK_PIN B2
//#define LED_COMPOSE_PIN B3
//#define LED_KANA_PIN B4

//#define BACKLIGHT_PIN B7
//#define BACKLIGHT_LEVELS 3
//#define BACKLIGHT_BREATHING

#define RGB_DI_PIN D3
//#ifdef RGB_DI_PIN
//#    define RGBLED_NUM 16
//#    define RGBLIGHT_HUE_STEP 8
//#    define RGBLIGHT_SAT_STEP 8
//#    define RGBLIGHT_VAL_STEP 8
//#    define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */
//#    define RGBLIGHT_SLEEP  /* If defined, the RGB lighting will be switched off when the host goes to sleep */
/*== all animations enable ==*/
//#    define RGBLIGHT_ANIMATIONS
/*== or choose animations ==*/
//#    define RGBLIGHT_EFFECT_BREATHING
//#    define RGBLIGHT_EFFECT_RAINBOW_MOOD
//#    define RGBLIGHT_EFFECT_RAINBOW_SWIRL
//#    define RGBLIGHT_EFFECT_SNAKE
//#    define RGBLIGHT_EFFECT_KNIGHT
//#    define RGBLIGHT_EFFECT_CHRISTMAS
//#    define RGBLIGHT_EFFECT_STATIC_GRADIENT
//#    define RGBLIGHT_EFFECT_RGB_TEST
//#    define RGBLIGHT_EFFECT_ALTERNATING
/*== customize breathing effect ==*/
/*==== (DEFAULT) use fixed table instead of exp() and sin() ====*/
//#    define RGBLIGHT_BREATHE_TABLE_SIZE 256      // 256(default) or 128 or 64
/*==== use exp() and sin() ====*/
//#    define RGBLIGHT_EFFECT_BREATHE_CENTER 1.85  // 1 to 2.7
//#    define RGBLIGHT_EFFECT_BREATHE_MAX    255   // 0 to 255
//#endif

#ifdef RGB_MATRIX_ENABLE

/* ws2812 RGB MATRIX */
#   define DRIVER_LED_TOTAL 76

 // reacts to keypresses
#   define RGB_MATRIX_KEYPRESSES

//  for all fingers used at once.
#   define LED_HITS_TO_REMEMBER 10

#   define RGB_MATRIX_MAXIMUM_BRIGHTNESS 50
#   define RGB_MATRIX_STARTUP_SPD 127
// the above brighness setting has no effect on rgb_matrix_set_color().
// Use darker colors instead.
/*              RGB darker COLORS             */
#   define RGB_DARKWHITE 0x33, 0x33, 0x33
#   define RGB_DARKRED 0x33, 0x0, 0x0
#   define RGB_DARKCORAL 0x33, 0x18, 0xF
#   define RGB_DARKORANGE 0x33, 0x19, 0x0
#   define RGB_DARKGOLDENROD 0x2B, 0x21, 0x6
#   define RGB_DARKGOLD 0x33, 0x2B, 0x0
#   define RGB_DARKYELLOW 0x33, 0x33, 0x0
#   define RGB_DARKCHARTREUSE 0x19, 0x33, 0x0
#   define RGB_DARKGREEN 0x0, 0x33, 0x0
#   define RGB_DARKSPRINGGREEN 0x0, 0x33, 0x19
#   define RGB_DARKTURQUOISE 0xE, 0x16, 0x15
#   define RGB_DARKTEAL 0x0, 0x19, 0x19
#   define RGB_DARKCYAN 0x0, 0x33, 0x33
#   define RGB_DARKAZURE 0x1E, 0x31, 0x33
#   define RGB_DARKBLUE 0x0, 0x0, 0x33
#   define RGB_DARKPURPLE 0x18, 0x0, 0x33
#   define RGB_DARKMAGENTA 0x33, 0x0, 0x33
#   define RGB_DARKPINK 0x33, 0x19, 0x26

//  https://docs.qmk.fm/#/feature_rgb_matrix
//  Enable suspend mode.
#   define RGB_DISABLE_WHEN_USB_SUSPENDED true

// //  enable below to shrink the firmware size ( -1974 bytes )
// #    define REDUCE_RGB_MATRIX_EFFECTS

//  enable below to shrink the firmware size ( -1574 bytes )
// #    define REDUCE_RGB_MATRIX_EFFECTS_2

// #    ifdef AUDIO_ENABLE
#   ifdef CONSOLE_ENABLE
// #        define DISABLE_RGB_MATRIX_SOLID_COLOR
#       define DISABLE_RGB_MATRIX_ALPHAS_MODS
#       define DISABLE_RGB_MATRIX_GRADIENT_UP_DOWN
#       define DISABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT
#       define DISABLE_RGB_MATRIX_BREATHING
#       define DISABLE_RGB_MATRIX_BAND_SAT
#       define DISABLE_RGB_MATRIX_BAND_VAL
#       define DISABLE_RGB_MATRIX_BAND_PINWHEEL_SAT
#       define DISABLE_RGB_MATRIX_BAND_PINWHEEL_VAL
#       define DISABLE_RGB_MATRIX_BAND_SPIRAL_SAT
#       define DISABLE_RGB_MATRIX_BAND_SPIRAL_VAL
#       define DISABLE_RGB_MATRIX_CYCLE_ALL
#       define DISABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT
#       define DISABLE_RGB_MATRIX_CYCLE_UP_DOWN
#       define DISABLE_RGB_MATRIX_CYCLE_OUT_IN
#       define DISABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL
#       define DISABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON
#       define DISABLE_RGB_MATRIX_DUAL_BEACON
#       define DISABLE_RGB_MATRIX_CYCLE_PINWHEEL
#       define DISABLE_RGB_MATRIX_CYCLE_SPIRAL
#       define DISABLE_RGB_MATRIX_RAINBOW_BEACON
#       define DISABLE_RGB_MATRIX_RAINBOW_PINWHEELS
#       define DISABLE_RGB_MATRIX_RAINDROPS
#       define DISABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS
#       define DISABLE_RGB_MATRIX_HUE_BREATHING
#       define DISABLE_RGB_MATRIX_HUE_PENDULUM
#       define DISABLE_RGB_MATRIX_HUE_WAVE
#       define DISABLE_RGB_MATRIX_TYPING_HEATMAP
#       define DISABLE_RGB_MATRIX_DIGITAL_RAIN
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
// #        define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
#       define DISABLE_RGB_MATRIX_SPLASH
#       define DISABLE_RGB_MATRIX_MULTISPLASH
#       define DISABLE_RGB_MATRIX_SOLID_SPLASH
#       define DISABLE_RGB_MATRIX_SOLID_MULTISPLASH
#   else
#       define DISABLE_RGB_MATRIX_SOLID_COLOR
#       define DISABLE_RGB_MATRIX_ALPHAS_MODS
#       define DISABLE_RGB_MATRIX_GRADIENT_UP_DOWN
#       define DISABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT
#       define DISABLE_RGB_MATRIX_BREATHING
#       define DISABLE_RGB_MATRIX_BAND_SAT
#       define DISABLE_RGB_MATRIX_BAND_PINWHEEL_SAT
#       define DISABLE_RGB_MATRIX_BAND_SPIRAL_SAT
#       define DISABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT
#       define DISABLE_RGB_MATRIX_RAINBOW_PINWHEELS

//  RAINDROPS don't match well with layer LED indicator (oc) using rgb_matrix_set_color().
#       define DISABLE_RGB_MATRIX_RAINDROPS
#       define DISABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS
//  Recommendend not to use then.

#       if defined(REDUCE_RGB_MATRIX_EFFECTS) || defined(VIA_ENABLE)
// #       ifdef REDUCE_RGB_MATRIX_EFFECTS
#           define DISABLE_RGB_MATRIX_BAND_PINWHEEL_VAL
#           define DISABLE_RGB_MATRIX_BAND_SPIRAL_VAL
#           define DISABLE_RGB_MATRIX_CYCLE_OUT_IN
#           define DISABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL
#           define DISABLE_RGB_MATRIX_DUAL_BEACON
#           define DISABLE_RGB_MATRIX_CYCLE_PINWHEEL
#           define DISABLE_RGB_MATRIX_CYCLE_SPIRAL
#       endif

#       define DISABLE_RGB_MATRIX_HUE_BREATHING
#       define DISABLE_RGB_MATRIX_HUE_PENDULUM
#       define DISABLE_RGB_MATRIX_HUE_WAVE
#       define DISABLE_RGB_MATRIX_TYPING_HEATMAP
#       define DISABLE_RGB_MATRIX_DIGITAL_RAIN
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
#       define DISABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS

#       if defined(REDUCE_RGB_MATRIX_EFFECTS_2) || defined(VIA_ENABLE)
// #       ifdef REDUCE_RGB_MATRIX_EFFECTS_2
#           define DISABLE_RGB_MATRIX_BAND_VAL
#           define DISABLE_RGB_MATRIX_CYCLE_ALL
#           define DISABLE_RGB_MATRIX_CYCLE_UP_DOWN
#           define DISABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON
#           define DISABLE_RGB_MATRIX_RAINBOW_BEACON
#           define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
#           define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
#           define DISABLE_RGB_MATRIX_MULTISPLASH
#           define DISABLE_RGB_MATRIX_SOLID_MULTISPLASH
#       endif
// #           define DISABLE_RGB_MATRIX_SOLID_REACTIVE
#       define DISABLE_RGB_MATRIX_SPLASH
#       define DISABLE_RGB_MATRIX_SOLID_SPLASH
#   endif  // AUDIO_ENABLE

// #define DISABLE_RGB_MATRIX_SOLID_COLOR
// #define DISABLE_RGB_MATRIX_ALPHAS_MODS
// #define DISABLE_RGB_MATRIX_GRADIENT_UP_DOWN
// #define DISABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT
// #define DISABLE_RGB_MATRIX_BREATHING
// #define DISABLE_RGB_MATRIX_BAND_SAT  // white background ver. of _BAND_VAL
// #define DISABLE_RGB_MATRIX_BAND_VAL
// #define DISABLE_RGB_MATRIX_BAND_PINWHEEL_SAT
// #define DISABLE_RGB_MATRIX_BAND_PINWHEEL_VAL
// #define DISABLE_RGB_MATRIX_BAND_SPIRAL_SAT
// #define DISABLE_RGB_MATRIX_BAND_SPIRAL_VAL
// #define DISABLE_RGB_MATRIX_CYCLE_ALL
// #define DISABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT
// #define DISABLE_RGB_MATRIX_CYCLE_UP_DOWN
// #define DISABLE_RGB_MATRIX_CYCLE_OUT_IN
// #define DISABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL
// #define DISABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON
// #define DISABLE_RGB_MATRIX_DUAL_BEACON
// #define DISABLE_RGB_MATRIX_CYCLE_PINWHEEL
// #define DISABLE_RGB_MATRIX_CYCLE_SPIRAL
// #define DISABLE_RGB_MATRIX_RAINBOW_BEACON
// #define DISABLE_RGB_MATRIX_RAINBOW_PINWHEELS
// #define DISABLE_RGB_MATRIX_RAINDROPS
// #define DISABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS  //White ver of above.
// #define DISABLE_RGB_MATRIX_HUE_BREATHING
// #define DISABLE_RGB_MATRIX_HUE_PENDULUM
// #define DISABLE_RGB_MATRIX_HUE_WAVE
// #define DISABLE_RGB_MATRIX_TYPING_HEATMAP
// #define DISABLE_RGB_MATRIX_DIGITAL_RAIN
// #define DISABLE_RGB_MATRIX_SOLID_REACTIVE
// #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
// #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
// #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
// #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
// #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
// #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
// #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
// #define DISABLE_RGB_MATRIX_SPLASH
// #define DISABLE_RGB_MATRIX_MULTISPLASH
// #define DISABLE_RGB_MATRIX_SOLID_SPLASH
// #define DISABLE_RGB_MATRIX_SOLID_MULTISPLASH
#endif  // RGB_MATRIX_ENABLE

/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
#define DEBOUNCE 5

/* define if matrix has ghost (lacks anti-ghosting diodes) */
//#define MATRIX_HAS_GHOST

/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
// #define LOCKING_SUPPORT_ENABLE
/* Locking resynchronize hack */
// #define LOCKING_RESYNC_ENABLE

/* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
 * This is useful for the Windows task manager shortcut (ctrl+shift+esc).
 */
//#define GRAVE_ESC_CTRL_OVERRIDE

/*
 * Force NKRO
 *
 * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
 * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
 * makefile for this to work.)
 *
 * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
 * until the next keyboard reset.
 *
 * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
 * fully operational during normal computer usage.
 *
 * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
 * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
 * bootmagic, NKRO mode will always be enabled until it is toggled again during a
 * power-up.
 *
 */
//#define FORCE_NKRO

/*
 * Feature disable options
 *  These options are also useful to firmware size reduction.
 */

/* disable debug print */
//#define NO_DEBUG

/* disable print */
//#define NO_PRINT

/* disable action features */
//#define NO_ACTION_LAYER

/* 2021/01/22 added to shrink firmware size */
// NO_ACTION_TAPPING -1964 bytes, however, this disables Layer mods...
// #define NO_ACTION_TAPPING
// NO_ACTION_ONESHOT -388 bytes
#define NO_ACTION_ONESHOT

/* disable these deprecated features by default */
#define NO_ACTION_MACRO
#define NO_ACTION_FUNCTION

/* Bootmagic Lite key configuration */
//#define BOOTMAGIC_LITE_ROW 0
//#define BOOTMAGIC_LITE_COLUMN 0

#ifdef MIDI_ENABLE
#   define MIDI_ADVANCED
// Initial velocity value (avoid using 127 since it is used as a special number in some sound sources.)
#   define MIDI_INITIAL_VELOCITY 117
#endif  //  MIDI_ENABLE

/*
 * Encoder options
 */
#ifdef ENCODER_ENABLE
#   define ENCODERS_PAD_A { C7 }  // dummy
#   define ENCODERS_PAD_B { B7 }  // dummy
#   define ENCODERS_PAD_A_RIGHT { F5 }
#   define ENCODERS_PAD_B_RIGHT { F4 }
#   define ENCODER_RESOLUTION 4
#   define TAP_CODE_DELAY 10
#endif  // ENCODER_ENABLE

A keyboards/bandominedoni/info.json => keyboards/bandominedoni/info.json +102 -0
@@ 0,0 1,102 @@
{
    "keyboard_name": "bandominedoni",
    "url": "https://github.com/3araht",
    "maintainer": "3araht",
    "layouts": {
        "LAYOUT": {
            "layout": [
                {"label": "l00", "x": 2, "y": 0.5},
                {"label": "l01", "x": 3, "y": 0.5},
                {"label": "l02", "x": 4, "y": 0.5},
                {"label": "l03", "x": 5, "y": 0.5},
                {"label": "l04", "x": 6, "y": 0.5},

                {"label": "l10", "x": 0.5, "y": 1.5},
                {"label": "l11", "x": 1.5, "y": 1.5},
                {"label": "l12", "x": 2.5, "y": 1.5},
                {"label": "l13", "x": 3.5, "y": 1.5},
                {"label": "l14", "x": 4.5, "y": 1.5},
                {"label": "l15", "x": 5.5, "y": 1.5},
                {"label": "l16", "x": 6.5, "y": 1.5},

                {"label": "l20", "x": 1, "y": 2.5},
                {"label": "l21", "x": 2, "y": 2.5},
                {"label": "l22", "x": 3, "y": 2.5},
                {"label": "l23", "x": 4, "y": 2.5},
                {"label": "l24", "x": 5, "y": 2.5},
                {"label": "l25", "x": 6, "y": 2.5},
                {"label": "l26", "x": 7, "y": 2.5},

                {"label": "l30", "x": 0.5, "y": 3.5},
                {"label": "l31", "x": 1.5, "y": 3.5},
                {"label": "l32", "x": 2.5, "y": 3.5},
                {"label": "l33", "x": 3.5, "y": 3.5},
                {"label": "l34", "x": 4.5, "y": 3.5},
                {"label": "l35", "x": 5.5, "y": 3.5},
                {"label": "l36", "x": 6.5, "y": 3.5},

                {"label": "l40", "x": 0, "y": 4.5},
                {"label": "l41", "x": 1, "y": 4.5},
                {"label": "l42", "x": 2, "y": 4.5},
                {"label": "l43", "x": 3, "y": 4.5},
                {"label": "l44", "x": 4, "y": 4.5},
                {"label": "l45", "x": 5, "y": 4.5},
                {"label": "l46", "x": 6, "y": 4.5},
                {"label": "l47", "x": 7, "y": 4.5},

                {"label": "oc", "x": 9, "y": 0},

                {"label": "r00", "x": 11.5, "y": 0},
                {"label": "r01", "x": 12.5, "y": 0},
                {"label": "r02", "x": 13.5, "y": 0},
                {"label": "r03", "x": 14.5, "y": 0},

                {"label": "fn", "x": 17, "y": 0},

                {"label": "r10", "x": 11, "y": 1},
                {"label": "r11", "x": 12, "y": 1},
                {"label": "r12", "x": 13, "y": 1},
                {"label": "r13", "x": 14, "y": 1},
                {"label": "r14", "x": 15, "y": 1},

                {"label": "ccw", "x": 16.5, "y": 1},
                {"label": "cw", "x": 17.5, "y": 1},

                {"label": "r20", "x": 10.5, "y": 2},
                {"label": "r21", "x": 11.5, "y": 2},
                {"label": "r22", "x": 12.5, "y": 2},
                {"label": "r23", "x": 13.5, "y": 2},
                {"label": "r24", "x": 14.5, "y": 2},
                {"label": "r25", "x": 15.5, "y": 2},

                {"label": "r30", "x": 9, "y": 3},
                {"label": "r31", "x": 10, "y": 3},
                {"label": "r32", "x": 11, "y": 3},
                {"label": "r33", "x": 12, "y": 3},
                {"label": "r34", "x": 13, "y": 3},
                {"label": "r35", "x": 14, "y": 3},
                {"label": "r36", "x": 15, "y": 3},
                {"label": "r37", "x": 16, "y": 3},

                {"label": "r40", "x": 9.5, "y": 4},
                {"label": "r41", "x": 10.5, "y": 4},
                {"label": "r42", "x": 11.5, "y": 4},
                {"label": "r43", "x": 12.5, "y": 4},
                {"label": "r44", "x": 13.5, "y": 4},
                {"label": "r45", "x": 14.5, "y": 4},
                {"label": "r46", "x": 15.5, "y": 4},
                {"label": "r47", "x": 16.5, "y": 4},

                {"label": "r50", "x": 9, "y": 5},
                {"label": "r51", "x": 10, "y": 5},
                {"label": "r52", "x": 11, "y": 5},
                {"label": "r53", "x": 12, "y": 5},
                {"label": "r54", "x": 13, "y": 5},
                {"label": "r55", "x": 14, "y": 5},
                {"label": "r56", "x": 15, "y": 5},
                {"label": "r57", "x": 16, "y": 5},
                {"label": "r58", "x": 17, "y": 5}
            ]
        }
    }
}

A keyboards/bandominedoni/keymaps/default/keymap.c => keyboards/bandominedoni/keymaps/default/keymap.c +84 -0
@@ 0,0 1,84 @@
/* Copyright 2021 3araht
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
#include QMK_KEYBOARD_H

// Defines names for use in layer keycodes and the keymap
enum layer_names {
#ifndef PEDAL_NORMALLY_CLOSED
    _OPEN,
#endif
    _CLOSE,
#ifdef PEDAL_NORMALLY_CLOSED
    _OPEN,
#endif
    _FN
};


const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
    [_OPEN] = LAYOUT(
                  MI_Gs_1, MI_As_1, MI_Cs_2, MI_F_2, MI_Gs_3,
       MI_E_1, MI_A_1, MI_G_2, MI_Ds_2, MI_F_3, MI_As_2, MI_F_1,
         MI_D_2, MI_A_2, MI_C_3, MI_E_3, MI_C_2, MI_G_1, TG_SWAP,
       MI_E_2, MI_Gs_2, MI_B_2, MI_D_3, MI_Fs_3, MI_Cs_3, MI_Fs_1,
     MI_D_1, MI_B_1, MI_G_3, MI_A_3, MI_Ds_3, MI_Fs_2, MI_Ds_1, MI_C_1,

     MO_SWAP,    MI_B_5, MI_Gs_5, MI_G_5, MI_F_5,     FN_MUTE,
         MI_Cs_3, MI_A_5, MI_Fs_5, MI_E_5, MI_Ds_5, KC_VOLD, KC_VOLU,
        MI_C_3, MI_D_3, MI_G_3, MI_As_4, MI_C_5, MI_D_5,
     TG_SWAP, MI_B_2, MI_E_3, MI_Cs_4, MI_Fs_3, MI_A_3, MI_C_4, MI_E_4,
       MI_A_2, MI_F_3, MI_As_3, MI_Gs_3, MI_B_3, MI_D_4, MI_Gs_4, MI_B_4,
     MI_Gs_2, MI_As_2, MI_Ds_3, MI_F_4, MI_Ds_4, MI_Fs_4, MI_A_4, MI_Cs_5, MI_G_4
    ),

    [_CLOSE] = LAYOUT(
                  MI_Gs_1, MI_As_1, MI_Ds_2, MI_Ds_3, MI_G_3,
       MI_D_1, MI_D_2, MI_As_2, MI_C_3, MI_Cs_2, MI_C_2, MI_Fs_1,
         MI_G_1, MI_G_2, MI_B_2, MI_D_3, MI_F_3, MI_Fs_2, TG_SWAP,
       MI_A_1, MI_E_2, MI_A_2, MI_Cs_3, MI_E_3, MI_Gs_2, MI_B_1,
     MI_E_1, MI_E_2, MI_Fs_3, MI_Gs_3, MI_B_3, MI_F_2, MI_Cs_1, MI_F_1,

     MO_SWAP,    MI_A_5, MI_Gs_5, MI_Fs_5, MI_F_5,     FN_MUTE,
         MI_C_3, MI_G_5, MI_As_4, MI_C_5, MI_Ds_5, KC_VOLD, KC_VOLU,
        MI_D_3, MI_Cs_3, MI_Gs_3, MI_As_3, MI_C_4, MI_D_5,
     TG_SWAP, MI_B_2, MI_Fs_3, MI_Fs_4, MI_G_3, MI_B_3, MI_D_4, MI_G_4,
       MI_A_2, MI_F_3, MI_E_3, MI_A_3, MI_Cs_4, MI_E_4, MI_A_4, MI_Cs_5,
     MI_Gs_2, MI_As_2, MI_Ds_3, MI_F_4, MI_E_4, MI_Gs_4, MI_B_4, MI_E_5, MI_Ds_4
    ),

    [_FN] = LAYOUT(
                   DF_SWAP, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
       XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
          XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______,
       XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
     XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,

     _______,        MI_OCTD, MI_OCTU, MI_VELD, MI_VELU,         _______,
                   XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
                XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
     _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
            XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
          XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
    )
};

void keyboard_post_init_user(void) {
    //  Set octave to MI_OCT_0
    midi_config.octave = MI_OCT_0 - MIDI_OCTAVE_MIN;

    // avoid using 127 since it is used as a special number in some sound sources.
    midi_config.velocity = MIDI_INITIAL_VELOCITY;
};

A keyboards/bandominedoni/keymaps/default/readme.md => keyboards/bandominedoni/keymaps/default/readme.md +1 -0
@@ 0,0 1,1 @@
# The default keymap for bandominedoni

A keyboards/bandominedoni/keymaps/led/keymap.c => keyboards/bandominedoni/keymaps/led/keymap.c +221 -0
@@ 0,0 1,221 @@
/* Copyright 2021 3araht
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
#include QMK_KEYBOARD_H

#define DF_COLE  DF(_COLEMAK)

#define _________________QWERTY_L1_________________ KC_Q,    KC_W,    KC_E,    KC_R,    KC_T
#define _________________QWERTY_L2_________________ KC_A,    KC_S,    KC_D,    KC_F,    KC_G
#define _________________QWERTY_L3_________________ KC_Z,    KC_X,    KC_C,    KC_V,    KC_B

#define _________________QWERTY_R1_________________ KC_Y,    KC_U,    KC_I,    KC_O,    KC_P
#define _________________QWERTY_R2_________________ KC_H,    KC_J,    KC_K,    KC_L,    KC_SCLN
#define _________________QWERTY_R3_________________ KC_N,    KC_M,    KC_COMM, KC_DOT,  KC_SLSH

#define _________________COLEMAK_L1________________ KC_Q,    KC_W,    KC_F,    KC_P,    KC_G
#define _________________COLEMAK_L2________________ KC_A,    KC_R,    KC_S,    KC_T,    KC_D
#define _________________COLEMAK_L3________________ KC_Z,    KC_X,    KC_C,    KC_V,    KC_B

#define _________________COLEMAK_R1________________ KC_J,    KC_L,    KC_U,    KC_Y,    KC_SCLN
#define _________________COLEMAK_R2________________ KC_H,    KC_N,    KC_E,    KC_I,    KC_O
#define _________________COLEMAK_R3________________ KC_K,    KC_M,    KC_COMM, KC_DOT,  KC_SLSH

#define _________________NUMBER_L__________________ KC_1,    KC_2,    KC_3,    KC_4,    KC_5
// #define _________________NUMBER_R__________________ KC_6,    KC_7,    KC_8,    KC_9,    KC_0

#define _________________FUNC__L___________________ KC_F1,   KC_F2,   KC_F3,   KC_F4,   KC_F5
// #define _________________FUNC__R___________________ KC_F6,   KC_F7,   KC_F8,   KC_F9,   KC_F10

// Defines names for use in layer keycodes and the keymap
enum layer_names {
#ifndef PEDAL_NORMALLY_CLOSED
    _OPEN,
#endif
    _CLOSE,
#ifdef PEDAL_NORMALLY_CLOSED
    _OPEN,
#endif
     _QWERTY,
     _COLEMAK,
     _MISC,
     _FN
};

// Alias layout macros that expand groups of keys.
#define LAYOUT_wrapper(...) LAYOUT(__VA_ARGS__)

const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
    [_OPEN] = LAYOUT(
                  MI_Gs_1, MI_As_1, MI_Cs_2, MI_F_2, MI_Gs_3,
       MI_E_1, MI_A_1, MI_G_2, MI_Ds_2, MI_F_3, MI_As_2, MI_F_1,
         MI_D_2, MI_A_2, MI_C_3, MI_E_3, MI_C_2, MI_G_1, TG_SWAP,
       MI_E_2, MI_Gs_2, MI_B_2, MI_D_3, MI_Fs_3, MI_Cs_3, MI_Fs_1,
     MI_D_1, MI_B_1, MI_G_3, MI_A_3, MI_Ds_3, MI_Fs_2, MI_Ds_1, MI_C_1,

     MO_SWAP,    MI_B_5, MI_Gs_5, MI_G_5, MI_F_5,     FN_MUTE,
         MI_Cs_3, MI_A_5, MI_Fs_5, MI_E_5, MI_Ds_5, KC_VOLD, KC_VOLU,
        MI_C_3, MI_D_3, MI_G_3, MI_As_4, MI_C_5, MI_D_5,
     TG_SWAP, MI_B_2, MI_E_3, MI_Cs_4, MI_Fs_3, MI_A_3, MI_C_4, MI_E_4,
       MI_A_2, MI_F_3, MI_As_3, MI_Gs_3, MI_B_3, MI_D_4, MI_Gs_4, MI_B_4,
     MI_Gs_2, MI_As_2, MI_Ds_3, MI_F_4, MI_Ds_4, MI_Fs_4, MI_A_4, MI_Cs_5, MI_G_4
    ),

    [_CLOSE] = LAYOUT(
                  MI_Gs_1, MI_As_1, MI_Ds_2, MI_Ds_3, MI_G_3,
       MI_D_1, MI_D_2, MI_As_2, MI_C_3, MI_Cs_2, MI_C_2, MI_Fs_1,
         MI_G_1, MI_G_2, MI_B_2, MI_D_3, MI_F_3, MI_Fs_2, TG_SWAP,
       MI_A_1, MI_E_2, MI_A_2, MI_Cs_3, MI_E_3, MI_Gs_2, MI_B_1,
     MI_E_1, MI_E_2, MI_Fs_3, MI_Gs_3, MI_B_3, MI_F_2, MI_Cs_1, MI_F_1,

     MO_SWAP,    MI_A_5, MI_Gs_5, MI_Fs_5, MI_F_5,     FN_MUTE,
         MI_C_3, MI_G_5, MI_As_4, MI_C_5, MI_Ds_5, KC_VOLD, KC_VOLU,
        MI_D_3, MI_Cs_3, MI_Gs_3, MI_As_3, MI_C_4, MI_D_5,
     TG_SWAP, MI_B_2, MI_Fs_3, MI_Fs_4, MI_G_3, MI_B_3, MI_D_4, MI_G_4,
       MI_A_2, MI_F_3, MI_E_3, MI_A_3, MI_Cs_4, MI_E_4, MI_A_4, MI_Cs_5,
     MI_Gs_2, MI_As_2, MI_Ds_3, MI_F_4, MI_E_4, MI_Gs_4, MI_B_4, MI_E_5, MI_Ds_4
    ),

    [_QWERTY] = LAYOUT_wrapper(
                   _________________NUMBER_L__________________,
       KC_GESC, KC_TAB, _________________QWERTY_L1_________________,
          KC_CAPS, _________________QWERTY_L2_________________, KC_H,
       KC_LSFT, _________________QWERTY_L3_________________, KC_N,
     KC_LCTL, KC_GRV, KC_LGUI, KC_LALT, MIS_EIS, KC_SPC, KC_SPC, KC_PSCR,

     MO(_MISC),        KC_LBRC, KC_RBRC, KC_BSLS, KC_0,         _______,
                  KC_6, KC_7, KC_8, KC_9, KC_BSPC, _______, _______,
                _________________QWERTY_R1_________________, KC_DEL,
     KC_PGUP, KC_G, _________________QWERTY_R2_________________, KC_ENT,
            KC_PGDN, KC_B, _________________QWERTY_R3_________________, KC_RSFT,
         KC_HOME, KC_END, KC_SPC, MIS_KAN, KC_RALT, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
    ),

    [_COLEMAK] = LAYOUT_wrapper(
                   _________________NUMBER_L__________________,
       KC_GESC, KC_TAB, _________________COLEMAK_L1________________,
          KC_LCTL, _________________COLEMAK_L2________________, KC_ENT,
       KC_LSFT, _________________COLEMAK_L3________________, KC_M,
     KC_CAPS, KC_GRV, KC_LGUI, KC_LALT, MIS_EIS, KC_SPC, KC_SPC, KC_PSCR,

     MO(_MISC),        KC_LBRC, KC_RBRC, KC_BSLS, KC_0,         _______,
                  KC_6, KC_7, KC_8, KC_9, KC_BSPC, _______, _______,
                _________________COLEMAK_R1________________, KC_DEL,
     KC_PGUP, KC_D, _________________COLEMAK_R2________________, KC_ENT,
            KC_PGDN, KC_B, _________________COLEMAK_R3________________, KC_RSFT,
         KC_HOME, KC_END, KC_SPC, MIS_KAN, KC_RALT, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
    ),

    [_MISC] = LAYOUT_wrapper(
                    _________________FUNC__L___________________,
       _______, _______, _______, _______, _______, _______, _______,
          _______, _______, _______, _______, _______, _______, _______,
       _______, _______, _______, _______, _______, _______, _______,
     _______, _______, _______, _______, _______, _______, _______, _______,

     _______,        _______, _______, _______, KC_F10,         _______,
                  KC_F6, KC_F7, KC_F8, KC_F9, _______, _______, _______,
                _______, _______, _______, _______, _______, _______,
     _______, _______, _______, _______, _______, _______, KC_QUOT, _______,
            _______, _______, _______, _______, _______, _______, _______, _______,
         _______, _______, _______, _______, _______, _______, _______, _______, _______
    ),

    [_FN] = LAYOUT(
                   DF_SWAP, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
       XXXXXXX, DF_QWER, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
          DF_COLE, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______,
       XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
     XXXXXXX, XXXXXXX, AG_NORM, AG_SWAP, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,

     _______,        MI_OCTD, MI_OCTU, MI_VELD, MI_VELU,         _______,
                   XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,  XXXXXXX, XXXXXXX,
                XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
     _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
            RGB_SAD, RGB_SAI, RGB_HUD, RGB_HUI, RGB_SPD, RGB_SPI, RGB_VAD, RGB_VAI,
          XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_RMOD, RGB_MOD, EEP_RST, RGB_TOG
    )
};

void eeconfig_init_user(void) {  // EEPROM is getting reset!
  #ifdef RGB_MATRIX_ENABLE
  rgb_matrix_enable();
  rgb_matrix_set_speed(RGB_MATRIX_STARTUP_SPD);
  rgb_matrix_sethsv(HSV_BLUE);

  rgb_matrix_mode(RGB_MATRIX_SOLID_REACTIVE);
  // rgb_matrix_mode(RGB_MATRIX_RAINBOW_MOVING_CHEVRON);
  #endif
}

void keyboard_post_init_user(void) {
    //  Set octave to MI_OCT_0
    midi_config.octave = MI_OCT_0 - MIDI_OCTAVE_MIN;

    // avoid using 127 since it is used as a special number in some sound sources.
    midi_config.velocity = MIDI_INITIAL_VELOCITY;

    //  party mode (for LED soldering test. Enable rainbow color effect, and disable led_indicator to check all LEDs)
    rgb_matrix_mode(RGB_MATRIX_RAINBOW_MOVING_CHEVRON);
};

#ifdef RGB_MATRIX_ENABLE
void rgb_matrix_indicators_user(void) {
    if (rgb_matrix_is_enabled()) {  // turn the lights on when it is enabled.
        uint8_t layer = biton32(layer_state);
        switch (layer) {
            case _CLOSE:
                // rgb_matrix_set_color(pgm_read_byte(&convert_led_location2number[11]),  RGB_RED);         //  RGB_TOG  <- too heavy.

                // Close state indicator
                rgb_matrix_set_color( 0, RGB_DARKWHITE);     //  oc
                break;

            case _FN:
                // left hand side
                rgb_matrix_set_color( 46, RGB_DARKORANGE);     //  DF_OPEN
                rgb_matrix_set_color( 48, RGB_DARKWHITE);      //  DF_QWER
                rgb_matrix_set_color( 60, RGB_DARKWHITE);      //  DF_COLE

                rgb_matrix_set_color( 73, RGB_DARKYELLOW);     //  AG_SWAP
                rgb_matrix_set_color( 72, RGB_DARKYELLOW);     //  AG_NORM


                // right hand side
                rgb_matrix_set_color( 1, RGB_DARKYELLOW);      //  MI_OCTD
                rgb_matrix_set_color(13, RGB_DARKGREEN);       //  MI_OCTU
                rgb_matrix_set_color(14, RGB_DARKYELLOW);      //  MI_VELD
                rgb_matrix_set_color(25, RGB_DARKGREEN);       //  MI_VELU

                rgb_matrix_set_color( 6, RGB_DARKBLUE);        //  RGB_SAD
                rgb_matrix_set_color( 9, RGB_DARKBLUE);        //  RGB_SAI
                rgb_matrix_set_color(18, RGB_DARKBLUE);        //  RGB_HUD
                rgb_matrix_set_color(21, RGB_DARKBLUE);        //  RGB_HUI
                rgb_matrix_set_color(29, RGB_DARKBLUE);        //  RGB_SPD
                rgb_matrix_set_color(32, RGB_DARKBLUE);        //  RGB_SPI
                rgb_matrix_set_color(36, RGB_DARKBLUE);        //  RGB_VAD
                rgb_matrix_set_color(39, RGB_DARKBLUE);        //  RGB_VAI

                rgb_matrix_set_color(31, RGB_DARKBLUE);        //  RGB_RMOD
                rgb_matrix_set_color(37, RGB_DARKBLUE);        //  RGB_MOD
                rgb_matrix_set_color(38, RGB_DARKPINK);        //  EEP_RST
                rgb_matrix_set_color(40, RGB_DARKRED);         //  RGB_TOG

                rgb_matrix_set_color(41, RGB_DARKORANGE);      //  _FN
                break;
        }
    }
}
#endif

A keyboards/bandominedoni/keymaps/led/readme.md => keyboards/bandominedoni/keymaps/led/readme.md +1 -0
@@ 0,0 1,1 @@
# The default keymap for bandominedoni

A keyboards/bandominedoni/keymaps/led/rules.mk => keyboards/bandominedoni/keymaps/led/rules.mk +2 -0
@@ 0,0 1,2 @@
RGB_MATRIX_ENABLE = yes       # Use RGB matrix (Don't enable this when RGBLIGHT_ENABLE is used.)
RGB_MATRIX_CUSTOM_USER = yes  # 

A keyboards/bandominedoni/keymaps/via/config.h => keyboards/bandominedoni/keymaps/via/config.h +18 -0
@@ 0,0 1,18 @@
/* Copyright 2021 3araht
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
 #pragma once

#define DYNAMIC_KEYMAP_LAYER_COUNT 5

A keyboards/bandominedoni/keymaps/via/keymap.c => keyboards/bandominedoni/keymaps/via/keymap.c +150 -0
@@ 0,0 1,150 @@
/* Copyright 2021 3araht
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
#include QMK_KEYBOARD_H

// Defines names for use in layer keycodes and the keymap
enum layer_names {
#ifndef PEDAL_NORMALLY_CLOSED
    _OPEN,
#endif
    _CLOSE,
#ifdef PEDAL_NORMALLY_CLOSED
    _OPEN,
#endif
    _MISC,
    _FN
};

const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
    [_OPEN] = LAYOUT(
                  MI_Gs_1, MI_As_1, MI_Cs_2, MI_F_2, MI_Gs_3,
       MI_E_1, MI_A_1, MI_G_2, MI_Ds_2, MI_F_3, MI_As_2, MI_F_1,
         MI_D_2, MI_A_2, MI_C_3, MI_E_3, MI_C_2, MI_G_1, TG_SWAP,
       MI_E_2, MI_Gs_2, MI_B_2, MI_D_3, MI_Fs_3, MI_Cs_3, MI_Fs_1,
     MI_D_1, MI_B_1, MI_G_3, MI_A_3, MI_Ds_3, MI_Fs_2, MI_Ds_1, MI_C_1,

     MO_SWAP,    MI_B_5, MI_Gs_5, MI_G_5, MI_F_5,     FN_MUTE,
         MI_Cs_3, MI_A_5, MI_Fs_5, MI_E_5, MI_Ds_5, KC_VOLD, KC_VOLU,
        MI_C_3, MI_D_3, MI_G_3, MI_As_4, MI_C_5, MI_D_5,
     TG_SWAP, MI_B_2, MI_E_3, MI_Cs_4, MI_Fs_3, MI_A_3, MI_C_4, MI_E_4,
       MI_A_2, MI_F_3, MI_As_3, MI_Gs_3, MI_B_3, MI_D_4, MI_Gs_4, MI_B_4,
     MI_Gs_2, MI_As_2, MI_Ds_3, MI_F_4, MI_Ds_4, MI_Fs_4, MI_A_4, MI_Cs_5, MI_G_4
    ),

    [_CLOSE] = LAYOUT(
                  MI_Gs_1, MI_As_1, MI_Ds_2, MI_Ds_3, MI_G_3,
       MI_D_1, MI_D_2, MI_As_2, MI_C_3, MI_Cs_2, MI_C_2, MI_Fs_1,
         MI_G_1, MI_G_2, MI_B_2, MI_D_3, MI_F_3, MI_Fs_2, TG_SWAP,
       MI_A_1, MI_E_2, MI_A_2, MI_Cs_3, MI_E_3, MI_Gs_2, MI_B_1,
     MI_E_1, MI_E_2, MI_Fs_3, MI_Gs_3, MI_B_3, MI_F_2, MI_Cs_1, MI_F_1,

     MO_SWAP,    MI_A_5, MI_Gs_5, MI_Fs_5, MI_F_5,     FN_MUTE,
         MI_C_3, MI_G_5, MI_As_4, MI_C_5, MI_Ds_5, KC_VOLD, KC_VOLU,
        MI_D_3, MI_Cs_3, MI_Gs_3, MI_As_3, MI_C_4, MI_D_5,
     TG_SWAP, MI_B_2, MI_Fs_3, MI_Fs_4, MI_G_3, MI_B_3, MI_D_4, MI_G_4,
       MI_A_2, MI_F_3, MI_E_3, MI_A_3, MI_Cs_4, MI_E_4, MI_A_4, MI_Cs_5,
     MI_Gs_2, MI_As_2, MI_Ds_3, MI_F_4, MI_E_4, MI_Gs_4, MI_B_4, MI_E_5, MI_Ds_4
    ),

    [_MISC] = LAYOUT(
                  _______, _______, _______, _______, _______,
       _______, _______, _______, _______, _______, _______, _______,
          _______, _______, _______, _______, _______, _______, _______,
       _______, _______, _______, _______, _______, _______, _______,
     _______, _______, _______, _______, _______, _______, _______, _______,

     _______,        _______, _______, _______, _______,         _______,
                  _______, _______, _______, _______, _______, _______, _______,
                _______, _______, _______, _______, _______, _______,
     _______, _______, _______, _______, _______, _______, _______, _______,
            _______, _______, _______, _______, _______, _______, _______, _______,
         _______, _______, _______, _______, _______, _______, _______, _______, _______
    ),

    [_FN] = LAYOUT(
                   DF_SWAP, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
       XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
          XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______,
       XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
     XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,

     _______,        MI_OCTD, MI_OCTU, MI_VELD, MI_VELU,         _______,
                   XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
                XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
     _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
            RGB_SAD, RGB_SAI, RGB_HUD, RGB_HUI, RGB_SPD, RGB_SPI, RGB_VAD, RGB_VAI,
          XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_RMOD, RGB_MOD, EEP_RST, RGB_TOG
    )
};

void eeconfig_init_user(void) {  // EEPROM is getting reset!
  #ifdef RGB_MATRIX_ENABLE
  rgb_matrix_enable();
  rgb_matrix_set_speed(RGB_MATRIX_STARTUP_SPD);
  rgb_matrix_sethsv(HSV_BLUE);

  rgb_matrix_mode(RGB_MATRIX_SOLID_REACTIVE);
  // rgb_matrix_mode(RGB_MATRIX_RAINBOW_MOVING_CHEVRON);
  #endif
}

void keyboard_post_init_user(void) {
    //  Set octave to MI_OCT_0
    midi_config.octave = MI_OCT_0 - MIDI_OCTAVE_MIN;

    // avoid using 127 since it is used as a special number in some sound sources.
    midi_config.velocity = MIDI_INITIAL_VELOCITY;
};

#ifdef RGB_MATRIX_ENABLE
void rgb_matrix_indicators_user(void) {
    if (rgb_matrix_is_enabled()) {  // turn the lights on when it is enabled.
        uint8_t layer = biton32(layer_state);
        switch (layer) {
            case _CLOSE:
                // rgb_matrix_set_color(pgm_read_byte(&convert_led_location2number[11]),  RGB_RED);         //  RGB_TOG  <- too heavy.

                // Close state indicator
                rgb_matrix_set_color( 0, RGB_DARKWHITE);     //  oc
                break;

            case _FN:
                // rgb_matrix_set_color(pgm_read_byte(&convert_led_location2number[11]),  RGB_RED);         //  RGB_TOG  <- too heavy.
                rgb_matrix_set_color(14, RGB_DARKYELLOW);      //  MI_OCTD
                rgb_matrix_set_color(25, RGB_DARKGREEN);       //  MI_OCTU
                rgb_matrix_set_color(14, RGB_DARKYELLOW);      //  MI_VELD
                rgb_matrix_set_color(25, RGB_DARKGREEN);       //  MI_VELU

                rgb_matrix_set_color( 6, RGB_DARKBLUE);        //  RGB_SAD
                rgb_matrix_set_color( 9, RGB_DARKBLUE);        //  RGB_SAI
                rgb_matrix_set_color(18, RGB_DARKBLUE);        //  RGB_HUD
                rgb_matrix_set_color(21, RGB_DARKBLUE);        //  RGB_HUI
                rgb_matrix_set_color(29, RGB_DARKBLUE);        //  RGB_SPD
                rgb_matrix_set_color(32, RGB_DARKBLUE);        //  RGB_SPI
                rgb_matrix_set_color(36, RGB_DARKBLUE);        //  RGB_VAD
                rgb_matrix_set_color(39, RGB_DARKBLUE);        //  RGB_VAI

                rgb_matrix_set_color(31, RGB_DARKBLUE);        //  RGB_RMOD
                rgb_matrix_set_color(37, RGB_DARKBLUE);        //  RGB_MOD
                rgb_matrix_set_color(38, RGB_DARKPINK);        //  EEP_RST
                rgb_matrix_set_color(40, RGB_DARKRED);         //  RGB_TOG

                rgb_matrix_set_color(41, RGB_DARKORANGE);      //  _FN
                break;
        }
    }
}
#endif

A keyboards/bandominedoni/keymaps/via/readme.md => keyboards/bandominedoni/keymaps/via/readme.md +1 -0
@@ 0,0 1,1 @@
# The default VIA keymap for bandominedoni

A keyboards/bandominedoni/keymaps/via/rules.mk => keyboards/bandominedoni/keymaps/via/rules.mk +3 -0
@@ 0,0 1,3 @@
RGB_MATRIX_ENABLE = yes       # Use RGB matrix (Don't enable this when RGBLIGHT_ENABLE is used.)
VIA_ENABLE = yes
MOUSEKEY_ENABLE = yes        # Mouse keys

A keyboards/bandominedoni/readme.md => keyboards/bandominedoni/readme.md +22 -0
@@ 0,0 1,22 @@
# bandominedoni

![bandoMIneDonI](https://github.com/3araht/bandoMIneDonI/blob/main/pictures/bandoMIneDonI.jpg)

bandoMIneDonI keyboard is a MIDI split keyboard with bandoneon layout.
Close and Open of the bellow is emulated by either using a sustain pedal, or tapping a dedicated keys to alter the close and open status.

* Keyboard Maintainer: [3araht](https://github.com/3araht)
* Hardware Supported: bandoMIneDonI keyboard, a split keyboard mainly work as bandoneon MIDI keyboard.
* Hardware Availability: [BOOTH](https://3araht.booth.pm/).

Make example for this keyboard (after setting up your build environment):

    make bandominedoni:default

Flashing example for this keyboard:

    make bandominedoni:default:flash

Uncomment "PEDAL_NORMALLY_CLOSED" in bandominedoni.h when normally-on pedal is used for switching Open/Close state.

See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).

A keyboards/bandominedoni/rgb_matrix_user.inc => keyboards/bandominedoni/rgb_matrix_user.inc +16 -0
@@ 0,0 1,16 @@
#ifdef RGB_MATRIX_KEYREACTIVE_ENABLED
RGB_MATRIX_EFFECT(my_party_rocks)

#    ifdef RGB_MATRIX_CUSTOM_EFFECT_IMPLS

bool my_party_rocks(effect_params_t* params) {
    RGB_MATRIX_USE_LIMITS(led_min, led_max);
    HSV hsv = {rand() & 0xFF, rand() & 0xFF, rgb_matrix_config.hsv.v};
    RGB rgb = rgb_matrix_hsv_to_rgb(hsv);
    // rgb_matrix_set_color(i, rgb.r, rgb.g, rgb.b);
    rgb_matrix_set_color_all(rgb.r, rgb.g, rgb.b);
    return led_max < DRIVER_LED_TOTAL;
}

#    endif      // RGB_MATRIX_CUSTOM_EFFECT_IMPLS
#endif          // RGB_MATRIX_KEYREACTIVE_ENABLED

A keyboards/bandominedoni/rules.mk => keyboards/bandominedoni/rules.mk +28 -0
@@ 0,0 1,28 @@
# MCU name
MCU = atmega32u4

# Bootloader selection
BOOTLOADER = caterina

# Build Options
#   change yes to no to disable
#
BOOTMAGIC_ENABLE = no       # Enable Bootmagic Lite
MOUSEKEY_ENABLE = no        # Mouse keys
EXTRAKEY_ENABLE = yes       # Audio control and System control
CONSOLE_ENABLE = no         # Console for debug
COMMAND_ENABLE = no         # Commands for debug and configuration
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
SLEEP_LED_ENABLE = no       # Breathing sleep LED during USB suspend
# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
NKRO_ENABLE = no            # USB Nkey Rollover
BACKLIGHT_ENABLE = no       # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no        # Enable keyboard RGB underglow
AUDIO_ENABLE = no           # Audio output
MIDI_ENABLE = yes           # MIDI support
ENCODER_ENABLE = yes        # encoder on mute button
SPLIT_KEYBOARD = yes        # Enables split keyboard support
RGB_MATRIX_ENABLE = no      # Use RGB matrix (Don't enable this when RGBLIGHT_ENABLE is used.)
RGB_MATRIX_DRIVER = WS2812  #

LTO_ENABLE = yes