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

rgblight 255 hue #5547

Merged
merged 1 commit into from
May 1, 2019
Merged

rgblight 255 hue #5547

merged 1 commit into from
May 1, 2019

Conversation

XScorpion2
Copy link
Contributor

@XScorpion2 XScorpion2 commented Apr 4, 2019

Converted rgblight to use 255 hue identical to rgb matrix
Converted some rgblight code to use math8

Description

Types of Changes

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

Issues Fixed or Closed by This PR

Checklist

  • My code follows the code style of this project.
  • 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).

quantum/rgblight.c Outdated Show resolved Hide resolved
lib/lib8tion/lib8tion.h Outdated Show resolved Hide resolved
@drashna
Copy link
Member

drashna commented Apr 4, 2019

I hate to ask, but could you include the changes to this file:
https://github.com/qmk/qmk_firmware/blob/master/quantum/rgblight_list.h

Also, it may make thing more complicated, but it may be a good idea to incorporate this: #5300

@XScorpion2
Copy link
Contributor Author

XScorpion2 commented Apr 4, 2019

I also need to take another stab at improving the gradient code as the way it is calculating the hue for each key has some serious rounding errors which are a bit worse under 255 hue vs 360 hue. And since hue is now 255 standard across both. It would make sense to rip out the hue to rgb functions into a common code file.

@drashna
Copy link
Member

drashna commented Apr 4, 2019

Well, improving the animations is something that has been discussed for a long time, and that nobody has wanted to do. So, awesome!

However, just a heads up, there are some a bunch of compilation errors here.

@XScorpion2
Copy link
Contributor Author

I probably won't get to it tonight before my flight, will pick this back up after vacation. Mind flagging as in progress?

@drashna
Copy link
Member

drashna commented Apr 4, 2019

I figured as much. I just wanted to make sure it was mentioned.

And enjoy!

@drashna
Copy link
Member

drashna commented Apr 5, 2019

@XScorpion2
Copy link
Contributor Author

@drashna I don't have permission to see that card.

@drashna
Copy link
Member

drashna commented Apr 5, 2019

Sorry, doing organizational stuff for Ergodox EZ/ZSA, and didn't realize that it posted comments by default.

/me waves hand
Nothing to see here.

@XScorpion2 XScorpion2 force-pushed the bugfix/rgblight_hue branch from 6ac3459 to 8b1f2bc Compare April 14, 2019 17:25
@XScorpion2
Copy link
Contributor Author

XScorpion2 commented Apr 14, 2019

Merged in #5300 and updated with 255 based hue values.
Fixed compile errors.
Fixed bad rounding errors in gradient effect.
Switched rgblight to reuse common rgb to hsv code.
PR should be no longer considered in progress.

@XScorpion2
Copy link
Contributor Author

@drashna I approve of your approval!

@drashna
Copy link
Member

drashna commented Apr 16, 2019

One thing though. Could a check for the mode be added to the rgblight_check_config function be added?
This way, if the structure change causes issues with the mode, it should be fixed.

@XScorpion2
Copy link
Contributor Author

@drashna I already put the mode check back into check config after @Lenbok pointed out the error

@drashna
Copy link
Member

drashna commented Apr 16, 2019

Ah, yeah, you're right.

But I ee that the HSV check was removed. Was this validated elsewhere, now?

@XScorpion2 XScorpion2 force-pushed the bugfix/rgblight_hue branch from f69295c to bfbc1a0 Compare April 29, 2019 21:44
@XScorpion2
Copy link
Contributor Author

Rebased on latest master, any update on merging this?

@drashna
Copy link
Member

drashna commented Apr 29, 2019

Just looking for some good approvals on the PR, to be honest

Copy link
Member

@noroadsleft noroadsleft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested on my Boardwalk; everything seems good.

Copy link
Contributor

@mechmerlin mechmerlin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mechmerlin mechmerlin merged commit 22ba36a into qmk:master May 1, 2019
drashna pushed a commit to zsa/qmk_firmware that referenced this pull request May 1, 2019
@XScorpion2 XScorpion2 deleted the bugfix/rgblight_hue branch May 2, 2019 01:29
foosinn pushed a commit to foosinn/qmk_firmware that referenced this pull request May 6, 2019
twschum added a commit to twschum/qmk_firmware that referenced this pull request Jun 11, 2019
Timbus pushed a commit to Timbus/qmk_firmware that referenced this pull request Jun 23, 2019
drashna pushed a commit that referenced this pull request Nov 21, 2019
* Adds layout for DZ60rev2 plate B, options 4 and 10

* Use KC_TRANS for layer keys

* Format layer0 with visual key size layout

* Add RGB controls; add start description; add KC_LOCK

* Update comments on rules.mk for DZ60

* Gets keymap compiling

* Fix wiring for shift on row 3

