Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decouple matrix scan from task loop #15722

Closed
wants to merge 2 commits into from

Conversation

zvecr
Copy link
Member

@zvecr zvecr commented Jan 3, 2022

Description

If I optimise matrix scanning,
  then RGB animations will be smoother
  then Split keyboard transaction iops increase

Why scan the keyboard matrix for interaction 10k times a second when USB would bottleneck at 1k? In theory, ignoring the case for "internal" keycodes, rate limiting certain actions could provide runtime for other components.

Existing issues:

  • custom matrix requires calling back into quantum
    • potential for inconsistencies and broken functionality
  • tight coupling between matrix scan and various quantum tasks
  • main code pathway unnecessarily nested

Various longer term end goals this feeds into:

  • allow rate limiting of various functionality
    • potential for hardware timer to drive components such as matrix scan at a fixed rate

TODO:

Types of Changes

  • Core
  • Bugfix
  • New feature
  • Enhancement/optimization
  • Keyboard (addition or update)
  • Keymap/layout/userspace (addition or update)
  • Documentation

Checklist

  • My code follows the code style of this project: C, Python
  • I have read the PR Checklist document and have made the appropriate changes.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • I have tested the changes and verified that they work and don't break anything (as well as I can manage).

@zvecr zvecr force-pushed the feature/decouple_matrix_scan branch from 0398333 to b7789b4 Compare January 3, 2022 19:17
@zvecr zvecr mentioned this pull request Jan 5, 2022
14 tasks
@zvecr zvecr force-pushed the feature/decouple_matrix_scan branch 2 times, most recently from 31e73d7 to 196f9e4 Compare January 13, 2022 20:22
@zvecr zvecr mentioned this pull request Jan 15, 2022
14 tasks
@zvecr zvecr force-pushed the feature/decouple_matrix_scan branch from 196f9e4 to b34a232 Compare January 20, 2022 17:44
@zvecr zvecr mentioned this pull request Jan 20, 2022
14 tasks
@zvecr zvecr force-pushed the feature/decouple_matrix_scan branch from c233789 to 3e2e63e Compare January 23, 2022 02:46
@zvecr zvecr force-pushed the feature/decouple_matrix_scan branch from 3e2e63e to 04c4601 Compare January 23, 2022 02:58
@stale
Copy link

stale bot commented Apr 16, 2022

Thank you for your contribution!
This pull request has been automatically marked as stale because it has not had activity in the last 45 days. It will be closed in 30 days if no further activity occurs. Please feel free to give a status update now, or re-open when it's ready.
For maintainers: Please label with awaiting review, breaking_change, in progress, or on hold to prevent the issue from being re-flagged.

@stale stale bot removed the awaiting changes label Apr 16, 2022
@drashna drashna requested a review from a team April 19, 2022 01:01
@zvecr
Copy link
Member Author

zvecr commented Feb 11, 2023

Closing as most content is now implemented, and rate limiting will be completed separately.

@zvecr zvecr closed this Feb 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants