summaryrefslogtreecommitdiff
path: root/tmk_core/protocol
AgeCommit message (Collapse)Author
2021-06-06[Core] ChibiOS fix O3 and LTO breakage of extra keys and joystick (#12819)Stefan Kerkmann
2021-06-07core: bump USB spec version in device descriptor to 2.0 (#13078)Michael Stapelberg
Co-authored-by: Ryan <fauxpark@gmail.com>
2021-05-18Fixup housekeeping from being invoked twice per loop. (#12933)Nick Brassel
2021-04-25eeprom driver: Refactor where eeprom driver initialisation (and EEPROM ↵Purdea Andrei
emulation initialisation) occurs to make it non-target-specific. (#12671)
2021-04-25Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-04-25Format code according to conventions (#12681)github-actions[bot]
Co-authored-by: QMK Bot <hello@qmk.fm>
2021-04-25Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-04-25Fix how USB queue overflow is handled in chibios. (#12576)Purdea Andrei
* Fix how USB queue overflow is handled in chibios. This commit reverts PR 12472 (commit c823fe2d3f23ed090e36ce39beed4c448298bd2f), and it implements the original intent of the commit in a better way. The original intent of the above mentioned commit was to not deadlock the keyboard when console is enabled, and hid_listen is not started. The above mentioned commit had a few drawbacks: 1) When a lot of data was printed to the console, the queue would get full, and drop data, even if hid_listen was running. (For example having matrix debug enabled just didn't work right at all) 2) I believe the function in which this was implemented is used by all other USB endpoints, so with the above change, overflow, and data loss could happen in other important functions of QMK as well. This commit implements deadlock prevention in a slightly similar way to how it's done on AVR. There is an additional static local variable, that memorizes whether the console has timeouted before. If we are in the timeouted=false state, then we send the character normally with a 5ms timeout. If it does time out, then hid_listen is likely not running, and future characters should not be sent with a timeout, but those characters should still be sent if there is space in the queue. The difference between the AVR implementation and this one is that the AVR implementation checks the queue state directly, but this implementation instead attempts to write the character with a zero timeout. If it fails, then we remain in the timeouted=true state, if it succeeds, then hid_listen started removing data from the queue, so we can go out of the timeouted=true state. * Added comment explaining the timeouted logic to console flow control. * Console flow control: refactor chibios flowcontrol code to make it more readable, and rename the timeouted variable to timed_out on both chibios and lufa. Changed comments to says timed_out is an approximation of listener_disconnected, to make it clear that it's not the same thing * fix typo
2021-04-19Apply the "NO_LIMITED_CONTROLLER_CONNECT" fix to atmega16u2 (#12482)Purdea Andrei
Co-authored-by: Ryan <fauxpark@gmail.com>
2021-04-10Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-04-10Format code according to conventions (#12540)github-actions[bot]
Co-authored-by: QMK Bot <hello@qmk.fm>
2021-04-10Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-04-10ChibiOS USB driver: prevent deadlock with CONSOLE_ENABLE = yes (#12472)Michael Stapelberg
Before this commit, attaching an ARM-based (i.e. ChibiOS-based) keyboard that uses CONSOLE_ENABLE = yes and produces debug messages would deadlock the keyboard unless one was running hid_listen. With this commit, dead-locking writes to the queue are detected and prevented. fixes #5631
2021-03-25Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-03-25Move `API_SYSEX_MAX_SIZE` out of `config_common.h` (#12302)Ryan
2021-03-18Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-03-18[CI] Format code according to conventions (#12277)github-actions[bot]
Co-authored-by: QMK Bot <hello@qmk.fm>
2021-03-18Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-03-18XT converter cleanup (#12264)Ryan
2021-02-28Refactor of USB code within split_common (#11890)Joel Challis
* Initial refactor of usb code within split_common * Add headers * Correct disable condition * Format * Align func name
2021-02-27Format code according to conventions (#12046)github-actions[bot]
Co-authored-by: QMK Bot <hello@qmk.fm>
2021-02-28Fix build for attiny85-based boards. (#12044)Nick Brassel
2021-02-26Format code according to conventions (#12024)github-actions[bot]
Co-authored-by: QMK Bot <hello@qmk.fm>
2021-02-26[BUG] Massdrop develop rgb fix (#12022)Nick Brassel
* Allow for disabling RGB_MATRIX on Massdrop boards. * Fixup init sequence. * Make some functions static as they've got very generic names.
2021-02-25Merge remote-tracking branch 'upstream/master' into developfauxpark
2021-02-25V-USB suspend refactor (#11891)Ryan
2021-02-20Output selection: Remove "USB and BT" option (#11940)Ryan
2021-02-15Format code according to conventions (#11905)github-actions[bot]
Co-authored-by: QMK Bot <hello@qmk.fm>
2021-02-14Refactor platform logic within print.h (#11863)Joel Challis
* Remove GCC check from debug * Remove platform logic from common.mk * Refactor platform logic within print.h * restore debug.c format * headers * Rename function pointer type * review comments * Update tmk_core/common/printf.c Co-authored-by: Nick Brassel <nick@tzarc.org> * Format Co-authored-by: Nick Brassel <nick@tzarc.org>
2021-02-07Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-02-07Migrate some tmk_core files to quantum (#11791)Joel Challis
* Migrate some tmk_core files to quantum * Fix build errors
2021-02-06Remove legacy print backward compatiblitly (#11805)Joel Challis
* Remove legacy print backward compatiblitly * Remove legacy print backward compatiblitly - core * revert comment changes
2021-02-06Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-02-06Manual formatting fix for serial_uart.c (#11806)Ryan
2021-02-05Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-02-06Serial refactor (#11521)Ryan
2021-02-02Address wake from sleep instability (#11450)Joshua Diamond
* resolve race condition between suspend and wake in LUFA * avoid multiple calls to suspend_power_down() / suspend_wakeup_init() * Remove duplicate suspend_power_down_kb() call * pause on wakeup to wait for USB state to settle * need the repeated suspend_power_down() (that's where the sleep is) * more efficient implementation * fine tune the pause after sending wakeup * speculative chibios version of pause-after-wake * make wakeup delay configurable, and adjust value * better location for wakeup delay
2021-02-01Decouple USB events from the USB interrupt handler. (#10437)Nick Brassel
2021-01-28Add support for 8 buttons to mouse report (#10807)Drashna Jaelre
* Add support for 8 buttons to mouse report This includes support for 8 buttons in mousekeys. However, this does move the keys around due to the fact that the last mousekey keycode is already 0xFF, so any past that would not work with register_code and the like, breaking them for tap hold keys, encoders, and other features. * Update mouse key docs * Add changes based on feedback * Fix VUSB report size comment Because drashna red gud * Fix typo in action.c * Fix IS_MOUSE_BUTTON check * Change start range for mousekeys so that the end is 0xFF properly * condense mousekeys check
2021-01-24Remove duplicated housekeeping in arm_atsam (#11672)Gentoli
2021-01-15Merge remote-tracking branch 'upstream/master' into developfauxpark
2021-01-15Adafruit BLE cleanups (#11556)Ryan
2021-01-15arm_atsam: temporarily lower raw HID endpoint/report size (#11554)Ryan
2021-01-11Merge remote-tracking branch 'origin/master' into developQMK Bot
2021-01-11Add support for shared EP on V-USB boards (#11103)Ryan
2021-01-01Merge remote-tracking branch 'upstream/master' into developfauxpark
2021-01-01Manually run formatting CI process (#11375)Joel Challis
2020-12-29Update ADB impelemtation in TMK Core (#11168)siggie0815
* Update ADB impelmentation in tmk_core to recent version. Pcked from tmk_keyboard repository revision: 48d696443857512d45f9a7329e0dd0a76345860f * Restore convenient ADB functions used in QMK port. * Do cformat.
2020-12-27Merge remote-tracking branch 'origin/master' into developQMK Bot
2020-12-28Ensure single newline at EOF for core files (#11310)Ryan