|
| 1 | +/* -*- mode: c++ -*- |
| 2 | + * Copyright (C) 2025 Keyboard.io, Inc. |
| 3 | + * |
| 4 | + * This program is free software: you can redistribute it and/or modify it under |
| 5 | + * the terms of the GNU General Public License as published by the Free Software |
| 6 | + * Foundation, version 3. |
| 7 | + * |
| 8 | + * This program is distributed in the hope that it will be useful, but WITHOUT |
| 9 | + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS |
| 10 | + * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more |
| 11 | + * details. |
| 12 | + * |
| 13 | + * You should have received a copy of the GNU General Public License along with |
| 14 | + * this program. If not, see <http://www.gnu.org/licenses/>. |
| 15 | + */ |
| 16 | + |
| 17 | +#include <Kaleidoscope.h> |
| 18 | +#include <Kaleidoscope-OneShot.h> |
| 19 | +#include <Kaleidoscope-OneShotMetaKeys.h> |
| 20 | +#include <Kaleidoscope-Escape-OneShot.h> |
| 21 | + |
| 22 | +#include "./common.h" |
| 23 | + |
| 24 | +// *INDENT-OFF* |
| 25 | +KEYMAPS( |
| 26 | + [0] = KEYMAP_STACKED |
| 27 | + ( |
| 28 | + Key_A, Key_B, ___, ___, ___, ___, ___, |
| 29 | + OneShot_ActiveStickyKey, ___, ___, ___, ___, ___, ___, |
| 30 | + ___, ___, ___, ___, ___, ___, |
| 31 | + ___, ___, ___, ___, ___, ___, ___, |
| 32 | + ___, ___, ___, ___, |
| 33 | + ___, |
| 34 | + |
| 35 | + ___, ___, ___, ___, ___, ___, ___, |
| 36 | + ___, ___, ___, ___, ___, ___, ___, |
| 37 | + ___, ___, ___, ___, ___, ___, |
| 38 | + ___, ___, ___, ___, ___, ___, ___, |
| 39 | + ___, ___, ___, ___, |
| 40 | + ___ |
| 41 | + ), |
| 42 | +) |
| 43 | +// *INDENT-ON* |
| 44 | + |
| 45 | +KALEIDOSCOPE_INIT_PLUGINS(OneShot, OneShotMetaKeys, EscapeOneShot); |
| 46 | + |
| 47 | +void setup() { |
| 48 | + Kaleidoscope.setup(); |
| 49 | + OneShot.setTimeout(50); |
| 50 | + OneShot.setHoldTimeout(20); |
| 51 | + OneShot.setDoubleTapTimeout(20); |
| 52 | +} |
| 53 | + |
| 54 | +void loop() { |
| 55 | + Kaleidoscope.loop(); |
| 56 | +} |
0 commit comments