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

RC smoothing auto factor tooltip text for 4.3 #2714

Merged
merged 1 commit into from
Jan 7, 2022

Conversation

haslinghuis
Copy link
Member

Fixes: #2711

@ctzsnooze
Copy link
Member

ctzsnooze commented Dec 26, 2021

This message will need version control.

The existing message is correct for 4.2. We will need a different message for 4.3.

Perhaps for 4.3 we could say:

"message": "Adjusts auto RC smoothing. 30 is the default.
Higher values smooth RC inputs more - e.g. 60 for HD freestyle or 90-120 for cinematic flying.
Note: Values over 50 will cause appreciable stick delay.
Lower values, eg 20-25, will transfer some of the RC control steps into the motor signals, slightly increasing motor heat, but will reduce RC delay slightly. This may be useful for racing."

@ctzsnooze ctzsnooze changed the title Fix auto factor Update rc smoothing auto factor tooltip text for 4.3 Dec 26, 2021
@ctzsnooze ctzsnooze changed the title Update rc smoothing auto factor tooltip text for 4.3 RC smoothing auto factor tooltip text for 4.3 Dec 26, 2021
@haslinghuis haslinghuis force-pushed the fix_auto_factor branch 2 times, most recently from c6a4e56 to 222d5b1 Compare December 26, 2021 23:03
@@ -631,6 +631,9 @@ TABS.receiver.initialize = function (callback) {
$('.tab-receiver .rcSmoothing-auto-factor').hide();
}

const tooltip = i18n.getMessage(semver.gte(FC.CONFIG.apiVersion, API_VERSION_1_44) ? "receiverRcSmoothingAutoFactorHelp2" : "receiverRcSmoothingAutoFactorHelp");
$('.receiverRcSmoothingAutoFactorHelp').attr('title', tooltip);
Copy link
Member

Choose a reason for hiding this comment

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

No need to attr here the tootltip for version < 1.44 since it is already defined and named in the html part.

Copy link
Member Author

@haslinghuis haslinghuis Dec 30, 2021

Choose a reason for hiding this comment

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

Now changed the values to be defaults using version control to minimize translation work

Copy link
Member

Choose a reason for hiding this comment

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

The other numbers, where we mention higher values, won't be correct for 4.2.
I think it is better to have entirely separate tooltips for 4.2 and 4.3.
These situations arise from time to time.
We shouldn't change the 4.2 tooltip.
We probably have a similar issue with antigravity gain. In 4.2 it could be pushed to 9 or 10 and would only increase I. In 4.3 it increases P also, and has inherently higher gain, and typically should NOT be pushed to 9 or 10. I haven't had time to check all these tooltips but we will need separate tooltips, or a tooltip that explains "in 4.2, do X, in 4.3 do Y".

Copy link
Member Author

Choose a reason for hiding this comment

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

We are free to add some extra defaults for those values too.

Copy link
Member

Choose a reason for hiding this comment

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

This need a lotof maintain @ctzsnooze , we should use generic tooltips for all versions

Copy link
Member

Choose a reason for hiding this comment

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

I agree, I think it would be simpler to just have the text for the tooltip. I don't think we need the code that pulls the default value by version. Just change the tooltip, if needed, by version.
If we think about antigravity, say, at one version we make a big change, then for many versions after, most likely no further change.
But when we do make a change, it is not just the default value that changes, but perhaps the way the code works, or the tuning information.
So my feeling is that we should keep tooltips as simple as possible, but version control them so that when they change significantly, we make a new tooltip for the newer version.
We can't have the same tooltip for all versions, it would just be useless in many settings. Eg transition. Now we have jitter reduction we don't recommend transition anymore, so we should change that tooltip to explain the new situation in 4.3, and that tooltip would be different from the tooltip for transition before 4.3

Fix target help
asizon
asizon previously approved these changes Dec 27, 2021
@haslinghuis haslinghuis added this to For discussion in Finalizing Firmware 4.3 Release via automation Dec 28, 2021
@haslinghuis haslinghuis moved this from For discussion to In Progress in Finalizing Firmware 4.3 Release Dec 28, 2021
@ctzsnooze
Copy link
Member

ctzsnooze commented Dec 29, 2021

Tested, works correctly.
Maybe update the text itself to:

