#include "config_common.h"
+#ifndef LIGHT_CONFIG_H
#define BACKLIGHT_BREATHING
#define BREATHING_PERIOD 3
+#endif
#ifdef AUDIO_ENABLE
#define STARTUP_SONG SONG(PLANCK_SOUND)
case QWERTY:
if (record->event.pressed) {
set_single_persistent_default_layer(_QWERTY);
- breathing_self_disable();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_self_disable();
+ #endif
}
return false;
break;
case DATA:
if (record->event.pressed) {
set_single_persistent_default_layer(_DATA);
- #ifdef BACKLIGHT_ENABLE
+ #ifdef BACKLIGHT_BREATHING
breathing_enable();
#endif
}
layer_on(_LOWER);
uint8_t default_layer = biton32(default_layer_state);
if (default_layer == _QWERTY) {
- #ifdef BACKLIGHT_ENABLE
+ #ifdef BACKLIGHT_BREATHING
breathing_enable();
#endif
}
layer_off(_LOWER);
uint8_t default_layer = biton32(default_layer_state);
if (default_layer == _QWERTY) {
- breathing_self_disable();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_self_disable();
+ #endif
}
update_tri_layer(_LOWER, _RAISE, _ADJUST);
}
layer_on(_RAISE);
uint8_t default_layer = biton32(default_layer_state);
if (default_layer == _QWERTY) {
- #ifdef BACKLIGHT_ENABLE
+ #ifdef BACKLIGHT_BREATHING
breathing_enable();
#endif
}
layer_off(_RAISE);
uint8_t default_layer = biton32(default_layer_state);
if (default_layer == _QWERTY) {
- breathing_self_disable();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_self_disable();
+ #endif
}
update_tri_layer(_LOWER, _RAISE, _ADJUST);
}
case BACKLIT:
if (record->event.pressed) {
register_code(KC_RSFT);
- #ifdef BACKLIGHT_ENABLE
+ #ifdef BACKLIGHT_BREATHING
backlight_step();
#endif
} else {
#include "../../config.h"
#define LEADER_TIMEOUT 300
+
+#ifndef LIGHT_CONFIG_H
#define BACKLIGHT_BREATHING
+#endif
/* cbbrowne user configuration */
if (record->event.pressed)
{
layer_on(_RAISE);
-#ifdef BACKLIGHT_ENABLE
+#ifdef BACKLIGHT_BREATHING
breathing_period_set(2);
breathing_pulse();
#endif
if (record->event.pressed)
{
layer_on(_LOWER);
-#ifdef BACKLIGHT_ENABLE
+#ifdef BACKLIGHT_BREATHING
breathing_period_set(2);
breathing_pulse();
#endif
}
#endif
+#ifndef LIGHT_CONFIG_H
#define BACKLIGHT_BREATHING
+#endif
#define TAPPING_TERM 150
#define MUSIC_MASK (keycode != KC_NO)
switch(id) {
case MACRO_BREATH_TOGGLE:
if (record->event.pressed) {
- breathing_toggle();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_toggle();
+ #endif
}
break;
case MACRO_BREATH_SPEED_INC:
if (record->event.pressed) {
- breathing_period_inc();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_inc();
+ #endif
}
break;
case MACRO_BREATH_SPEED_DEC:
if (record->event.pressed) {
- breathing_period_dec();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_dec();
+ #endif
}
break;
case MACRO_BREATH_DEFAULT:
if (record->event.pressed) {
- breathing_period_default();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_default();
+ #endif
}
break;
}
#define MATRIX_COLS 12
/* Planck PCB default pin-out */
+#ifndef LIGHT_CONFIG_H
#define MATRIX_ROW_PINS { D0, D5, B5, B6 }
#define MATRIX_COL_PINS { F1, F0, B0, C7, F4, F5, F6, F7, D4, D6, B4, D7 }
#define UNUSED_PINS
+#endif
/*
* MIDI options
/* Only print user print statements */
#define USER_PRINT
+#ifndef LIGHT_CONFIG_H
#define BACKLIGHT_BREATHING
+#endif
/* disable action features */
//#define NO_ACTION_LAYER
case MACRO_BREATH_TOGGLE:
if (record->event.pressed)
{
+ #ifdef BACKLIGHT_BREATHING
breathing_toggle();
+ #endif
}
break;
case MACRO_BREATH_SPEED_INC:
if (record->event.pressed)
{
+ #ifdef BACKLIGHT_BREATHING
breathing_period_inc();
+ #endif
}
break;
case MACRO_BREATH_SPEED_DEC:
if (record->event.pressed)
{
+ #ifdef BACKLIGHT_BREATHING
breathing_period_dec();
+ #endif
}
break;
case MACRO_BREATH_DEFAULT:
if (record->event.pressed)
{
+ #ifdef BACKLIGHT_BREATHING
breathing_period_default();
+ #endif
}
break;
if (record->event.pressed)
{
layer_on(LAYER_UPPER);
- breathing_period_set(2);
- breathing_pulse();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_set(2);
+ breathing_pulse();
+ #endif
update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
}
else
if (record->event.pressed)
{
layer_on(LAYER_LOWER);
- breathing_period_set(2);
- breathing_pulse();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_set(2);
+ breathing_pulse();
+ #endif
update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
}
else
case MACRO_FUNCTION:
if (record->event.pressed)
{
- breathing_period_set(3);
- breathing_enable();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_set(3);
+ breathing_enable();
+ #endif
layer_on(LAYER_FUNCTION);
}
else
{
- breathing_period_set(1);
- breathing_self_disable();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_set(1);
+ breathing_self_disable();
+ #endif
layer_off(LAYER_FUNCTION);
}
break;
#define MATRIX_COLS 12
/* Planck PCB default pin-out */
+#ifndef LIGHT_CONFIG_H
#define MATRIX_ROW_PINS { D0, D5, B5, B6 }
#define MATRIX_COL_PINS { F1, F0, B0, C7, F4, F5, F6, F7, D4, D6, B4, D7 }
#define UNUSED_PINS
+#endif
/* Prevent use of disabled MIDI features in the keymap */
//#define MIDI_ENABLE_STRICT 1
/* Only print user print statements */
#define USER_PRINT
+#ifndef LIGHT_CONFIG_H
#define BACKLIGHT_BREATHING
+#endif
/* disable action features */
//#define NO_ACTION_LAYER
case MACRO_BREATH_TOGGLE:
if (record->event.pressed)
{
+ #ifdef BACKLIGHT_BREATHING
breathing_toggle();
+ #endif
}
break;
case MACRO_BREATH_SPEED_INC:
if (record->event.pressed)
{
+ #ifdef BACKLIGHT_BREATHING
breathing_period_inc();
+ #endif
}
break;
case MACRO_BREATH_SPEED_DEC:
if (record->event.pressed)
{
+ #ifdef BACKLIGHT_BREATHING
breathing_period_dec();
+ #endif
}
break;
case MACRO_BREATH_DEFAULT:
if (record->event.pressed)
{
+ #ifdef BACKLIGHT_BREATHING
breathing_period_default();
+ #endif
}
break;
if (record->event.pressed)
{
layer_on(LAYER_UPPER);
- breathing_period_set(2);
- breathing_pulse();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_set(2);
+ breathing_pulse();
+ #endif
update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
}
else
if (record->event.pressed)
{
layer_on(LAYER_LOWER);
- breathing_period_set(2);
- breathing_pulse();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_set(2);
+ breathing_pulse();
+ #endif
update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
}
else
case MACRO_FUNCTION:
if (record->event.pressed)
{
- breathing_period_set(3);
- breathing_enable();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_set(3);
+ breathing_enable();
+ #endif
layer_on(LAYER_FUNCTION);
}
else
{
- breathing_period_set(1);
- breathing_self_disable();
+ #ifdef BACKLIGHT_BREATHING
+ breathing_period_set(1);
+ breathing_self_disable();
+ #endif
layer_off(LAYER_FUNCTION);
}
break;