diff options
Diffstat (limited to 'src/model01.ino')
-rw-r--r-- | src/model01.ino | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/src/model01.ino b/src/model01.ino new file mode 100644 index 0000000..3a714d7 --- /dev/null +++ b/src/model01.ino @@ -0,0 +1,68 @@ +/*********************************************************************** + * A firmware Sketch for the Keyboardio Model 01 + * Copyright © 2019 Guilhem Moulin <guilhem@fripost.org> + * + * 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 3 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 <Kaleidoscope.h> +#include <Kaleidoscope-Colormap.h> +#include <Kaleidoscope-EEPROM-Settings.h> +#include <Kaleidoscope-Escape-OneShot.h> +#include <Kaleidoscope-IdleLEDs.h> +#include <Kaleidoscope-LEDControl.h> +#include <Kaleidoscope-LED-ActiveModColor.h> +#include <Kaleidoscope-LED-Palette-Theme.h> +#include <Kaleidoscope-OneShot.h> +#include <Kaleidoscope-MouseKeys.h> +#include <Kaleidoscope-Unicode.h> + +#include "TapDance.h" +#include "keymap.h" + + +KALEIDOSCOPE_INIT_PLUGINS( + EEPROMSettings + , TapDance + , LEDControl + , IdleLEDs + , LEDPaletteTheme + , ColormapEffect + , MouseKeys + , OneShot + , EscapeOneShot + , ActiveModColorEffect +); + +void setup() { + Kaleidoscope.setup(); + + ColormapEffect.max_layers(LAYER_MAX+1); + ColormapEffect.activate(); + + MouseWrapper.speedLimit = 64; + MouseKeys.speed = 15; + MouseKeys.accelDelay = 35; + + IdleLEDs.idle_time_limit = 60; +} + +void loop() { + Kaleidoscope.loop(); + + if (cancelOneShot) { + OneShot.cancel(); + cancelOneShot = false; + } +} |