Browse Source

Add Daisy, a macropad with dual rotary encoders + update Scarlet readme.md (#12221)

* Daisy first commit buggy

* buggy still underglow crash

* Daisy V1

* ReadMe Updates
pull/12380/head
Blake 3 years ago
committed by GitHub
parent
commit
c4d05010cb
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 285 additions and 2 deletions
  1. +112
    -0
      keyboards/draytronics/daisy/config.h
  2. +19
    -0
      keyboards/draytronics/daisy/daisy.c
  3. +33
    -0
      keyboards/draytronics/daisy/daisy.h
  4. +25
    -0
      keyboards/draytronics/daisy/info.json
  5. +51
    -0
      keyboards/draytronics/daisy/keymaps/default/keymap.c
  6. +20
    -0
      keyboards/draytronics/daisy/readme.md
  7. +23
    -0
      keyboards/draytronics/daisy/rules.mk
  8. +2
    -2
      keyboards/draytronics/scarlet/readme.md

+ 112
- 0
keyboards/draytronics/daisy/config.h View File

@ -0,0 +1,112 @@
/*Copyright 2021 Blake Drayson / Draytronics
Contact info@draytronics.co.uk
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"
#define VENDOR_ID 0x4454 //DT for DrayTronics
#define PRODUCT_ID 0x4441 //DA for Daisy
#define DEVICE_VER 0x0100 //Version 1
#define MANUFACTURER Draytronics
#define PRODUCT DAISY
/* key matrix size */
#define MATRIX_ROWS 3
#define MATRIX_COLS 4
/*
* 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 { B0, C0, C1}
#define MATRIX_COL_PINS { C2, C3, C4, C5 }
#define UNUSED_PINS
#define ENCODERS_PAD_A { B1, D0 }
#define ENCODERS_PAD_B { B2, D1 }
/* COL2ROW, ROW2COL*/
#define DIODE_DIRECTION COL2ROW
#define TAP_CODE_DELAY 10
/* 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
//#define NO_ACTION_TAPPING
//#define NO_ACTION_ONESHOT
/* disable these deprecated features by default */
#define NO_ACTION_MACRO
#define NO_ACTION_FUNCTION
//Underglow
#define RGB_DI_PIN D4 // Underglow led pin
#ifdef RGB_DI_PIN
#define RGBLED_NUM 4
#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
#endif

+ 19
- 0
keyboards/draytronics/daisy/daisy.c View File

@ -0,0 +1,19 @@
/*Copyright 2021 Blake Drayson / Draytronics
Contact info@draytronics.co.uk
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 "daisy.h"

+ 33
- 0
keyboards/draytronics/daisy/daisy.h View File

@ -0,0 +1,33 @@
/*Copyright 2021 Blake Drayson / Draytronics
Contact info@draytronics.co.uk
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 _x_ KC_NO
#include "quantum.h"
#define LAYOUT_daisy( \
K00, K03, \
K10, K11, K12, K13, \
K20, K21, K22, K23 \
) { \
{ K00, _x_, _x_, K03, }, \
{ K10, K11, K12, K13, }, \
{ K20, K21, K22, K23, }, \
}

+ 25
- 0
keyboards/draytronics/daisy/info.json View File

@ -0,0 +1,25 @@
{
"keyboard_name": "Draytronics DAISY",
"url": "https://www.draytronics.co.uk/daisy",
"maintainer": "ghostseven",
"width": 4,
"height": 3,
"layouts": {
"LAYOUT": {
"layout": [
{"label":"", "x":0, "y":0},
{"label":"", "x":3, "y":0},
{"label":"", "x":0, "y":1},
{"label":"", "x":1, "y":1},
{"label":"", "x":2, "y":1},
{"label":"", "x":3, "y":1},
{"label":"", "x":0, "y":2},
{"label":"", "x":1, "y":2},
{"label":"", "x":2, "y":2},
{"label":"", "x":3, "y":1, "h":2}
]
}
}
}

+ 51
- 0
keyboards/draytronics/daisy/keymaps/default/keymap.c View File

@ -0,0 +1,51 @@
/*Copyright 2021 Blake Drayson / Draytronics
Contact info@draytronics.co.uk
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 _BASE 0 // Base layer
#define _CODE 1 // Code layer
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_BASE] = LAYOUT_daisy(
KC_MUTE, KC_HOME,
MO(_CODE), KC_MPRV, KC_MNXT, KC_MPLY,
C(KC_LEFT), C(KC_UP), C(KC_DOWN), C(KC_RIGHT)
),
[_CODE] = LAYOUT_daisy(
KC_MUTE, KC_END,
_______, RGB_MOD, RGB_VAI, RGB_TOG,
G(S(KC_5)), G(A(KC_ESC)), G(KC_F), RESET
)
};
void encoder_update_user(uint8_t index, bool clockwise) {
if (index == 0) {
if (clockwise) {
tap_code(KC_VOLD);
} else {
tap_code(KC_VOLU);
}
}
else if (index == 1) {
if (clockwise) {
tap_code(KC_PGUP);
} else {
tap_code(KC_PGDN);
}
}
}

+ 20
- 0
keyboards/draytronics/daisy/readme.md View File

@ -0,0 +1,20 @@
# DAISY
![daisy](https://www.draytronics.co.uk/wp-content/uploads/2020/12/repository-open-graph-template-1.png)
An open source macro pad with rotary encoders and under glow, designed to be easily built with (mostly) through hole components. More info / kits / PCB designs available at [draytronics.co.uk/daisy](https://www.draytronics.co.uk/daisy)
* Keyboard Maintainer: [Blake Drayson](https://github.com/ghostseven)
* Hardware Supported: DAISY PCB / ATMega328P
* Hardware Availability: [draytronics.co.uk](https://draytronics.co.uk)
Make example for this keyboard (after setting up your build environment):
make draytronics/daisy:default
Flashing example for this keyboard:
make draytronics/daisy:default:flash
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).
VIA design config file avaliable [here](https://www.draytronics.co.uk/f_daisy/draytronics_daisy_via_config.json)

+ 23
- 0
keyboards/draytronics/daisy/rules.mk View File

@ -0,0 +1,23 @@
# MCU name
MCU = atmega328p
# Bootloader selection
BOOTLOADER = USBasp
# Build Options
# change yes to no to disable
#
BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration
MOUSEKEY_ENABLE = yes # 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 = yes # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output
ENCODER_ENABLE = yes # Rotary encoder support

+ 2
- 2
keyboards/draytronics/scarlet/readme.md View File

@ -2,11 +2,11 @@
![scarlet](https://www.draytronics.co.uk/wp-content/uploads/2020/10/Scarlet-PCB-Compared-Combined.png)
A open source 17 key numpad keyboard, designed to be easily built at home with through hole components. More info / kits / PCB designs available at [draytronics.co.uk/scarlet](draytronics.co.uk)
A open source 17 key numpad keyboard, designed to be easily built at home with through hole components. More info / kits / PCB designs available at [draytronics.co.uk/scarlet](https://draytronics.co.uk)
* Keyboard Maintainer: [Blake Drayson](https://github.com/ghostseven)
* Hardware Supported: SCARLET PCB / ATMega32A
* Hardware Availability: [draytronics.co.uk](draytronics.co.uk)
* Hardware Availability: [draytronics.co.uk](https://draytronics.co.uk)
Make example for this keyboard (after setting up your build environment):


Loading…
Cancel
Save