Adjusts the amount of auto RC smoothing.<br />The default is 30.<br /><br />Higher values, e.g. 60 for HD freestyle or 90-120 for cinematic flying, will smooth out sharp RC inputs, giving smoother video, but may cause noticeable stick delay.<br /><br />Lower values, eg 20-25, may be useful for racing, giving slightly less RC delay at the cost of slightly warmer motors.

@McGiverGim
Copy link
Member

I have seen that we have a lot of "default" values in the tooltips for Betaflight 4.3. This that seems a good idea will be a nightmare of maintenance in the future, when something "changes" and we start recommending different values.
And any change in the text makes that all the translators of all the languages need to translate it again.

@haslinghuis
Copy link
Member Author

haslinghuis commented Dec 30, 2021

@McGiverGim Agreed. We need more generic messages. Adding a defaults struct in fc.js we could make defaults independent from translated messages.

@ctzsnooze adapted your latest suggestion to use a variable for default firmware version. Is the message generic enough to use for 4.2 and later firmware?

@haslinghuis
Copy link
Member Author

@chmelevskij please check as it's working but I don't like / understand the console output:

localization-04da3b28.js:132 i18next::interpolator: missed to pass in variable autoFactor for interpolating Adjusts the amount of auto RC smoothing.<br><br>The default is {{autoFactor}}.<br><br>Higher values, e.g. 60 for HD freestyle or 90-120 for cinematic flying, will smooth out sharp RC inputs, giving smoother video, but may cause noticeable stick delay.<br><br>Lower values, eg 20-25, may be useful for racing, giving slightly less RC delay at the cost of slightly warmer motors.

@ctzsnooze
Copy link
Member

ctzsnooze commented Dec 31, 2021

@McGiverGim tooltips will need to change when the a parameter becomes functionally different. By that I mean, when it works a differently, or needs to be adjusted in a different way, compared to earlier versions.

This is relatively infrequent, but when it happens, the user needs a tooltip that is relevant to the code they are running, and doesn't give them bad advice. Two examples in 4.3 are antigravity gain and rc smoothing auto factor.

We don't need explicitly to include default values in tooltips, but it is very helpful to include advice on how to set the parameter to a range that works effectively.

With Presets, a user may get parameter values that they did not enter, and may wonder if the value is at default or not.

I think it would be very helpful to be able to include the default value in tooltips, or to have some other generic means to show what the default value is, so the user can check if the value is default or not. There is no simple way, otherwise, of doing this.

Hence, having some method to easily display the default could be very useful. If the text for "Default: " could be referenced to a specific message, and the value derived cleverly, there would be no translation effort.

However in practice, when we do make changes that require different tooltips, we will need either a singe 'combined' tooltip in the form, "for firmware after N.N, our advice is P, for earlier firmware, our advice is Q", or, we provide separate tooltips so for 4.2 "our advice is P" and for 4.3 "our advice is Q".

The second seems better to me, especially where significant changes arise, and this will be the case in 4.3 for at least some parameters.

asizon
asizon previously approved these changes Jan 2, 2022
@asizon asizon added the Tested label Jan 2, 2022
limonspb
limonspb previously approved these changes Jan 4, 2022
@haslinghuis haslinghuis assigned limonspb and haslinghuis and unassigned limonspb Jan 5, 2022
@blckmn
Copy link
Member

blckmn commented Jan 5, 2022

AUTOMERGE: (FAIL)

  • github identifies PR as mergeable -> FAIL
  • assigned to a milestone -> PASS
  • cooling off period lapsed -> PASS
  • commit count less or equal to three -> PASS
  • Don't merge label NOT found -> PASS
  • at least one RN: label found -> PASS
  • Tested label found -> PASS
  • assigned to an approver -> PASS
  • approver count at least three -> FAIL

@sonarcloud
Copy link

sonarcloud bot commented Jan 5, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@limonspb limonspb merged commit fb3f3b9 into betaflight:master Jan 7, 2022
Finalizing Firmware 4.3 Release automation moved this from In Progress to Finished (Merged) Jan 7, 2022
@haslinghuis haslinghuis deleted the fix_auto_factor branch January 7, 2022 00:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

10.8.0 RC1 Auto Factor text balloon
7 participants