Skip to content

Instantly share code, notes, and snippets.

@yhara
Last active Nov 28, 2020
Embed
What would you like to do?
Ψ Compiling keymap with gmake alpha:yhara:flash
QMK Firmware 0.10.53 Making alpha with keymap yhara and target flash
avr-gcc (Homebrew AVR GCC 8.4.0) 8.4.0
Copyright (C) 2018 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Size before: text data bss dec hex filename
0 22924 0 22924 598c .build/alpha_yhara.hex
Compiling: keyboards/alpha/keymaps/yhara/keymap.c keyboards/alpha/keymaps/yhara/keymap.c:87:7: error: type de
faults to 'int' in declaration of 'rgblight_segment_t' [-Werror=implicit-int]
const rgblight_segment_t PROGMEM symbol_layer[] = RGBLIGHT_LAYER_SEGMENTS( ^~~~~~~~~~~~~~~~~~
keyboards/alpha/keymaps/yhara/keymap.c:87:34: error: expected ',' or ';' before 'symbol_layer'
const rgblight_segment_t PROGMEM symbol_layer[] = RGBLIGHT_LAYER_SEGMENTS(
^~~~~~~~~~~~
keyboards/alpha/keymaps/yhara/keymap.c:88:21: error: expected identifier or '(' before ',' token
{0, 10, HSV_RED}, // Light 4 LEDs, starting with LED 6
^
keyboards/alpha/keymaps/yhara/keymap.c:90:1: error: expected identifier or '(' before ')' token
);
^
keyboards/alpha/keymaps/yhara/keymap.c:91:7: error: type defaults to 'int' in declaration of 'rgblight_segment_t' [-Werror=implicit-int]
const rgblight_segment_t PROGMEM number_layer[] = RGBLIGHT_LAYER_SEGMENTS(
^~~~~~~~~~~~~~~~~~
keyboards/alpha/keymaps/yhara/keymap.c:91:34: error: expected ',' or ';' before 'number_layer'
const rgblight_segment_t PROGMEM number_layer[] = RGBLIGHT_LAYER_SEGMENTS(
^~~~~~~~~~~~
keyboards/alpha/keymaps/yhara/keymap.c:93:1: error: expected identifier or '(' before ')' token
);
^
keyboards/alpha/keymaps/yhara/keymap.c:94:7: error: type defaults to 'int' in declaration of 'rgblight_segment_t' [-Werror=implicit-int]
const rgblight_segment_t PROGMEM other_layer[] = RGBLIGHT_LAYER_SEGMENTS( [16/1934]
^~~~~~~~~~~~~~~~~~
keyboards/alpha/keymaps/yhara/keymap.c:94:34: error: expected ',' or ';' before 'other_layer'
const rgblight_segment_t PROGMEM other_layer[] = RGBLIGHT_LAYER_SEGMENTS(
^~~~~~~~~~~
keyboards/alpha/keymaps/yhara/keymap.c:96:1: error: expected identifier or '(' before ')' token
);
^
keyboards/alpha/keymaps/yhara/keymap.c:97:7: error: type defaults to 'int' in declaration of 'rgblight_segment_t' [-Werror=implicit-int]
const rgblight_segment_t PROGMEM cursor_layer[] = RGBLIGHT_LAYER_SEGMENTS(
^~~~~~~~~~~~~~~~~~
keyboards/alpha/keymaps/yhara/keymap.c:97:34: error: expected ',' or ';' before 'cursor_layer'
const rgblight_segment_t PROGMEM cursor_layer[] = RGBLIGHT_LAYER_SEGMENTS(
^~~~~~~~~~~~
keyboards/alpha/keymaps/yhara/keymap.c:99:1: error: expected identifier or '(' before ')' token
);
^
keyboards/alpha/keymaps/yhara/keymap.c:101:25: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
const rgblight_segment_t* const PROGMEM my_rgb_layers[] = {
^
keyboards/alpha/keymaps/yhara/keymap.c: In function 'keyboard_post_init_user':
keyboards/alpha/keymaps/yhara/keymap.c:110:5: error: 'rgblight_layers' undeclared (first use in this function); did you mean 'rgblight_ranges'?
rgblight_layers = my_rgb_layers;
^~~~~~~~~~~~~~~
rgblight_ranges
keyboards/alpha/keymaps/yhara/keymap.c:110:5: note: each undeclared identifier is reported only once for each function it appears in
keyboards/alpha/keymaps/yhara/keymap.c:110:23: error: 'my_rgb_layers' undeclared (first use in this function)
rgblight_layers = my_rgb_layers;
^~~~~~~~~~~~~
keyboards/alpha/keymaps/yhara/keymap.c: In function 'layer_state_set_user':
keyboards/alpha/keymaps/yhara/keymap.c:114:5: error: implicit declaration of function 'rgblight_set_layer_state'; did you mean 'rgblight_decrease_sat'? [-Werr
or=implicit-function-declaration]
rgblight_set_layer_state(0, layer_state_cmp(state, 1));
^~~~~~~~~~~~~~~~~~~~~~~~
rgblight_decrease_sat
cc1: all warnings being treated as errors
[ERRORS]
|
|
|
gmake[1]: *** [tmk_core/rules.mk:386: .build/obj_alpha_yhara/keyboards/alpha/keymaps/yhara/keymap.o] Error 1
gmake: *** [Makefile:584: alpha:yhara:flash] Error 1
Make finished with errors
#include QMK_KEYBOARD_H
#include "keymap_jp.h"
#define HOME 0
#define SYMBOL 1
#define NUMBER 2
#define OTHER 3 //FN
#define CURSOR 4
// DONT FORGET TO UPDATE COMBO_COUNT in config.h when adding a new combo
typedef const uint16_t comb_keys_t[];
static PROGMEM comb_keys_t
comb_keys_Enter = {KC_SPC, KC_SCLN, COMBO_END},
comb_keys_BackSpace = {KC_SPC, KC_P, COMBO_END},
comb_keys_Delete = {KC_SPC, KC_D, COMBO_END},
comb_keys_Tab = {KC_SPC, KC_Q, COMBO_END},
comb_keys_Kana = {KC_SPC, KC_B, COMBO_END},
comb_keys_Eisu = {KC_SPC, KC_V, COMBO_END},
comb_keys_Escape = {KC_SPC, KC_A, COMBO_END};
combo_t key_combos[7] = {
COMBO( comb_keys_Enter, KC_ENT ),
COMBO( comb_keys_BackSpace, KC_BSPC ),
COMBO( comb_keys_Delete, KC_DEL ),
COMBO( comb_keys_Tab, KC_TAB ),
COMBO( comb_keys_Kana, KC_LANG1 ),
COMBO( comb_keys_Eisu, KC_LANG2 ),
COMBO( comb_keys_Escape, KC_ESC ),
};
enum custom_keycodes {
MACRO1 = SAFE_RANGE
};
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
if (record->event.pressed) {
switch (keycode) {
case MACRO1:
SEND_STRING("I'm so sorry... -PyroL");
return false;
}
}
return true;
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[HOME] = LAYOUT(
KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, LT(OTHER,KC_P),
MT(MOD_LCTL,KC_A), LT(NUMBER,KC_S), LT(SYMBOL,KC_D), KC_F, KC_G, KC_H, KC_J, LT(SYMBOL,KC_K), LT(NUMBER,KC_L), MT(MOD_RCTL,KC_SCLN),
MT(MOD_LSFT,KC_Z), KC_X, KC_C, GUI_T(KC_V), LT(CURSOR,KC_SPC), KC_B, KC_N, MT(MOD_RSFT,KC_M)
),
[SYMBOL] = LAYOUT(
// ! @ # $ % ^ & ( ) *
KC_EXLM, JP_AT, KC_HASH, KC_DLR, KC_PERC, JP_CIRC, JP_AMPR, JP_LPRN, JP_RPRN, JP_ASTR,
// ~ | = \ ` ' { [ ] :
S(JP_CIRC),S(JP_YEN),JP_EQL,JP_YEN,JP_GRV, JP_QUOT, JP_LCBR, JP_LBRC, JP_RBRC, JP_COLN,
// _ + ? " } < >
JP_UNDS, JP_PLUS, S(KC_SLSH), JP_DQT, KC_SPC, JP_RCBR, S(KC_COMM), S(KC_DOT)),
[NUMBER] = LAYOUT(
KC_1, KC_2, KC_3, KC_4, KC_5, KC_1, KC_2, KC_3, KC_4, KC_5,
KC_6, KC_7, KC_8, KC_9, KC_0, KC_6, KC_7, KC_8, KC_9, KC_0,
KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO),
[OTHER] = LAYOUT(
RESET, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_TRNS,
KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO,
RGB_VAI, RGB_VAD, RGB_HUI, RGB_TOG, RGB_MOD, KC_MPLY, KC_VOLD, KC_VOLU),
[CURSOR] = LAYOUT(
KC_TAB, KC_NO, KC_END,KC_NO, KC_NO, KC_NO, KC_NO, S(KC_TAB), KC_TAB, KC_BSPC,
KC_HOME,KC_NO, KC_DEL, KC_NO, KC_NO, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_ENT,
KC_ESC, KC_NO, KC_NO, GUI_T(KC_LANG2),KC_TRNS,KC_LANG1, KC_NO, MOD_RSFT),
};
void matrix_init_user(void) {
}
void matrix_scan_user(void) {
}
//
// Lighting Layers
//
const rgblight_segment_t PROGMEM symbol_layer[] = RGBLIGHT_LAYER_SEGMENTS(
{0, 10, HSV_RED}, // Light 4 LEDs, starting with LED 6
{0, 10, HSV_RED} // Light 4 LEDs, starting with LED 12
);
const rgblight_segment_t PROGMEM number_layer[] = RGBLIGHT_LAYER_SEGMENTS(
{0, 10, HSV_CYAN}
);
const rgblight_segment_t PROGMEM other_layer[] = RGBLIGHT_LAYER_SEGMENTS(
{0, 10, HSV_PURPLE}
);
const rgblight_segment_t PROGMEM cursor_layer[] = RGBLIGHT_LAYER_SEGMENTS(
{0, 10, HSV_GREEN}
);
const rgblight_segment_t* const PROGMEM my_rgb_layers[] = {
symbol_layer,
number_layer,
other_layer,
cursor_layer,
NULL
};
void keyboard_post_init_user(void) {
rgblight_layers = my_rgb_layers;
}
layer_state_t layer_state_set_user(layer_state_t state) {
rgblight_set_layer_state(0, layer_state_cmp(state, 1));
rgblight_set_layer_state(1, layer_state_cmp(state, 2));
rgblight_set_layer_state(2, layer_state_cmp(state, 3));
rgblight_set_layer_state(3, layer_state_cmp(state, 4));
return state;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment