[Keyboard] Add Treasure TYPE-9 Series II (#13725)
Co-authored-by: Ryan <fauxpark@gmail.com> Co-authored-by: Drashna Jaelre <drashna@live.com>
This commit is contained in:
parent
aa0b7079a4
commit
5a0985aa4a
50
keyboards/treasure/type9s2/config.h
Normal file
50
keyboards/treasure/type9s2/config.h
Normal file
@ -0,0 +1,50 @@
|
||||
/* Copyright 2021 Treasure
|
||||
|
||||
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 0x5452
|
||||
#define PRODUCT_ID 0x5492
|
||||
#define DEVICE_VER 0x0001
|
||||
#define MANUFACTURER TREASURE
|
||||
#define PRODUCT TYPE-9 Series II
|
||||
|
||||
/* key matrix size */
|
||||
#define MATRIX_ROWS 3
|
||||
#define MATRIX_COLS 3
|
||||
|
||||
/* Keyboard Matrix Assignments*/
|
||||
#define MATRIX_ROW_PINS { B4, B5, D2 }
|
||||
#define MATRIX_COL_PINS { B2, B3, C5 }
|
||||
#define UNUSED_PINS
|
||||
|
||||
/* COL2ROW, ROW2COL*/
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
||||
#define BACKLIGHT_PIN B7
|
||||
|
||||
/* 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
|
||||
|
||||
/* number of backlight levels */
|
||||
#define BACKLIGHT_LEVELS 3
|
||||
|
22
keyboards/treasure/type9s2/info.json
Normal file
22
keyboards/treasure/type9s2/info.json
Normal file
@ -0,0 +1,22 @@
|
||||
{
|
||||
"keyboard_name": "Treasure TYPE-9 Series II",
|
||||
"url": "http://treasuretypes.com",
|
||||
"maintainer": "Treasure",
|
||||
"width": 3,
|
||||
"height": 3,
|
||||
"layouts": {
|
||||
"LAYOUT_ortho_3x3": {
|
||||
"layout": [
|
||||
{"label": "7", "x": 0, "y": 0},
|
||||
{"label": "8", "x": 1, "y": 0},
|
||||
{"label": "9", "x": 2, "y": 0},
|
||||
{"label": "4", "x": 0, "y": 1},
|
||||
{"label": "5", "x": 1, "y": 1},
|
||||
{"label": "6", "x": 2, "y": 1},
|
||||
{"label": "1", "x": 0, "y": 2},
|
||||
{"label": "2", "x": 1, "y": 2},
|
||||
{"label": "3", "x": 2, "y": 2}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
43
keyboards/treasure/type9s2/keymaps/default/keymap.c
Normal file
43
keyboards/treasure/type9s2/keymaps/default/keymap.c
Normal file
@ -0,0 +1,43 @@
|
||||
/* Copyright 2021 Treasure
|
||||
*
|
||||
* 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
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT_ortho_3x3(
|
||||
MO(1), KC_MPLY, BL_STEP,
|
||||
KC_VOLD, KC_MUTE, KC_VOLU,
|
||||
KC_KP_1, KC_KP_2, KC_KP_3
|
||||
),
|
||||
|
||||
[1] = LAYOUT_ortho_3x3(
|
||||
_______, _______, MO(2),
|
||||
_______, _______, _______,
|
||||
_______, _______, _______
|
||||
),
|
||||
|
||||
[2] = LAYOUT_ortho_3x3(
|
||||
_______, _______, _______,
|
||||
_______, _______, _______,
|
||||
_______, _______, MO(3)
|
||||
),
|
||||
|
||||
[3] = LAYOUT_ortho_3x3(
|
||||
_______, _______, _______,
|
||||
_______, _______, _______,
|
||||
RESET, _______, _______
|
||||
)
|
||||
};
|
1
keyboards/treasure/type9s2/keymaps/default/readme.md
Normal file
1
keyboards/treasure/type9s2/keymaps/default/readme.md
Normal file
@ -0,0 +1 @@
|
||||
# The default keymap for Type-9 Series II
|
43
keyboards/treasure/type9s2/keymaps/via/keymap.c
Normal file
43
keyboards/treasure/type9s2/keymaps/via/keymap.c
Normal file
@ -0,0 +1,43 @@
|
||||
/* Copyright 2021 Treasure
|
||||
*
|
||||
* 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
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT_ortho_3x3(
|
||||
KC_KP_7, KC_KP_8, KC_KP_9,
|
||||
KC_KP_4, LT(1, KC_KP_5), KC_KP_6,
|
||||
KC_KP_1, KC_KP_2, KC_KP_3
|
||||
),
|
||||
|
||||
[1] = LAYOUT_ortho_3x3(
|
||||
_______, _______, _______,
|
||||
_______, _______, _______,
|
||||
_______, _______, _______
|
||||
),
|
||||
|
||||
[2] = LAYOUT_ortho_3x3(
|
||||
_______, _______, _______,
|
||||
_______, _______, _______,
|
||||
_______, _______, _______
|
||||
),
|
||||
|
||||
[3] = LAYOUT_ortho_3x3(
|
||||
_______, _______, _______,
|
||||
_______, _______, _______,
|
||||
_______, _______, _______
|
||||
)
|
||||
};
|
1
keyboards/treasure/type9s2/keymaps/via/readme.md
Normal file
1
keyboards/treasure/type9s2/keymaps/via/readme.md
Normal file
@ -0,0 +1 @@
|
||||
# The default keymap for Type-9 Series II
|
1
keyboards/treasure/type9s2/keymaps/via/rules.mk
Normal file
1
keyboards/treasure/type9s2/keymaps/via/rules.mk
Normal file
@ -0,0 +1 @@
|
||||
VIA_ENABLE = yes
|
17
keyboards/treasure/type9s2/readme.md
Normal file
17
keyboards/treasure/type9s2/readme.md
Normal file
@ -0,0 +1,17 @@
|
||||
# Treasure TYPE-9 Series II
|
||||
|
||||
![TYPE9SII](https://i.imgur.com/lohJ0Dal.png)
|
||||
|
||||
Treasure TYPE-9 Series II is a 3x3 Macropad.
|
||||
|
||||
* Keyboard Maintainer: [Treasure](https://github.com/TreasureTypes)
|
||||
* Hardware Supported: Treasure TYPE-9 Series II PCB
|
||||
* Hardware Availability: [Treasure Store](http://treasuretypes.com)
|
||||
|
||||
To place the keyboard into bootloader mode in order to flash it, use the reset button on the PCB.
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make treasure/type9s2:default
|
||||
|
||||
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).
|
23
keyboards/treasure/type9s2/rules.mk
Normal file
23
keyboards/treasure/type9s2/rules.mk
Normal file
@ -0,0 +1,23 @@
|
||||
# MCU name
|
||||
MCU = atmega32u2
|
||||
|
||||
# Bootloader selection
|
||||
BOOTLOADER = atmel-dfu
|
||||
|
||||
# Build Options
|
||||
# change yes to no to disable
|
||||
#
|
||||
BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration
|
||||
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 = yes # Enable keyboard backlight functionality
|
||||
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth
|
||||
AUDIO_ENABLE = no # Audio output
|
||||
LTO_ENABLE = yes
|
16
keyboards/treasure/type9s2/type9s2.c
Normal file
16
keyboards/treasure/type9s2/type9s2.c
Normal file
@ -0,0 +1,16 @@
|
||||
/* Copyright 2021 Treasure
|
||||
*
|
||||
* 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 "type9s2.h"
|
29
keyboards/treasure/type9s2/type9s2.h
Normal file
29
keyboards/treasure/type9s2/type9s2.h
Normal file
@ -0,0 +1,29 @@
|
||||
/* Copyright 2021 Treasure
|
||||
*
|
||||
* 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"
|
||||
|
||||
#define LAYOUT_ortho_3x3( \
|
||||
K00, K01, K02, \
|
||||
K10, K11, K12, \
|
||||
K20, K21, K22 \
|
||||
) { \
|
||||
{ K00, K01, K02 }, \
|
||||
{ K10, K11, K12 }, \
|
||||
{ K20, K21, K22 } \
|
||||
}
|
Loading…
Reference in New Issue
Block a user