-
Notifications
You must be signed in to change notification settings - Fork 323
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
Update with v0.7.5 latency testing #605
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Tests were done using Ferals optamized testing sketch found here: https://github.com/FeralAI/usblag_optimized/blob/main/usblag_optimized.ino
arntsonl
approved these changes
Oct 30, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! That is great to have both the XLSX and the updated numbers
jack2game
pushed a commit
to jack2game/GP2040-CE
that referenced
this pull request
Nov 1, 2023
Tests were done using Ferals optamized testing sketch found here: https://github.com/FeralAI/usblag_optimized/blob/main/usblag_optimized.ino
jack2game
added a commit
to jack2game/GP2040-CE
that referenced
this pull request
Nov 2, 2023
* Add Rotate, update doc, separate SOCD for LS&RS * Indentation * Indentation * convert core GPIO pin mappings from button-to-pin to pin-to-action (OpenStickCommunity#504) * convert core GPIO pin mappings from button2pin to pin2action this changes the core board config and gamepad behavior to be that the settings/user configures what each pin does, rather than the old behavior which configures what pin each button is assigned to. this allows for the new configuration to have one canonical location for what each of the pins does, and removes the limitation that a button can only normally be activated by one pin --- now it is trivial to assign many pins to take the same action "actions" are all button presses right now, but they may be other things in the future as this branch expands. this is just the core functionality and migration code for now, further changes (removing extra input addon, refactoring DDI, maybe refactoring the sliders, working the profiles into this scheme, etc.) to come * remove the extra button addon, it is unnecessary now * unset deprecated pin mappings after migration * unset the extra button addon pin after migration * fix the processing of the aux state/Fn button * renumber the non-managed pin enum entries motivation for this is the migration sets everything to NONE anyway, so the 0 value isn't super important to us, and protobuf by convention seems to use the lowest value as a default (e.g. in the python GUI editor), so setting that to NONE is idiomatic in both cases * fix the unsetting of the extra input addon after migrating * convert DDI pins to gpioMappings the rest of the DDI settings remain untouched, and the whole addon is basically where it always was, this just allows for centralization in the new GPIO mappings * add TODO for fixing the pin UI * fix the checking of the DDI masks * convert get/setPinMappings API to match refactor * "hardcode" the writing of 30 pins to JSON ArduinoJson retains the reference to the string until write time, so it was only actually publishing the value for pin29 * convert the JS slider pins to the centralized config there's not much left of the addon other than the config for what to do when nothing is held, so, this is a great candidate for getting folded into core * rename default JS mode option for consistency w/SOCD slider * preliminary SOCD slider port to gpioMappings * correct JS slider migration to refer to proper config/defines * correct SOCD slider migration by referring to proper settings * Global pin state action example using zustand * Export baseUrl * Pin to action ui playground, using global state with zustand * Hide som actions from dropdown. make the select disabled if action is set from board * Add a form for semantics * Add translation for labels, dynamic columns. * Remove pin -> action PoC from playground * Make savePins return promise * Replace pin mapping with pin -> action * Remove unused handler in usePinStore * remove DDI pins from addon page, point at Pin Mapping page * add more add-on pin usages to the UI * flag miscellaneous addon pins as ASSIGNED in migration * when saving addons/display pins in web config, mark them ASSIGNED * don't allow profiles to touch RESERVED/ASSIGNED_TO_ADDON this is partially a problem now (we shouldn't let a profile assign a pin that is normally reserved or on a addon), and partially a problem in the future (we shouldn't let a profile SET a pin to reserved/for an addon), when the profiles are refactored to use gpio mappings * Add better typing for usePinStore * - Create a new Capture button component that is reusable for any input. - Make new pin mapping handle labels for all input modes including swapTpShareLabels * don't include ASSIGNED_TO_ADDON in getUsedPins temporary measure as the addons' validation needs reworking to support a response that includes their own pins * don't allow setPinMappings to set/change addon/reserved pins * addons API shouldn't refer to DDI pins anymore now that they're "core" * remove unused API stuff from the dev server JSON * DRY on the simple protobuf-or-boardconfig pin migrations this also removes the protobuf isValidPin(foo) check and replaces it with a has_ + a nested check that it's between 0 and 29, so that if a user set a button to -1, we don't fallback to the BoardConfig.h, which would clobber their intentional unmapping * set ASSIGNED_TO_ADDON -> NONE if the new addon pin is invalid * un-ASSIGNED_TO_ADDON the Dminus pins when unsetting the Dplus pins * Remove double call on context * Remove useState for selectedBoard as it's only set once * Remove unused imports * Remove setLoading on getPinMappings as this creates race conditions, remove log * Map new pin actions to button mappings for profile settings * Remove unused lodash import * Remove export * remove unused EXTRA_BUTTON_ENABLED define * track when migrations have occurred I believe that it would be possible, without this history, for someone to unmap certain gpioMappings (or hotkeys) for intentional reasons and then accidentally trigger a re-conversion of the old BoardConfig.h values, meaning they could never unmap certain hotkeys or gpioMappings. this bool avoids that by only running the migration code once ever maybe it makes startup faster too, idk * remove unnecessary save()s in slider addons * define types for a pin and a gamepad mask --------- Co-authored-by: ian <[email protected]> * Update with v0.7.5 latency testing (OpenStickCommunity#605) Tests were done using Ferals optamized testing sketch found here: https://github.com/FeralAI/usblag_optimized/blob/main/usblag_optimized.ino * Input Macro Add-on Button labels (OpenStickCommunity#603) * Fix for missing value in input macro add-on page * - Allow capture button to not have any text if small prop - Send one label for macro page - Align button and inputs on macro page --------- Co-authored-by: ian <[email protected]> --------- Co-authored-by: Brian S. Stephan <[email protected]> Co-authored-by: ian <[email protected]> Co-authored-by: TheTrain <[email protected]> Co-authored-by: Luke Arntson <[email protected]>
jack2game
added a commit
to jack2game/GP2040-CE
that referenced
this pull request
Jun 12, 2024
* Add Rotate, update doc, separate SOCD for LS&RS * Indentation * Indentation * convert core GPIO pin mappings from button-to-pin to pin-to-action (OpenStickCommunity#504) * convert core GPIO pin mappings from button2pin to pin2action this changes the core board config and gamepad behavior to be that the settings/user configures what each pin does, rather than the old behavior which configures what pin each button is assigned to. this allows for the new configuration to have one canonical location for what each of the pins does, and removes the limitation that a button can only normally be activated by one pin --- now it is trivial to assign many pins to take the same action "actions" are all button presses right now, but they may be other things in the future as this branch expands. this is just the core functionality and migration code for now, further changes (removing extra input addon, refactoring DDI, maybe refactoring the sliders, working the profiles into this scheme, etc.) to come * remove the extra button addon, it is unnecessary now * unset deprecated pin mappings after migration * unset the extra button addon pin after migration * fix the processing of the aux state/Fn button * renumber the non-managed pin enum entries motivation for this is the migration sets everything to NONE anyway, so the 0 value isn't super important to us, and protobuf by convention seems to use the lowest value as a default (e.g. in the python GUI editor), so setting that to NONE is idiomatic in both cases * fix the unsetting of the extra input addon after migrating * convert DDI pins to gpioMappings the rest of the DDI settings remain untouched, and the whole addon is basically where it always was, this just allows for centralization in the new GPIO mappings * add TODO for fixing the pin UI * fix the checking of the DDI masks * convert get/setPinMappings API to match refactor * "hardcode" the writing of 30 pins to JSON ArduinoJson retains the reference to the string until write time, so it was only actually publishing the value for pin29 * convert the JS slider pins to the centralized config there's not much left of the addon other than the config for what to do when nothing is held, so, this is a great candidate for getting folded into core * rename default JS mode option for consistency w/SOCD slider * preliminary SOCD slider port to gpioMappings * correct JS slider migration to refer to proper config/defines * correct SOCD slider migration by referring to proper settings * Global pin state action example using zustand * Export baseUrl * Pin to action ui playground, using global state with zustand * Hide som actions from dropdown. make the select disabled if action is set from board * Add a form for semantics * Add translation for labels, dynamic columns. * Remove pin -> action PoC from playground * Make savePins return promise * Replace pin mapping with pin -> action * Remove unused handler in usePinStore * remove DDI pins from addon page, point at Pin Mapping page * add more add-on pin usages to the UI * flag miscellaneous addon pins as ASSIGNED in migration * when saving addons/display pins in web config, mark them ASSIGNED * don't allow profiles to touch RESERVED/ASSIGNED_TO_ADDON this is partially a problem now (we shouldn't let a profile assign a pin that is normally reserved or on a addon), and partially a problem in the future (we shouldn't let a profile SET a pin to reserved/for an addon), when the profiles are refactored to use gpio mappings * Add better typing for usePinStore * - Create a new Capture button component that is reusable for any input. - Make new pin mapping handle labels for all input modes including swapTpShareLabels * don't include ASSIGNED_TO_ADDON in getUsedPins temporary measure as the addons' validation needs reworking to support a response that includes their own pins * don't allow setPinMappings to set/change addon/reserved pins * addons API shouldn't refer to DDI pins anymore now that they're "core" * remove unused API stuff from the dev server JSON * DRY on the simple protobuf-or-boardconfig pin migrations this also removes the protobuf isValidPin(foo) check and replaces it with a has_ + a nested check that it's between 0 and 29, so that if a user set a button to -1, we don't fallback to the BoardConfig.h, which would clobber their intentional unmapping * set ASSIGNED_TO_ADDON -> NONE if the new addon pin is invalid * un-ASSIGNED_TO_ADDON the Dminus pins when unsetting the Dplus pins * Remove double call on context * Remove useState for selectedBoard as it's only set once * Remove unused imports * Remove setLoading on getPinMappings as this creates race conditions, remove log * Map new pin actions to button mappings for profile settings * Remove unused lodash import * Remove export * remove unused EXTRA_BUTTON_ENABLED define * track when migrations have occurred I believe that it would be possible, without this history, for someone to unmap certain gpioMappings (or hotkeys) for intentional reasons and then accidentally trigger a re-conversion of the old BoardConfig.h values, meaning they could never unmap certain hotkeys or gpioMappings. this bool avoids that by only running the migration code once ever maybe it makes startup faster too, idk * remove unnecessary save()s in slider addons * define types for a pin and a gamepad mask --------- Co-authored-by: ian <[email protected]> * Update with v0.7.5 latency testing (OpenStickCommunity#605) Tests were done using Ferals optamized testing sketch found here: https://github.com/FeralAI/usblag_optimized/blob/main/usblag_optimized.ino * Input Macro Add-on Button labels (OpenStickCommunity#603) * Fix for missing value in input macro add-on page * - Allow capture button to not have any text if small prop - Send one label for macro page - Align button and inputs on macro page --------- Co-authored-by: ian <[email protected]> * Merge * 20231111 merge (#20) * Test combo (#19) * test 12 * Proof of concept * 1&2 buttons * Separate Tilt Rotate * Update doc * Delete docs * text * Update cpp * update cpp --------- Co-authored-by: Brian S. Stephan <[email protected]> Co-authored-by: ian <[email protected]> Co-authored-by: TheTrain <[email protected]> Co-authored-by: Luke Arntson <[email protected]>
jack2game
added a commit
to jack2game/GP2040-CE
that referenced
this pull request
Jun 24, 2024
* Add Rotate, update doc, separate SOCD for LS&RS * Indentation * Indentation * convert core GPIO pin mappings from button-to-pin to pin-to-action (OpenStickCommunity#504) * convert core GPIO pin mappings from button2pin to pin2action this changes the core board config and gamepad behavior to be that the settings/user configures what each pin does, rather than the old behavior which configures what pin each button is assigned to. this allows for the new configuration to have one canonical location for what each of the pins does, and removes the limitation that a button can only normally be activated by one pin --- now it is trivial to assign many pins to take the same action "actions" are all button presses right now, but they may be other things in the future as this branch expands. this is just the core functionality and migration code for now, further changes (removing extra input addon, refactoring DDI, maybe refactoring the sliders, working the profiles into this scheme, etc.) to come * remove the extra button addon, it is unnecessary now * unset deprecated pin mappings after migration * unset the extra button addon pin after migration * fix the processing of the aux state/Fn button * renumber the non-managed pin enum entries motivation for this is the migration sets everything to NONE anyway, so the 0 value isn't super important to us, and protobuf by convention seems to use the lowest value as a default (e.g. in the python GUI editor), so setting that to NONE is idiomatic in both cases * fix the unsetting of the extra input addon after migrating * convert DDI pins to gpioMappings the rest of the DDI settings remain untouched, and the whole addon is basically where it always was, this just allows for centralization in the new GPIO mappings * add TODO for fixing the pin UI * fix the checking of the DDI masks * convert get/setPinMappings API to match refactor * "hardcode" the writing of 30 pins to JSON ArduinoJson retains the reference to the string until write time, so it was only actually publishing the value for pin29 * convert the JS slider pins to the centralized config there's not much left of the addon other than the config for what to do when nothing is held, so, this is a great candidate for getting folded into core * rename default JS mode option for consistency w/SOCD slider * preliminary SOCD slider port to gpioMappings * correct JS slider migration to refer to proper config/defines * correct SOCD slider migration by referring to proper settings * Global pin state action example using zustand * Export baseUrl * Pin to action ui playground, using global state with zustand * Hide som actions from dropdown. make the select disabled if action is set from board * Add a form for semantics * Add translation for labels, dynamic columns. * Remove pin -> action PoC from playground * Make savePins return promise * Replace pin mapping with pin -> action * Remove unused handler in usePinStore * remove DDI pins from addon page, point at Pin Mapping page * add more add-on pin usages to the UI * flag miscellaneous addon pins as ASSIGNED in migration * when saving addons/display pins in web config, mark them ASSIGNED * don't allow profiles to touch RESERVED/ASSIGNED_TO_ADDON this is partially a problem now (we shouldn't let a profile assign a pin that is normally reserved or on a addon), and partially a problem in the future (we shouldn't let a profile SET a pin to reserved/for an addon), when the profiles are refactored to use gpio mappings * Add better typing for usePinStore * - Create a new Capture button component that is reusable for any input. - Make new pin mapping handle labels for all input modes including swapTpShareLabels * don't include ASSIGNED_TO_ADDON in getUsedPins temporary measure as the addons' validation needs reworking to support a response that includes their own pins * don't allow setPinMappings to set/change addon/reserved pins * addons API shouldn't refer to DDI pins anymore now that they're "core" * remove unused API stuff from the dev server JSON * DRY on the simple protobuf-or-boardconfig pin migrations this also removes the protobuf isValidPin(foo) check and replaces it with a has_ + a nested check that it's between 0 and 29, so that if a user set a button to -1, we don't fallback to the BoardConfig.h, which would clobber their intentional unmapping * set ASSIGNED_TO_ADDON -> NONE if the new addon pin is invalid * un-ASSIGNED_TO_ADDON the Dminus pins when unsetting the Dplus pins * Remove double call on context * Remove useState for selectedBoard as it's only set once * Remove unused imports * Remove setLoading on getPinMappings as this creates race conditions, remove log * Map new pin actions to button mappings for profile settings * Remove unused lodash import * Remove export * remove unused EXTRA_BUTTON_ENABLED define * track when migrations have occurred I believe that it would be possible, without this history, for someone to unmap certain gpioMappings (or hotkeys) for intentional reasons and then accidentally trigger a re-conversion of the old BoardConfig.h values, meaning they could never unmap certain hotkeys or gpioMappings. this bool avoids that by only running the migration code once ever maybe it makes startup faster too, idk * remove unnecessary save()s in slider addons * define types for a pin and a gamepad mask --------- Co-authored-by: ian <[email protected]> * Update with v0.7.5 latency testing (OpenStickCommunity#605) Tests were done using Ferals optamized testing sketch found here: https://github.com/FeralAI/usblag_optimized/blob/main/usblag_optimized.ino * Input Macro Add-on Button labels (OpenStickCommunity#603) * Fix for missing value in input macro add-on page * - Allow capture button to not have any text if small prop - Send one label for macro page - Align button and inputs on macro page --------- Co-authored-by: ian <[email protected]> * Merge * 20231111 merge (#20) * Test combo (#19) * test 12 * Proof of concept * 1&2 buttons * Separate Tilt Rotate * Update doc * Delete docs * text * Update cpp * update cpp --------- Co-authored-by: Brian S. Stephan <[email protected]> Co-authored-by: ian <[email protected]> Co-authored-by: TheTrain <[email protected]> Co-authored-by: Luke Arntson <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Tests were done using Ferals optamized testing sketch found here: https://github.com/FeralAI/usblag_optimized/blob/main/usblag_optimized.ino