* Hold a with other key to send Ctrl-A before other key

* Adds compile-time defined mac-compatability media keycodes

* Adds logic in place for capturing taps (w/ timeout)

* Add send_keys(...) which can send up to 64 nested keycodes

* Implement send_keys callable with n repeats

* Tweaks some of the keymap

* Add reset keycode; add disable to custom shortcuts

* Adds a special "off" layer where bonus mod goes to layer 0, every other key KC_NO

* Adjust timeout; mousekey settings

* Changes layout of Home,End,PgUp/Dn on the dedicated arrow keys L1/L2

* PoC on rgb lighted layer indication

* Refactors color table defines

* Adds logic for controlling layer lights

* Only change state on one side of the event lol

* Switch back to Tapping Toggle for layer 4

* Add custom config file for keyboard; TT and mousekey settings

* Code cleanup; starting to refactor special ctrl tapping keys functions

* Move defines and �reak out functions

* Remove debugging light

* Adjust keymaps; add enter

* Adds a couple custom macros

* Add simplified version of keymap to help debug issues

* Adds basi numpad configuration for levinson keyboard half

* Use ANSI ctrl key as layer 1 for better one hand (`)

* Adapt to new 8bit hue from #5547; layer enum use everywhere

* Move custom code out to users/ space

* Flip col pins, move key assignments to "left hand"

* Update readme

* Implement placeholder macros

* Notes

* Reduce tapping time for SFT_T(/)

* Adds vim features; refactors things

* Adds fork of the vim features written by xton

* Use correct backspace keycode

* Add VIM_ESC

* Add "OFF" to the RGB/HSV definitions

* Clean up rules, use new "OFF" definition

* Add windows KC_CALCULATOR key to numpad

* Reformat layers with better guide; change layer names

* Add sleep key

* Change timeout delay

* Add a "code paste" which surrounds a ^V with ```

* Try removing shift tap on rshift /

* Update macros

* Update the "code paste" macro

* Update keymap with reset, calc, equals

* Update keyboards/dz60/keymaps/twschum_b_4_10_simple/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update keyboards/dz60/keymaps/twschum_b_4_10/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Revert quantum/rgblight_list.h

* Better name for split space layout; rename KEYMAP->LAYOUT

* Rename KEYMAP->LAYOUT

* Use simpler :flash command

* Clean up layout files

* Use qmk's MOD_MASK_CTRL

* Sync lufa submodule

* Cleanup from noroadsleft's PR comments

* Modernize vim layer code
ripxorip pushed a commit to ripxorip/qmk_firmware that referenced this pull request Dec 3, 2019
* Adds layout for DZ60rev2 plate B, options 4 and 10

* Use KC_TRANS for layer keys

* Format layer0 with visual key size layout

* Add RGB controls; add start description; add KC_LOCK

* Update comments on rules.mk for DZ60

* Gets keymap compiling

* Fix wiring for shift on row 3

* Hold a with other key to send Ctrl-A before other key

* Adds compile-time defined mac-compatability media keycodes

* Adds logic in place for capturing taps (w/ timeout)

* Add send_keys(...) which can send up to 64 nested keycodes

* Implement send_keys callable with n repeats

* Tweaks some of the keymap

* Add reset keycode; add disable to custom shortcuts

* Adds a special "off" layer where bonus mod goes to layer 0, every other key KC_NO

* Adjust timeout; mousekey settings

* Changes layout of Home,End,PgUp/Dn on the dedicated arrow keys L1/L2

* PoC on rgb lighted layer indication

* Refactors color table defines

* Adds logic for controlling layer lights

* Only change state on one side of the event lol

* Switch back to Tapping Toggle for layer 4

* Add custom config file for keyboard; TT and mousekey settings

* Code cleanup; starting to refactor special ctrl tapping keys functions

* Move defines and �reak out functions

* Remove debugging light

* Adjust keymaps; add enter

* Adds a couple custom macros

* Add simplified version of keymap to help debug issues

* Adds basi numpad configuration for levinson keyboard half

* Use ANSI ctrl key as layer 1 for better one hand (`)

* Adapt to new 8bit hue from qmk#5547; layer enum use everywhere

* Move custom code out to users/ space

* Flip col pins, move key assignments to "left hand"

* Update readme

* Implement placeholder macros

* Notes

* Reduce tapping time for SFT_T(/)

* Adds vim features; refactors things

* Adds fork of the vim features written by xton

* Use correct backspace keycode

* Add VIM_ESC

* Add "OFF" to the RGB/HSV definitions

* Clean up rules, use new "OFF" definition

* Add windows KC_CALCULATOR key to numpad

* Reformat layers with better guide; change layer names

* Add sleep key

* Change timeout delay

* Add a "code paste" which surrounds a ^V with ```

* Try removing shift tap on rshift /

* Update macros

* Update the "code paste" macro

* Update keymap with reset, calc, equals

* Update keyboards/dz60/keymaps/twschum_b_4_10_simple/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update keyboards/dz60/keymaps/twschum_b_4_10/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Revert quantum/rgblight_list.h

* Better name for split space layout; rename KEYMAP->LAYOUT

* Rename KEYMAP->LAYOUT

* Use simpler :flash command

* Clean up layout files

* Use qmk's MOD_MASK_CTRL

* Sync lufa submodule

* Cleanup from noroadsleft's PR comments

* Modernize vim layer code
patrl pushed a commit to patrl/qmk_firmware that referenced this pull request Dec 29, 2019
* Adds layout for DZ60rev2 plate B, options 4 and 10

* Use KC_TRANS for layer keys

* Format layer0 with visual key size layout

* Add RGB controls; add start description; add KC_LOCK

* Update comments on rules.mk for DZ60

* Gets keymap compiling

* Fix wiring for shift on row 3

* Hold a with other key to send Ctrl-A before other key

* Adds compile-time defined mac-compatability media keycodes

* Adds logic in place for capturing taps (w/ timeout)

* Add send_keys(...) which can send up to 64 nested keycodes

* Implement send_keys callable with n repeats

* Tweaks some of the keymap

* Add reset keycode; add disable to custom shortcuts

* Adds a special "off" layer where bonus mod goes to layer 0, every other key KC_NO

* Adjust timeout; mousekey settings

* Changes layout of Home,End,PgUp/Dn on the dedicated arrow keys L1/L2

* PoC on rgb lighted layer indication

* Refactors color table defines

* Adds logic for controlling layer lights

* Only change state on one side of the event lol

* Switch back to Tapping Toggle for layer 4

* Add custom config file for keyboard; TT and mousekey settings

* Code cleanup; starting to refactor special ctrl tapping keys functions

* Move defines and �reak out functions

* Remove debugging light

* Adjust keymaps; add enter

* Adds a couple custom macros

* Add simplified version of keymap to help debug issues

* Adds basi numpad configuration for levinson keyboard half

* Use ANSI ctrl key as layer 1 for better one hand (`)

* Adapt to new 8bit hue from qmk#5547; layer enum use everywhere

* Move custom code out to users/ space

* Flip col pins, move key assignments to "left hand"

* Update readme

* Implement placeholder macros

* Notes

* Reduce tapping time for SFT_T(/)

* Adds vim features; refactors things

* Adds fork of the vim features written by xton

* Use correct backspace keycode

* Add VIM_ESC

* Add "OFF" to the RGB/HSV definitions

* Clean up rules, use new "OFF" definition

* Add windows KC_CALCULATOR key to numpad

* Reformat layers with better guide; change layer names

* Add sleep key

* Change timeout delay

* Add a "code paste" which surrounds a ^V with ```

* Try removing shift tap on rshift /

* Update macros

* Update the "code paste" macro

* Update keymap with reset, calc, equals

* Update keyboards/dz60/keymaps/twschum_b_4_10_simple/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update keyboards/dz60/keymaps/twschum_b_4_10/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Revert quantum/rgblight_list.h

* Better name for split space layout; rename KEYMAP->LAYOUT

* Rename KEYMAP->LAYOUT

* Use simpler :flash command

* Clean up layout files

* Use qmk's MOD_MASK_CTRL

* Sync lufa submodule

* Cleanup from noroadsleft's PR comments

* Modernize vim layer code
ridingqwerty pushed a commit to ridingqwerty/qmk_firmware that referenced this pull request Jan 10, 2020
HokieGeek pushed a commit to HokieGeek/qmk_firmware that referenced this pull request Feb 21, 2020
* Adds layout for DZ60rev2 plate B, options 4 and 10

* Use KC_TRANS for layer keys

* Format layer0 with visual key size layout

* Add RGB controls; add start description; add KC_LOCK

* Update comments on rules.mk for DZ60

* Gets keymap compiling

* Fix wiring for shift on row 3

* Hold a with other key to send Ctrl-A before other key

* Adds compile-time defined mac-compatability media keycodes

* Adds logic in place for capturing taps (w/ timeout)

* Add send_keys(...) which can send up to 64 nested keycodes

* Implement send_keys callable with n repeats

* Tweaks some of the keymap

* Add reset keycode; add disable to custom shortcuts

* Adds a special "off" layer where bonus mod goes to layer 0, every other key KC_NO

* Adjust timeout; mousekey settings

* Changes layout of Home,End,PgUp/Dn on the dedicated arrow keys L1/L2

* PoC on rgb lighted layer indication

* Refactors color table defines

* Adds logic for controlling layer lights

* Only change state on one side of the event lol

* Switch back to Tapping Toggle for layer 4

* Add custom config file for keyboard; TT and mousekey settings

* Code cleanup; starting to refactor special ctrl tapping keys functions

* Move defines and �reak out functions

* Remove debugging light

* Adjust keymaps; add enter

* Adds a couple custom macros

* Add simplified version of keymap to help debug issues

* Adds basi numpad configuration for levinson keyboard half

* Use ANSI ctrl key as layer 1 for better one hand (`)

* Adapt to new 8bit hue from qmk#5547; layer enum use everywhere

* Move custom code out to users/ space

* Flip col pins, move key assignments to "left hand"

* Update readme

* Implement placeholder macros

* Notes

* Reduce tapping time for SFT_T(/)

* Adds vim features; refactors things

* Adds fork of the vim features written by xton

* Use correct backspace keycode

* Add VIM_ESC

* Add "OFF" to the RGB/HSV definitions

* Clean up rules, use new "OFF" definition

* Add windows KC_CALCULATOR key to numpad

* Reformat layers with better guide; change layer names

* Add sleep key

* Change timeout delay

* Add a "code paste" which surrounds a ^V with ```

* Try removing shift tap on rshift /

* Update macros

* Update the "code paste" macro

* Update keymap with reset, calc, equals

* Update keyboards/dz60/keymaps/twschum_b_4_10_simple/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update keyboards/dz60/keymaps/twschum_b_4_10/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Revert quantum/rgblight_list.h

* Better name for split space layout; rename KEYMAP->LAYOUT

* Rename KEYMAP->LAYOUT

* Use simpler :flash command

* Clean up layout files

* Use qmk's MOD_MASK_CTRL

* Sync lufa submodule

* Cleanup from noroadsleft's PR comments

* Modernize vim layer code
JeffreyPalmer pushed a commit to JeffreyPalmer/qmk_firmware that referenced this pull request Feb 27, 2020
BorisTestov pushed a commit to BorisTestov/qmk_firmware that referenced this pull request May 23, 2024
* Adds layout for DZ60rev2 plate B, options 4 and 10

* Use KC_TRANS for layer keys

* Format layer0 with visual key size layout

* Add RGB controls; add start description; add KC_LOCK

* Update comments on rules.mk for DZ60

* Gets keymap compiling

* Fix wiring for shift on row 3

* Hold a with other key to send Ctrl-A before other key

* Adds compile-time defined mac-compatability media keycodes

* Adds logic in place for capturing taps (w/ timeout)

* Add send_keys(...) which can send up to 64 nested keycodes

* Implement send_keys callable with n repeats

* Tweaks some of the keymap

* Add reset keycode; add disable to custom shortcuts

* Adds a special "off" layer where bonus mod goes to layer 0, every other key KC_NO

* Adjust timeout; mousekey settings

* Changes layout of Home,End,PgUp/Dn on the dedicated arrow keys L1/L2

* PoC on rgb lighted layer indication

* Refactors color table defines

* Adds logic for controlling layer lights

* Only change state on one side of the event lol

* Switch back to Tapping Toggle for layer 4

* Add custom config file for keyboard; TT and mousekey settings

* Code cleanup; starting to refactor special ctrl tapping keys functions

* Move defines and �reak out functions

* Remove debugging light

* Adjust keymaps; add enter

* Adds a couple custom macros

* Add simplified version of keymap to help debug issues

* Adds basi numpad configuration for levinson keyboard half

* Use ANSI ctrl key as layer 1 for better one hand (`)

* Adapt to new 8bit hue from qmk#5547; layer enum use everywhere

* Move custom code out to users/ space

* Flip col pins, move key assignments to "left hand"

* Update readme

* Implement placeholder macros

* Notes

* Reduce tapping time for SFT_T(/)

* Adds vim features; refactors things

* Adds fork of the vim features written by xton

* Use correct backspace keycode

* Add VIM_ESC

* Add "OFF" to the RGB/HSV definitions

* Clean up rules, use new "OFF" definition

* Add windows KC_CALCULATOR key to numpad

* Reformat layers with better guide; change layer names

* Add sleep key

* Change timeout delay

* Add a "code paste" which surrounds a ^V with ```

* Try removing shift tap on rshift /

* Update macros

* Update the "code paste" macro

* Update keymap with reset, calc, equals

* Update keyboards/dz60/keymaps/twschum_b_4_10_simple/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update keyboards/dz60/keymaps/twschum_b_4_10/keymap.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Update users/twschum/twschum.c

Co-Authored-By: Drashna Jaelre <[email protected]>

* Revert quantum/rgblight_list.h

* Better name for split space layout; rename KEYMAP->LAYOUT

* Rename KEYMAP->LAYOUT

* Use simpler :flash command

* Clean up layout files

* Use qmk's MOD_MASK_CTRL

* Sync lufa submodule

* Cleanup from noroadsleft's PR comments

* Modernize vim layer code
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.

5 participants