The Big Rename

Rename the firmware from KeyboardioFirmware to Kaleidoscope.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
pull/105/head
Gergely Nagy 8 years ago
parent eaeae8157b
commit e305e51455

@ -3,10 +3,10 @@
generate_keymaps () { generate_keymaps () {
. ${ROOT}/tools/settings.sh . ${ROOT}/tools/settings.sh
rm -f examples/KeyboardioFirmware/generated/keymaps.h rm -f examples/Kaleidoscope/generated/keymaps.h
(cd examples/KeyboardioFirmware/layouts && \ (cd examples/Kaleidoscope/layouts && \
( find . -type f | sort | xargs -n 1 -I % sh -c 'perl ../../../tools/generate_keymaps.pl < % >> ../generated/keymaps.h' )) ( find . -type f | sort | xargs -n 1 -I % sh -c 'perl ../../../tools/generate_keymaps.pl < % >> ../generated/keymaps.h' ))
} }
DEFAULT_SKETCH=KeyboardioFirmware DEFAULT_SKETCH=Kaleidoscope
compile_HOOKS="generate_keymaps" compile_HOOKS="generate_keymaps"

@ -7,4 +7,4 @@ astyle:
find . -type f -name \*.h |xargs -n 1 astyle --style=google find . -type f -name \*.h |xargs -n 1 astyle --style=google
%: %:
@tools/keyboardio-builder $@ @tools/kaleidoscope-builder $@

