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

Feature Request - Interactive Configuration : control=config allow toggle of single bits of a byte #341

Closed
Scachi opened this issue Sep 10, 2019 · 2 comments

Comments

@Scachi
Copy link

Scachi commented Sep 10, 2019

Right now it is only possible to do presets using the config control using hex values.
Using hex values for a single bit will also set the other bits of that byte.

To be able to max out the usage of all available bits & bytes of the pmem storage one sometimes has to put different checkboxes into a single byte that don't match logical wise.
Example:
using byteoffset 0 bitoffset 0 : "Enable Rapid Fire" and byteoffset 0 bitoffset 1 : "Enable Anti Recoil".
When I want to create a config item for Rapid Fire enabled I can't to this without changing or risking the change of the Anti Recoil checkbox at the same time.

At the moment "#nn:hh" is used to jump to a nn:specific byte offset and set hh:hex.
Is it possible to add something like "^nn:bitmask to set a bitmask with placeholder to keep some bit unchanged ? (not defining them as 1 or 0)
Example: '^00:???????1" will set that single bit of byte 0 to 1 only without touching the other.
Or any other special char + , ' , - , | , $ ...

@J2Kbr
Copy link
Owner

J2Kbr commented Sep 11, 2019

Operations OR and AND added on Gtuner IV 1.05 revision 1 (I suggest wait the same update be available on Gtuner Air before publish scripts).

Here is how this works:
GIVICFG:#02:04 Assign the hex value 04 to position hex 02
GIVICFG:#02|04 Bitwise OR the hex value 04 with the current value on position hex 02
GIVICFG:#02&FB Bitwise AND the hex value FB with the current value on position hex 02

@J2Kbr
Copy link
Owner

J2Kbr commented Sep 11, 2019

Added on Gtuner Air: J2Kbr/GtunerAir#13

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants