QMK breaking change update: haptic DRV_pulse function changed to drv2605l_pulse, and macros for that function changed, updated
This commit is contained in:
parent
ed866244a7
commit
93d8a77234
|
|
@ -22,7 +22,7 @@
|
|||
#include <string.h>
|
||||
#include "klor.h"
|
||||
#ifdef HAPTIC_ENABLE
|
||||
#include "drivers/haptic/DRV2605L.h"
|
||||
#include "drivers/haptic/drv2605l.h"
|
||||
#endif //HAPTIC ENABLE
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@
|
|||
#include <string.h>
|
||||
#include "klor.h"
|
||||
#ifdef HAPTIC_ENABLE
|
||||
#include "drivers/haptic/DRV2605L.h"
|
||||
#include "drivers/haptic/drv2605l.h"
|
||||
#endif //HAPTIC ENABLE
|
||||
|
||||
|
||||
|
|
@ -616,7 +616,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
#endif // AUDIO_ENABLE
|
||||
}
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(pulsing_strong);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_PULSING_STRONG_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
eeconfig_update_keymap(keymap_config.raw);
|
||||
clear_keyboard(); // ──── clear to prevent stuck keys
|
||||
|
|
@ -632,7 +632,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_COLEMAK);
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(transition_hum);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_TRANSITION_HUM_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
return false;
|
||||
|
|
@ -640,7 +640,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_QWERTY);
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(transition_hum);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_TRANSITION_HUM_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
return false;
|
||||
|
|
@ -692,7 +692,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
case KC_MPLY:
|
||||
if (record->event.pressed) {
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(sharp_click);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_SHARP_CLICK_100);
|
||||
#endif // HAPTIC_ENABL
|
||||
}
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@
|
|||
#include <string.h>
|
||||
#include "klor.h"
|
||||
#ifdef HAPTIC_ENABLE
|
||||
#include "drivers/haptic/DRV2605L.h"
|
||||
#include "drivers/haptic/drv2605l.h"
|
||||
#endif //HAPTIC ENABLE
|
||||
|
||||
|
||||
|
|
@ -608,7 +608,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
#endif // AUDIO_ENABLE
|
||||
}
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(pulsing_strong);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_PULSING_STRONG_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
eeconfig_update_keymap(keymap_config.raw);
|
||||
clear_keyboard(); // ──── clear to prevent stuck keys
|
||||
|
|
@ -624,7 +624,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_COLEMAK);
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(transition_hum);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_TRANSITION_HUM_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
return false;
|
||||
|
|
@ -632,7 +632,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_QWERTY);
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(transition_hum);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_TRANSITION_HUM_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
return false;
|
||||
|
|
@ -723,7 +723,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
case KC_MPLY:
|
||||
if (record->event.pressed) {
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(sharp_click);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_SHARP_CLICK_100);
|
||||
#endif // HAPTIC_ENABL
|
||||
}
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
#include "klor.h"
|
||||
|
||||
#ifdef HAPTIC_ENABLE
|
||||
#include "drivers/haptic/DRV2605L.h"
|
||||
#include "drivers/haptic/drv2605l.h"
|
||||
#endif //HAPTIC ENABLE
|
||||
|
||||
/*
|
||||
|
|
@ -686,7 +686,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
#endif // AUDIO_ENABLE
|
||||
}
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(pulsing_strong);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_PULSING_STRONG_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
eeconfig_update_keymap(keymap_config.raw);
|
||||
clear_keyboard(); // ──── clear to prevent stuck keys
|
||||
|
|
@ -702,7 +702,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_COLEMAK);
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(transition_hum);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_TRANSITION_HUM_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
return false;
|
||||
|
|
@ -710,7 +710,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_QWERTY);
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(transition_hum);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_TRANSITION_HUM_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
return false;
|
||||
|
|
@ -718,14 +718,14 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
if (record->event.pressed) {
|
||||
layer_off(_TVPAINT1);
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(pulsing_strong);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_PULSING_STRONG_1_100);
|
||||
#endif // HAPTIC
|
||||
}
|
||||
return false;
|
||||
case TVP1:
|
||||
if (record->event.pressed) {
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(transition_hum);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_TRANSITION_HUM_1_100);
|
||||
#endif // HAPTIC
|
||||
}
|
||||
break;
|
||||
|
|
@ -797,7 +797,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
SEND_STRING(SS_LSFT(SS_LWIN("S"))); //WIN
|
||||
}
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(strong_click1);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_STRONG_CLICK_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
break;
|
||||
|
|
@ -805,7 +805,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
case KC_MPLY:
|
||||
if (record->event.pressed) {
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(sharp_click);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_SHARP_CLICK_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
break;
|
||||
|
|
@ -813,7 +813,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
case LCTL(KC_S):
|
||||
if (record->event.pressed) {
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(medium_click1);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_MEDIUM_CLICK_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
break;
|
||||
|
|
@ -821,7 +821,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
case KC_CAPS:
|
||||
if (record->event.pressed) {
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(medium_click1);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_MEDIUM_CLICK_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
#ifdef AUDIO_ENABLE
|
||||
led_t led_usb_state = host_keyboard_led_state();
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@
|
|||
#include <string.h>
|
||||
#include "klor.h"
|
||||
#ifdef HAPTIC_ENABLE
|
||||
#include "drivers/haptic/DRV2605L.h"
|
||||
#include "drivers/haptic/drv2605l.h"
|
||||
#endif //HAPTIC ENABLE
|
||||
|
||||
// clang-format off
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#if HAPTIC_ENABLE
|
||||
#include "drivers/haptic/DRV2605L.h"
|
||||
#include "drivers/haptic/drv2605l.h"
|
||||
#endif //HAPTIC ENABLE
|
||||
|
||||
// ┌────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
|
||||
|
|
@ -507,7 +507,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
#endif // AUDIO_ENABLE
|
||||
}
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(pulsing_strong);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_PULSING_STRONG_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
eeconfig_update_keymap(keymap_config.raw);
|
||||
clear_keyboard(); // ──── clear to prevent stuck keys
|
||||
|
|
@ -517,7 +517,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_QWERTY);
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(pulsing_strong);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_PULSING_STRONG_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
return false;
|
||||
|
|
@ -525,7 +525,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_COLEMAK);
|
||||
#ifdef HAPTIC_ENABLE
|
||||
DRV_pulse(pulsing_strong);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_PULSING_STRONG_1_100);
|
||||
#endif // HAPTIC_ENABLE
|
||||
}
|
||||
return false;
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ oled_rotation_t oled_init_kb(oled_rotation_t rotation) {
|
|||
|
||||
|
||||
//#ifdef HAPTIC_ENABLE
|
||||
//#include "drivers/haptic/DRV2605L.h"
|
||||
//#include "drivers/haptic/drv2605l.h"
|
||||
//#endif //HAPTIC ENABLE
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@
|
|||
|
||||
#ifdef HAPTIC_ENABLE
|
||||
|
||||
#include "drivers/haptic/DRV2605L.h"
|
||||
#include "drivers/haptic/drv2605l.h"
|
||||
|
||||
layer_state_t fp_layer_state_set_haptic(layer_state_t state) {
|
||||
switch (get_highest_layer(state)) {
|
||||
|
|
@ -37,17 +37,17 @@ bool fp_process_record_haptic(uint16_t keycode, keyrecord_t *record) {
|
|||
# ifdef FP_HAPTIC_MOUSE_BUTTONS
|
||||
case KC_BTN1:
|
||||
if (record->event.pressed) {
|
||||
DRV_pulse(medium_click1);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_MEDIUM_CLICK_1_100);
|
||||
}
|
||||
break;
|
||||
case KC_BTN2:
|
||||
if (record->event.pressed) {
|
||||
DRV_pulse(sh_dblclick_str);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_SHORT_DOUBLE_CLICK_STRONG_1_100);
|
||||
}
|
||||
break;
|
||||
case KC_BTN3:
|
||||
if (record->event.pressed) {
|
||||
DRV_pulse(medium_click1);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_MEDIUM_CLICK_1_100);
|
||||
}
|
||||
break;
|
||||
# endif
|
||||
|
|
@ -59,7 +59,7 @@ bool fp_process_record_haptic(uint16_t keycode, keyrecord_t *record) {
|
|||
# else
|
||||
if ((get_mods() & MOD_MASK_CTRL) || (get_oneshot_mods() & MOD_MASK_CTRL)) {
|
||||
# endif
|
||||
DRV_pulse(lg_dblclick_str);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_LONG_DOUBLE_SHARP_CLICK_STRONG_1_100);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
|
@ -70,7 +70,7 @@ bool fp_process_record_haptic(uint16_t keycode, keyrecord_t *record) {
|
|||
# else
|
||||
if ((get_mods() & MOD_MASK_CTRL) || (get_oneshot_mods() & MOD_MASK_CTRL)) {
|
||||
# endif
|
||||
DRV_pulse(lg_dblclick_str);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_LONG_DOUBLE_SHARP_CLICK_STRONG_1_100);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
|
@ -81,7 +81,7 @@ bool fp_process_record_haptic(uint16_t keycode, keyrecord_t *record) {
|
|||
# else
|
||||
if ((get_mods() & MOD_MASK_CTRL) || (get_oneshot_mods() & MOD_MASK_CTRL)) {
|
||||
# endif
|
||||
DRV_pulse(soft_bump);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_SOFT_BUMP_100);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
|
@ -95,7 +95,7 @@ bool fp_process_record_haptic(uint16_t keycode, keyrecord_t *record) {
|
|||
# else
|
||||
if ((get_mods() & MOD_MASK_CTRL) || (get_oneshot_mods() & MOD_MASK_CTRL)) {
|
||||
# endif
|
||||
DRV_pulse(soft_bump);
|
||||
drv2605l_pulse(DRV2605L_EFFECT_SOFT_BUMP_100);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
|
|
|||
Loading…
Reference in New Issue