Commit graph

1871 commits

Author SHA1 Message Date
Ryan
b45a037c7e
Rename some Quantum keycodes (#15968)
* Rename some Quantum keycodes

* Tweak EEPROM clear and debug keycode short aliases
2022-01-22 03:34:15 +00:00
Joel Challis
d840ef2b28
Relocate matrix_scan_quantum tasks (#15882)
* Move matrix_scan_quantum tasks

* Fix tests

* Fix up missing refs
2022-01-19 17:38:48 +00:00
Albert Y
1d3c2ceded
Add init function to clear previous effect (#15815) 2022-01-17 06:48:09 +11:00
QMK Bot
9cd2024814 Merge remote-tracking branch 'origin/master' into develop 2022-01-15 07:28:32 +00:00
Drashna Jaelre
5bad37cb56
[Bug] Remove config.h include in dynamic_keymap.c (#15886) 2022-01-15 18:28:29 +11:00
Alabastard-64
2842ab4052
Add PMW3389 optical sensor Support (Updated) (#15740)
Co-authored-by: Drashna Jaelre <drashna@live.com>
2022-01-11 14:33:13 -08:00
Nick Brassel
0c402157fc
Advanced deferred_exec for core-side code. (#15579) 2022-01-10 18:26:46 +00:00
Pete Sevander
21958a9343
New combo configuration options (#15083)
Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>
2022-01-09 12:02:25 -08:00
Joel Challis
7562f6644f
Slight tidy up of keyboard task loop (#15725) 2022-01-09 03:50:44 +00:00
Leo Deng
82d3bdb733
IS31FL3733 driver for LED Matrix (#15088) 2022-01-08 19:37:03 -08:00
Joel Challis
8dbc8a802c
Unify the key up/down behaviour of RGB keycodes (#15730) 2022-01-06 18:52:32 +11:00
QMK Bot
5fcdff9935
Format code according to conventions (#15693) 2021-12-31 23:46:23 +00:00
Dasky
4fe6f3cd7a
Fix split pointing for analog joystick (#15691)
Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-12-31 15:38:23 -08:00
Drashna Jaelre
14d5c3f2f1
[Bug] Include missing string.h include (#15606) 2021-12-28 10:57:41 +11:00
Drashna Jaelre
c86baf3ece
[Core] Fix bug and code regression for Split Common (#15603) 2021-12-28 10:01:51 +11:00
uqs
d3952523fe
pwm3360 driver cleanup and diff reduction to adns9800 (#15559)
* Diff reduction between ADNS9800 and PMW3360 drivers.

They are very similar devices. This (somewhat) unreadable diff is
essentially a no-op, but it makes a `vimdiff` between the 2 drivers much
more readable.

* Cleanup pwm3360 driver some more.

Remove redundant calls to spi_start() and spi_stop(), as pmw3360_write()
will already call these.
2021-12-27 21:26:09 +11:00
Jay Greco
ac31863021
Custom matrix lite support for split keyboards (#14674)
* Custom matrix lite support for split keyboards

* WIP: matrix -> matrix_common refactor

* Move matrix_post_scan() to matrix_common.c
2021-12-27 21:03:40 +11:00
QMK Bot
eadfcb9a40
Format code according to conventions (#15590) 2021-12-27 14:34:15 +11:00
QMK Bot
c20096c7aa Merge remote-tracking branch 'origin/master' into develop 2021-12-27 02:51:13 +00:00
Erik Berthold
2c8d46f408
fix RGB_DISABLE_TIMEOUT flicker on split keyboards (#14954) 2021-12-27 13:50:44 +11:00
Chad Austin
25713dc222
Add sym_defer_pr debouncer type (#14948) 2021-12-27 13:44:56 +11:00
Drashna Jaelre
672c6b4721
Make (un)register code functions weak (#15285) 2021-12-27 12:15:56 +11:00
QMK Bot
f9cf09ebd1
Format code according to conventions (#15588) 2021-12-27 12:10:04 +11:00
Dasky
7f7364c559
[Core] Split support for pointing devices. (#15304)
* Draft implementation

* formatting

* fix combined buttons

* remove pimoroni throttle

* sync pointing on a throttle loop with checksum

* no longer used

* doh

Co-authored-by: Drashna Jaelre <drashna@live.com>

* switch pimoroni to a cpi equivalent

* add cpi support

* allow user modification of seperate mouse reports

* a little tidy up

* add *_RIGHT defines.

* docs

* doxygen comments

* basic changelog

* clean up pimoroni

* small doc fixes

* Update docs/feature_pointing_device.md

Co-authored-by: Drashna Jaelre <drashna@live.com>

* performance tweak if side has usb

* Don't run init funtions on wrong side

* renamed some variables for consistency

* fix pimoroni typos

* Clamp instead of OR

* Promote combined values to uint16_t

* Update pointing_device.c

Co-authored-by: Drashna Jaelre <drashna@live.com>
Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-12-27 12:05:51 +11:00
vectorstorm
0391801267
Fixes potential wpm sampling overflow, along with code comment fixes (#15277)
Co-authored-by: Trevor Powell <trevor@vectorstorm.com.au>
2021-12-27 11:52:56 +11:00
QMK Bot
53472a4e7b Merge remote-tracking branch 'origin/master' into develop 2021-12-24 22:31:48 +00:00
Chris Broekema
c4b03509da
Save a single byte of memory for joystick buttons (#15555)
Co-authored-by: Joel Challis <git@zvecr.com>
2021-12-24 14:31:15 -08:00
QMK Bot
3a2d01df6a Merge remote-tracking branch 'origin/master' into develop 2021-12-16 18:05:44 +00:00
billybraga
f383d3d8be
Fix inverted gt and lt send_string mapping in canadian multilingual (#15487)
Co-authored-by: Ryan <fauxpark@gmail.com>
Co-authored-by: Billy Braga <bbraga@progi.com>
2021-12-16 10:05:06 -08:00
QMK Bot
c8fd62432a Merge remote-tracking branch 'origin/master' into develop 2021-12-16 05:59:42 +00:00
Yoichiro Tanaka
231cd7a39f
Fix some wrong keycode macros in locale mapping files (#15488) 2021-12-16 16:59:04 +11:00
Ryan
c12268807d
Migrate serial_uart usages to UART driver (#15479)
* Migrate Thermal Printer feature to UART driver

* Migrate 40percentclub UT47 to UART driver

* Migrate Centromere to UART driver

* Migrate Chimera Ergo to UART driver

* Migrate Chimera Let's Split to UART driver

* Migrate Chimera Ortho to UART driver

* Migrate Chimera Ortho Plus to UART driver

* Migrate Comet46 to UART driver

* Migrate Palm USB converter to UART driver

* Migrate Sun USB converter to UART driver

* Migrate Dichotomy to UART driver

* Migrate Honeycomb to UART driver

* Migrate Mitosis to UART driver

* Migrate Redox W to UART driver

* Migrate Uni660 to UART driver

* Migrate Telophase to UART driver
2021-12-15 11:00:39 +00:00
Stefan Kerkmann
8b865a9d64
[Core] Don't send keyboard reports that propagate no changes to the host (#14065) 2021-12-14 10:40:18 -08:00
Dipl.-Ing. Raoul Rubien, BSc
415faebd65
added missing audio_off_user() callback (#15457)
Co-authored-by: Raoul Rubien <raoul.rubienr@gmail.com>
2021-12-11 16:58:25 -08:00
Drashna Jaelre
5f7c0e3097
Add missing define for unicode common (#15416) 2021-12-06 11:36:30 -08:00
Drashna Jaelre
942b3cf16c
Generalize Unicode defines (#15409) 2021-12-06 09:38:36 -08:00
Joel Challis
2726856cde
Implement MAGIC_TOGGLE_CONTROL_CAPSLOCK (#15368) 2021-11-30 17:34:08 -08:00
Stefan Kerkmann
c1297ceb97
[Core] Remove matrix_is_modified() and debounce_is_active() (#15349) 2021-11-29 08:22:10 -08:00
QMK Bot
5ebeb32ec0 Merge remote-tracking branch 'origin/master' into develop 2021-11-29 15:08:12 +00:00
Karl Shea
84b8cdc1a4
Fix bit loss in cie_lightness() when doing division to resolve #15331 (#15344)
* Fix bit loss in cie_lightness() when doing division.

* Use the right types

* Format

Co-authored-by: zvecr <git@zvecr.com>
2021-11-29 15:07:36 +00:00
wheredoesyourmindgo
7f67504993
Added cancel_key_lock function (#15321) 2021-11-29 00:17:07 -08:00
Stefan Kerkmann
ca5670762b
Fix HOLD_ON_OTHER_KEY_PRESS after #11059 (#15307)
that broke compilation because of a typo: KEYPRESS should have been
KEY_PRESS
2021-11-28 05:54:51 +11:00
Drashna Jaelre
b3fc33faf7
Re-add encoder tests (#15312)
Co-authored-by: Balz Guenat <balz.guenat@gmail.com>
2021-11-27 22:19:22 +11:00
Drashna Jaelre
4d0dd1eab7
[Bug] Revert Assymmetrical Split Encoder support (#12090) (#15311)
* Revert "fix broken macro in transport.h (#15239)"

This reverts commit 06f18e22d9.

* Revert "Rework encoders to enable asymmetric split keyboards (#12090)"

This reverts commit 32215d5bff.
2021-11-27 14:40:09 +11:00
precondition
4bac5f53d8
New feature: DYNAMIC_TAPPING_TERM_ENABLE (#11036)
* New feature: `DYNAMIC_TAPPING_TERM_ENABLE`

3 new quantum keys to configure the tapping term on the fly.

* Replace sprintf call in tapping_term_report by get_u16_str

* Replace tab with 4 spaces
2021-11-26 07:06:50 +11:00
Isaac Elenbaas
d9393b8684
Add Retro Shift (Auto Shift for Tap Hold via Retro Tapping) and Custom Auto Shifts (#11059)
* Add Retro Shift and Custom Auto Shifts

* Fix compilation errors with no RETRO_SHIFT value
2021-11-25 23:12:14 +11:00
Nick Brassel
7746aefe94 Revert "[Tests] Increase QMK test coverage (#13789)"
This reverts commit b6054c0206.
2021-11-23 09:54:04 +11:00
Stefan Kerkmann
b6054c0206
[Tests] Increase QMK test coverage (#13789)
* Add per-test keymaps

* Add better trace and info logs for failed unit-tests

* Add layer state assertion with tracing message

* Use individual test binaries configuration options

* Add basic qmk functionality tests

* Add tap hold configurations tests

* Add auto shift tests

* `qmk format-c

* Fix tests

Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-11-23 08:15:04 +11:00
Drashna Jaelre
32a87d3517
Add uint to char functions (#15244)
* Add uint to char functions

* appease the all mighty lint

* Further appease Lint

* Update functions

* Add doxygen comment

* Update quantum/quantum.c

Co-authored-by: Nick Brassel <nick@tzarc.org>

* Apply suggestions from code review

Co-authored-by: Nick Brassel <nick@tzarc.org>

* Add declaration for get_numeric_string

* fix formatting and bug

Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-11-23 08:13:22 +11:00
Zach White
08ce0142ba
Macros in JSON keymaps (#14374)
* macros in json keymaps

* add advanced macro support to json

* add a note about escaping macro strings

* add simple examples

* format json

* add support for language specific keymap extras

* switch to dictionaries instead of inline text for macros

* use SS_TAP on the innermost tap keycode

* add the new macro format to the schema

* document the macro limit

* add the json keyword for syntax highlighting

* fix format that vscode screwed up

* Update feature_macros.md

* add tests for macros

* change ding to beep

* add json support for SENDSTRING_BELL

* update doc based on feedback from sigprof

* document host_layout

* remove unused var

* improve carriage return handling

* support tab characters as well

* Update docs/feature_macros.md

Co-authored-by: Nick Brassel <nick@tzarc.org>

* escape backslash characters

* format

* flake8

* Update quantum/quantum_keycodes.h

Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-11-22 11:11:35 -08:00
Balz Guenat
06f18e22d9
fix broken macro in transport.h (#15239) 2021-11-20 20:09:21 +00:00
Balz Guenat
32215d5bff
Rework encoders to enable asymmetric split keyboards (#12090)
Co-authored-by: Balz Guenat <balz.guenat@siemens.com>
Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-11-20 09:06:08 -08:00
Joel Challis
2728603fe6
Move tmk_core/common/<plat> (#13918) 2021-11-19 10:41:02 -08:00
Drashna Jaelre
50dc313e80
[Bug] Revert backlight pins on function call (#15205) 2021-11-19 06:06:55 +11:00
Drashna Jaelre
88eaf78628
[Bug] Fix missing variable for Backlight Breathing (#15199)
* [Bug] Fix missing varaible for Backlight Breathing

* Better fix

* formatting
2021-11-18 16:37:34 +11:00
QMK Bot
cc7600cf0e
Format code according to conventions (#15196) 2021-11-18 08:07:45 +11:00
Mikkel Jeppesen
e0a5056963
Made AVR backlight pwm resolution configurable (#7521)
* Made static backlight pwm resolution configurable

* Made breathing backlighting configurable too

* Finished my ifdef

* Ran clang-format

* Added missing semi-colon

* Solved weird behaviour by right-shifting the right amount

* Made breathing period scaled on actual pwm frequency

* Made the low end deadzone scaled on the top value

* Moved 'pwm_frequency' declaration outside ifdef

* Fixed 'never used' error

* Fixed 'never used' error

* Fixed breathing ISR to 120Hz

* Removed pwm_frequency constant
Constant is no longer needed since running the breathing ISR at a fixed 120Hz

* Re-add brightness limiting

* re-introduce scaling
2021-11-18 07:56:13 +11:00
QMK Bot
25b087925c
Format code according to conventions (#15195) 2021-11-17 20:42:00 +00:00
Albert Y
557e5ddf99
Rename RGB fractal (#15174)
Co-authored-by: filterpaper <filterpaper@localhost>
2021-11-16 11:14:57 -08:00
Drashna Jaelre
160b0558f5
Require explicit enabling of RGB Matrix modes (#15018) 2021-11-15 10:41:04 -08:00
vectorstorm
c9fd698711
Reimplements WPM feature to be smaller & precise (#13902)
* Reimplements WPM feature.

 - Now calculates exact WPM over the last up to three seconds of typing.
 - WPM_SMOOTHING removed, as it's no longer needed.
 - WPM_SAMPLE_SECONDS added, to specify how long a period to average WPM
   over, set to 5 seconds by default.
 - WPM_SAMPLE_PERIODS added, to specify how many sampling buffers we'll
   use.  Each one uses one extra byte of space.  Having more will lead
   to smoother decay of WPM values.  Defaults to 50 (we're saving so
   many bytes of firmware space I felt like being extravagent, and this
   change is still a big size saving overall)
 - WPM_UNFILTERED option added (defaults to unset), which disables all
   filtering within the WPM feature.  This saves some space in the
   firmware and also reduces latency between typing and the WPM
   calculation measuring it.  (saves 70 bytes in my tests)
 - WPM_LAUNCH_CONTROL added (defaults to unset).  When typing begins
   while the current displayed WPM value is zero, the WPM calculation
   only considers the time elapsed since typing began, not the whole
   WPM_SAMPLE_SECONDS buffer.  The result of this is that the displayed
   WPM value much more rapidly reaches an accurate WPM value, even when
   results are being filtered. (costs 22 bytes in my tests)
 - Updates documentation to reflect changed options.

Saves about 900 bytes, in my tests, compared against the previous implementation,
with default settings.

* Apply suggestions from code review

Co-authored-by: Sergey Vlasov <sigprof@gmail.com>

Co-authored-by: Trevor Powell <trevor@vectorstorm.org>
Co-authored-by: Nick Brassel <nick@tzarc.org>
Co-authored-by: Sergey Vlasov <sigprof@gmail.com>
2021-11-16 05:40:52 +11:00
Nick Brassel
36d123e9c5
Add support for deferred executors. (#14859)
* Add support for deferred executors.

* More docs.

* Include from quantum.h

* Cleanup.

* Parameter checks

* Comments.

* qmk format-c

* I accidentally a few words.

* API name change.

* Apply suggestions from code review

Co-authored-by: Sergey Vlasov <sigprof@gmail.com>

* Review comments.

* qmk format-c

* Review comments.

Co-authored-by: Sergey Vlasov <sigprof@gmail.com>
2021-11-15 18:21:09 +00:00
Drashna Jaelre
b3ee124da6
Add needed include to pointing_device.c (#15167) 2021-11-16 04:09:31 +11:00
Drashna Jaelre
56e3f06a26
Rework and expand Pointing Device support (#14343)
Co-authored-by: Dasky <32983009+daskygit@users.noreply.github.com>
2021-11-14 22:03:24 -08:00
Drashna Jael're
7e86c37962
Merge remote-tracking branch 'origin/master' into develop 2021-11-13 09:32:14 -08:00
Markus Fritsche
8323177472
add wait to unicode for win (#15061)
Co-authored-by: Markus Fritsche <fritsche.markus@gmail.com>
2021-11-12 15:00:36 -08:00
Ryan
f529580860
Basic keycode overhaul (#14726) 2021-11-03 22:22:17 -07:00
Joel Challis
2d0ed4367b
Remove deprecated KEYMAP alias (#15037)
* Remove deprecated KEYMAP alias

* Remove some KEYMAP references

* Remove some KEYMAP references
2021-11-03 12:18:11 +11:00
Joel Challis
634e42b2b4
Revert to old init order for host driver (#15029)
* Partially revert 14888
2021-11-02 18:53:46 +00:00
Nick Brassel
699e69bec5
Fixup LED matrix. (#15020) 2021-11-02 10:05:42 +00:00
Purdea Andrei
76fb54403c
haptic: Feature to disable it when usb port is not configured or suspended. (#12692)
This also add support for specifying a LED pin to indicate haptic status,
and also adds support for a haptic-enable pin, which is useful to turn off
the boost converter on the solenoid driver.
2021-11-02 16:54:29 +11:00
Albert Y
2173b5373c
Add Pixel Rain RGB Matrix effect (#14155)
* Add Pixel animation header file

* Add Pixel animation to documentation

* Add Pixel animation to core include file

* Remove unintended spaces

* Remove seeding of PRNG

* Increase frequency of lit keys

Co-authored-by: filterpaper <filterpaper@localhost>
2021-11-02 10:40:25 +11:00
lalalademaxiya1
f4ea262c17
Add a new led driver for Keychron's keyboards. (#14872)
* Add a new led driver for Keychron's keyboards.

* Update ckled2001.c/ckled2001.h.

* Update ckled2001.c/ckled2001.h.

* Update ckled2001.c/ckled2001.h.

* Update ckled2001.c

* Add a new led driver

* Update ckled2001.c

* Update ckled2001.c

* Update ckled2001.c

* Update ckled2001.c

* Delete ckled2001.c

* Create ckled2001.c

* Update ckled2001.c

* Update chibios-contrib

Co-authored-by: keychron-dev <85598583+keychron-dev@users.noreply.github.com>
Co-authored-by: lokher <lokher@gmail.com>
2021-11-02 09:43:53 +11:00
Woody
f775da96b1
define to AUTO_SHIFT_DISABLED_AT_STARTUP (#14201)
Co-authored-by: agodinhost <agodinhost@globo.com>
2021-11-02 09:11:55 +11:00
Vlad K
a29ca1e7f1
Add support for ISSI drivers on both sides of a split keyboard (#13842)
* Gets RGB working on a split keyboard with IS31FL3733. Currently needs small tweak to re-enable WS2812

* Added helper function

* Trying to integrate the function

* Moved functionality into a macro

* Swapped conditional for a macro everywhere

* Tidying up

* More code cleanup

* Documentation updates

* Fixed formatting via linter

* Switching to a function from a macro

* Fixed compile error

* Fixing WS2812 behavior. UNTESTED.

* Updated documentation about the driver addresses.

* Fixed code for WS2812

* Trying to add in LED_MATRIX support

* Updated effects for LED matrix

* Updated third-party effect defines.

* Ran format-c on modified files

* Apply suggestions from code review

Co-authored-by: Ryan <fauxpark@gmail.com>

* Move to static inline. Avoids issues with gcc v8+

* Move helper function for LED_matrix to static inline to avoid issues with gcc v8+

Co-authored-by: Vlad Kvitnevskiy <vladkvit@outlook.com>
Co-authored-by: Ryan <fauxpark@gmail.com>
2021-11-02 09:04:37 +11:00
Joel Challis
92385e30cd
Manually format develop (#15003) 2021-11-01 19:18:33 +00:00
Albert Y
4bf7ce2298
Add Fractal RGB matrix effects (#12670)
* Squashed fractal effect commit for easier rebase

* Update documentation

* Squashed fractal effect commit for easier rebase

* Update documentation

* Update doc spacing

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update feature_rgb_matrix.md

Co-authored-by: filterpaper <filterpaper@localhost>
Co-authored-by: Ryan <fauxpark@gmail.com>
Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-11-02 04:30:07 +11:00
Drashna Jaelre
2980c63d3d
Fix issues with Oneshot disabling (#14934) 2021-11-01 09:41:24 -07:00
Joel Challis
0f92614240
Fix develop after recent changes (#14975)
* Fix sleep led issues

* Fix tests
2021-10-28 23:43:57 +01:00
Joel Challis
dcfffa7b67
Relocate protocol files within tmk_core/common/ (#14972)
* Relocate non platform files within tmk_core/common/

* clang
2021-10-28 22:31:59 +01:00
Joel Challis
780e763c13
Remove SERIAL_MOUSE (#14969) 2021-10-28 02:43:51 +01:00
Joel Challis
b780c797be
Migrate makefile utilities to sub-directory (#14917) 2021-10-28 01:07:53 +01:00
Chad Austin
ee23aae87f
Optimize matrix scanning by removing variable shifts (#14947) 2021-10-26 20:01:57 -07:00
QMK Bot
462323418e Merge remote-tracking branch 'origin/master' into develop 2021-10-26 23:11:25 +00:00
MasterSpoon
015c4cf5be
Update mcu_selection.mk with current ChibiOS path (#14909) 2021-10-26 16:10:48 -07:00
Joel Challis
2ec268bd21
Begin to carve out platform/protocol API - Migrate keyboard_* calls (#14888) 2021-10-24 20:39:41 +01:00
QMK Bot
1fb2a0c74e Merge remote-tracking branch 'origin/master' into develop 2021-10-20 03:51:11 +00:00
Drashna Jaelre
0fd45d5984
Fix type of Tap Dance max index variable (#14887) 2021-10-19 20:50:44 -07:00
QMK Bot
034e78c083 Merge remote-tracking branch 'origin/master' into develop 2021-10-20 01:48:39 +00:00
Sergey Vlasov
c9562ebfde
Make the MAGIC_TOGGLE_GUI keycode work (#14886) 2021-10-19 18:48:01 -07:00
Stefan Kerkmann
e50867d52d
[Core] Add support for RISC-V builds and GD32VF103 MCU (#12508)
* Add support for RISC-V builds and GD32VF103 MCU

* Add toolchain selection in chibios.mk based on the mcu selected in
mcu_selection.mk
* Reorder and added comments to chibios.mk to have a streamlined makefile
* Add GD32VF103 mcu to possible targets for QMK.
* Add STM32 compatibility for GD32VF103 MCU, this is hacky but more efficent
  then rewriting every driver.
* Add GigaDevice DFU bootloader as flash target, please note that
  dfu-util of at least version 0.10 is needed.
* Add analog driver compatibility
* Add apa102 bitbang driver compatibility
* Add ws2812 bitbang driver compatibility
* Add eeprom in flash emulation compatibility
* Allow faster re-builds with ccache

* Add SiPeed Longan Nano to platform files

* Add SiPeed Longan Nano Onekeys

* Make quine compatible with other bootloaders

* Support builds with picolibc

* Add risc-v toolchain to arch and debian/ubuntu scripts
2021-10-18 16:23:20 +11:00
Joel Challis
83e978da1f
Further tidy up of STM32 eeprom emulation (#14591) 2021-10-16 02:58:48 +01:00
Ryan
61cc9e8042
Fix misplaced endif in led_matrix_drivers.c (#14785) 2021-10-10 21:32:29 -07:00
Ryan
b487e10753
Clean up LED/RGB Matrix driver config (#14760) 2021-10-10 16:57:49 -07:00
Joel Challis
dace4d5f0d
Remove QWIIC_DRIVERS (#14174) 2021-10-09 14:48:27 +01:00
Joel Challis
00fd404433
Put back eeconfig_update_ functions (#14751) 2021-10-08 13:44:07 +01:00
Joel Challis
e0d688d4c8
Move converter specific tmk_core protocols (#14743) 2021-10-07 23:14:26 +01:00
precondition
0d72438ad6
Correct the Turkish F '?' keycode (TR_QUES) (#14740)
define TR_QUES S(TR_ASTR) // ? → define TR_QUES S(TR_SLSH) // ?
2021-10-07 15:01:50 +01:00
Joel Challis
1c0347b8b8
Remove SERIAL_LINK feature (#14727)
* Remove SERIAL_LINK

* more stale paths in doxygen-todo

* Fix

* More refs

* Update testing docs

* Update doxygen-todo

Co-authored-by: Ryan <fauxpark@gmail.com>

Co-authored-by: Ryan <fauxpark@gmail.com>
2021-10-07 12:32:05 +11:00
Joel Challis
60297a1099
Reuse of EEPROM debounce logic (#14699)
* reuse rgb debounce logic

* Refactor led matrix

* Remove log line

* timeout should not be hard coded
2021-10-07 01:47:14 +01:00
Nick Brassel
b2a186cf92
Purge uGFX. (#14720)
* Purge uGFX.

* Remove remnants of visualizer.

* Remove remnants of uGFX.
2021-10-07 10:57:48 +11:00
Ryan
d8f0c8783a
Remove sysex API (#14723) 2021-10-06 19:34:46 +11:00
Drashna Jaelre
ba8f1454f4
Move Audio drivers from quantum to platform drivers folder (#14308)
* Move Audio drivers from quantum to platform drivers folder

* fix path for audio drivers

Co-authored-by: Ryan <fauxpark@gmail.com>

Co-authored-by: Ryan <fauxpark@gmail.com>
2021-10-06 12:01:45 +11:00
QMK Bot
9f0e74802a Merge remote-tracking branch 'origin/master' into develop 2021-10-06 00:50:53 +00:00
Drashna Jaelre
3b8c4979dc
[Bug] Fix command feature if mousekey is enabled and using 3-speed setting (#14697) 2021-10-05 17:50:23 -07:00
Purdea Andrei
eb5b24f97c
Add LM() keys to the list of keys disabled by NO_HAPTIC_MOD (#14181) 2021-10-03 12:02:05 -07:00
Ryan
1a9e7b95ab
Change MK66F18 -> MK66FX1M0 (#14659) 2021-09-30 23:14:37 +01:00
Purdea Andrei
b02a539625
Added power tracking api (#12691)
* Add power tracking API to lufa and chibios targets

* power.c: Pass through power state to the notify function

* power: added notify_power_state_change_user too.

* making it pass the PR linter

* Add a POWER_STATE_NO_INIT state, that we start in before calling power_init();

* Rename *power* to *usb_power*

* removing stray newline

* Rename usb_power* to usb_device_state*

* Update quantum/usb_device_state.h

Co-authored-by: Drashna Jaelre <drashna@live.com>

* Fix comment

* usb_device_state.h: Don't include quantum.h, only the necessary headers.

Co-authored-by: Drashna Jaelre <drashna@live.com>
2021-09-30 06:31:39 +10:00
QMK Bot
be3d7063a0 Merge remote-tracking branch 'origin/master' into develop 2021-09-29 18:37:46 +00:00
Drashna Jaelre
02ab7b1888
[Core] Fix "6kro enable" and clarify naming (#14563)
* Fix USB_6KRO_ENABLE compilation errors

* Add info to docs

* Rename define to be more accurate

* Remove unused rule

* Refixe docs
2021-09-29 11:37:11 -07:00
Drashna Jaelre
e1bf49fc97
Remove GCC version check from song list inclusion (#14600) 2021-09-25 18:35:27 +01:00
Joel Challis
3a2a39e5ec
Initial pass of F405 support (#14584)
* Initial pass of F405 support

* remove some conf files

* docs

* clang
2021-09-25 00:19:41 +01:00
Marcus van Houdt
8b6c16ea1f
Add ability to use numpad digits for unicode mode UC_WIN (#14496)
Co-authored-by: Konstantin Đorđević <vomindoraan@gmail.com>
2021-09-21 15:23:49 -07:00
Joakim Tufvegren
8130690a28
Improvements to handling of disconnected split keyboards. (#14033)
* Use memcmp and memcpy to compare and copy slave matrix.

...and memset to initialize `matrix` and `raw_matrix`.

Increased my scan rate (while connected) by ~100 (on Ergodox Infinity).
Effect on AVR is unknown.

Co-authored-by: Stefan Kerkmann <karlk90@pm.me>

* Fix `matrix_post_scan` signalling change on every scan while disconnected.

* Undo removal of initialization of `slave_matrix`.

This has the effect of increasing my Ergodox Infinity firmware size by 8
bytes instead of decreasing by 8 bytes, and lowers the scan rate while
connected back to the initial value before these changes, but _might_
solve some issues on AVR.

Co-authored-by: Stefan Kerkmann <karlk90@pm.me>
2021-09-18 17:29:22 +10:00
QMK Bot
bf23e4647b Merge remote-tracking branch 'origin/master' into develop 2021-09-15 17:07:47 +00:00
Drashna Jaelre
169d5bd21d
[Bug] Fix IS31fl3741 driver to accept 1 or 2 addresses (#14451)
Co-authored-by: Joel Challis <git@zvecr.com>
2021-09-15 10:07:08 -07:00
Thomas Weißschuh
83988597f4
Add Support for USB programmable buttons (#12950) 2021-09-15 08:40:22 -07:00
Joel Challis
fa141a5a8f
Migrate STM32_EEPROM_ENABLE to use EEPROM_DRIVER (#14433) 2021-09-15 01:21:36 -07:00
Drashna Jaelre
26e796fb9c
fix typo in backlight code from #14439 (#14442) 2021-09-15 03:37:45 +01:00
Joel Challis
a78f0e8a0b
Refactor use of _STM32_ defines (#14439) 2021-09-15 11:19:51 +10:00
QMK Bot
d2eb9c03af Merge remote-tracking branch 'origin/master' into develop 2021-09-12 23:48:41 +00:00
Drashna Jaelre
ab34ecb669
Apply TAP_CODE_DELAY to Tap Dance key sequences (#14412)
* Add  support to tap dances

* Move default tap code defines to header file
2021-09-13 00:48:11 +01:00
QMK Bot
1837d98425 Merge remote-tracking branch 'origin/master' into develop 2021-09-09 01:35:09 +00:00
JayceFayne
f3bef84dac
ST7565_TIMEOUT 0 and ST7565_DISABLE_TIMEOUT should behave the same (#14315) 2021-09-08 18:34:49 -07:00
JayceFayne
da81e5c7cd
OLED TIMEOUT 0 and OLED_DISABLE_TIMEOUT should behave the same (#14302) 2021-09-08 18:34:34 -07:00
Drashna Jaelre
15710db4ad
Move feature suspend logic out of platform specific code (#14210) 2021-08-30 20:21:03 +01:00
Purdea Andrei
9583f9f589
[Bug] Fix build error when enabling NO_HAPTIC_MOD (#14178)
Without this build would fail, if a keyboard had haptic feedback enabled,
TAPPING_TOGGLE was not overridden in a config.h, and if NO_HAPTIC_MOD was
defined in config.h.
2021-08-30 11:22:53 -07:00
Joel Challis
a84de5e22b
Revert 14083 && 14144 (#14150)
* Revert "Short term bodge for firmware size bloat (#14144)"

This reverts commit a8d6547346.

* Revert "Tidy up quantum.c now some of tmk_core has been merged (#14083)"

This reverts commit c4dbf4bf01.
2021-08-25 01:16:59 +01:00
Joel Challis
2cade3a483
Align some quantum sub-directories (#14134)
* Misc folder tidy

* Review comments

* Remove redundant entry
2021-08-24 17:07:11 +01:00
Joel Challis
a8d6547346
Short term bodge for firmware size bloat (#14144) 2021-08-24 16:09:23 +01:00
Joel Challis
c4dbf4bf01
Tidy up quantum.c now some of tmk_core has been merged (#14083) 2021-08-24 14:28:37 +01:00
Xelus22
4e1c5887c5
[Core] Refactor OLED to allow easy addition of other types (#13454)
* add docs

* core changes

* update keyboards to new OLED

* updated users to new OLED

* update layouts to new OLED

* fixup docs

* drashna's suggestion

* fix up docs

* new keyboards with oled

* core split changes

* remaining keyboard files

* Fix The Helix keyboards oled options

* reflect develop

Co-authored-by: Drashna Jaelre <drashna@live.com>
Co-authored-by: mtei <2170248+mtei@users.noreply.github.com>
2021-08-24 16:28:26 +10:00
Donald Kjer
e756a21636
eeprom_stm32: implement high density wear leveling (#12567)
* eeprom_stm32: implement wear leveling
Update EECONFIG_MAGIC_NUMBER
eeprom_stm32: check emulated eeprom size is large enough
* eeprom_stm32: Increasing simulated EEPROM density on stm32
* Adding utility script to decode emulated eeprom
* Adding unit tests
* Applying qmk cformat changes
* cleaned up flash mocking
* Fix for stm32eeprom_parser.py checking via signature with wrong base
* Fix for nk65 keyboard

Co-authored-by: Ilya Zhuravlev <whatever@xyz.is>
Co-authored-by: zvecr <git@zvecr.com>
2021-08-23 23:15:34 +01:00
QMK Bot
2481e109a0 Merge remote-tracking branch 'origin/master' into develop 2021-08-23 22:06:37 +00:00
Olli Helenius
9472c4b8cb
Fix US_RDQU keycode (#13464)
`US_RDQU` and `US_LDQU` were aliased to the same keycode. `US_RDQU`
should use the right bracket.
2021-08-24 08:06:04 +10:00
Path Nirvana
f314705921
adding uf2 flash support for blackpill 401 (#13968)
* adding uf2 flash support for blackpill 401

* forgot to add blackpill to keyboard header file

* making changes requested by drashna

* fixing tzarc s comments

* removing the keyboard

* undo the change to dactyl_manuform.h
2021-08-24 08:05:10 +10:00
Joakim Tufvegren
0ae20e7457
Make solo half of split keyboards (more) usable. (#13523)
* Make solo half of split keyboards (more) usable.

Using only one half of a split keyboard (that's using the split_common
framework to communicate) is not a great experience, since several read
timeouts per scan cycle cause an unusably slow scan rate.

This change blocks all split communication attempts for 500 ms
(configurable) after an error occurs, causing the scan rate to become at
least _more_ usable, but might need some tweaking to work fully on most
keyboards. One read timeout still needs to occur after the 500 ms has
passed, and if that timeout isn't low enough, some scan cycles may still
be too slow.

* Fix lint complaint.

* Require 25 consecutive comm errors to see comms as disconnected.

The number of max errors can be overridden by defining
`SPLIT_MAX_CONNECTION_ERRORS`.

* Add comments to new defines, and ability to disable disconnection check.

Also increase `SPLIT_MAX_CONNECTION_ERRORS` to 40, since it's divisible
by most relevant numbers for the description.

* Make lint happy ...again

* Only update `connection_check_timer` when needed.

* Add new defines to split keyboard documentation.

* Move connection timeout logic to transport.c, add `is_transport_connected`.

* Use split_common disconnection logic in matrix.c.

Instead of doing more or less the same thing twice.

* Move disconnection logic to `transport_master`.

Is a cleaner implementation, and causes the scan rate while disconnected
to increase instead of decrease.

* Lint fixes.

* Lower default `SERIAL_USART_TIMEOUT` to 20 ms.

The read timeout must be low enough to not cause exessively long scan
cycles when using a solo split half. 10 ms was determined from testing
to work fine even with the slowest defined baudrate of 19200 (5 ms was
too low for that case), so 20 ms should be fine for most cases.

* Remove `SERIAL_USART_TIMEOUT` from ergodox_infinity/config.h

Was somewhat mistakenly included in an earlier PR.

* Fix building with `USE_I2C`.

* Reduce built firmware size.

Not really sure why this works, the idea was taken from tzarc's work on
split disconnection.

* Tweak and improve opt-out for split disconnection logic.

There are now two ways to opt out from this feature:
* Set `SPLIT_MAX_CONNECTION_ERRORS` to 0. This will completely disable
  the connection status checks (also affects the slave matrix reset logic in
  matrix.c, though).
* Set `SPLIT_CONNECTION_CHECK_TIMEOUT` to 0. This will only disable the
  communication throttling while disconnected. Will make the firmware
  smaller.

* Make split disconnection logic work with custom transports.

Includes a fallback implementation for keyboards using a custom
split_util.c but not a custom matrix.c (currently no such keyboard seems
to be merged, though).

* Remove unnecessary include of timer.h

Co-authored-by: Joel Challis <git@zvecr.com>

Co-authored-by: Joel Challis <git@zvecr.com>
2021-08-22 10:51:17 +10:00
Drashna Jaelre
a80d789147
Fix issues with VIA EEPROM init and bring in line with eeconfig functionality (#13243)
Co-authored-by: Ryan <fauxpark@gmail.com>
2021-08-20 21:02:53 -07:00
Ryan
a7d48b063e
Fix LED Matrix suspend code (#14090) 2021-08-20 10:43:49 -07:00
Drashna Jaelre
92fa07336c
[Bug] Fix RGB/LED Matrix Suspend code (#14084) 2021-08-20 06:14:42 -07:00
Joel Challis
69c71d4843
Align DIP_SWITCH_PINS_RIGHT implementation with encoders (#14079) 2021-08-20 10:15:11 +01:00
XScorpion2
9d1c98c891
Added right vs left specific pin assignments for dip switch (#13074)
* Added right vs left specific pin assignments for dip switch

* Update feature_dip_switch.md

* Ran formatting tools
2021-08-19 18:39:15 +01:00
tucvbif
703f027717
Allow for removal of hysteresis on 4x encoders (#13698)
* Remove hysteresis on 4x encoders

Sometimes, controller skips encoder pulses and when it returns to default position, the encoder_pulses variable isn't equals 0. And when I turn encoder in opposite direciton, it skips first click becase of encoder_pulses crosses zero. To prevent this, I add the ENCODER_DEFAULT_POS constant, and reset encoder_pulses into 0 when the state variable equals ENCODER_DEFAULT_POS.

* Documentation for ENCODER_DEFAULT_POS
2021-08-18 09:40:00 +10:00
Joel Challis
b8e913c8db
Migrate platform independent code from tmk_core -> quantum (#13673)
* Migrate action|keyboard|keycode|eeconfig from tmk_core -> quantum
2021-08-18 00:18:58 +01:00
Joel Challis
96e2b13d1d
Begin to carve out platform/protocol API - Single main loop (#13843)
* Begin to carve out platform/protocol API

* Fix up after rebase
2021-08-18 00:11:07 +01:00
Drashna Jaelre
4c4f632378
Add a toggle key for GUI On/Off in Magic feature (#13830) 2021-08-18 08:47:50 +10:00
a-chol
75b49aff56
Digitizer HID interface : absolute coordinates for mouse cursor (#12851)
* Add digitizer HID interface for setting the mouse cursor position at
absolute screen coordinates. Tested on Pro Micro, Proton C and
Blackpill.

* Update docs/feature_digitizer.md

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update tmk_core/protocol/usb_descriptor.c

Co-authored-by: Ryan <fauxpark@gmail.com>

* Add missing copyrights
Add V-USB support

* Add support for digitizer dedicated endpoint for lufa and chibios.
Fix formatting issues
Move digitizer_task definition to the feature's base implementation file

* Run cformat on modified files

* Change digitizer report usage to Digitizer instead of Pen to avoid
pointer disappearing on Windows.

* Update tmk_core/protocol/vusb/vusb.c

Co-authored-by: Ryan <fauxpark@gmail.com>

* Run cformat from docker image

* Remove send_digitizer from host_driver_t and instead rely on the
declaration being the interface to the implementation in each
HW-specific usb implementation.

* Fix build : send_digitizer shouldn't be static in vusb and add
weak-linkage implementation for tests without usb implementation

* Change digitizer user interface to match pointing device's

* Update documentation with new API

Co-authored-by: a-chol <nothing@none.com>
Co-authored-by: Ryan <fauxpark@gmail.com>
2021-08-18 04:52:44 +10:00
freqmod
705774f7bf
Steno combinedkeys (#12538)
* Add support for steno keys that press adjacent keys simultaniously

* Add some docs for steno combined keys
2021-08-18 04:48:00 +10:00
Drashna Jaelre
7da97c293d
Rgb matrix/enable modes explicitly (#13758)
* Change animations to require explicet activation

* Add support for legacy config

* Make default for now

* Add LED Matrix support

* change LED Matrix docs
2021-08-18 04:19:00 +10:00
Drashna Jaelre
4e3726bfe1
Fixup Audio startup and add to documents (#13606)
* Fixup Audio startup and add to documents

* fix doc descriptions
2021-08-15 21:51:50 +01:00
Drashna Jaelre
f56c202fb3
Fix ifdefs for OLED split sync code (#14017) 2021-08-15 00:54:08 -07:00
Drashna Jaelre
488aaa0980
Enable sync of OLED/ST7565 display on/off state on Splits (#13542)
* Enable sync of OLED/ST7565 display on/off state on Splits

* Only send if states are not matched

Co-authored-by: Nick Brassel <nick@tzarc.org>

Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-08-15 15:39:08 +10:00
Pete Sevander
fd3dc3a997
Fix combo_disable (#13988)
- Dump key buffer when combos are disabled.
- Recursive calls to `dump_key_buffer` need to start dumping the buffer
  from index i+1 to avoid possible infinite loops.
- Handle combo key releases even though combo processing is disabled.
2021-08-14 14:45:52 +10:00
Nick Brassel
65e3760853
Fix compilation issue. (#13926) 2021-08-09 13:20:15 +10:00
thpoll83
b43c6bc176
Add support for STM32F407x MCUs. (#13718)
* Add support for STM32F407x MCUs.

* Removing STMF407 MCU variation

* Update quantum/mcu_selection.mk

Remove options for dfu flashing

Co-authored-by: Ryan <fauxpark@gmail.com>

* DISABLE STM32_USB_USE_OTG1

* Update platforms/chibios/GENERIC_STM32_F407XE/configs/mcuconf.h

Co-authored-by: Drashna Jaelre <drashna@live.com>

* Update platforms/chibios/GENERIC_STM32_F407XE/configs/mcuconf.h

Co-authored-by: thomas.pollak <thomas.pollak@dynatrace.com>
Co-authored-by: Ryan <fauxpark@gmail.com>
Co-authored-by: Drashna Jaelre <drashna@live.com>
Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-08-09 06:52:13 +10:00
Liyang HU
383fae55c5
Refactor quantum/command.{c,h} for code size & {read,maintain}ability (#11842)
* quantum/command.c: coalesce `print()`s in `command_common_help()` & `print_version()`

Also undo some damage by clang-format in b624f32f94

* quantum/command.c: replace `print(…); print_{,val_}{dec,hex}*(…);` sequences with single `xprintf(…)`

`print_{dec,hex}*(…)` are just `#define`s for `xprintf(…)` anyway.

Each additional `xprintf(…)` costs ~8 bytes: the call instructions,
plus an additional NUL terminator.

This _really_ adds up: this commit saves 814 bytes on my ATmega32.

* quantum/command.c: optimise `mousekey_console()` for size & legibility

Made various tweaks to the interface, but still functionally identical.

Assume `KC_1`…`KC_0` to be contiguous, and removed `numkey2num(…)` entirely.
It was exported in `command.h` by 1a0bac8bcc for no obvious reason, before
which it was `static`. I doubt anyone uses it.

`mousekey_console()` is now enabled regardless of `MK_3_SPEED`.
Needs fleshing out for things other than the X11 variant though.

This commit saves 638 bytes on my ATmega32.
2021-08-07 17:12:57 +10:00
James Young
a03aa301de
Remove Full Bootmagic (#13846)
* disambiguate Bootmagic rules in keymaps

The files edited by this commit were added at a point in time where `BOOTMAGIC_ENABLE = yes` enabled full Bootmagic.

This commit edits the files to specify that full Bootmagic is intended.

* remove BOOTMAGIC_ENABLE=full setting

* unify commented BOOTMAGIC_ENABLE rules in keyboards

Explicitly sets `BOOTMAGIC_ENABLE = no` in keyboards where the rule was commented out.

Command:

```
find keyboards/ -type f -name 'rules.mk' -and -not -path '*/keymaps/*' -exec sed -i -e 's;#[ \t]*\(BOOTMAGIC_ENABLE\)[ \t=]\+\([a-zA-Z]\+\).*;\1 = no       # Virtual DIP switch configuration;g' {} +
```

* remove commented Bootmagic rules from keymap/user level

Command:

```
find keyboards/ layouts/ users/ -type f -name 'rules.mk' -exec sed -i -e '/#.*\(BOOTMAGIC_ENABLE\)[ \t=]\+\([a-z]\+\).*/d' {} +
```

* update keyboard BOOTMAGIC_ENABLE rule formatting

Sets the formatting of BOOTMAGIC_ENABLE rules to `BOOTMAGIC_ENABLE = [value]`, without the inline comments (which will be replaced later).

Command:

```
find keyboards/ -type f -name 'rules.mk' -and -not -path '*/keymaps/*' -exec sed -i -e 's;\(BOOTMAGIC_ENABLE\)[ \t=]\+\([a-z]\+\).*;\1 = \2;g' '{}' +
```

* update keyboards' BOOTMAGIC_ENABLE settings

Updates keyboard `rules.mk` files to use `BOOTMAGIC_ENABLE = lite` where `BOOTMAGIC_ENABLE = full` was being used.

Command:

```
find keyboards/ -type f -name 'rules.mk' -and -not -path '*/keymaps/*' -exec sed -i -e 's;\(BOOTMAGIC_ENABLE = \)full;\1lite;g' '{}' +
```

* update keymap/user BOOTMAGIC_ENABLE settings

Updates keymap/user `rules.mk` files to use `BOOTMAGIC_ENABLE = lite` where `BOOTMAGIC_ENABLE = full` was being used.

Commands:

```
find keyboards/ -type f -name 'rules.mk' -and -path '*/keymaps/*' -exec sed -i -e 's;\(BOOTMAGIC_ENABLE[ \t=]\+\)full;\1lite;g' '{}' +
find layouts/community/ users/ -type f -name 'rules.mk' -exec sed -i -e 's;\(BOOTMAGIC_ENABLE[ \t=]\+\)full;\1lite;g' '{}' +
```

* remove and replace inline comments in keyboards and keymap/user files

Removes and replaces the inline comments, which have been updated to read `Enable Bootmagic Lite`.

Commands:

```
find keyboards/ -type f -name 'rules.mk' -and -path '*/keymaps/*' -exec sed -i -e 's;\(BOOTMAGIC_ENABLE\)[ \t=]\+\([a-z]\+\).*;\1 = \2;g' '{}' +
find layouts/community/ users/ -type f -name 'rules.mk' -exec sed -i -e 's;\(BOOTMAGIC_ENABLE\)[ \t=]\+\([a-z]\+\).*;\1 = \2;g' '{}' +
find keyboards/ layouts/community/ users/ -type f -name 'rules.mk' -exec sed -i -e 's;\(BOOTMAGIC_ENABLE = lite\);\1     # Enable Bootmagic Lite;g' '{}' +
find keyboards/ layouts/community/ users/ -type f -name 'rules.mk' -exec sed -i -e 's;\(BOOTMAGIC_ENABLE = yes\);\1      # Enable Bootmagic Lite;g' '{}' +
find keyboards/ layouts/community/ users/ -type f -name 'rules.mk' -exec sed -i -e 's;\(BOOTMAGIC_ENABLE = no\);\1       # Enable Bootmagic Lite;g' '{}' +
```

* rename improperly named makefiles

Some files intended to be used as makefiles had improper names causing them to not be used as intended when building.

This commit corrects the filenames of the affected files.

* update renamed file with new rule formatting

* update QMK's template files

Updates QMK's `rules.mk` templates to use the new inline comment.

* update QMK Docs

- remove documentation of full Bootmagic
- update links to Bootmagic Lite doc
- add doc for Magic Keycodes

* rules.mk patch for coarse/ixora and coarse/vinta
2021-08-06 23:59:56 -07:00
QMK Bot
538d9d7890 Merge remote-tracking branch 'origin/master' into develop 2021-08-06 05:54:10 +00:00
Joel Challis
c588d232cb
Avoid name conflicts with usb_hid Arduino code (#13870)
* Avoid name conflicts with usb_hid Arduino code

* Fix tests
2021-08-06 15:53:38 +10:00
Pete Sevander
7e983796e1
Process combos earlier & overlapping combos (#8591)
* Combo processing improvements.

Now it is possible to use ModTap and LayerTap keys as part of combos.
Overlapping combos also don't trigger all the combos, just exactly the
one that you press.

New settings:
- COMBO_MUST_HOLD_MODS
- COMBO_MOD_TERM
- COMBO_TERM_PER_COMBO
- COMBO_MUST_HOLD_PER_COMBO
- COMBO_STRICT_TIMER
- COMBO_NO_TIMER

* Remove the size flags from combo_t struct boolean members.

This in the end actually saves space as the members are accessed so many
times. The amount of operations needed to access the bits uses more
memory than setting the size saves.

* Fix `process_combo_key_release` not called correctly with tap-only combos

* Fix not passing a pointer when NO_ACTION_TAPPING is defined.

* Docs for `COMBO_ONLY_FROM_LAYER`

* Update docs/feature_combo.md

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

* Update quantum/process_keycode/process_combo.c

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

* Add `EXTRA_SHORT_COMBOS` option.

Stuff combo's `disabled` and `active` flags into `state`. Possibly can
save some space.

* Add more examples and clarify things with dict management system.

- Simple examples now has a combo that has modifiers included.
- The slightly more advanced examples now are actually more advanced
  instead of just `tap_code16(<modded-keycode>)`.
- Added a note that `COMBO_ACTION`s are not needed anymore as you can
  just use custom keycodes.
- Added a note that the `g/keymap_combo.h` macros use the
  `process_combo_event` function and that it is not usable in one's
  keymap afterwards.

* Update docs/feature_combo.md

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

* Update docs/feature_combo.md

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

* Update docs/feature_combo.md

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

* Update docs/feature_combo.md

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

* Update docs/feature_combo.md

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

* Change "the" combo action example to "email" example.

* Update docs/feature_combo.md

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

* Fix sneaky infinite loop with `combo_disable()`

No need to call `dump_key_buffer` when disabling combos because the
buffer is either being dumped if a combo-key was pressed, or the buffer is empty
if a non-combo-key is pressed.

* Update docs/feature_combo.md

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

* Update docs/feature_combo.md

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>

Co-authored-by: precondition <57645186+precondition@users.noreply.github.com>
Co-authored-by: Drashna Jaelre <drashna@live.com>
2021-08-06 09:44:57 +10:00
QMK Bot
600faab707 Merge remote-tracking branch 'origin/master' into develop 2021-08-04 00:23:25 +00:00
Drashna Jaelre
a0f2be18a4
Add bootloader section to keyboard template (#13774)
* Add bootloader section to keyboard template

* Apply suggestions from code review

Co-authored-by: Ryan <fauxpark@gmail.com>

Co-authored-by: Ryan <fauxpark@gmail.com>
2021-08-04 01:23:18 +01:00
QMK Bot
c48d9c2b2a Merge remote-tracking branch 'origin/master' into develop 2021-08-03 21:40:39 +00:00
Joakim Tufvegren
2b097d670a
Fix overflows in WPM calculations (#13128)
* Fix overflow in WPM calculations.

First, the "fresh" WPM calculation could end up being up to 12000 (with
default `WPM_ESTIMATED_WORD_SIZE`) if keys were pressed more or less
simultaneously. This value has now been clamped down to 255, in effect
clamping WPM to its max value of 255.

Second, with `WPM_ALLOW_COUNT_REGRESSION` enabled, it was possible to
regress the WPM below 0 (i.e. to 255) by just repeatedly pressing
backspace.

* Fix WPM being limited to 235 due to float/int logic.
2021-08-04 07:40:08 +10:00
Joel Challis
34de7ca224
Move print/debug files to quantum (#12069)
* move print/debug files to quantum

* Update comments
2021-08-03 18:49:33 +01:00
Joel Challis
3f419dc872
Unconditionally call led_init_ports (#12116)
* Unconditionally call led_init_ports

* Another call to led_init_ports
2021-08-03 18:34:32 +01:00
Drashna Jaelre
ebed2e9a81
[BUG] Fix Key Override includes (#13831)
* [BUG] Fix Key Override includes

* simplify includes
2021-08-01 16:29:23 +01:00
Joel Challis
4ef8ff458d
Minor tidy up of key overrides (#13747)
* Minor tidy up of key overrides

* Update quantum/quantum.c

* Update quantum/quantum.c
2021-07-28 12:01:49 +01:00
Joel Challis
03d258c222
matrix_scan_x -> x_task (#13748) 2021-07-28 12:01:23 +01:00
Joel Challis
3858a784c7
Align AW20216 driver (#13712)
* Align AW20216 driver

* Update drivers/awinic/aw20216.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Review comments

* formatting fixes

* stop if start failed?

* review comments

Co-authored-by: Ryan <fauxpark@gmail.com>
2021-07-27 23:55:51 +01:00
Joel Challis
f945c352e7
Haptic: driver-> feature (#13713) 2021-07-25 19:14:58 -07:00
Nick Brassel
4ec8764c70 Merge remote-tracking branch 'upstream/master' into develop 2021-07-25 12:17:15 +10:00
Joel Challis
b5bcd5b0a1
Refactor some platform dependent logic (#13675) 2021-07-24 19:56:45 +01:00
Joel Challis
567da49ed0
Avoid LTO conficts on arm_atsam (#13676) 2021-07-24 12:13:06 +01:00
Nick Brassel
489c0f969d
Disables rgblight twinkle by default. (#13677)
This takes up about 700 bytes of space, and needs to be swapped to
opt-in, rather than opt-out. Build failures in general on AVR due to the
scarcity of available flash. People can re-enable it by adding to their
keymap's config.h files:

```
  #define RGBLIGHT_EFFECT_TWINKLE
```
2021-07-24 13:40:00 +10:00
Patrick Stadler
fb9a254a43
Retain brightness with lighting layers (#13025)
Add guard `RGBLIGHT_LAYERS_RETAIN_VAL` to retain the currently used val
when applying lighting layers.
2021-07-21 23:46:12 -07:00
QMK Bot
8925199ae8 Merge remote-tracking branch 'origin/master' into develop 2021-07-20 16:17:22 +00:00
Carl-Fredrik Arvidson
3486870ee4
Adds Swedish Mac ISO and ANSI keymaps (#13055)
* Adds Swedish Mac ISO and ANSI keymaps

* Replaces NBSP with space

* Adds missing keys

* Remove duplicates

* Remove duplicates

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Change case and remove whitespace

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Fix uppercase

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Add specific files for Swedish Pro

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Remove whitespace

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_pro_osx_ansi.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/keymap_swedish_osx_iso.h

Co-authored-by: Ryan <fauxpark@gmail.com>

Co-authored-by: Ryan <fauxpark@gmail.com>
2021-07-20 09:16:17 -07:00
Joakim Tufvegren
1414e9736d
Switch Ergodox Infinity over to split_common (#13481) 2021-07-19 18:54:32 -07:00
Ryan
777fffb067
Revert "Add rgblight to RGB Matrix VPATH" (#13559) 2021-07-17 13:39:52 +10:00
QMK Bot
d1295ffe9a Merge remote-tracking branch 'origin/master' into develop 2021-07-17 03:13:57 +00:00
Takeshi ISHII
d26537acc1
remove RGBLIGHT_H_DUMMY_DEFINE macro from rgblight.h (#13569) 2021-07-17 12:13:16 +09:00
Ryan
332a5aa7cb
Move SENDSTRING_BELL code to send_string.h (#13566) 2021-07-16 09:40:20 -07:00
Johannes Choo
10d7eca5af
Fix LED Hit Counter for LED/RGB Matrix (#12674) 2021-07-16 09:37:18 -07:00
QMK Bot
f0198ad15e Merge remote-tracking branch 'origin/master' into develop 2021-07-16 03:55:56 +00:00
Takeshi ISHII
5fda0e2c04
remove #include "rgblight.h" when defined(RGB_MATRIX_ENABLE) from quantum.h (#13555) 2021-07-16 12:54:56 +09:00
Chris Cullin
70267b35c3
Dual RGB Matrix IS31FL3737 driver support to address #13442 (#13457)
* initial commit

* removed changes to write_pwm_buffer

* backward compatbility added

* fixed issue with backward compatibility

* documentation update

* removed unneccessary comment. branched from master

* updated per comments #13457

* removed blank line

* cformat on diff files
2021-07-15 22:52:05 +01:00
Jonas Gessner
52cfc9259b
[Feature] Key Overrides (#11422) 2021-07-13 10:13:51 -07:00
Takeshi ISHII
ac2e6e01f1
Change the prototype of matrix_output_unselect_delay() (#13045)
The prototype of matrix_output_unselect_delay() has been changed as follows.

```c
void matrix_output_unselect_delay(uint8_t line, bool key_pressed);
```

Currently, no keyboard seems to be redefining `matrix_output_unselect_delay()`, so there is no change in the system behavior.

With this change, the keyboard level code can get some optimization hints, for example, the following.

```c
 void matrix_output_unselect_delay(uint8_t line, bool key_pressed) {
     /* If none of the keys are pressed,
      *  there is no need to wait for time for the next line. */
     if (key_pressed) {
 #ifdef MATRIX_IO_DELAY
 #  if MATRIX_IO_DELAY > 0
         wait_us(MATRIX_IO_DELAY);
 #  endif
 #else
         wait_us(30);
 #endif
     }
}
```
2021-07-13 16:50:25 +09:00
Joakim Tufvegren
4706231831
Fix two out of bounds accesses from #13330. (#13525)
Two occurrences of `MATRIX_ROWS` weren't properly changed to
`ROWS_PER_HAND` in #13330, causing a crash during boot on at least my
Ergodox Infinity (including #13481).
2021-07-12 08:43:05 -07:00
Drashna Jaelre
ccc0b23a75
Unify matrix for split common and regular matrix (#13330) 2021-07-11 14:31:35 -07:00
Ryan
50d4dfd2e6
keymap_extras: Remove deprecated defines (#12949) 2021-07-06 09:05:11 +10:00
Jameson Thatcher
550d9253b0
Allow invert of SPLIT_HAND_PIN logic (#13433)
* added support for inverting the hand pin for split keyboards

* Added docs about SPLIT_HAND_LOW_IS_LEFT

* Update docs/feature_split_keyboard.md

bring #define for split hand pin low for left half name in line with grid pin define

Co-authored-by: Joel Challis <git@zvecr.com>

* Update quantum/split_common/split_util.c

update split hand pin low is left name to match split hand grid define

Co-authored-by: Joel Challis <git@zvecr.com>

Co-authored-by: Joel Challis <git@zvecr.com>
2021-07-05 09:06:40 +10:00
Thomas Weißschuh
b5c361542e
mousekey: expose current report to users (#13069) 2021-07-03 00:50:47 -07:00
Drashna Jaelre
3ab805fc67
Add support for NO_PIN to all matrix types (#12238)
Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-07-03 00:20:11 -07:00
Drashna Jaelre
8da8aabbe5
Improve layer mask handling (#13065) 2021-07-03 00:19:52 -07:00
Stefan Kerkmann
04bc74d8f5
Switch split_common to CRC subsystem (#13418) 2021-07-02 22:28:32 +01:00
Drashna Jaelre
0bde920817
Convert Dip Switch callbacks to boolean functions (#13399) 2021-07-01 08:22:21 -07:00
QMK Bot
8b2e5d622c Merge remote-tracking branch 'origin/master' into develop 2021-07-01 06:42:24 +00:00
Ryan
dc3896e31c
Cleanup junk chars, part 4 (#13345) 2021-07-01 16:41:51 +10:00