* Skip process_music in NO_MUSIC_MODE is defined
* Skip matrix_scan_music if NO_MUSIC_MODE is defined
* Skip music_all_notes_off if NO_MUSIC_MODE is defined
* Leave matrix_scan_music in, because it reduces firmware size by 150b....
* Add docs for NO_MUSIC_MODE
* Move lufa descriptor to protocol/usb_descriptor
* Try to compile usb_descriptor on ChibiOS
* Add lufa_utils for ChibiOS
Lufa USB descriptors for ChibiOS
* More lufa_util compatibility fixes
* First compiling version of shared USB descriptor
* Send the usb descriptors
* Fix the CONSOLE output on ChibiOS
* Add errors for unsupported interfaces
* Enable support for vitual serial port USB descriptors
* Implement virtual serial port for ChibiOS
* Cleanup the lufa_utils
Use the default lufa header files
* Add raw hid support for ChibiOS
This is completely untested
* Enable midi compilation on ChibiOS
* Move midi functionality out of lufa.c
* Don't register sysex callback when not needed
* ChibiOS compilation fixes
* Update ChibiOS submodule
* Fix the Midi USB descriptor
It didn't work properly when both Midi and Virtual serial port was enabled.
* Add MIDI support for ChibiOS
* Fix USB descriptor strings on ChibiOS
* Use serial usb driver for raw hid
* Generalize the ChibiOS stream like drivers
This makes the initialization much more simple and eliminates a lot of
the code duplication.
* Convert console output to chibios stream driver
* Fixes for ChibiOS update
* Update the ChibiOS contrib submodule
To include the usb data toggle synchronization fixes
* Fix duplicate reset enumeration on ChibiOS
* Add missing include
* Add number of endpoints check for ChibiOS
* Enable serial USB driver on all keyboards
* Add missing includes when API is enabled withot midi
* Add another missing inlcude
* Cleanup Mechmini keymap. Once the custom RGB function is defined, there is no need to manually handle RGB code.
* Change default to KEYMAP_MIT, not KEYMAP_OFFSET
* Add custom RGB code for JJ40
* Reset Mechmini advertised power draw to 500. Will have to test actual maximum power draw later.
* RGB working on JJ40.
* Fix: saturation increase/decrease flipped
* Add new directory for my custom keymap with RGB keycodes
* Swap LAlt and LGUI
* Update JJ40 max power draw with measured value
* Update: fun40 rules.mk to enable underglow; earlier failed Travis CI
* Fix: init RGB LEDs on boot. Also added HHKB-like keymap for XD60.
* Super rudimentary backlight test, init RGB LEDs on boot
* Backlighting works - stays on for now
* Toggling working
* Now can override backlight.c functions. Problem was functions in backlight.c weren't called before due to a lack of matrix_scan_quantum() in matrix.c
* Timers not working
* Delete global.h
* Cleanup
* Compiles
* Good sign: LEDs stop working again
* Handle timer1 overflow
* Progress: fix: forgot to init
* Backlighting fully working now except breathing.
* Revert keymap to original keycodes
* Update XD60 keymap README
* Update JJ40 keymap with backlight toggles
* Breathing working just fine.
* Update references
* Add backlight_set() call
* Cleanup code to disable backlight
* Fix: does not compile
* Fix: missing call to rgblight_task.
* Testing with BACKLIGHT_BREATHING
* Cleanup
* Cleanup comments
* More commenting cleanup.
* Do not enable BACKLIGHT_BREATHING by default
* Get audio working on clueboard/60
* add keys for music mode
* Change doubles to floats
* add keys for all the songs
* revert to the default startup sound
* Remove music mode until we can figure out why it crashes
* add breathing to bananasplit
* backlight breathing overhaul
* fix the backlight_tick thing.
* fix for vision_division backlight
* fix a few keymaps and probably break breathing for some weirdly set-up boards.
* remove BL_x keycodes because they made unreasonable assumptions
* some fixes for BL keycodes
* integer cie lightness scaling
* use cie lightness for non-breathing backlight and make breathing able to reach true max brightness
* Added functions to read HSV values
I have added three functions to rgb_light.c to be able to read the hue, saturation and value from other places.
They are rgblight_get_hue(), rgblight_get_sat(), adn rgblight_get_val().
* Create keymap.c
* Add COSPAD support to QMK
I have ported the COSPAD numpad to qmk.
* Update readme.md
* Update cospad.c
* new planck keymap, new feature - hybrid shift/enter action key (great for small keyboards!)
* corrected documentation to specify rules.mk file instead of Makefile
* pull fuse settings for bootloader jump
* fix 32a chips
* make automatic bootloader selection optional
* quantify bootloaders
* fixs #164, speeds up dfu reset
* fix for chips w/o usb
* missing an n
* fix bootloader sizes, use words for addresses
* fix bmini, pearl, and [[ issue, make things quiet
* ignore avr errors on arm for now
* update settings for the light
* document bootloader stuff
* add bootloader title
* Fix pointer device options
when the feature was added, the appropriate option definition wasn't created. This needs to be added to function properly.
* Update common_features.mk
* missing underscore in init function declaration
This commit adds a new keycode `RGB_SMOD` which is the same as `RGB_MOD` (cycle through all modes),
but when it is used in combination with shift it will reverse the direction.
* Address #1689 by using a formula to define the breathing curve and exposing defines to control the shape of the curve.
* Tweak the behavior of breathing for clueboard
* redo make args to use colons, better folder structuring system [skip ci]
* don't put spaces after statements - hard lessons in makefile development
* fix-up some other rules.mk
* give travis a chance
* reset KEYMAPS variable
* start converting keyboards to new system
* try making all with travis
* redo make args to use colons, better folder structuring system [skip ci]
* don't put spaces after statements - hard lessons in makefile development
* fix-up some other rules.mk
* give travis a chance
* reset KEYMAPS variable
* start converting keyboards to new system
* try making all with travis
* start to update readmes and keyboards
* look in keyboard directories for board.mk
* update visualizer rules
* fix up some other keyboards/keymaps
* fix arm board ld includes
* fix board rules
* fix up remaining keyboards
* reset layout variable
* reset keyboard_layouts
* fix remainging keymaps/boards
* update readmes, docs
* add note to makefile error
* update readmes
* remove planck keymap warnings
* update references and docs
* test out tarvis build stages
* don't use stages for now
* don't use stages for now
* initial clueboard_60 support
* LED lighting support
* fix the clueboard->clueboard_66 rename
* Add layout support to clueboard_60
* Fix the 60_iso layout so it's actually iso
* add a default keymap for AEK layout
* fix clueboard_17
* Fixup the ISO layouts
* Fix the `wait_ms()/wait_us()` definitions for chibios
* Fix up the wait_ms/wait_us hack. Reduce stack size.
* Add a missing #include "wait.h"
* commit files that should have already been comitted
* add new RGB keycodes and clean up lets split keymap
* extraneous cases
* More cleanup and added macro
* one more macro
* cleaned up my planck keymap and added macros
* Transitioned planck keymap to new formatting / audio modes based on new default
* Remove extraneous newline in song list, add keycodes missed in previous commit
* error in graphical representation of keycodes
* Remove all Makefiles from the keyboards directory.
* update keymaps added in the last 8 days
* Ignore keyboard/keymap makefiles
* update hand_wire to reflect our new Makefile-less reality
* Update the make guide to reflect the new reality
* move planck keymap options to rules.mk
* update planck keymaps 4real
* trigger travis
* add back build_keyboard.mk
* restore changes to build_keyboard
* Allow the knight animation to be restricted to a portion of the LED strip
* Add keys for jumping directly to particular animation modes
* Remove orphaned break statements
* Tweak the `RGB_MODE` buttons so they cycle through the same mode.
* small indentation fix
* include variables and .h files as pp directives
* start layout compilation
* split ergodoxes up
* don't compile all layouts for everything
* might seg fault
* reset layouts variable
* actually reset layouts
* include rules.mk instead
* remove includes from rules.mk
* update variable setting
* load visualizer from path
* adds some more examples
* adds more layouts
* more boards added
* more boards added
* adds documentation for layouts
* use lowercase names for LAYOUT_
* add layout.json files for each layout
* add community folder, default keymaps for layouts
* touch-up default layouts
* touch-up layouts, some keyboard rules.mk
* update documentation for layouts
* fix up serial/i2c switches
This adds the `ACTION_TAP_DANCE_DUAL_ROLE` helper, which makes it easy to have
keys that act as a key on the first tap, and as a layer toggle on the second.
Fixes#1532, reported by @Ptomerty.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
This protocol breaks out "duplicate" keys into their own entry in the packet so that more complicated logic can be done on the software side, including support for additional languages and alternative theories.
Requires virtser; Allows QMK to speak the TX BOlt protocol used by stenography machines and software (such as Plover). The upside is that Plover can be configured to listen only to TX Bolt allow the keyboard to switch layers without need to enable/disable the Plover software, or to have a second non-Steno keyboard work concurrently.
Instead of having all sendstring keycode mappings in the main quantum.c
file, give each one its own file in keymap_extras that can be #included
in a user's keymap. If one is included, it will define the appropriate
lookup tables and overwrite the weak definitions in quantum.c.
(Including more than one sendstring definition will fail at compile
time.)
Update @rai-suta's test keymap to match, as well as the documentation.
Refactor new-ish JIS_KEYCODE send_string implementation with existing
send_string
Reshuffle JIS in line with other alternative keycodes for sendstring,
and make them all accessible via compile-time options
Add a separate function to allow sending a string with a delay.
*NOTE:* it might still be desirable to set the software layout to sv_SE in your
OS.
Swedish (sv_SE) Qwerty layout for ErgoDox, based on the Default configuration
I have tried making this as close of a match I could between the [default
ErgoDox EZ configuration](https://ergodox-ez.com/pages/our-firmware) and a
standard Swedish Qwerty layout.
Notable differences from default:
=================================
* There are three special character buttons (acute accent, circumflex/tilde and
apostrophe/asterisk) that don't have any buttons to map to naturally. I've put
these at other places:
* Acute accent (´) can be found in the lower left corner, conveniently
placed to reach for making an é.
* Apostrophe (') was put in the lower left corner, close to acute accent.
* Circumflex (^) and asterisk (*) was placed in the lower right corner.
* Tilde (~) and diaeresis (¨) I couldn't find a good place for, so I left
those out. I could only get the buttons to produce a single one of the
characters. How can I get it to work properly?
* The Alt button on right thumb was exchanged for AltGr (RAlt).
* I changed the backslash in the numpad (layer 1) for a minus. Thought it was
more sensible.
* I didn't find a good place for the "<>|" button, so that one was left out.
That is a problem that really needs to be resolved. Pipe can be found on layer
one, however.
* allow mod swapping for mod tap
* quick include
* fix the mod swapping
* make changes consistent with action code
* fix bug
* re-enable no gui, etc
* fix binary comps
* solid logic
If a macro play key is inadvertently recorded in a dynamic macro
a loop is created and the macro will not terminate when played.
This should be prevented.
More specifically, we save them and then place the `macro_end` pointer
before them so they are essentially ignored and the other macro may
freely overwrite them.
Right after the user initiates the macro recording, they usually need
to release some keys used to access the DYN_REC_START layers. It makes
sense to ignore them.
Note: The keys used to access the DYN_REC_STOP key are *not* ignored.
Dynamic macro functionality is modified to check for `DYN_REC_STOP`, so
that macro recording can be stopped with a designated key combination
(e.g. `qs` or anything) instead of mandating the use of a `_DYN` layer.
`_DYN` layer stopping can still be done by passing `DYN_REC_STOP` within
`process_record_user()`:
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
uint16_t macro_kc = (keycode == MO(_DYN) ? DYN_REC_STOP : keycode);
if (!process_record_dynamic_macro(macro_kc, record)) {
return false;
}
return true;
}
No animation, display led statuses and layer name on the same screen
Don't display layer bitmap
Fully saturated colors for caps, less saturated ones normally
* Clarify the license for files we have signoff on
* Update against the currently signed off files
* Remove unused and not clearly licensed headers
* Replace an #endif I accidentally removed while resolving merge conflicts
Refactored Bluetooth support to make adding new Bluetooth modules
easier in the future.
* Remove `OUT_BLE` key from QMK's keymap. `OUT_BT` is all we need now
as there's no difference anymore.
* Made BLUETOOTH_ENABLE build option legacy as not to break existing
keymaps (Falls back to existing EZ Key support if on)
* Removed `ADAFRUIT_BLE_ENABLE` build option
* Created new build option `BLUETOOTH` with module option (Currently
`AdafruitEZKey` & `AdafruitBLE`)
* Moved all LUFA bluetooth key/mouse events under `BLUETOOTH_ENABLE`
ifdef with selected modules output.
Update existing keymaps to enable MIDI_BASIC functionality. Also added
an option MIDI_ENABLE_STRICT to be strict about keycode use (which also
reduces memory footprint at runtime)
tone array:
text data bss dec hex filename
0 25698 0 25698 6462 satan_newsboytko.hex
0x6480 bytes written into 0x7000 bytes memory (89.73%).
note on array:
text data bss dec hex filename
0 25802 0 25802 64ca satan_newsboytko.hex
0x6500 bytes written into 0x7000 bytes memory (90.18%).
The previous two options were COL2ROW, ROW2COL; this adds CUSTOM_MATRIX
to disable the built-in matrix scanning code.
Most notably, this obviates the need to set MATRIX_ROW_PINS or
MATRIX_COL_PINS.
since the keycode for a tap dance process gets process only after the
TAPPING_TERM timeout, you really only have ONESHOT_TIMEOUT -
TAPPING_TERM time to tap or double tap on the key. This fix save the
oneshot_mods into the action.state structure and applies the mods with
the keycode when it's registered. It also unregisters the mod when the
the tap dance process gets reset.
Scenario:
Locking the KC_LSHIFT, and then using a tap dance key that registers a
S(KC_9) will unregister the KC_LSHIFT.
The tap dance or any keycode that is registered should not have the
side effect of cancelling a locked moditifier. We should be using a
similar logic as the TMK codes in tmk_core/comman/action.c:158.
A macro key can now be easily set to act as a modifier on hold, and
press a shifted key when tapped. Or to switch layers when held, and
again press a shifted key when tapped.
Various other helper defines have been created which send macros when
the key is pressed, released and tapped, cleaning up the
action_get_macro function inside keymap definitions.
The layer switching macros require a GCC extension - 'compound
statements enclosed within parentheses'. The use of this extension is
already present within the macro subsystem of this project, so its use
in this commit should not cause any additional issues.
MACRO_NONE had to be cast to a (macro_t*) to suppress compiler
warnings within some tapping macros.
In register_code16 and unregister_code16 we call register_code and
unregister_code twice, once for the mods and once for the keycode.
The (un)register_code have many check to see that keycode we have sent
however because we know that we are sending it a mods key, why not
just skip all of it and call (un)register_mods instead. This will skip
alot of checks and should speedup the loop a little.
Since we can't read the real_mods and oneshot_mods static variable
directly within the update_user_visualizer_state
function (Threading and serial link). We are know storing the mods
states in the visualizer_keyboard_status_t structure. We can now
display the status of the modifier keys on the LCD display.
Fix memory leaks by using stack instead of malloc
Reduce memory usage by having less temporary bufffers
Remove warnings by adding includes
Decrease code size by 608 bytes (mostly due to not linking malloc)
More robust handling of buffer overflows
Unlike the arduino functions, these don't take abstract pin numbers,
they take pin labels like `B0`. Also, rather than taking very
generic parameter names, these take slightly more descriptive
enum values.
These improve the clarity of code that would otherwise be inscrutable
bit manipulation in tersely named port register names.
Define a default TAPPING_TERM in quantum.c, for keyboards that do not
have it set. Fixes the CI failure.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
When one holds a Space Cadet shift, to have it act as a shift, so that
mouse behaviour changes, when released without any other key pressed, it
still registers a paren. To remedy this, add a hold timeout: if the key
is held longer than TAPPING_TERM, it will not register the parens.
Fixes#884, with the side-effect of not being able to have parens
trigger the OS-side repeat anymore.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
There was an odd case, which confused the hell out of tap-dance: suppose
you had a number of tap-dance keys, on a layer, and as part of the
tap-dance, you turned that layer off - or had it on one-shot to begin
with. In this case, the keydown event would trigger the tap-dance key,
but the keyup would not. This had two funky consequences:
- tap-dance did not correctly register that the dance has ended.
- pressing any other tap-dance key would interrupt the previous
tap-dance, and potentially input unwanted characters.
To fix this, we simply do not start a tap-dance sequence on keyup, only
when it is pressed. This way the previous sequence has enough time to
time-out and finish properly, and we don't get confused.
This fixesalgernon/ergodox-layout#107.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
There may be cases where one would like to know the current Unicode
input mode, without having to keep track of it themselves. Add a
function that does just this.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
In order to not declare the same variable in multiple objects (which
happens when building UCIS-enabled keymap for both the ErgoDox EZ and
the ErgoDox Infinity), move the declaration to the .c file, and keep
only an extern reference in the header.
Many thanks to @fredizzimo for spotting the error in Travis, and
suggesting the fix.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
These functions register not only the 8bit keycode, but the modifiers
too. It doesn't handle the full range of the upper 8bits, just the mods,
but that's a good start.
Changed the tap-dance pair functions to use these, so one can do:
`ACTION_TAP_DANCE_DOUBLE (KC_COLN, KC_SCLN)`
...and that will do the right thing.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
This reworks how the tap-dance feature works: instead of one global
state, we have a state for each tap-dance key, so we can cancel them
when another tap-dance key is in flight. This fixes#527.
Since we have a state for each key, we can avoid situation where a keyup
would mess with our global state. This fixes#563.
And while here, we also make sure to fire events only once, and this
fixes#574.
There is one breaking change, though: tap-dance debugging support was
removed, because dumping the whole state would increase the firmware
size too much. Any keymap that made use of this, will have to be
updated (but there's no such keymap in the repo).
Also, there's a nice trick used in this rework: we need to iterate
through tap_dance_actions in a few places, to check for timeouts, and so
on. For this, we'd need to know the size of the array. We can't discover
that at compile-time, because tap-dance gets compiled separately. We'd
like to avoid having to terminate the list with a sentinel value,
because that would require updates to all keymaps that use the feature.
So, we keep track of the highest tap-dance code seen so far, and iterate
until that index.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Include `action_tapping.h`, so the keymap does not have to define a
`TAPPING_TERM` for us, and we can use the default.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
When entering unicode codes, use some delay, so the OS has time to
process the information. This is not needed on all systems, but some
seem to require it.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
It turns out that register_hex32 did not work reliably, and some systems
only allow 7 chars after the unicode magic sequence, while others allow
8. To remedy the situation, store the codes as strings, and type those
in instead of doing bit shifting magic.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Extract out the part of `qk_ucis_start` that inputs the placeholder
symbol, and make it weak, so it can be overridden.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
If the symbol name being entered is longer than the max, stop recording
it, and stop processing keycodes apart from the ones that can delete,
finish or cancel the sequence.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
The purpose of this change is to allow keymaps to specify a dictionary
of unicode symbol name to code mappings, and let the person at the
keyboard enter unicode symbols by name.
This is done by having a way to trigger unicode symbol input mode, when
all keys are cached until Esc, Enter or Space are pressed. Once that
happens, we try to look up the symbol from our lookup table. If found,
we erase back, and type the unicode magic in to get that symbol. If not
found, we still erase back, start unicode input mode, and replay what
the user typed in.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
This moves the unicode input start / end sequences into their own
functions, so keymaps and other functionality can build on it too.
At the same time, it changes how the Linux variant works, to match
reality: CTRL+SHIFT must be unregistered too, and we close the thing
with a Space instead.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
In the header, this was defined as `set_unicode_input_mode`, but the
implementation had `set_unicode_mode` for a name. Changed the
implementation to match the header.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Removes a number of duplicated code, by passing actions around instead
of keycodes, so the various dance action functions do not have to look
up the action, but the caller does that for them.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Refactored the code a little, so all callbacks now receive a `user_data`
pointer, which can be anything. As an example, the key pairs from
`ACTION_TAP_DANCE_DOUBLE` now use this, and custom, built-in functions.
This makes it easier to extend the tap dance functionality, and also
simplifies the code a little.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
With this change, tap dance will now store the pressed state of the
tap-dance key, and allow one to make an action sooner, while the key is
still held, and only unregister when the key is released.
The registration must happen in the `on_dance_finished` callback, while
unregistering goes to `on_reset`. The surrounding code makes sure not to
call either multiple times.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>