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

Tilt state refactor and analog mid adjustments #585

Merged
merged 6 commits into from
Oct 19, 2023

Conversation

mikepparks
Copy link
Contributor

Reworked @InfraredAces #577 to include the recent Analog middle value changes from #582. Also refactors the state checking when pressing the modifiers to remove redundant logic.

jack2game added a commit to jack2game/GP2040-CE that referenced this pull request Oct 19, 2023
Copy link
Contributor

@arntsonl arntsonl left a comment

Choose a reason for hiding this comment

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

Looks great!

@arntsonl arntsonl merged commit 0390dca into OpenStickCommunity:main Oct 19, 2023
62 checks passed
jack2game added a commit to jack2game/GP2040-CE that referenced this pull request Oct 19, 2023
* Placeholder file for Rotation

* Rotate placeholder

* update source

* function done

* add rotation function

* add rotation function

* Create AnalogMod

* Combined Rotate and Tilt

* Update app.js

* Update analogmod.h

* Merge branch 'OpenStickCommunity:main' into Rotation + Add new doc

* Set default value relaying PR OpenStickCommunity#567

* Update default value for Tilt

* update proto with backward compatibility

* Update Tilt Behavior as PR OpenStickCommunity#577 + Streamline functions with cases re-written

* Merge branch 'OpenStickCommunity:main' into Rotation

* update dpadToAnalog function with input_Mode parameter

* Change all rotation to clockwise, allow 0-360 degree

* update config page

* update docs + using new mid point

* update doc + update comments

* Reflecting Changes in OpenStickCommunity#585, updating the Tilt1+Tilt2 and Rotate1+Rotate2 behavior

* Added First Win SOCD mode

* remove junk in configs/Pico/BoardConfig.h

* Separate SOCD for LS and RS

* Better trigonometry + more rotation

* Update analogmod.md

* Update BoardConfig.h

* Update BoardConfig.h

* Update add-ons.md, remove Tilt

* update _sidebar.md + config_utils.cpp

---------

Co-authored-by: root <root@ncbox2>
jack2game added a commit to jack2game/GP2040-CE that referenced this pull request Oct 20, 2023
* Change target button for DirectInput/PS3 Mode in documentation (OpenStickCommunity#570)

Change target button for DirectInput/PS3 Mode

Currently both Xinput and DirectInput/PS3 Modes are labeled as being invoked by B2. This is to change the DirectInput/PS3 button to be B3.

* Update analog trigger mode to include digital state (OpenStickCommunity#571)

* Allow digital input state and analog value state to co-exist for triggers when Gamepad.hasAnalogTriggers is true.
Added analog trigger check for keyboard host to avoid potential issues.

* Fixed issue where Wii analog trigger options could not be changed to None

* Change PS4 analog trigger state back to previous behavior. Report already handles both button and trigger values. XInput does not support both.

* More Macro fixes (OpenStickCommunity#574)

* Add Macro Board LED enabled field

* Add Macro addon enable indicator in OLED

* Enable Macro Lock in Focus Mode addon by default

* Small cleanup

* Fix default On-Board LED enable issue (OpenStickCommunity#573)

* Add missing On-Board LED initialization entry

* Add board LED define in default BoardConfig

* Fix doc typo (OpenStickCommunity#579)

* Fix Reflex CTRL SNES Pinout, Rename Reflex Encode, Add Reflex Encode V2 (OpenStickCommunity#576)

* Update Reflex Encode Fighting Board config

* Fix onboard LED

* Reflex CTRL SNES config

* Update cmake.yml

* Update cmake.yml

* Fix cmake.yml

* Add ReflexEncodeV2

* Rename "ReflexEncoder" to "ReflexEncodeV1" and add cmake.yml entries

* MiSTercade V2 Board

* Just build mistercade

* Add 15th button

* Update BoardConfig.h

* Define onboard LED GPIO

* Update cmake.yml

* Update BoardConfig.h

* Rebase

* Enable onboard LED

* Fix ON_BOARD_LED

* Update cmake.yml

* Update Board Configs

* Update usage.md

* Sync with main repo

* Update ReflexEncodeV2 Readme

* Revert "Update ReflexEncodeV2 Readme"

This reverts commit 216f71d.

* Update ReflexEncodeV2 Readme

* Update EncodeV1 and EncodeV2 board configs

* Typo

* Change ON_BOARD_LED function

---------

Co-authored-by: Robot <[email protected]>
Co-authored-by: TheTrain <[email protected]>

* Adds config for the Rana Tadpole (OpenStickCommunity#580)

* resolve issue 578 (OpenStickCommunity#581)

* resolve issue 578

Fixes issue 578 by adding a check for input mode and applying a bit shift to the mid value present in the 8-bit modes before the shift down to 8-bit. The issue was from the generic gamepad 16-bit mid value being 0x7FFFF shifting down to 0x7F which is not true center for input modes, as they expect 0x80 to be center.

* PS4 macros

Separate PS4 and HID macros, add them to their relevant USB reports.

* fix joystick midpoints (OpenStickCommunity#582)

* resolve issue 578

Fixes issue 578 by adding a check for input mode and applying a bit shift to the mid value present in the 8-bit modes before the shift down to 8-bit. The issue was from the generic gamepad 16-bit mid value being 0x7FFFF shifting down to 0x7F which is not true center for input modes, as they expect 0x80 to be center.

* PS4 macros

Separate PS4 and HID macros, add them to their relevant USB reports.

* fix joystick midpoint

Create helper function and add fix to missed areas.

* Update GamepadState.h

* Tilt adjustments (OpenStickCommunity#584)

* Mark Tilt addon as unavailable if pins are not defined when enabled.

* Fix indent on tilt.

* Tilt state refactor and analog mid adjustments (OpenStickCommunity#585)

* Mark Tilt addon as unavailable if pins are not defined when enabled.

* Fix indent on tilt.

* Incorporates PR OpenStickCommunity#577 and analog mid changes from OpenStickCommunity#582

* Tilt state refactor

* Allow tilt dpad mode to work with existing dpad inputs

* Updating All Gamepad MID Macros to use our mid-function (OpenStickCommunity#583)

* Replacing all the mid macros

* Updating everything to mid

* Update tilt.cpp

* Fixes Macro type Press and Loop issue (OpenStickCommunity#587)

* Fix looping macro first input line duration error

* Fix Press macro interruptible check with debounce

* Remove onboard LED pin definition from devices without an onboard LED (OpenStickCommunity#590)

---------

Co-authored-by: outphase <[email protected]>
Co-authored-by: Mike Parks <[email protected]>
Co-authored-by: deeebug <[email protected]>
Co-authored-by: AkariiinMKII <[email protected]>
Co-authored-by: misteraddons <[email protected]>
Co-authored-by: Robot <[email protected]>
Co-authored-by: TheTrain <[email protected]>
Co-authored-by: NickGuyver <[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
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants