* Branch point for 2020 November 28 Breaking Change
* Remove matrix_col_t to allow MATRIX_ROWS > 32 (#10183)
* Add support for soft serial to ATmega32U2 (#10204)
* Change MIDI velocity implementation to allow direct control of velocity value (#9940)
* Add ability to build a subset of all keyboards based on platform.
* Actually use eeprom_driver_init().
* Make bootloader_jump weak for ChibiOS. (#10417)
* Joystick 16-bit support (#10439)
* Per-encoder resolutions (#10259)
* Share button state from mousekey to pointing_device (#10179)
* Add hotfix for chibios keyboards not wake (#10088)
* Add advanced/efficient RGB Matrix Indicators (#8564)
* Naming change.
* Support for STM32 GPIOF,G,H,I,J,K (#10206)
* Add milc as a dependency and remove the installed milc (#10563)
* ChibiOS upgrade: early init conversions (#10214)
* ChibiOS upgrade: configuration file migrator (#9952)
* Haptic and solenoid cleanup (#9700)
* XD75 cleanup (#10524)
* OLED display update interval support (#10388)
* Add definition based on currently-selected serial driver. (#10716)
* New feature: Retro Tapping per key (#10622)
* Allow for modification of output RGB values when using rgblight/rgb_matrix. (#10638)
* Add housekeeping task callbacks so that keyboards/keymaps are capable of executing code for each main loop iteration. (#10530)
* Rescale both ChibiOS and AVR backlighting.
* Reduce Helix keyboard build variation (#8669)
* Minor change to behavior allowing display updates to continue between task ticks (#10750)
* Some GPIO manipulations in matrix.c change to atomic. (#10491)
* qmk cformat (#10767)
* [Keyboard] Update the Speedo firmware for v3.0 (#10657)
* Maartenwut/Maarten namechange to evyd13/Evy (#10274)
* [quantum] combine repeated lines of code (#10837)
* Add step sequencer feature (#9703)
* aeboards/ext65 refactor (#10820)
* Refactor xelus/dawn60 for Rev2 later (#10584)
* add DEBUG_MATRIX_SCAN_RATE_ENABLE to common_features.mk (#10824)
* [Core] Added `add_oneshot_mods` & `del_oneshot_mods` (#10549)
* update chibios os usb for the otg driver (#8893)
* Remove HD44780 References, Part 4 (#10735)
* [Keyboard] Add Valor FRL TKL (+refactor) (#10512)
* Fix cursor position bug in oled_write_raw functions (#10800)
* Fixup version.h writing when using SKIP_VERSION=yes (#10972)
* Allow for certain code in the codebase assuming length of string. (#10974)
* Add AT90USB support for serial.c (#10706)
* Auto shift: support repeats and early registration (#9826)
* Rename ledmatrix.h to match .c file (#7949)
* Split RGB_MATRIX_ENABLE into _ENABLE and _DRIVER (#10231)
* Split LED_MATRIX_ENABLE into _ENABLE and _DRIVER (#10840)
* Merge point for 2020 Nov 28 Breaking Change
* First pass
* Add config options to docs
* Update some wording
* Slight tidy up of backlight caps logic
* Init pin to correct state
* Move init location
* Reverse default state
* Better handle LTO_ENABLE
Especially when calling from command line
* Replace LINK_TIME_OPTIMIZATION_ENABLE with LTO_ENABLE
* Remove long for LTO from show_options.mk
* Initialize Layer State on startup
Right now, on startup, the default layer state gets called and set, triggering the callback functions for the default layer state. However, the normal layer state never actually gets initialized. It's set to 0 directly, by default, but the callback functions are never actually called. This creates some inconsistency in the behavior for end users. This adds a simple "clear" that triggers the callback on startup. This should produce more consisten behavior between the two functions and layer masks.
* Stupid hack
* Fix type casting?
* Fix compile issues with magic is disabled
* add support for hid gamepad interface
add documentation for HID joystick
Add joystick_task to read analog axes values even when no key is pressed or release. update doc
Update docs/feature_joystick.md
Manage pin setup and read to maintain matrix scan after analog read
* Incorporates patches and changes to HID reporting
There are some patches provided by @a-chol incorporated on this commit,
and also some changes I made to the HID Report structure.
The most interesting is the one dealing with number of buttons: Linux
doesn't seem to care, but Windows requires the HID structure to be byte
aligned (that's in the spec). So if one declares 8/16/32... buttons they
should not have any issues, but this is what happens when you have 9
buttons:
```
bits |0|1|2|3|4|5|6|7|
|*|*|*|*|*|*|*|*| axis 0 (report size 8)
|*|*|*|*|*|*|*|*| ...
|*|*|*|*|*|*|*|*|
|*|*|*|*|*|*|*|*|
|*|*|*|*|*|*|*|*|
|*|*|*|*|*|*|*|*|
|*|*|*|*|*|*|*|*| axis 6
|*|*|*|*|*|*|*|*| first 8 buttons (report size 1)
|*| | | | | | | | last of 9 buttons, not aligned
```
So for that I added a conditonal that will add a number of reports with
size 1 to make sure it aligns to the next multiple of 8. Those reports
send dummy inputs that don't do anything aside from aligning the data.
Tested on Linux, Windows 10 and Street Fighter (where the joystick is
recognized as direct-input)
* Add save and restore of each pin used in reading joystick (AVR).
Allow output pin to be JS_VIRTUAL_AXIS if the axis is connected to Vcc
instead of an output pin from the MCU.
Fix joystick report id
Fix broken v-usb hid joystick interface. Make it more resilient to unusual settings (none multiple of eight button count, 0 buttons or 0 axes)
Correct adc reading for multiple axes. Piecewise range conversion for uncentered raw value range. Input, output and ground pin configuration per axis.
Documentation fixes
* Fix port addressing for joystick analog read
* The other required set of changes
As per the PR, the changes still holding it up.
Add onekey for testing.
Fix ARM builds.
Fix device descriptor when either axes or buttons is zero.
Add compile-time check for at least one axis or button.
Move definition to try to fix conflict.
PR review comments.
qmk cformat
* avoid float functions to compute range mapping for axis adc reading
* Remove V-USB support for now. Updated docs accordingly.
* Update tmk_core/protocol/lufa/lufa.c
Co-Authored-By: Ryan <fauxpark@gmail.com>
* Update tmk_core/protocol/usb_descriptor.c
Co-Authored-By: Ryan <fauxpark@gmail.com>
* Update tmk_core/protocol/usb_descriptor.c
Co-Authored-By: Ryan <fauxpark@gmail.com>
* Update tmk_core/protocol/usb_descriptor.c
Co-Authored-By: Ryan <fauxpark@gmail.com>
* Add support for joystick adc reading for stm32 MCUs. Fix joystick hid report sending for chibios
* Fix HID joystick report sending for ChibiOS.
Add one analog axis to the onekey:joystick keymap.
Fix pin state save and restore during joystick analog read for STM32
MCUs.
* Update tmk_core/protocol/chibios/usb_main.c
Co-Authored-By: Ryan <fauxpark@gmail.com>
* Update tmk_core/protocol/lufa/lufa.c
Co-Authored-By: Ryan <fauxpark@gmail.com>
* Add missing mcuconf.h and halconf.h to onekey:joystick keymap.
Add suggested fixes from PR.
* Switch saveState and restoreState signature to use pin_t type.
onekey:joystick : add a second axis, virtual and programmatically animated.
* Update docs/feature_joystick.md
Co-Authored-By: Ryan <fauxpark@gmail.com>
* Update docs/feature_joystick.md
Co-Authored-By: Ryan <fauxpark@gmail.com>
* Add PR corrections
* Remove halconf.h and mcuconf.h from onekey keymaps
* Change ADC_PIN to A0
Co-authored-by: achol <allecooll@hotmail.com>
Co-authored-by: José Júnior <jose.junior@gmail.com>
Co-authored-by: a-chol <achol@notamail.com>
Co-authored-by: Nick Brassel <nick@tzarc.org>
Co-authored-by: Ryan <fauxpark@gmail.com>
* Re-fix the dual-bank bootloader stuff.
* Use wait_ms() instead of using nop's for a delay, as ChibiOS is actually running at the time of bootloader jump.
Mousekey scrolling should have a separate repeat variable
to keep track of scrolling acceleration, instead of being
tied to mouse movement scolling in mousekeys. The send function
should record when the last movement was made since this is
when movement is actually sent. Doing this fixes the bug where
the initial press of a mousekey scroll button causes a double scroll.
Signed-off-by: Daniel Hong <daniel.hong@live.com>
Fixes the handling for the oneshot cleanup, so it only cleans up if it is active. It should not cleanup of SHO is off (eg using a normal oneshot key), nor if it's actively pressed or used.
Previous behavior BROKE swap hand key.
* I2C_TIMEOUT is not defined on arm teensy
* Work round teensy having different ChibiOS config options
* Stash OLED conf files
* update comment
* update comment
* Remove stm32 alias to allow teensy alt mode
With this change, when ps2_mouse is disabled, mousekeys works as usual. With
ps2_mouse enabled, mousekeys button state is shared with ps2_mouse for clicking,
dragging, and scrolling, mousekeys clicks are produced by ps2_mouse only, and
mouskeys button state is transferred to mousekeys without generating clicks to
enable mousekeys dragging.
Co-authored-by: Drashna Jaelre <drashna@live.com>
Co-authored-by: Drashna Jaelre <drashna@live.com>
* init
* add RETRO_TAP; tap anyway after TAP_TERM, if no interruption
* RETRO_TAP works for other types of taps
* revert to upstream/master
* explain this fork in readme
* use one readme.md file instaed
* fix the error if NO_ACTION_ONESHOT is defined
* restore readme.md to upstream master
Co-authored-by: Tsan-Kuang Lee <tsan.kuang.lee@gmail.com>
* Branch point for 2020 May 30 Breaking Change
* Migrate `ACTION_LAYER_TOGGLE` to `TG()` (#8954)
* Migrate `ACTION_MODS_ONESHOT` to `OSM()` (#8957)
* Migrate `ACTION_DEFAULT_LAYER_SET` to `DF()` (#8958)
* Migrate `ACTION_LAYER_MODS` to `LM()` (#8959)
* Migrate `ACTION_MODS_TAP_KEY` to `MT()` (#8968)
* Convert V-USB usbdrv to a submodule (#8321)
* Unify Tap Hold functions and documentation (#8348)
* Changing board names to prevent confusion (#8412)
* Move the Keyboardio Model01 to a keyboardio/ subdir (#8499)
* Move spaceman keyboards (#8830)
* Migrate miscellaneous `fn_actions` entries (#8977)
* Migrate `ACTION_MODS_KEY` to chained mod keycodes (#8979)
* Organizing my keyboards (plaid, tartan, ergoinu) (#8537)
* Refactor Lily58 to use split_common (#6260)
* Refactor zinc to use split_common (#7114)
* Add a message if bin/qmk doesn't work (#9000)
* Fix conflicting types for 'tfp_printf' (#8269)
* Fixed RGB_DISABLE_AFTER_TIMEOUT to be seconds based & small internals cleanup (#6480)
* Refactor and updates to TKC1800 code (#8472)
* Switch to qmk forks for everything (#9019)
* audio refactor: replace deprecated PLAY_NOTE_ARRAY (#8484)
* Audio enable corrections (2/3) (#8903)
* Split HHKB to ANSI and JP layouts and Add VIA support for each (#8582)
* Audio enable corrections (Part 4) (#8974)
* Fix typo from PR7114 (#9171)
* Augment future branch Changelogs (#8978)
* Revert "Branch point for 2020 May 30 Breaking Change"
This commits add the SH_OS keycode, which works similarly to one shot
layers:
* while pressed, the keyboard is swapped
* if no keys were pressed while it was pressed, the next key press is
swapped
SH_OS also supports chaining with one shot layers:
OSL(x) + SH_OS + key interprets the key press on the oneshot layer.
The ONESHOT_TIMEOUT setting used by one shot keys and layers is also
used by oneshot swap hands. In the above chaining scenario the timeout
of the oneshot layer is reset when swap hands is activated.
Resolves#2682
* Refactor to use mpaland/printf
* trim firmware size
* remove keymap changes
* run clang format
* Fixup after rebase
* fix up git-submodule command for printf
* tmk_core/common: Fixing TIMER_DIFF macro to calculate difference correctly after the timer wraps.
Let's go through an example, using the following macro:
If the first timer read is 0xe4 and the second one is 0x32, the timer wrapped.
If the timer would have had more bits, it's new value would have been 0x132,
and the correct difference in time is 0x132 - 0xe4 = 0x4e
old code TIMER_DIFF_8(0x32, 0xe4) = 0xff - 0xe4 + 0x32 = 0x4d, which is wrong.
new code TIMER_DIFF_8(0x32, 0xe4) = 0xff + 1 - 0xe4 + 0x32 = 0x4e, which is correct.
This also gives a chance for a smart compiler to optimize the code using normal
integer overflow.
For example on AVR, the following C code:
uint8_t __attribute__ ((noinline)) test(uint8_t current_timer, uint8_t start_timer)
{
return TIMER_DIFF_8(current_timer, start_timer);
}
With the original code, it gets translated to the following list of instructions:
00004c6e <test>:
4c6e: 98 2f mov r25, r24
4c70: 86 1b sub r24, r22
4c72: 96 17 cp r25, r22
4c74: 08 f4 brcc .+2 ; 0x4c78 <test+0xa>
4c76: 81 50 subi r24, 0x01 ; 1
4c78: 08 95 ret
But with this commit, it gets translated to a single instruction:
00004c40 <test>:
4c40: 86 1b sub r24, r22
4c42: 08 95 ret
This unfortunately doesn't always work so nicely, for example the following C code:
int __attribute__ ((noinline)) test(uint8_t current_timer, uint8_t start_timer)
{
return TIMER_DIFF_8(current_timer, start_timer);
}
(Note: return type changed to int)
With the original code it gets translated to:
00004c6e <test>:
4c6e: 28 2f mov r18, r24
4c70: 30 e0 ldi r19, 0x00 ; 0
4c72: 46 2f mov r20, r22
4c74: 50 e0 ldi r21, 0x00 ; 0
4c76: 86 17 cp r24, r22
4c78: 20 f0 brcs .+8 ; 0x4c82 <test+0x14>
4c7a: c9 01 movw r24, r18
4c7c: 84 1b sub r24, r20
4c7e: 95 0b sbc r25, r21
4c80: 08 95 ret
4c82: c9 01 movw r24, r18
4c84: 84 1b sub r24, r20
4c86: 95 0b sbc r25, r21
4c88: 81 50 subi r24, 0x01 ; 1
4c8a: 9f 4f sbci r25, 0xFF ; 255
4c8c: 08 95 ret
Wth this commit it gets translated to:
00004c40 <test>:
4c40: 28 2f mov r18, r24
4c42: 30 e0 ldi r19, 0x00 ; 0
4c44: 46 2f mov r20, r22
4c46: 50 e0 ldi r21, 0x00 ; 0
4c48: 86 17 cp r24, r22
4c4a: 20 f0 brcs .+8 ; 0x4c54 <test+0x14>
4c4c: c9 01 movw r24, r18
4c4e: 84 1b sub r24, r20
4c50: 95 0b sbc r25, r21
4c52: 08 95 ret
4c54: c9 01 movw r24, r18
4c56: 84 1b sub r24, r20
4c58: 95 0b sbc r25, r21
4c5a: 93 95 inc r25
4c5c: 08 95 ret
There is not much performance improvement in this case, however at least with this
commit it functions correctly.
Note: The following commit will improve compiler output for the latter example.
* tmk_core/common: Improve code generation for TIMER_DIFF* macros
Because of integer promotion the compiler is having a hard time generating
efficient code to calculate TIMER_DIFF* macros in some situations.
In the below example, the return value is "int", and this is causing the
trouble.
Example C code:
int __attribute__ ((noinline)) test(uint8_t current_timer, uint8_t start_timer)
{
return TIMER_DIFF_8(current_timer, start_timer);
}
BEFORE: (with -Os)
00004c40 <test>:
4c40: 28 2f mov r18, r24
4c42: 30 e0 ldi r19, 0x00 ; 0
4c44: 46 2f mov r20, r22
4c46: 50 e0 ldi r21, 0x00 ; 0
4c48: 86 17 cp r24, r22
4c4a: 20 f0 brcs .+8 ; 0x4c54 <test+0x14>
4c4c: c9 01 movw r24, r18
4c4e: 84 1b sub r24, r20
4c50: 95 0b sbc r25, r21
4c52: 08 95 ret
4c54: c9 01 movw r24, r18
4c56: 84 1b sub r24, r20
4c58: 95 0b sbc r25, r21
4c5a: 93 95 inc r25
4c5c: 08 95 ret
AFTER: (with -Os)
00004c40 <test>:
4c40: 86 1b sub r24, r22
4c42: 90 e0 ldi r25, 0x00 ; 0
4c44: 08 95 ret
Note: the example is showing -Os but improvements can be seen at all optimization levels,
including -O0. We never use -O0, but I tested it to make sure that no extra code is
generated in that case.OA
* quantum/debounce: Fix custom wrapping timers in eager_pr and eager_pk debounce algorithms
Please see the below simulated sequence of events:
Column A is the 16-bit value returned by read_timer();
Column B is the value returned by custom_wrap_timer_read();
Column C is the original code: (timer_read() % MAX_DEBOUNCE)
A, B, C
65530, 19, 30
65531, 20, 31
65532, 21, 32
65533, 22, 33
65534, 23, 34
65535, 24, 35
0 25, 0
1, 26, 1
2, 27, 2
3, 28, 3
4, 29, 4
5, 30, 5
read_timer() wraps about every 1.09 seconds, and so debouncing might
fail at these times without this commit.
* quantum/debounce/eager_pr and eager_pk: modifications for code readability according to code review.
* quantum/debounce/eager_pr and eager_pk: modifications for code readability according to code review. (2)
* Define NO_ACTION_MACRO/FUNCTION in header instead of makefile when LTO is enabled
Currently, boards and keymaps that define NO_ACTION_MACRO/FUNCTION unconditionally
will not compile with LTO_ENABLE (#8604). This fixes the issue by moving the
definitions from common.mk to action.h, which enables us to check for previous
definitions of those macros (this cannot be done in a makefile).
* Remove LTO checks in templates
Since now NO_ACTION_MACRO/FUNCTION are defined as needed in action.h (which is
included by quantum.h), checking for LTO in keyboard and user code is no
longer required.
* Update LTO_ENABLE docs
* Update tmk_core/common/progmem.h
Co-Authored-By: Ryan <fauxpark@gmail.com>
* Update quantum/rgblight.c
Co-Authored-By: Ryan <fauxpark@gmail.com>
* fixed problem with implicit declaration in quantum/rgblight.c (#8381)
Co-authored-by: Ryan <fauxpark@gmail.com>
* Port over some AVR backlight logic to SLEEP_LED
* Port over some AVR backlight logic to SLEEP_LED - add timer 3
* Port over some AVR backlight logic to SLEEP_LED - clang format
* Enable SLEEP_LED within vusb protocol
* Improve process_record system
Code based on @colinta's
* Rename and better handle functions
* Fix incorrect function call to process_record_user
* Add documentation for post_process_record
* Add both get_event_keycode and get_record_keycode functions
And add some comments about these functions
* Update code format
* Cleanup merge artifacts
* Add support for Bootmagic lite when using SPLIT_HAND_PIN
* Deduplicate bootmagic_lite logic from within via
* Revert location of defaults so that user overrides still work for now
* Tidy up code slightly
* Fix extra keyboard report during test_fixture teardown
* Add tests for pressing two keys with only different modifers
* Fix#1708
When two keys that use the same keycode, but different modifiers were
pressed at the same time, the second keypress wasn't registered. This is
fixed by forcing a key release when we detect a new press for the same
keycode.
* Fix the NKRO version of is_key_pressed
* Fix uninitalized loop variable
Co-authored-by: Jack Humbert <jack.humb@gmail.com>
* Moved contents of rgblight_reconfig.h to rgblight_post_config.h.
In #3582, rgblight_reconfig.h had to be newly created. Now, the build system of qmk_firmware has a post_cofig feature, so that what was done in rgblight_reconfig.h can now be realized in rgblight_post_config.h.
**This commit does not change the build result.**
Testing script
```shell
# build on master
git checkout master
echo master > /tmp/master_md5.txt
# RGBLIGHT_ENABLE = no
make HELIX=verbose helix/rev2:default:clean
make HELIX=verbose helix/rev2:default
md5 helix_rev2_default.hex >> /tmp/master_md5.txt
# RGBLIGHT_ENABLE = yes, with animations
make HELIX=verbose helix/rev2/back:default:clean
make HELIX=verbose helix/rev2/back:default
md5 helix_rev2_back_default.hex >> /tmp/master_md5.txt
# RGBLIGHT_ENABLE = yes, without animations
make HELIX=verbose,no_ani helix/rev2/back:default:clean
make HELIX=verbose,no_ani helix/rev2/back:default
md5 helix_rev2_back_default.hex >> /tmp/master_md5.txt
# build on refactor_rgblight_reconfig.h
git checkout refactor_rgblight_reconfig.h
echo refactor_rgblight_reconfig.h > /tmp/branch_md5.txt
# RGBLIGHT_ENABLE = no
make HELIX=verbose helix/rev2:default:clean
make HELIX=verbose helix/rev2:default
md5 helix_rev2_default.hex >> /tmp/branch_md5.txt
# RGBLIGHT_ENABLE = yes, with animations
make HELIX=verbose helix/rev2/back:default:clean
make HELIX=verbose helix/rev2/back:default
md5 helix_rev2_back_default.hex >> /tmp/branch_md5.txt
# RGBLIGHT_ENABLE = yes, without animations
make HELIX=verbose,no_ani helix/rev2/back:default:clean
make HELIX=verbose,no_ani helix/rev2/back:default
md5 helix_rev2_back_default.hex >> /tmp/branch_md5.txt
diff -u /tmp/master_md5.txt /tmp/branch_md5.txt
```
Test result:
```
--- /tmp/master_md5.txt 2020-01-03 15:42:22.000000000 +0900
+++ /tmp/branch_md5.txt 2020-01-03 15:42:42.000000000 +0900
@@ -1,4 +1,4 @@
-master
+refactor_rgblight_reconfig.h
MD5 (helix_rev2_default.hex) = f360032edd522448366d471d8f4f8181
MD5 (helix_rev2_back_default.hex) = 0c663acc6cccc44476b3b969ad22a48f
MD5 (helix_rev2_back_default.hex) = e66b1195ff6d38e6e22c975b8ae42fd3
```
* Expressions that are too long are difficult to read, so wrap them.
* Edit the expression again
* remove `defined(RGBLIGHT_ANIMATIONS)` in `tmk_core/common/*/suspend.c`, `tmk_core/protocol/*/main.c`
move contents of rgblight_reconfig.h to rgblight.h.
The following changes were made to rgblight.h.
```diff
+#ifdef RGBLIGHT_USE_TIMER
void rgblight_task(void);
void rgblight_timer_init(void);
void rgblight_timer_enable(void);
void rgblight_timer_disable(void);
void rgblight_timer_toggle(void);
+#else
+#define rgblight_task()
+#define rgblight_timer_init()
+#define rgblight_timer_enable()
+#define rgblight_timer_disable()
+#define rgblight_timer_toggle()
+#endif
```
The following changes were made to tmk_core/common/avr/suspend.c, tmk_core/common/chibios/suspend.c, tmk_core/protocol/chibios/main.c, tmk_core/protocol/lufa/lufa.c, tmk_core/protocol/vusb/main.c.
```diff
-# ifdef RGBLIGHT_ANIMATIONS
rgblight_timer_enable();
-# endif
```
```diff
-#if defined(RGBLIGHT_ANIMATIONS) && defined(RGBLIGHT_ENABLE)
+#if defined(RGBLIGHT_ENABLE)
rgblight_task();
#endif
```
* remove 'defined(RGBLIGHT_ANIMATIONS)' in tmk_core/common/keyboard.c
Co-authored-by: Joel Challis <git@zvecr.com>
* Compile error if ONESHOT_TIMEOUT defined but oneshot disabled
When ONESHOT_TIMEOUT and NO_ACTION_ONESHOT are both defined, this code
fails to compile.
Wrap the one usage of ONESHOT_TIMEOUT that is inconsistent with the
rest so all usages are properly wrapped by a check of NO_ACTION_ONESHOT.
* Run file through clang-format
Co-authored-by: Ted M Lin <tedmlin@gmail.com>
* Option to use function for KEYCODE2 routines.
Convert the KEYCODE2SYSTEM and KEYCODE2CONSUMER macros to functions,
defaulting to using the macros. The function form allows the compiler
to optimize the switch statement itself, over the macro nested
ternaries.
To enable this feature, #define USE_KEYCODE2_FUNCTION.
Testing against a random selection of avr-based keyboards, this
increased available flash by ~500 bytes. For arm-based keyboards,
the available flash increased by ~400 bytes.
* Replace macro with function entirely.
As zvecr states, go bold and just commit to using the function instead
of the macro.
* Reformat whitespace now that functional review is done
Verified against clang-format output.
* Dedupe extrakey report struct, and send functions in V-USB & LUFA
* Doc comment for consistency
* Wrap it in ifdef to prevent unused function error
* Do the same for ATSAM
- uprintf -> dprintf
- Fix atsam "vendor" eeprom.
- Bump Kinetis K20x to 64 bytes, too.
- Rollback Kinetis to 32 bytes as partitioning can only be done once. Add warning about changing the value.
- Change RAM-backed "fake" EEPROM implementations to match eeconfig's current usage.
- Add 24LC128 by request.
* Run clang-format manually to fix recently changed files
* Run clang-format manually to fix recently changed files - revert template files
* Run clang-format manually to fix recently changed files - format off for ascii_to_keycode_lut
* Implement IGNORE_MOD_TAP_INTERRUPT_PER_KEY
- Add configurable option IGNORE_MOD_TAP_INTERRUPT_PER_KEY
- Add function get_ignore_mod_tap_interrupt iff the option is enabled
Unless IGNORE_MOD_TAP_INTERRUPT_PER_KEY is defined, this patch does not affect the resulting binary.
* Add documentation for IGNORE_MOD_TAP_INTERRUPT_PER_KEY
* Move some common matrix code to a common location
* Refactor some 'custom_matrix_helper' logic to use custom matrix lite
* Fix build for kinesis/stapelberg - abuse of vpath was picking up matrix.c from core when custom matrix was enabled
* Add validation for CUSTOM_MATRIX
* VIA Refactor
* Remove old code
* review changes
* review changes
* Fix cannonkeys/satisfaction75/prototype:via build
* Add via.h to quantum.h
* Move backlight init to after backlight config load
* Merge branch 'master' into via_refactor_pr
* Update user's rules.mk to new way of enabling VIA
* Added id_switch_matrix_state
* Review changes
* Add central location for chibios defines
* Add central location for chibios defines - actually add files this time....
* Add Copyright header
* Update include order to resolve i2cv1 build errors
* Move tmk_core/common/backlight to quantum/backlight
* Add guards to backlight inclusion
* Add guards to backlight inclusion
* Update backlight guards on clueboard/60
* Use full paths to avoid vpath issues
* Initial stab at some fake dfu-util-split-left behaviour
* Apply suggestions from code review
Co-Authored-By: fauxpark <fauxpark@gmail.com>
* Clang format fixes
* Fake eeprom init for both left and right hand
This will manually wipe the EEPROM. This is a hacky solution for when new ranges are added or moved around.
A better (more complicated) solution would be to zero out everything, not just known ranges. But for now, this is a hacky solution that will work.
* Additional changes for Layer State typedef compatibility
* Replace biton32 with get_highest_layer in docs
* Change additional layer structure code
* Fix uGFX reference issue
* Remove dynamic_keymap check
* Where did all these extra spaces come from
Co-Authored-By: fauxpark <fauxpark@gmail.com>
* Add MAGIC_SWAP_CONTROL_LGUI and MAGIC_UNSWAP_CONTROL_LGUI keycodes
Key codes to swap and unswap the control and windows/cmd keys
* Fix issues with pull request #6110
Renamed swap/unswap lctl and lgui key codes, added key codes to swap/unswap rctl and rgui, and moved new bool inside keycode_config.h struct to the end
* Move new keycodes to the end of the enum (#6110)
* add cases for swapped control and OS keys to mod_config (#6110)
* Add new keycodes to feature_bootmagic.md (#6110)
* Add R+L swap codes to keep in parity with AG_* codes
* Extend Magic range check to include new magic codes
* Update audio docs
* Combine 2 byte ranges into 1 word for EECONFG
Fix names for Keymap config EEPROM
* Update docs/feature_bootmagic.md
Co-Authored-By: noroadsleft <18669334+noroadsleft@users.noreply.github.com>
* Update docs/feature_bootmagic.md
Co-Authored-By: noroadsleft <18669334+noroadsleft@users.noreply.github.com>
* Update docs/feature_bootmagic.md
Co-Authored-By: noroadsleft <18669334+noroadsleft@users.noreply.github.com>
* Update docs/feature_bootmagic.md
Co-Authored-By: noroadsleft <18669334+noroadsleft@users.noreply.github.com>
* Remove superfluous JTAG disable code
* 32A has differently named register
* Accidentally some operators
* 32A also has different JTAG pins
* Wrap disable_jtag() in an ifndef
* Document this new define
* Rename the define, it conflicts with a LUFA thing
Also, move the ifndef wrapping to the call in keyboard_setup()
* Extend allowed range of tappable keycodes to include modifiers
* Get rid of the magic numbers altogether
* Remove some more magic numbers
* Extract LM() functionality from ACT_LAYER_TAP
* Use ACTION() macro everywhere
* Update IS_COMMAND definition in templates to use MOD_MASK_SHIFT
* Update IS_COMMAND in docs
* Update IS_COMMAND default definition in tmk_core
* Update table in Command docs based on suggestion
Co-Authored-By: fauxpark <fauxpark@gmail.com>
* Store backlight breathing state in EEPROM
* Reduce backlight_config.level from 6 bits to 4 (max 15 "on" levels)
* Error out if BACKLIGHT_LEVELS is > 15
* Remove mention of default backlight pin in rules.mk template
* Remove pointless comment
Zeroing out spd in eeconfig_init_quantum
Switched to block read & update
Update tmk_core/common/eeconfig.h
Co-Authored-By: Drashna Jaelre <drashna@live.com>
Fixing init compile error
Update eeconfig.c
Dead / Missing API cleanup
alignment
* Typedef'ed layer_state_t to uint32_t.
This enables future work with layer_state_t to uint8_t for optimization purposes.
* Removed accidental xeal60 commit
* Revert to egyptian brackets, added sizeof(layer_state_t) so when layer_state_t is redefined it will automagically work.
* Add additional typedefs
* Add checks for setting layer state
* Update tmk_core/common/action_layer.h
Co-Authored-By: alex-ong <the.onga@gmail.com>
* Revert commit.
* Increase delay for Hold-Tap register for CAPSLOCK
Because it seems that the 80ms delay wasn't too much
* Screw it, make the caps delay a define and make it configurable
* Re-fix Mousekey Movements
After the new movement model was instroduced, it broke diagonal momement, again. Reapplying fix from #3147 to both old and new acceleration method.
* Make diagonal mouse report checks more readable
Co-Authored-By: drashna <drashna@live.com>
Patch from https://github.com/qmk/qmk_firmware/issues/3657#issuecomment-415147411
Long story short, in avr-gcc pre-8.2, reset_key was assigned to a memory area that was in a normal range, but when 8.2 came out, that memory got moved to an out of range area, causing errors like 0x800293 out of range. Apparently, this was fixed up in avr-gcc, but we haven't seen a release with the fix yet (we expected it in 8.3, but that didn't happen for some reason).
What this commit does is move the reset_key back to the original memory location it was in before.
When waking from suspend, only enable the LED drivers if they were not previously set to disabled by the user. This functionality was removed by the recent updates to adapt Massdrop keyboards to QMK RGB Matrix. Affects Massdrop CTRL and ALT keyboards compiled using Massdrop Configurator mode.
* Add customizable tapping terms
* Add Documentation
* Fix function
* Fixes
* It's not a pointer
* Add debugging output
* Update documentation to be at least vaguely accurate
* Use `get_tapping_term(tapping_key.event)` instead
`e` doesn't include column and row information, properly. It registers as 255, regardless of the actual keypress.
However `tapping_key.event` actually gives the correct column and row information. It appears be the correct structure to use.
In fact, it looks like the issue is that `e` is actually the "TICK" structure, as defined in keyboard.h
* Use variable tapping term value rather than define
* Silly drashna - tapping_key.event, not event
* add get_event_keycode() function
* Fix typo
Co-Authored-By: drashna <drashna@live.com>
* Remove post_process_record_quantum since it's the wrong PR
* Update quantum/quantum.c
Co-Authored-By: drashna <drashna@live.com>
* Better handle ifdef statement for permissive hold
Since we can't be sure that tapping term is actually 500
* Update quantum.c comments based on feedback
* Clean up get_tapping_term function
Clean up function so that users don't need to call the event function, and instead only check the keycode
* Add ability to run functionality on and off
* Make ifdef's more compact
* port Massdrop CTRL/ALT to use RGB Matrix
Co-authored-by: Matt Schneeberger <helluvamatt@gmail.com>
* Massdrop lighting support working
This commit is to get the Massdrop lighting code working again through use of the compilation define USE_MASSDROP_CONFIGURATOR added to a keymap's rules.mk.
Added keymaps for both CTRL and ALT named default_md and mac_md. These should be used if the Massdrop style lighting is desired.
* Updating config based on testing results with patrickmt & compile errors
* Updates for PR5328
For CTRL and ALT:
Moved location of new RGB Matrix macros from config_led.h to config.h.
Added RGB_MATRIX_LED_FLUSH_LIMIT (time between flushes) to config.h for correct LED driver update timing.
Re-added missing breathing code for when Massdrop configurator mode is defined.
* remove prilik keymap form PR
* Draft commit of typing speed RGB control
* More information in the readme
* Support all RGB animation modes (Fixes#1)
* Added support for all RGB light modes to use typing speed
Except christmas lights because that is seizure-inducing at high speeds!
* Introduced a value range specific to each RGB mode
Because some modes are a little too much when running at full speed!
* Update readme.md
* Update readme.md
* Re-arrange typing_speed definitions (Fixes#5) (#6)
* Re-arrange variable definitions to avoid including quantum.h from rgblight.c
* Fix a compilation error when trying to run make test:all
* Tweaks to the typing speed decay rate
* Renamed to momentum; moved implementation into dedicated files
* Groundwork for toggling momentum on/off (currently always on)
* Add EEPROM toggle for momentum-matching
* Moved momentum out of RGBLIGHT_ENABLE toggles so it's more generic
* Move momentum decay task out of rgblight_task()
* Fix missing momentum.h in lufa.c
* Experimental LED support (untested)
* Draft commit of typing speed RGB control
* More information in the readme
* Support all RGB animation modes (Fixes#1)
* Added support for all RGB light modes to use typing speed
Except christmas lights because that is seizure-inducing at high speeds!
* Introduced a value range specific to each RGB mode
Because some modes are a little too much when running at full speed!
* Update readme.md
* Update readme.md
* Re-arrange typing_speed definitions (Fixes#5) (#6)
* Re-arrange variable definitions to avoid including quantum.h from rgblight.c
* Fix a compilation error when trying to run make test:all
* Tweaks to the typing speed decay rate
* Renamed to momentum; moved implementation into dedicated files
* Groundwork for toggling momentum on/off (currently always on)
* Add EEPROM toggle for momentum-matching
* Moved momentum out of RGBLIGHT_ENABLE toggles so it's more generic
* Move momentum decay task out of rgblight_task()
* Fix missing momentum.h in lufa.c
* Added documentation
* Renamed feature to velocikey
* Reverted readme to original state
* Correct the readme title
* Updated feature name in the docs
* Update EECONFIG name
* Add compile-time toggles for velocikey
* Update feature documentation
* Revert "Merge branch 'led-support' into master"
This reverts commit e123ff5febf61639b9a9020748e1c2e2313460ff, reversing
changes made to df111a55b9d4929182e16108b1c0ead15b16df97.
* Move velocikey EECONFIG definition to depend on VELOCIKEY_ENABLE
* Rename decay_task function to decelerate
* Apply suggestions from code review
Co-Authored-By: chrislewisdev <chris@chrislewisdev.com>
* Re-order eeconfig definitions
* Apply coding conventions
* Apply #ifdef check in lufa.c
* Refactored interval time checks into one functionc
* Small rename
* Fix unused function error for layouts not using all rgb effects
* Only update EEPROM if Velocikey is enabled
* Incorporate code review feedback
* Small adjustment to top-end decay rate
* Add Velocikey documentation to table of contents
* Bring tetris:default keymap size down by disabling audio
* Change Command keycode defaults to match corresponding Bootmagic codes
* Make alternate magic key keycodes consistent
* Reflect changes from previous commit in tmk_core/common/command.c
* Remove unnecessary MAGIC_KEY_* definitions from keymaps compatible with these changes
* Swap E and BSPACE for MAGIC_KEY_EEPROM
* Add MAGIC_KEY_EEPROM_CLEAR instead of MAGIC_KEY_EEPROM_ALT
* Remove BOOTMAGIC_ENABLE checks around EECONFIG stuff
* Update Command descriptions
* initial work to add eeprom to haptic feedback and decouple the feedback process from keyboards
* Haptic feedback enhancements: on/off toggle working, feedback order working
todo:
-work on modes switching
-get modes switching to save to eeprom
* haptic enhancement - eeprom and modes added
* Added set and get functions for haptic feedback
* initial implementation of solenoids under haptic feedback
* changed eeprom to 32 bits to reserve blocks for future features
* start documentation of haptic feedback
* change keycode per comment from reviewers
* typo fixes
* added eeprom for solenoid configs
* added solenoid and docs
* Add/fix default parameters configs, improve docs
* more doc cleanup
* add in solenoid buzz toggle, clean up doc
* some fixes for error in compiling solenoid
* fix a chibios specific i2c read function and added one for AVR controllers in DRV2605L.c
* fixes for avr side issues
* update keymap
* fix keymap compile error
* fix bugs found during solenoid testing
* set pin that is not powered during bootloader
* added warning about certain pins on the MCU may trip solenoid during DFU/bootloader
* Added xeal60 via clone of lets split
* Delete removed other keymaps
* Basic keymap (no FN). Compiles.
* Removed NP_STAR and NP_SLSH.
* Removed "debounce_algo = manual" in all keyboards with CUSTOM_MATRIX = yes.
* Changed order of rules in TMK. Documented feature.
* Fixed missing whitespace in debounce documentation
Table wasn't working due to missing newline.
* Added bold in a few areas.
* DO NOT USE - Removed debounce from TMK.
* Remove accidental xeal60 commit
* DO NOT USE - debounce successfully compiled.
* DO NOT USE Revert back to original API to support split_keyboards.
* Working eager_pk
* Whitespace cleanup.
* Restored debounce.h since there wasnt any real change.
* Moved debouncing_time variable to inside #if debounce
* Removed check for custom_matrix. We can safely include the debounce file for compilation when custom_matrix is used.
* Removed #include "matrix.h" from debounce.h
* Bug fix - was using MATRIX_ROWS instead of num_rows
* Fixed compilation error with debounce_sym_g
* Renamed DEBOUNCE_ALGO to DEBOUNCE_TYPE
* Malloc array in debounce_eager_pk, since split keyboards only use MATRIX_ROWS/2.
* Fix compile error in debounce_eager_pk
* Stricter, leaner DEBOUNCE_TYPE section in common_features.mk. Cleanup debounce_type.mk