Add short names for all our supported devices

Signed-off-by: Gergely Nagy <algernon@keyboard.io>
pull/760/head
Gergely Nagy 5 years ago
parent 69582320f2
commit 7792037abf
No known key found for this signature in database
GPG Key ID: AC1E90BAC433F68F

@ -27,16 +27,17 @@
#include "kaleidoscope/driver/storage/ATmega32U4EEPROMProps.h"
#include "kaleidoscope/driver/storage/AVREEPROM.h"
#define ATMEGA32U4_DEVICE_PROPS(BOARD_, BOOTLOADER_, ROW_PINS_, COL_PINS_) \
struct BOARD_##Props : kaleidoscope::device::ATmega32U4KeyboardProps { \
struct KeyScannerProps \
: public kaleidoscope::driver::keyscanner::ATmegaProps \
{ \
ATMEGA_KEYSCANNER_PROPS(ROW_PIN_LIST(ROW_PINS_), \
COL_PIN_LIST(COL_PINS_)); \
}; \
typedef kaleidoscope::driver::keyscanner::ATmega<KeyScannerProps> KeyScanner;\
typedef kaleidoscope::driver::bootloader::avr::BOOTLOADER_ BootLoader; \
#define ATMEGA32U4_DEVICE_PROPS(BOARD_, BOOTLOADER_, NAME_, ROW_PINS_, COL_PINS_) \
struct BOARD_##Props : kaleidoscope::device::ATmega32U4KeyboardProps { \
struct KeyScannerProps \
: public kaleidoscope::driver::keyscanner::ATmegaProps \
{ \
ATMEGA_KEYSCANNER_PROPS(ROW_PIN_LIST(ROW_PINS_), \
COL_PIN_LIST(COL_PINS_)); \
}; \
typedef kaleidoscope::driver::keyscanner::ATmega<KeyScannerProps> KeyScanner; \
typedef kaleidoscope::driver::bootloader::avr::BOOTLOADER_ BootLoader; \
static constexpr const char *short_name = NAME_; \
};
#define ATMEGA32U4_DEVICE(BOARD_) \
@ -46,15 +47,15 @@
#ifndef KALEIDOSCOPE_VIRTUAL_BUILD
#define ATMEGA32U4_KEYBOARD(BOARD_, BOOTLOADER_, ROW_PINS_, COL_PINS_) \
ATMEGA32U4_DEVICE_PROPS(BOARD_, BOOTLOADER_, \
#define ATMEGA32U4_KEYBOARD(BOARD_, BOOTLOADER_, NAME_, ROW_PINS_, COL_PINS_) \
ATMEGA32U4_DEVICE_PROPS(BOARD_, BOOTLOADER_, NAME_, \
FORWARD(ROW_PINS_), FORWARD(COL_PINS_)) \
ATMEGA32U4_DEVICE(BOARD_)
#else // ifndef KALEIDOSCOPE_VIRTUAL_BUILD
#define ATMEGA32U4_KEYBOARD(BOARD_, BOOTLOADER_, ROW_PINS_, COL_PINS_) \
ATMEGA32U4_DEVICE_PROPS(BOARD_, BOOTLOADER_, \
#define ATMEGA32U4_KEYBOARD(BOARD_, BOOTLOADER_, NAME_, ROW_PINS_, COL_PINS_) \
ATMEGA32U4_DEVICE_PROPS(BOARD_, BOOTLOADER_, NAME_, \
FORWARD(ROW_PINS_), FORWARD(COL_PINS_)) \
/* Device definition omitted for virtual device builds. \
* We need to forward declare the device name, though, as there are \

@ -170,6 +170,7 @@ struct RaiseProps : kaleidoscope::device::BaseProps {
typedef RaiseSideFlasherProps SideFlasherProps;
typedef kaleidoscope::util::flasher::KeyboardioI2CBootloader<SideFlasherProps> SideFlasher;
static constexpr const char *short_name = "raise";
};
class Raise: public kaleidoscope::device::Base<RaiseProps> {

@ -53,6 +53,7 @@ struct ErgoDoxProps : public kaleidoscope::device::ATmega32U4KeyboardProps {
KEYSCANNER_PROPS(14, 6);
};
typedef kaleidoscope::driver::bootloader::avr::HalfKay Bootloader;
static constexpr const char *short_name = "ErgoDox-EZ";
};
#ifndef KALEIDOSCOPE_VIRTUAL_BUILD

@ -40,6 +40,7 @@ struct KBD4xProps : kaleidoscope::device::ATmega32U4KeyboardProps {
};
typedef kaleidoscope::driver::keyscanner::ATmega<KeyScannerProps> KeyScanner;
typedef kaleidoscope::driver::bootloader::avr::FLIP Bootloader;
static constexpr const char *short_name = "kbd4x";
};
#ifndef KALEIDOSCOPE_VIRTUAL_BUILD

@ -84,6 +84,7 @@ struct ImagoProps : kaleidoscope::device::ATmega32U4KeyboardProps {
typedef ImagoLEDDriverProps LEDDriverProps;
typedef ImagoLEDDriver LEDDriver;
typedef kaleidoscope::driver::bootloader::avr::Caterina BootLoader;
static constexpr const char *short_name = "imago";
};
#ifndef KALEIDOSCOPE_VIRTUAL_BUILD

@ -120,6 +120,7 @@ struct Model01Props : public kaleidoscope::device::ATmega32U4KeyboardProps {
typedef Model01KeyScannerProps KeyScannerProps;
typedef Model01KeyScanner KeyScanner;
typedef kaleidoscope::driver::bootloader::avr::Caterina BootLoader;
static constexpr const char *short_name = "kbio01";
};
#ifndef KALEIDOSCOPE_VIRTUAL_BUILD

@ -29,7 +29,7 @@ namespace device {
namespace olkb {
ATMEGA32U4_KEYBOARD(
Planck, HalfKay,
Planck, HalfKay, "planck",
ROW_PIN_LIST({ PIN_D0, PIN_D5, PIN_B5, PIN_B6 }),
COL_PIN_LIST({ PIN_F1, PIN_F0, PIN_B0, PIN_C7, PIN_F4, PIN_F5, PIN_F6, PIN_F7, PIN_D4, PIN_D6, PIN_B4, PIN_D7 })
);

@ -47,6 +47,7 @@ struct SplitographyProps : kaleidoscope::device::ATmega32U4KeyboardProps {
};
typedef kaleidoscope::driver::keyscanner::ATmega<KeyScannerProps> KeyScanner;
typedef kaleidoscope::driver::bootloader::avr::FLIP BootLoader;
static constexpr const char *short_name = "splitography";
};
#ifndef KALEIDOSCOPE_VIRTUAL_BUILD

@ -36,7 +36,7 @@ namespace device {
namespace technomancy {
ATMEGA32U4_KEYBOARD(
Atreus, HalfKay,
Atreus, HalfKay, "atreus",
#ifdef KALEIDOSCOPE_HARDWARE_ATREUS_PINOUT_ASTAR
ROW_PIN_LIST({PIN_D0, PIN_D1, PIN_D3, PIN_D2}),
COL_PIN_LIST({PIN_D7, PIN_C6, PIN_B5, PIN_B4, PIN_E6, PIN_D4, PIN_B6, PIN_F6, PIN_F7, PIN_D6, PIN_B7})

@ -30,7 +30,7 @@ namespace device {
namespace technomancy {
ATMEGA32U4_KEYBOARD(
Atreus2, Caterina,
Atreus2, Caterina, "atreus",
ROW_PIN_LIST({PIN_F6, PIN_F5, PIN_F4, PIN_F1}),
COL_PIN_LIST({PIN_F7, PIN_E2, PIN_C7, PIN_C6, PIN_B6, PIN_B5, PIN_D7, PIN_D6, PIN_D4, PIN_D5, PIN_D3, PIN_D2})
);

Loading…
Cancel
Save