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

refactor(mixer): improve delays #4256

Merged
merged 3 commits into from
Nov 7, 2023
Merged

refactor(mixer): improve delays #4256

merged 3 commits into from
Nov 7, 2023

Conversation

raphaelcoeffic
Copy link
Member

@raphaelcoeffic raphaelcoeffic commented Oct 27, 2023

This PR removes the distinction between following with respect to how delays are handled:

  • a conditional mixer line (using a set of flight modes and/or conditional switch),
  • a non-conditional one.

Fixes #4254

@philmoz
Copy link
Collaborator

philmoz commented Oct 28, 2023

Looks ok to me. I was looking at this yesterday and your solution is almost exactly the same as what I came up with.

One thing, not directly related to this issue, is that the 'stickIndex' variable is redundant.
Change line 794 to:
mixsrc_t srcRaw = md->srcRaw;
and you can delete stickIndex.

@raphaelcoeffic raphaelcoeffic added this to the 2.9.2 milestone Oct 28, 2023
@raphaelcoeffic
Copy link
Member Author

@pfeerick we should probably mention this in the release notes. Just in case someone had set something in the delays that was ineffective then, but would be now.

@raphaelcoeffic raphaelcoeffic added the rn: warning Warning needed in release notes label Oct 28, 2023
Copy link
Collaborator

@3djc 3djc left a comment

Choose a reason for hiding this comment

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

Looks good to me, I think time to rework fully the mixer is closing, no matter how scary

@gagarinlg
Copy link
Member

Only with unit tests with close to 100% code coverage

@pfeerick pfeerick added the bug 🪲 Something isn't working label Nov 5, 2023
@pfeerick pfeerick self-requested a review November 6, 2023 10:46
@pfeerick
Copy link
Member

pfeerick commented Nov 7, 2023

Can't see anything broken here... only fixed 😁 Servo auto test delay/slow mixer, and various switch-based slow/delay with FM conditionals working as expected.

@pfeerick pfeerick merged commit 6eef254 into main Nov 7, 2023
37 checks passed
@pfeerick pfeerick deleted the fix-4254 branch November 7, 2023 00:50
MRC3742 pushed a commit to MRC3742/edgetx that referenced this pull request Dec 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🪲 Something isn't working rn: warning Warning needed in release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Delay doesn't work in interaction with Flight Modes
5 participants