1
0
Fork 0
Commit graph

1207 commits

Author SHA1 Message Date
QMK Bot
bd639752db format code according to conventions [skip ci] 2020-04-28 07:04:07 +00:00
Ryan
aaeef7a833
Add Romanian keymap and sendstring LUT (#8852) 2020-04-28 16:23:48 +10:00
Ryan
43785126a7
Merge pull request #8710 from vomindoraan/keymap_extras_fixup 2020-04-19 19:18:05 +10:00
Konstantin Đorđević
ed910c8e97 Add back deprecated SE_AE keycode 2020-04-19 02:56:52 +02:00
joseandres42
195324cc4c
Add dvorak's spanish variant to quantum/keymap_extras (#8732)
* Added dvorak's spanish variant.

* Fixed spacing

* Fixed filename typo

* Applied fixes and suggestions.

* Fixed spacing

* Added sendstring_spanish_dvorak.h

* Fixed sendstring_spanish.h

* Update quantum/keymap_extras/sendstring_spanish_dvorak.h

Co-Authored-By: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/sendstring_spanish.h

Co-Authored-By: Ryan <fauxpark@gmail.com>

* Update quantum/keymap_extras/sendstring_spanish_dvorak.h

Co-Authored-By: Ryan <fauxpark@gmail.com>

Co-authored-by: joseandres42 <joseandres42@Orion-PC.localdomain>
Co-authored-by: Ryan <fauxpark@gmail.com>
2020-04-18 17:12:36 -07:00
Ryan
cd5399942b
Merge pull request #8722 from fauxpark/keymap-extras-bepo 2020-04-19 06:58:01 +10:00
Ryan
fd4bbd8d11
Update Italian macOS keymaps and add sendstring LUTs (#8701)
* Update Italian macOS keymaps and add sendstring LUTs

* Wrong letter
2020-04-19 06:57:36 +10:00
Ryan
f43cb31476
Update French and German macOS keymaps and add sendstring LUTs (#8700) 2020-04-19 06:57:05 +10:00
Ryan
89eb3a9e42
Update Swiss French/German keymaps and add sendstring LUTs (#8689) 2020-04-19 06:56:49 +10:00
fauxpark
09a1917103 Slight rename of double angle quote keycodes 2020-04-13 21:15:37 +10:00
Takeshi ISHII
d3c29c9b3c
Bugfix for quantum/dip_switch.c (#8731)
* 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-04-12 12:44:24 -07:00
Konstantin Đorđević
370577e4ed
Add *OPT aliases for *ALT keycodes and macros (#8714) 2020-04-12 11:37:55 -07:00
QMK Bot
5380c29dd7 format code according to conventions [skip ci] 2020-04-12 18:11:52 +00:00
artjomsR
23f19852b9
Added Workman ZXCVM variation (#8686)
* 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-04-12 10:37:17 -07:00
Drashna Jaelre
23124b9fd1
Fix bug with layer caching in get_event_keycode (#8693)
* Fix bug with layer caching in get_event_keycode

* Improve naming
2020-04-12 17:27:17 +02:00
Purdea Andrei
b8c3f4c60b
quantum/debounce: Added sym_pk debounce algorithm (#8587)
* 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-04-11 21:29:48 +10:00
QMK Bot
cc38627816 format code according to conventions [skip ci] 2020-04-11 00:48:16 +00:00
Purdea Andrei
6c2c3c13e9
Various fixes to how timer differences are calculated (#8585)
* 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-04-11 10:14:28 +10:00
Konstantin Đorđević
be2f5816b6
Fix compile issues related to NO_ACTION_MACRO/FUNCTION and LTO_ENABLE (#8663)
* 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-04-09 00:18:30 +01:00
fauxpark
0499f30f59 Update BÉPO keymap and sendstring LUT 2020-04-07 20:50:10 +10:00
Wilba
9bfa713421
Configurable VIA layout options default value (#8707) 2020-04-06 20:27:44 +01:00
Konstantin Đorđević
e0909a31c7 GR_DTON → GR_DIAT 2020-04-06 19:32:40 +02:00
Konstantin Đorđević
d6bffdf577 Small corrections to Belgian, Serbian and Slovenian keymaps 2020-04-06 19:10:57 +02:00
fauxpark
bf38f39c3f Wrong letter 2020-04-06 20:15:13 +10:00
fauxpark
62d1d69ba9 Update Italian macOS keymaps and add sendstring LUTs 2020-04-06 15:30:36 +10:00
Ryan
c3c2eb71e1
Add Greek keymap (#8636)
* 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-04-05 00:56:20 -07:00
Ryan
28a6a4a15b
Add Polish keymap (#8637)
* 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-04-05 00:55:13 -07:00
Drashna Jaelre
ccb37f673a
Add Russian keymap (#8638)
* Add Russian keymap

* Switch to ANSI layout
2020-04-05 00:53:52 -07:00
Ryan
c5efbc45a1
Add Korean keymap (#8635)
* 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-04-05 00:51:10 -07:00
Joel Challis
9c4bf0ac4a
Initial support for ATtiny85 (#8632)
* Initial support for ATtiny85

* Update mcu selection
2020-04-02 22:23:57 +01:00
Joel Challis
58a9c84d6b
Strip out features to allow minimum firmware sizes (#8645) 2020-04-01 21:06:22 +01:00
fauxpark
781308507d Switch to ANSI layout 2020-04-02 03:10:51 +11:00
Ryan
95c5c11d0b
Miscellaneous cleanups (#8639)
* Miscellaneous cleanups

* Cast NO_PIN
2020-04-01 15:49:45 +01:00
fauxpark
3fe8d604a4 Add Russian keymap 2020-04-01 14:09:34 +11:00
Ryan
194bc7a7e1
Add Slovak keymap and sendstring LUT (#8561) 2020-04-01 14:01:24 +11:00
Ryan
fec4283022
Add Serbian keymaps and sendstring LUT (#8560)
* Add Serbian keymaps and sendstring LUT

* Apply suggestions from code review

Co-Authored-By: Konstantin Đorđević <vomindoraan@gmail.com>

* Fix formatting

Co-authored-by: Konstantin Đorđević <vomindoraan@gmail.com>
2020-04-01 14:01:01 +11:00
Ryan
17af712b7c
Add Lithuanian keymap and sendstring LUT (#8562)
* Add Lithuanian keymap and sendstring LUT

* Add Lithuanian AZERTY
2020-04-01 14:00:34 +11:00
Ryan
712ded1f2f
Add Latvian keymap and sendstring LUT (#8563) 2020-04-01 14:00:02 +11:00
Konstantin Đorđević
bdfdc506da
Rename UC_OSX (and related constants) to UC_MAC (#8589)
* 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
2020-03-31 18:28:43 +02:00
Ryan
51a81813b0
V-USB: Consolidate usbconfig.h's into a single file (#8584) 2020-03-31 13:17:04 +01:00
QMK Bot
9acd5e04d5 format code according to conventions [skip ci] 2020-03-30 20:52:13 +00:00
Antosha
0afcb8a36c
Added USSR anthem. (#8588) 2020-03-30 22:17:04 +02:00
Ryan
14079ce698
V-USB: Use structs for USB descriptors (#8572)
* V-USB: Use structs for USB descriptors

* Update usbconfigs

* cformat pass
2020-03-28 13:02:25 +11:00
Drashna Jaelre
ed80874f72
Fix IT_APOS backward compatibility define in keymap_italian.h (#8565)
* Fix IT_APOS backward compatibility define in keymap_italian.h

Found by ZSA.
2020-03-27 09:44:06 +11:00
Ryan
981ea87b05
Add Estonian keymap (#8527) 2020-03-26 16:51:07 +11:00
Ryan
65252ebf67
Add Croatian keymap (#8525)
* Add Croatian keymap

* Fix comment on HR_DIAE
2020-03-26 16:50:39 +11:00
Joel Challis
6ceaae30f5
Run clang-format manually to fix recently changed files (#8552) 2020-03-25 14:39:53 +11:00
Ryan
6d1af63842
Add Irish keymap (#8528) 2020-03-22 17:32:43 -07:00
Ryan
6c4a744a1b
Add Czech keymap (#8526) 2020-03-22 17:31:19 -07:00
QMK Bot
76cb2b1160 format code according to conventions [skip ci] 2020-03-22 14:03:14 +00:00