summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-06-12Remove old setup scripts (#8811)Ryan
2020-06-12MILC: Fix setting config values for store_true and store_false (#8813)skullydazed
2020-06-12Miscellaneous stuff: remove clang-complete and autocomplete.sh, fix some ↵Ryan
rules.mk comments (#8784)
2020-06-12CLI: Fix doctor error when can't run `bin/qmk --version`. (#8796)Pete Johanson
2020-06-12CLI: Use `shutil.which` to detect gmake, instead of OS check.Pete Johanson
2020-06-12CLI: Invoke gmake on FreeBSD when using `qmk compile`.Pete Johanson
* Current makefiles aren't portable, so invoke gmake on FreeBSD.
2020-06-12Slight rename of double angle quote keycodesfauxpark
2020-06-12Fix AVR SPI parameter configuration, remove timeouts due to sync protocol. ↵Nick Brassel
(#8775)
2020-06-12Add support for hardware and board initialisation overrides. (#8330)Nick Brassel
* Add support for hardware and board initialisation overrides. * qmk cformat. * Add some documentation. * Docs clarity. * Make early_hardware_init_pre a no-op for now, until migrations occur. * Doco update * Make distinction between keyboard and ChibiOS board in docs * Doc anchors. * Update tmk_core/protocol/chibios/main.c Co-Authored-By: Joel Challis <git@zvecr.com> * Rework bootloader entry to be off by default, allow opting-in. Co-authored-by: Joel Challis <git@zvecr.com>
2020-06-12Bugfix for quantum/dip_switch.c (#8731)Takeshi ISHII
* dipsw test on helix/rev2/sc/back:five_rows * bug fix quantum/dip_switch.c * test end. remove test code. Revert "dipsw test on helix/rev2/sc/back:five_rows" This reverts commit 4b13ebb996e1c4997e6deb1fa3b3227db5fa9661. * dipsw test on helix/rev2/sc/back:five_rows * update quantum/dip_switch.c * test end. remove test code. Revert "dipsw test on helix/rev2/sc/back:five_rows" This reverts commit bf99ace095528ad65c531229bcf5ece037dda595.
2020-06-12Add *OPT aliases for *ALT keycodes and macros (#8714)Konstantin Đorđević
2020-06-12Added Workman ZXCVM variation (#8686)artjomsR
* Added Workman ZXCVM variation * Update quantum/keymap_extras/keymap_workman_zxcvm.h Co-Authored-By: Konstantin Đorđević <vomindoraan@gmail.com> * Update quantum/keymap_extras/sendstring_workman_zxcvm.h Co-Authored-By: Ryan <fauxpark@gmail.com> * Update quantum/keymap_extras/keymap_workman_zxcvm.h Co-Authored-By: Ryan <fauxpark@gmail.com> * Update quantum/keymap_extras/keymap_workman_zxcvm.h Co-Authored-By: Ryan <fauxpark@gmail.com> * Update quantum/keymap_extras/sendstring_workman_zxcvm.h Co-Authored-By: Ryan <fauxpark@gmail.com> Co-authored-by: Konstantin Đorđević <vomindoraan@gmail.com> Co-authored-by: Ryan <fauxpark@gmail.com>
2020-06-12Fix bug with layer caching in get_event_keycode (#8693)Drashna Jaelre
* Fix bug with layer caching in get_event_keycode * Improve naming
2020-06-12Upgrade gcc version/tweak package installs in Gentoo installation (#8757)James Forcier
GCC 4.9.4 is no longer available on Gentoo (or Sabayon), which causes problems when attempting to install on either of these platforms. Since QMK is not particularly sensitive to its GCC version, modify the version restriction to <9 so newer versions of GCC may be installed. Since the toolchain for arm-none-eabi isn't currently installed as part of setup, add that as well. Additionally, drop the Python installation as part of the Gentoo installation process. Python is a core system package on Gentoo and can therefore be assumed to be present; in addition, the slot restriction of 3.5 which was present is also no longer available in Gentoo. Finally, separate the gcc rebuild invocation of `emerge` from the new packages that may need to be installed, and apply the `--noreplace` flag to new packages so that they are not rebuilt if already present.
2020-06-12quantum/debounce: Added sym_pk debounce algorithm (#8587)Purdea Andrei
* quantum/debounce: Added sym_pk debounce algorithm * Apply suggestions from code review Co-Authored-By: Ryan <fauxpark@gmail.com> * quantum/debounce/sym_pk: delete comments and rename functions following code review * quantum/debounce/sym_pk: Modifications for code readability according to code review * quantum/debounce/sym_pk: Modifications for code readability according to code review (2) * quantum/debounce/sym_pk: code review: cleaner code Co-Authored-By: Nick Brassel <nick@tzarc.org> Co-authored-by: Ryan <fauxpark@gmail.com> Co-authored-by: Nick Brassel <nick@tzarc.org>
2020-06-12Various fixes to how timer differences are calculated (#8585)Purdea Andrei
* 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)
2020-06-12Add PS2_MOUSE_ROTATE to compensate for device orientation (#8650)Manna Harbour
* Add PS2_MOUSE_ROTATE to compensate for device orientation * fixup! Add PS2_MOUSE_ROTATE to compensate for device orientation * Reformat with IndentPPDirectives: AfterHash as per #6316
2020-06-12Fix compile issues related to NO_ACTION_MACRO/FUNCTION and LTO_ENABLE (#8663)Konstantin Đorđević
* 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
2020-06-12Fix edge-case with configErovia
Without this check, users can lock themselves out by enabling developer mode, than disabling the dependencies. They wouldn't be able to turn off developer mode as none of the subcommands (including 'config') would work.
2020-06-12Don't hide for devs...Erovia
2020-06-12Apply @skullydazed's suggestions, move 'import milc'Erovia
Only 'import milc' after we are sure that the minimum required modules are available, as it depends on a few of them.
2020-06-12Rebase on master, hide some other subcommandsErovia
The list of hidden subcommands were approved by @skullydazed ;) Currently hidden if 'user.developer' is not True: - cformat - docs - kle2json - pyformat - pytest
2020-06-12Use milc for config check, requirements fixesErovia
Use milc's config finding and parsing to check if the user is a developer or not. 'requirements-dev.txt' will now load 'requirements.txt', so no need to run pip twice. Add missing 'yapf' dependency to 'requirements-dev.txt'.
2020-06-12CLI: Add development mode supportErovia
Hide development specific options and don't require dev modules unless `user.developer` is set to `True`.
2020-06-12spi_master for AVR (#8299)Ryan
* Change _delay_ms/us() to wait_ms/us() * Switch to platform-agnostic GPIO macros * Add AVR spi_master and migrate Adafruit BLE code * Set verbose back to false * Add clock divisor, bit order and SPI mode configuration for init * Add start and stop functions * Move configuration of mode, endianness and speed to `spi_start()` * Some breaks here would be good * Default Adafruit BLE clock divisor to 4 (2MHz on the Feather 32U4) * Remove mode and divisor enums * Add some docs * No hr at EOF * Add links in sidebar
2020-06-12Update BÉPO keymap and sendstring LUTfauxpark
2020-06-12Correctly handle json keymaps with ANY()skullY
2020-06-12GR_DTON → GR_DIATKonstantin Đorđević
2020-06-12Small corrections to Belgian, Serbian and Slovenian keymapsKonstantin Đorđević
2020-06-12Wrong letterfauxpark
2020-06-12Update Italian macOS keymaps and add sendstring LUTsfauxpark
2020-06-12V-USB: Remove some stuff from usbconfig.h that should not be configurable ↵Ryan
(#8656) * V-USB: Remove some stuff from usbconfig.h that should not be configurable * Clean up some ifdefs * And some more * Even more
2020-06-12Doctor: Add avrdude/dfu-util/dfu-programmer version printing (#8678)Ryan
* Doctor: Add avrdude/dfu-util/dfu-programmer version printing * Extra newline * Iterate through version checking functions
2020-06-12V-USB remote wakeup (#7627)Drashna Jaelre
* V-USB remote wakeup Backport from tmk/tmk_keyboard@391c979be751eaf113c8f53c36644a6bb6ff12f6 * Change vusb.c remote wake config as per fauxpark's suggestion
2020-06-12Add Greek keymap (#8636)Ryan
* Add Greek keymap * Split left shift (unused), change keycode for dialytika tonos * Update quantum/keymap_extras/keymap_greek.h Co-Authored-By: Konstantin Đorđević <vomindoraan@gmail.com> * Fix definition for DTON Co-authored-by: Konstantin Đorđević <vomindoraan@gmail.com>
2020-06-12Add Polish keymap (#8637)Ryan
* Add Polish keymap * Fix wrong AltGr mapping * These are ogoneks, not cedillas * Too many !s * ANSI * Just use BSLS * Move BSLS * Move PIPE * Fix some incorrect names in keymap_slovak.h Thanks to vomindoraan
2020-06-12Switch to ANSI layoutfauxpark
2020-06-12Add Korean keymap (#8635)Ryan
* Add Korean keymap * Switch to ANSI layout * Update quantum/keymap_extras/keymap_korean.h Co-Authored-By: Konstantin Đorđević <vomindoraan@gmail.com> Co-authored-by: Konstantin Đorđević <vomindoraan@gmail.com>
2020-06-12minor tweaksskullY
2020-06-12Fix saving output from avrdude and dfu-programmerRoss Baquir
2020-06-12Use version_arg in ESSENTIAL_BINARIES dictRoss Baquir
2020-06-12Fixes #8541 by getting version from -dumpversion then --version as fallbackRoss Baquir
2020-06-12Initial support for ATtiny85 (#8632)Joel Challis
* Initial support for ATtiny85 * Update mcu selection
2020-06-12Fix AVR ws2812 when ADDRESS_BASE is non zero (#8646)Joel Challis
* Fix AVR ws2812 when ADDRESS_BASE is non zero * fix port * remove unused function defs
2020-06-12Fix `pgm_read_ptr()` define for ARM (#8658)Ryan
2020-06-12Strip out features to allow minimum firmware sizes (#8645)Joel Challis
2020-06-12Updated V-USB template to allow usbFunctionWriteOut (#8634)yiancar
2020-06-12Miscellaneous cleanups (#8639)Ryan
* Miscellaneous cleanups * Cast NO_PIN
2020-06-12Migrate :program logic to :flash (#8631)Joel Challis
2020-06-12Rename UC_OSX (and related constants) to UC_MAC (#8589)Konstantin Đorđević
* Rename UC_OSX (and related constants) to UC_MAC * Update UNICODE_SONG_OSX references to UNICODE_SONG_MAC * Update UC_M_OS references to UC_M_MA * Add UC_OSX alias for backwards compatibility * Add deprecation warning for UC_OSX to Unicode docs * Add UC_M_OS alias for backwards compatibility * Update newly found UC_M_OS and UNICODE_SONG_OSX references * Add legacy UNICODE_MODE_OSX alias, revert changes to user keymaps * Add legacy UNICODE_SONG_OSX alias, revert changes to user keymaps * Replace removed sounds in Unicode song doc examples