@ -5,13 +5,13 @@ Right now, the code is really ugly. It'll be nicer soon. Please don't judge us t
# Getting Started # Getting Started
Pick a directory to work in, you'll need to clone multiple repositories. We'll assume you picked `$HOME/keyboardio`, if you chose another adapt the commands below accordingly. Pick a directory to work in, you'll need to clone multiple repositories. We'll assume you picked `$HOME/kaleidoscope`, if you chose another adapt the commands below accordingly.
## Setup the Arduino IDE ## Setup the Arduino IDE
Setup the Arduino IDE on your system. Make sure you install at least version 1.6, since older version may not support all required features. Setup the Arduino IDE on your system. Make sure you install at least version 1.6, since older version may not support all required features.
* On Linux, follow the instructions [on the wiki](https://github.com/keyboardio/KeyboardioFirmware/wiki/Arduino-Setup-Linux). * On Linux, follow the instructions [on the wiki](https://github.com/keyboardio/Kaleidoscope/wiki/Arduino-Setup-Linux).
* On macOS, install using [homebrew](http://brew.sh/) [cask](https://caskroom.github.io/) with `brew cask install arduino` or download the application from [the official website](https://www.arduino.cc/en/Main/Software) and move it to your `/Applications` folder. * On macOS, install using [homebrew](http://brew.sh/) [cask](https://caskroom.github.io/) with `brew cask install arduino` or download the application from [the official website](https://www.arduino.cc/en/Main/Software) and move it to your `/Applications` folder.
## Install the Keyboardio Hardware Definitions ## Install the Keyboardio Hardware Definitions
@ -24,8 +24,8 @@ SKETCHBOOK_DIR=$HOME/Documents/Arduino
# on Linux the default is # on Linux the default is
SKETCHBOOK_DIR=$HOME/Arduino SKETCHBOOK_DIR=$HOME/Arduino
# go to your keyboardio directory # go to your kaleidoscope directory
cd $HOME/keyboardio cd $HOME/kaleidoscope
# then clone the hardware definitions # then clone the hardware definitions
git clone --recursive https://github.com/keyboardio/Arduino-Boards.git git clone --recursive https://github.com/keyboardio/Arduino-Boards.git
# and make them available to the arduino environment # and make them available to the arduino environment
@ -33,19 +33,19 @@ mkdir -p $SKETCHBOOK_DIR/hardware/keyboardio
ln -s $HOME/keyboardio/Arduino-Boards $SKETCHBOOK_DIR/hardware/keyboardio/avr ln -s $HOME/keyboardio/Arduino-Boards $SKETCHBOOK_DIR/hardware/keyboardio/avr
``` ```
## Clone and Build the Keyboardio Firmware ## Clone and Build the Kaleidoscope Firmware
```sh ```sh
# go to your keyboardio directory # go to your keyboardio directory
cd $HOME/keyboardio cd $HOME/kaleidoscope
# then clone the firmware repository # then clone the firmware repository
git clone https://github.com/keyboardio/KeyboardioFirmware.git git clone https://github.com/keyboardio/Kaleidoscope.git
# and build your firmware! # and build your firmware!
cd KeyboardioFirmware cd Kaleidoscope
make make
``` ```
<3 jesse <3 jesse
[![Build [![Build
Status](https://travis-ci.org/keyboardio/KeyboardioFirmware.svg?branch=master)](https://travis-ci.org/keyboardio/KeyboardioFirmware) Status](https://travis-ci.org/keyboardio/Kaleidoscope.svg?branch=master)](https://travis-ci.org/keyboardio/Kaleidoscope)

@ -1,5 +1,5 @@
/* -*- mode: c++ -*- /* -*- mode: c++ -*-
* AppSwitcher -- A Keyboardio Example * AppSwitcher -- A Kaleidoscope Example
* Copyright (C) 2016, 2017 Gergely Nagy * Copyright (C) 2016, 2017 Gergely Nagy
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
@ -17,7 +17,8 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/ */
#include "Akela-HostOS.h" #include "Kaleidoscope.h"
#include "Kaleidoscope-HostOS.h"
#include "Macros.h" #include "Macros.h"
@ -56,10 +57,10 @@ const macro_t *macroAction(uint8_t macroIndex, uint8_t keyState) {
} }
void setup () { void setup () {
Keyboardio.setup (KEYMAP_SIZE); Kaleidoscope.setup (KEYMAP_SIZE);
Keyboardio.use (&HostOS, &Macros, NULL); Kaleidoscope.use (&HostOS, &Macros, NULL);
} }
void loop () { void loop () {
Keyboardio.loop (); Kaleidoscope.loop ();
} }

@ -1,5 +1,5 @@
/* -*- mode: c++ -*- /* -*- mode: c++ -*-
* AppSwitcher -- A Keyboardio Example * AppSwitcher -- A Kaleidoscope Example
* Copyright (C) 2016, 2017 Gergely Nagy * Copyright (C) 2016, 2017 Gergely Nagy
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
@ -17,13 +17,13 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/ */
#define AKELA_HOSTOS_GUESSER 1 #define KALEIDOSCOPE_HOSTOS_GUESSER 1
#include <Akela-HostOS.h> #include <Kaleidoscope-HostOS.h>
#include "Macros.h" #include "Macros.h"
using namespace Akela::HostOS; using namespace KaleidoscopePlugins::HostOS;
static bool appSwitchActive = false; static bool appSwitchActive = false;

@ -1,5 +1,5 @@
/* -*- mode: c++ -*- /* -*- mode: c++ -*-
* AppSwitcher -- A Keyboardio Example * AppSwitcher -- A Kaleidoscope Example
* Copyright (C) 2016, 2017 Gergely Nagy * Copyright (C) 2016, 2017 Gergely Nagy
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
@ -19,7 +19,7 @@
#pragma once #pragma once
#include <Keyboardio-Macros.h> #include <Kaleidoscope-Macros.h>
enum { enum {
M_APPSWITCH, M_APPSWITCH,

@ -4,19 +4,19 @@
#define DEBUG_SERIAL false #define DEBUG_SERIAL false
#include "Keyboardio-MouseKeys.h" #include "Kaleidoscope-MouseKeys.h"
#include "Keyboardio-Macros.h" #include "Kaleidoscope-Macros.h"
#include "Keyboardio-LEDControl.h" #include "Kaleidoscope-LEDControl.h"
#include "Keyboardio-Numlock.h" #include "Kaleidoscope-Numlock.h"
#include "KeyboardioFirmware.h" #include "Kaleidoscope.h"
#include "generated/keymaps.h" #include "generated/keymaps.h"
#include "LED-Off.h" #include "LED-Off.h"
#include "Keyboardio-LEDEffect-SolidColor.h" #include "Kaleidoscope-LEDEffect-SolidColor.h"
#include "Keyboardio-LEDEffect-Breathe.h" #include "Kaleidoscope-LEDEffect-Breathe.h"
#include "Keyboardio-LEDEffect-Chase.h" #include "Kaleidoscope-LEDEffect-Chase.h"
#include "Keyboardio-LEDEffect-Rainbow.h" #include "Kaleidoscope-LEDEffect-Rainbow.h"
#include "Keyboardio-Model01-TestMode.h" #include "Kaleidoscope-Model01-TestMode.h"
uint8_t primary_keymap = 0; uint8_t primary_keymap = 0;
uint8_t temporary_keymap = 0; uint8_t temporary_keymap = 0;
@ -52,9 +52,9 @@ const macro_t *macroAction(uint8_t macroIndex, uint8_t keyState) {
} }
void setup() { void setup() {
Keyboardio.setup(KEYMAP_SIZE); Kaleidoscope.setup(KEYMAP_SIZE);
Keyboardio.use(&TestMode, Kaleidoscope.use(&TestMode,
&LEDControl, &LEDOff, &LEDControl, &LEDOff,
&solidRed, &solidOrange, &solidYellow, &solidGreen, &solidBlue, &solidIndigo, &solidViolet, &solidRed, &solidOrange, &solidYellow, &solidGreen, &solidBlue, &solidIndigo, &solidViolet,
&LEDBreatheEffect, &LEDRainbowEffect, &LEDChaseEffect, &NumLock, &LEDBreatheEffect, &LEDRainbowEffect, &LEDChaseEffect, &NumLock,
@ -68,5 +68,5 @@ void setup() {
void loop() { void loop() {
Keyboardio.loop(); Kaleidoscope.loop();
} }

@ -1,10 +1,10 @@
name=KeyboardioFirmware name=Kaleidoscope
version=0.0.1 version=0.0.1
author=Jesse Vincent author=Jesse Vincent
maintainer=Jesse Vincent <jesse@keyboard.io> maintainer=Jesse Vincent <jesse@keyboard.io>
sentence=Firmware for the Keyboardio Model 01. sentence=Firmware for the Keyboardio Model 01, and other Arduino-powered keyboards.
paragraph=... paragraph=...
category=Communication category=Communication
url=https://github.com/keyboardio/KeyboardioFirmware url=https://github.com/keyboardio/Kaleidoscope
architectures=avr architectures=avr
dot_a_linkage=true dot_a_linkage=true

@ -1,13 +1,13 @@
#include "KeyboardioFirmware.h" #include "Kaleidoscope.h"
#include <stdarg.h> #include <stdarg.h>
Keyboardio_::Keyboardio_(void) { Kaleidoscope_::Kaleidoscope_(void) {
memset(eventHandlers, 0, HOOK_MAX * sizeof(custom_handler_t)); memset(eventHandlers, 0, HOOK_MAX * sizeof(custom_handler_t));
memset(loopHooks, 0, HOOK_MAX * sizeof(custom_handler_t)); memset(loopHooks, 0, HOOK_MAX * sizeof(custom_handler_t));
} }
void void
Keyboardio_::setup(const byte keymap_count) { Kaleidoscope_::setup(const byte keymap_count) {
wdt_disable(); wdt_disable();
delay(100); delay(100);
Keyboard.begin(); Keyboard.begin();
@ -22,7 +22,7 @@ Keyboardio_::setup(const byte keymap_count) {
custom_loop_t loopHooks[HOOK_MAX]; custom_loop_t loopHooks[HOOK_MAX];
void void
Keyboardio_::loop(void) { Kaleidoscope_::loop(void) {
KeyboardHardware.scan_matrix(); KeyboardHardware.scan_matrix();
for (byte i = 0; loopHooks[i] != NULL && i < HOOK_MAX; i++) { for (byte i = 0; loopHooks[i] != NULL && i < HOOK_MAX; i++) {
@ -40,16 +40,16 @@ Keyboardio_::loop(void) {
} }
void void
Keyboardio_::use(KeyboardioPlugin *plugin, ...) { Kaleidoscope_::use(KaleidoscopePlugin *plugin, ...) {
va_list ap; va_list ap;
KeyboardioPlugin *p; KaleidoscopePlugin *p;
plugin->begin(); plugin->begin();
va_start(ap, plugin); va_start(ap, plugin);
while ((p = va_arg(ap, KeyboardioPlugin*)) != NULL) { while ((p = va_arg(ap, KaleidoscopePlugin*)) != NULL) {
p->begin(); p->begin();
}; };
va_end(ap); va_end(ap);
} }
Keyboardio_ Keyboardio; Kaleidoscope_ Kaleidoscope;

@ -20,7 +20,7 @@ void setup();
#include <math.h> #include <math.h>
#include <avr/wdt.h> #include <avr/wdt.h>
#include KEYBOARDIO_HARDWARE_H #include KALEIDOSCOPE_HARDWARE_H
#include "key_events.h" #include "key_events.h"
#include "plugin.h" #include "plugin.h"
#include "layers.h" #include "layers.h"
@ -33,13 +33,13 @@ extern HARDWARE_IMPLEMENTATION KeyboardHardware;
#define KEYMAP_SIZE (sizeof(keymaps) / ROWS / COLS / sizeof(Key)) #define KEYMAP_SIZE (sizeof(keymaps) / ROWS / COLS / sizeof(Key))
class Keyboardio_ { class Kaleidoscope_ {
public: public:
Keyboardio_(void); Kaleidoscope_(void);
void setup(const byte keymap_count); void setup(const byte keymap_count);
void loop(void); void loop(void);
void use(KeyboardioPlugin *plugin, ...) __attribute__((sentinel)); void use(KaleidoscopePlugin *plugin, ...) __attribute__((sentinel));
}; };
extern Keyboardio_ Keyboardio; extern Kaleidoscope_ Kaleidoscope;

@ -2,7 +2,7 @@
#include <Arduino.h> #include <Arduino.h>
#include "KeyboardioHID.h" #include "KeyboardioHID.h"
#include KEYBOARDIO_HARDWARE_H #include KALEIDOSCOPE_HARDWARE_H
#include "key_defs.h" #include "key_defs.h"
#include "keyswitch_state.h" #include "keyswitch_state.h"
#include "hooks.h" #include "hooks.h"

@ -1,6 +1,6 @@
#pragma once #pragma once
class KeyboardioPlugin { class KaleidoscopePlugin {
public: public:
virtual void begin(void) = 0; virtual void begin(void) = 0;
}; };

@ -17,14 +17,14 @@ firmware_size () {
} }
find_sketch () { find_sketch () {
if [ -e "${SOURCEDIR}/.keyboardio-builder.conf" ]; then if [ -e "${SOURCEDIR}/.kaleidoscope-builder.conf" ]; then
. "${SOURCEDIR}/.keyboardio-builder.conf" . "${SOURCEDIR}/.kaleidoscope-builder.conf"
fi fi
SKETCH="${SKETCH:-${DEFAULT_SKETCH}}" SKETCH="${SKETCH:-${DEFAULT_SKETCH}}"
LIBRARY="${LIBRARY:-${SKETCH}}" LIBRARY="${LIBRARY:-${SKETCH}}"
for path in "hardware/keyboardio/avr/libraries/Akela-${LIBRARY}/examples/${SKETCH}" \ for path in "hardware/keyboardio/avr/libraries/Kaleidoscope-${LIBRARY}/examples/${SKETCH}" \
"examples/${LIBRARY}" \ "examples/${LIBRARY}" \
"src"; do "src"; do
if [ -f "${path}/${SKETCH}.ino" ]; then if [ -f "${path}/${SKETCH}.ino" ]; then
@ -134,7 +134,7 @@ compile () {
} }
_find_all () { _find_all () {
for plugin in hardware/keyboardio/avr/libraries/Akela-*/examples/* \ for plugin in hardware/keyboardio/avr/libraries/Kaleidoscope-*/examples/* \
examples/* \ examples/* \
src/*.ino; do src/*.ino; do
if [ -d "$(dirname ${plugin})" ] || [ -f "${plugin}" ]; then if [ -d "$(dirname ${plugin})" ] || [ -f "${plugin}" ]; then
@ -251,12 +251,12 @@ ROOT="$(cd $(dirname $0)/..; pwd)"
export ROOT export ROOT
export SOURCEDIR="$(pwd)" export SOURCEDIR="$(pwd)"
if [ -e "${HOME}/.keyboardio-builder.conf" ]; then if [ -e "${HOME}/.kaleidoscope-builder.conf" ]; then
. "${HOME}/.keyboardio-builder.conf" . "${HOME}/.kaleidoscope-builder.conf"
fi fi
if [ -e "${SOURCEDIR}/.keyboardio-builder.conf" ]; then if [ -e "${SOURCEDIR}/.kaleidoscope-builder.conf" ]; then
. "${SOURCEDIR}/.keyboardio-builder.conf" . "${SOURCEDIR}/.kaleidoscope-builder.conf"
fi fi
Loading…
Cancel
Save