Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add sowbug/68keys and sowbug/ansi_tkl #11589

Merged
merged 5 commits into from
Feb 10, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 47 additions & 0 deletions keyboards/sowbug/68keys/68keys.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
/* Copyright 2021 Mike Tsao
*
* 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/>.
*/

// 68keys.c
sowbug marked this conversation as resolved.
Show resolved Hide resolved

#include "68keys.h"

#ifdef RGB_MATRIX_ENABLE
led_config_t g_led_config = { {
sowbug marked this conversation as resolved.
Show resolved Hide resolved
// Key Matrix to LED Index
{ 0, 1, 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, NO_LED, NO_LED, NO_LED },
{ 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, NO_LED, NO_LED, NO_LED },
{ 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, NO_LED, NO_LED, NO_LED, NO_LED, NO_LED, NO_LED }
}, {
// LED Index to Physical Position
{0, 0}, {12, 0}, {25, 0}, {38, 0}, {51, 0}, {64, 0}, {77, 0}, {90, 0}, {103, 0}, {116, 0}, {129, 0}, {142, 0}, {155, 0}, {175, 0}, {198, 0}, {211, 0}, {3, 12}, {19, 12}, {32, 12}, {45, 12}, {58, 12}, {71, 12}, {84, 12}, {97, 12}, {110, 12}, {123, 12}, {136, 12}, {149, 12}, {162, 12}, {178, 12}, {198, 12}, {211, 12}, {4, 25}, {22, 25}, {35, 25}, {48, 25}, {61, 25}, {74, 25}, {87, 25}, {100, 25}, {113, 25}, {126, 25}, {139, 25}, {152, 25}, {173, 25}, {8, 38}, {29, 38}, {42, 38}, {55, 38}, {68, 38}, {81, 38}, {94, 38}, {107, 38}, {120, 38}, {133, 38}, {146, 38}, {170, 38}, {198, 38}, {1, 51}, {17, 51}, {34, 51}, {82, 51}, {131, 51}, {147, 51}, {163, 51}, {185, 51}, {198, 51}, {211, 51}
}, {
// LED Index to Flag
LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT, LED_FLAG_KEYLIGHT
}
};
sowbug marked this conversation as resolved.
Show resolved Hide resolved

void suspend_power_down_kb(void)
{
rgb_matrix_set_suspend_state(true);
}

void suspend_wakeup_init_kb(void)
{
rgb_matrix_set_suspend_state(false);
}
#endif // #ifdef RGB_MATRIX_ENABLE
32 changes: 32 additions & 0 deletions keyboards/sowbug/68keys/68keys.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/* Copyright 2021 Mike Tsao
*
* 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/>.
*/

// 68keys.h
sowbug marked this conversation as resolved.
Show resolved Hide resolved

#pragma once

#include "quantum.h"

#define LAYOUT_default( A0, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10, A11, A12, A13, A14, A15, B0, B1, B2, B3, B4, B5, B6, B7, B8, B9, B10, B11, B12, B13, B14, B15, C0, C1, C2, C3, C4, C5, C6, C7, C8, C9, C10, C11, C12, D0, D1, D2, D3, D4, D5, D6, D7, D8, D9, D10, D11, D12, E0, E1, E2, E3, E4, E5, E6, E7, E8, E9) \
{ \
{ A0, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10, A11, A12, A13, A14, A15 }, \
{ B0, B1, B2, B3, B4, B5, B6, B7, B8, B9, B10, B11, B12, B13, B14, B15 }, \
{ C0, C1, C2, C3, C4, C5, C6, C7, C8, C9, C10, C11, C12, KC_NO, KC_NO, KC_NO }, \
{ D0, D1, D2, D3, D4, D5, D6, D7, D8, D9, D10, D11, D12, KC_NO, KC_NO, KC_NO }, \
{ E0, E1, E2, E3, E4, E5, E6, E7, E8, E9, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO } \
}

#define LAYOUT LAYOUT_default
10 changes: 10 additions & 0 deletions keyboards/sowbug/68keys/bootloader_defs.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
/* Address for jumping to bootloader on STM32 chips. */
/* It is chip dependent, the correct number can be looked up here (page 175):
* http://www.st.com/web/en/resource/technical/document/application_note/CD00167594.pdf
* This also requires a patch to chibios:
* <tmk_dir>/tmk_core/tool/chibios/ch-bootloader-jump.patch
*/

// STM32F103* does NOT have an USB bootloader in ROM (only serial),
// so setting anything here does not make much sense
#define STM32_BOOTLOADER_ADDRESS 0x80000000
Loading