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

Show the limit in motors graph #472

Merged
merged 1 commit into from Oct 30, 2020

Conversation

McGiverGim
Copy link
Member

Fixes #467

Is related to this firmware PR too betaflight/betaflight#10106

I think this is what @ctzsnooze wants, but I'm not too sure because I don't have logs with motor limits enabled to see if it works in all cases.

I opened it as draft to be discussed to see if this is what we want to achieve, so ignore the code until discussed.

Everybody feel free to test and comment.

@ctzsnooze
Copy link
Member

ctzsnooze commented Sep 23, 2020

Thanks, McGiverGim!

The logs I have with motor_output_limit less than 100 appear to do the right thing at the higher end of the throttle.

At the low end, a log with dynamic and motor_output_limit shows a throttle setpoint of 6.2% (the configured idle percentage), but the motor percentage says 9% (probably from motor_output_limit) while the displayed motor percentage is shown as 0%.

It would be good if the motors traces matched the percentage shown in the numbers.

In other words, so that the displayed motor range is from 'absolute DShot zero' to 'absolute DShot max'. In other words, motors should:

  • be zero when disarmed,
  • rise to the idle value on arming, and then
  • move to the motor_output_limit at full throttle.

I'm hoping that throttle setpoint would be shown as a percentage from 0-100 related to stick position, but the motors tab percentage should show the current DShot drive as a percentage of the full DShot range.

Motors_idle

@McGiverGim
Copy link
Member Author

@ctzsnooze I'm not sure if I understand you.

In my graphs I see the same value in the right panel, in the graph, or in the table for motors. And is the value that has been written into the blackbox.
I think maybe I don't understand what you are saying. Can you post some screen captures to see what is the problem?

We will need too some logs with other different motor protocol (oneshot, multishot, proshot) to see what are the max and min values they use, I'm not too sure if they use the same scale than dshot. We don't need a real flight, a simple FC at the desk is enough, only some log with minimum and maximum throttle to see what they send. At this moment all my sdcard are damaged so I can't record them by myself.

@ctzsnooze
Copy link
Member

ctzsnooze commented Sep 23, 2020

I will make some better test log soon, apologies for being slow.

The image above shows motor graph indicating 0%, but showing as a number as 9%, while throttle setpoint shows idle percentage (in this case 6.2). It seems to me that the motor graph should show actual DShot idle number in the range 0-2047, with the number shown as the percentage of the 0-2047 range. At idle, throttle setpoint should, I think, indicate the configured idle percentage, so at idle, all traces should overlap if motor_output_limit is 100.

@McGiverGim
Copy link
Member Author

How do you know that the motor graph shows a 0%? I think it is 8%. Can you add other line of something that goes from 0 to any other value to see if it goes under the motor line?

I have ignored the minimum value of 48 for motors, maybe the percentages are not accurate for this reason. I will change that and update the code. I suppose: 48 -> 0%, 2047 -> 100%.

About showing dshot value, I think is easier to users understand values from 0 to 100% and not from 48 to 2047. And more if it changes from an analog protocol to dshot. But this can be discussed later. It will not be difficult to show if needed.

@McGiverGim
Copy link
Member Author

Ahh! I know, your setpoint is 6% and the motors 8%, and setpoint is over motor. Can you attach your log, please?

@ctzsnooze
Copy link
Member

It is not an ideal log, because I can't remember if it it has motor output limit enabled... It will do. I will make another that has easier values to test with, from current master. This is not from current master.
7in.BBL.zip

@McGiverGim
Copy link
Member Author

@ctzsnooze fixed! Now it looks much better, please test the latest code. If it works ok, I think we have pending:

  • A log with limit enabled, to see what the header looks like.
  • Logs with other protocols, with and without limit.
  • Discuss if we need to show a percentage or the dshot value directly.

@McGiverGim
Copy link
Member Author

Fixed some offsets... another thing to decide if finally we stay with percentages: now is strange that the setpoint throttle uses one decimal, but the motors have no decimals. Maybe we need to unify both.

@McGiverGim McGiverGim force-pushed the motor_output_limits_graph branch 3 times, most recently from 61c3383 to c8c0276 Compare September 23, 2020 13:48
@McGiverGim
Copy link
Member Author

Uploaded a new version that:

  • Can work with analog and digital protocols
  • Show next to the percentage the raw value (dshot or analog). In this way we can validate if my graphs are ok.

@McGiverGim
Copy link
Member Author

After talking with @ctzsnooze it seems he is happy with the final result of this PR. So ready to be reviewed, modified if necessary and merged.
This PR is how @ctzsnooze and me see how the motors must be shown in the graphs, specially after this firmware PR: betaflight/betaflight#10294

@McGiverGim McGiverGim marked this pull request as ready for review October 23, 2020 11:44
@@ -511,7 +511,7 @@ function FlightLogFieldPresenter() {
case 'motor[5]':
case 'motor[6]':
case 'motor[7]':
return Math.round(flightLog.rcMotorRawToPct(value)) + " %";
return `${Math.round(flightLog.rcMotorRawToPct(value))} %`;
Copy link
Member

Choose a reason for hiding this comment

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

With a float we get more precision? Using 1‰ should be enough? But didn't look further if that precision can be used in the graphs.

PWM Dshot MotorPct
1000 0 -2.40120
1001 48 0.00000
1002 50 0.10010
1003 52 0.20020
1004 54 0.30030
1005 56 0.40040
1006 58 0.50050
1007 60 0.60060
1008 62 0.70070
1009 64 0.80080
1010 66 0.90090
1011 68 1.00100
1012 70 1.10110
1013 72 1.20120
1014 74 1.30130
1015 76 1.40140

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, I commented it somewhere to add one decimal to the percentage (more than one is too much).

Another solution is to let the percentage, and add the "real" motor value:

For example: 23 % (46) or the inverse 46 (23 %).

Copy link
Member

Choose a reason for hiding this comment

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

In true DShot values, we have 1000 steps? So perhaps one decimal point on the percentage?

@@ -1147,7 +1147,16 @@ FlightLog.prototype.rcCommandRawToThrottle = function(value) {

FlightLog.prototype.rcMotorRawToPct = function(value) {
// Motor displayed as percentage
return Math.min(Math.max(((value - this.getSysConfig().motorOutput[0]) / (this.getSysConfig().motorOutput[1] - this.getSysConfig().motorOutput[0])) * 100.0, 0.0),100.0);
let motorPct;
Copy link
Member

Choose a reason for hiding this comment

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

Why are we changing this - we are sending the motor limits explicitly to be able to use the correct values and not having to make assumptions.

Copy link
Member

Choose a reason for hiding this comment

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

Which assumptions are you referring to?

Copy link
Member

Choose a reason for hiding this comment

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

All that are made in this proposal.

Copy link
Member

Choose a reason for hiding this comment

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

That's not actually helping us get anywhere now is it :-)

Copy link
Member

Choose a reason for hiding this comment

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

I've been using this build for about 200 or more log analyses now.
In day to day use, focusing on idle and motors, it seems perfect to me.
So if you are proposing a change, then please be constructive and indicate what exactly you think should be changed.

@@ -261,10 +261,11 @@ GraphConfig.load = function(config) {
try {
if (fieldName.match(/^motor\[/)) {
return {
offset: -(sysConfig.motorOutput[1] + sysConfig.motorOutput[0]) / 2,
offset: sysConfig.fast_pwm_protocol < FAST_PROTOCOL.indexOf('DSHOT150') ?
Copy link
Member

Choose a reason for hiding this comment

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

Again, this should use the actual values for the range.

Copy link
Member

Choose a reason for hiding this comment

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

What actual values should be used?

Copy link
Member

Choose a reason for hiding this comment

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

The ones for the range - or what others can you think of?

Copy link
Member

Choose a reason for hiding this comment

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

I'm not intending to be obtuse to annoy.
I really do not know what range you are referring to.
You could mean the lowest or highest value received in the log for all I know.

@mikeller
Copy link
Member

Let's establish some facts to facilitate a discussion on this:

So, my proposal to solve this in a generic way is:

  • add a dynamicIdleMotorOffset header field to the blackbox log, to contain the dynamic idle offset value (or 0 if dynamic idle is not enabled);
  • use the existing throttle percentage calculation if dynamic idle is not enabled, or calculate based on the range [dunamicIdleMotorOffset...motorOutput[1]] if dynamic idle is enabled.

@ctzsnooze
Copy link
Member

ctzsnooze commented Oct 25, 2020

This is how, with these changes, a log is displayed when there is no dynamic idle, a default 5.5% idle, and no scaling or anything odd.
It is easy to see the absolute DShot value to any motor never falls below that value, and it's easy to visualise the magnitude of the DShot idle quantum.
Screen Shot 2020-10-25 at 23 48 28

@ctzsnooze
Copy link
Member

ctzsnooze commented Oct 25, 2020

This is an image showing a quad with dynamic idle active, and the default 5.5% idle, showing the motors occasionally going to zero percent throttle, or, in other words, to a zero DShot drive value.
Screen Shot 2020-10-25 at 23 51 17

@ctzsnooze
Copy link
Member

ctzsnooze commented Oct 25, 2020

@mikeller To me this seems exactly how McGyverGim and I, and most people I know, would actually want it displayed. We can see at a glance whether or not dynamic idle is configured.
Imagine that the upper trace had the DShot idle percentage at the zero line. It would then look much the same as the lower trace, even though the actual idle behaviour is completely different. Visually we would have no clue whether or not dynamic idle was active, and would not know if their DShot idle was 2% or 10%.
We actually want the appearance to immediately indicate whether dynamic idle is active or not; and if dynamic idle is not active, we want to see the magnitude of the DSHot idle offset visually and immediately in the graph.
This PR achieves that goal.

@mikeller
Copy link
Member

@ctzsnooze: As I said before, calling something that is based on a range that starts at a point that has got no relation to any physical a 'percentage' is not a good approach. Much rather, the current 'motor output percentage' graph should be fixed so that it displays the output percentage the way all users are used to.

But I can see where you want to go with this, and I think the right approach is to add a new graph for 'motor output value (normalised)' - this graph will be 1000 points both for Dshot and analogue protocols (as this is the range inherent to both protocols), and give you what you want - a scaled down version of the motor percentage based on the adjustments like output scaling and dynamic idle.

@ctzsnooze
Copy link
Member

I can't comment on the best technical implementation approach.

However from the user perspective, just because something was done a certain way in the past is not a sufficient reason to continue with it in the future.

The original motors graph made sense for the old analog protocols, where there was no absolute zero. We are not changing anything for those users.

With digital protocols, and especially with dynamic idle, things are very different. There is an absolute zero value for the motors, and our idle sits above this at some point.

The old display method is and was inherently misleading, since it implied that the motor drive was zero when the throttle was zero. This was never true in any protocol, but in the analog days there was nothing we could do about it.

Now we have digital control protocols and know what the absolute zero is, we can fix this. It's my view that we need to break from the display of the past so that the user gets 'truthful' information about what the motors are being instructed to do.

I don't agree that we should make an entirely different motors display. That would be even more confusing. People would keep asking why one was different from the other.

I am very confident that those who view logs will come to very quickly appreciate the virtues of this change. It is so much more logical than the old situation, and so obvious, in retrospect, that people will very quickly appreciate the benefit.

So I vote that we should keep the PR as is, other than any technical improvement to the coding, because it does exactly what we should have done long ago.

@ctzsnooze
Copy link
Member

ctzsnooze commented Oct 26, 2020

Mike, I probably look at more log files per day than anyone else on earth. Honestly. I deal nearly every day with people who are trying to interpret our logs.
Unless we have this change, my life gets massively harder.
It is really difficult to be able to show people what happens with dynamic idle, and even what DShot idle actually does, without this change.
Once we always show the actual idle value going to the motors, lots of things make sense. It's really hard to explain to people what their idle value does if its invisible.
This gets even more important when they compare motor drive to the rpm values. If they change DShot idle, with dynamic idle off, their idle rpm changes, but the displayed motor drive at idle does not. This makes no sense.
Once the idle offset is displayed in the motors tab, a whole lot of things make sense, particularly now we can measure rpm and display it, and even more so with dynamic idle.
As I said before, if the coding here is technically in need of some improvement, I'm all for that, but functionally the outcome - the 'user experience' - is exactly what I think we need it to be.

@McGiverGim
Copy link
Member Author

Is clear that we have different points of view:

  • @mikeller wants to show only the minimum "effective" range. To me this is most strange because we have different representations. If the user enables dyn idle, it will have a very different view of the motors than without it. I think a coherent view for all the configurations is better. And you suggest to add more parameters to the header to deal with it. If we have more features in a future that use more effective range than the habitual we need to add more parameters and deal with all of them and maybe have a different limit representation for each one.
  • @ctzsnooze and me want to show the motor "possibly" range. The same for all the configurations to maintain coherence. With this we don't need to take into account any feature that reduces or increments the effective range, it will be shown always. For us is good to show in the graphs the limit configured in the motor, the idle (dynamic and static), etc. A blank space in the motors graph is valuable for us if it gives information.

I suppose that the decision to show the current 0-100% effective range in the past was done because nobody, specially in the times that we used analog protocols, thought that in a future we will have features to limit/expand the ranges. Now we have different requisites so we need to adapt to them.

The latest decision is yours @mikeller so if I need to create a new virtual field for this, I can do it, but I don't think is the best solution.

@mikeller
Copy link
Member

@McGiverGim: My proposal is to add both in parallel:

  • keep the 0 - 100% 'motor output percentage' display that is pre-existing, but fix it so that for dynamic idle the percentage can drop below 0% (== idle speed) for users who simply want to see what the motors are doing in their current configuration;
  • add a new 'motor output value' that shows the normalised value of 0 - 1000 'motor output units' for users who want to get a view of the 'raw' data output.

@McGiverGim
Copy link
Member Author

Yes, that is what I wanted to say with "create a virtual field".

If I'm not wrong, the first part was accomplished with your changes in the firmware part. It changes the header values that are used by the blackbox to decide the range to shown. But I have not tested it.

The second one, is the virtual field to create. But I don't think we must normalize it. Move the dshot/analog values to a normalization of 0-1000 (or 0.0-100.0%) does not give anything here I think. We can't show the real 48-2047 for dshot and the value configured as min-max for analog. I can add both informations if needed (real dshot-analog value and percentage).

But as I said before, I don't think is the best solution. But if the decision has been taken I will look into it later.

@McGiverGim
Copy link
Member Author

Directly uploaded the source with the decimal. Here is the result:
image

@McGiverGim
Copy link
Member Author

I will fix the Sonar issues later, so wait until then to review the code.

@McGiverGim McGiverGim force-pushed the motor_output_limits_graph branch 2 times, most recently from 8543f58 to 3272405 Compare October 26, 2020 14:14
@McGiverGim
Copy link
Member Author

I think that ready to be reviewed.
I have not fixed a lot of code smells because they are in a code that I have not touched at all and I think it can increase the complexity of the review. If you want that I fix them too is not a problem.

js/flightlog.js Outdated Show resolved Hide resolved
js/flightlog.js Outdated
let motorPct;
if (this.getSysConfig().fast_pwm_protocol < FAST_PROTOCOL.indexOf('DSHOT150')) {
// Analog protocol
const ANALOG_RANGE = this.getSysConfig().maxthrottle - ANALOG_MIN_VALUE;
Copy link
Member

Choose a reason for hiding this comment

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

This is inconsistent with the rest - the range should be 2000 - 1000 to indicate the maximum possible range, just like it is for Dshot.

Copy link
Member

Choose a reason for hiding this comment

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

Actually I was wrong - this should use maxthrottle and minthrottle, and should also use minthrottle to normalise the offset.

Copy link
Member Author

Choose a reason for hiding this comment

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

I was unsure too when I implemented it. The objective of this new motor vision is to show the complete "physical" motor range, from motor stop, to motor at its physical max. In dshot is easy, it has a range from 48 to 2047 for any motor, but in analog I was unsure.

If I remember right, in analog protocols we needed to do a "calibration" that restricts the range that can be pased to the values minthrottle to maxthrottle, but I was not sure if minthottle was the motor stop or was the "analog idle" value.

If it is the motor stop, I think you are right and I we need to restrict to it. If it is the "idle" value then I think we need to represent the motor stop too to maintain coherence between both protocols and we need to send lower values too to show the motor stop value, and for this reason I use the 1000 value.

As I say, I was not too sure, it has been so long since I used analog protocols...

Copy link
Member

@ctzsnooze ctzsnooze Oct 28, 2020

Choose a reason for hiding this comment

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

min_throttle is the lowest sent to any motor while flying, and normally would reflect a stable idle at zero stick.

min command is the value to be sent when the motors should be stopped.
In the old motors display we saw 0% when at minthrottle and 100% when at max throttle, both in graph and numbers.

The analog situation around min_throttle is not quite the same as the DShot situation. With DShot, zero is always some consistent point below where the motors actually spin. The relationship between the user's idle point and the zero point is reasonably consistent with DShot, and has some meaning, especially when dynamic idle is present.

For analog protocols, min_command can be set much lower than the spin-up point. It is not always set to 1000. Where it is set is of no consequence once flying, since the motor drive signal cannot go below the configured min_throttle value, and dynamic idle cannot be applied.

To be comparable to DShot in the new display, we would show min_command as the zero point, and then show the motor drive signal as a percentage about this.

If we did this, motors should show zero percent only at idle, or during motor_stop, and then jump to min_throttle on arming, and never go below min_throttle while flying. I can't envisage anything useful coming from this, since there is no configuration that can ever cause motor drive to go below min_throttle while in flight, and it doesn't matter what the offset is down to min_command.

I can envisage a benefit from the existing method, where min_throttle is shown as 0%. In this PR as originally envisaged, only the analog protocol would go to zero consistently while in flight. No DShot protocol would do that, they would all have some DShot offset.

Hence by not having an offset of any kind when an analog protocol is chosen, the graph alone will immediately tell us if the user has an analog ESC connection or a Digital connection.

By my thinking there is no need, and no benefit, of displaying the offset between min_command and min_throttle in any motors display. And I perceive an advantage in NOT doing so.

In the past we only ever showed a simple percentage above min_throttle, and we've never had a complaint about that. I see no virtue in changing from the historical depiction.

For the analog protocols, perhaps showing the actual PWM value that was sent to the motors might be useful, in brackets after the percentage. Whether it is actually useful to display this, I don't know, it's never been a request and to date I haven't envisaged a use for it. But that is the only change that some users might consider an improvement.

case 'motorRaw[5]':
case 'motorRaw[6]':
case 'motorRaw[7]':
return `${flightLog.rcMotorRawToPctPhysical(value).toFixed(1)} % (${value})`;
Copy link
Member

@mikeller mikeller Oct 26, 2020

Choose a reason for hiding this comment

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

And % absolute here. If we change the percentage to 2 decimal places we also can drop the value, as this shows an accurate representation.

Copy link
Member Author

Choose a reason for hiding this comment

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

I tried to restrict the size to minimum. We have not too much space here, but I will try.

case 'motor[5]':
case 'motor[6]':
case 'motor[7]':
return `${flightLog.rcMotorRawToPctEffective(value).toFixed(1)} %`;
Copy link
Member

Choose a reason for hiding this comment

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

This should still include the raw value for reference and the percentage should be marked as relative to avoid confusion, so probably ${flightLog.rcMotorRawToPctEffective(value).toFixed(1)} % relative (${value}).

Copy link
Member Author

Choose a reason for hiding this comment

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

In the old code it has not raw value, but I can add it too without problem. The same concern about the size but I will try.

@ctzsnooze
Copy link
Member

ctzsnooze commented Oct 28, 2020

I very strongly disagree with including a 'legacy' motor page, and adding extra terms such as 'absolute' and 'relative' to deal with the problems that arise from including a 'legacy' motor page.

Having one single updated motors panel as per the original PR will be less confusing than providing two and with extra terminology and extra numbers in brackets.

The virtue of including include a 'legacy' motors panel is to the user a place they can go to see exactly how it would have looked before. So if we did include it, then we should not change it in any way. The proposal seems to be to include it but also change it. That makes no sense to me.

There is a lot of value in keeping the log display simple and concise. We should not clutter it with extra values unless they provide a benefit to the user somehow.

If we provide two decimal places for the percentage, that is more than enough accuracy, and for digital protocols will convey the exact value that would have been sent. Since this PR originally always showed DShot values in 'absolute' form, the percentage to convert to a number comparable to both the idle setpoint and the values that appear in our motors tab. No other additional number in brackets is required, nor does it add any additional benefit.

I strongly suggest we keep this change clean and simple, making no change to how the analog protocols are displayed, and displaying all digital protocols in absolute range with two decimal points for their percentage. No extra numbers in brackets, no 'absolute' or 'relative' suffixes. That's all we need to do.

I am confident that if we do include a legacy panel, it will get essentially no use and will likely be removed in a year or so. As such including it, and worrying about the complications that we get from including it, is just a waste of everyones time and energy.

@ctzsnooze
Copy link
Member

@mikeller could you maybe indicate, clearly, what you think the goal should be here? I've stated my thoughts, but they disagree with yours, and I think McGyverGim is in the challenging position of having to try to code it.

We have discussed this privately, and I felt that a clear description of your position would be helpful.

My position, as articulated originally in the PR, and modified somewhat following our discussions, is that we should:

  • have only one Motors panel, titled, Motors, as before.
  • display motor drive in percentages to the right of the waveform, as always, but with two decimal points precision
  • for analog protocols, the zero point for waveform and percentages would be min_throttle, as always, with the range being from min to max throttle. No change would be required other than the two decimal points in the percentage number.
  • for digital protocols, the zero point for waveforms and percentages would be a zero DShot drive signal (47 raw) and the 100% point would be full DShot drive (2048 raw). I don't know if the existing code supports a different DShot range if the user customises it, but ideally it would. The waveform would show zero when disarmed or motor stop was active, and jump to the defined idle value at idle after arming. With dynamic idle, motor drive values can go below the DShot idle percentage in flight, but when dynamic idle is not active, they should not.
  • no other values would be added in brackets after the percentages, or any other suffixes.

If you want anything different from this, please clearly spell out your vision of how motors data should be displayed, ie if you want to add another panel, how would you name it, how the data would be scaled for analog and digital forms, what ancillary values, if any, besides percentages, would be added, etc.

I would be really grateful if you could give us some clarity on this.

@McGiverGim
Copy link
Member Author

Yes please, apart from the technical issues that I need to fix, the final desired result is not clear to me.

I know you have talked about this, so if we can agree the final desired result it will be great.

@mikeller are you ok with the latest message of @ctzsnooze ? Only one motor graph, the one added in this PR, removing the old one?

@mikeller
Copy link
Member

@McGiverGim: I am ok with the definition that @ctzsnooze gives for the new graph.
Where we disagree on is that I do not think it is the right approach to force users to use the new graph. There are no flash space or performance concerns in the blackbox log viewer, so having the old and new graphs both available comes at a very low cost, and will give users the choice to stay with the graph they are familiar with if they prefer.

So my proposal:

  1. keep the existing graph, rename it to 'Motors (legacy)';
  2. add in an additional graph with (all from @ctzsnooze):
  • display motor drive in percentages to the right of the waveform, as always, but with two decimal points precision
  • for analog protocols, the zero point for waveform and percentages would be min_throttle, as always, with the range being from min to max throttle. No change would be required other than the two decimal points in the percentage number.
  • for digital protocols, the zero point for waveforms and percentages would be a zero DShot drive signal (47 raw) and the 100% point would be full DShot drive (2048 raw). I don't know if the existing code supports a different DShot range if the user customises it, but ideally it would. The waveform would show zero when disarmed or motor stop was active, and jump to the defined idle value at idle after arming. With dynamic idle, motor drive values can go below the DShot idle percentage in flight, but when dynamic idle is not active, they should not.
  • no other values would be added in brackets after the percentages, or any other suffixes.

N.b. I will propose a fix to show dynamic idle behaviour in the existing graph once betaflight/betaflight#10307 has been merged.

@McGiverGim
Copy link
Member Author

Understood. I will try to do the changes tomorrow.

@ctzsnooze
Copy link
Member

@mikeller
Thanks for the clarification.
Which should be the default, going forward - Motors (legacy) or Motors ?
I would be in complete agreement with you if Motors - the new format - was the default.

@mikeller
Copy link
Member

@ctzsnooze: I think it makes sense to use the new graph as the default for new users.

@McGiverGim
Copy link
Member Author

Let's see if I have understood all, this is the final result:

image

@mikeller
Copy link
Member

@McGiverGim: We should leave the existing graph (now 'Motors (legacy)') the way it is, including leaving the motor output values shown in braces after the percentage.

@McGiverGim
Copy link
Member Author

The way it is are you saying with the first changes of this PR? In the current master there is no raw value in the motors graph between braces.
But I can change it if you want, something like:
Motor (Legacy) [1] 20.45 % (454)

Will be ok?

@mikeller
Copy link
Member

@McGiverGim: I thought we had them? But yes, having the raw values in the legacy motor graph will be valuable, so please add them.

@McGiverGim
Copy link
Member Author

@McGiverGim: I thought we had them? But yes, having the raw values in the legacy motor graph will be valuable, so please add them.

Added as requested.

@sonarcloud
Copy link

sonarcloud bot commented Oct 30, 2020

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 2 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@mikeller mikeller added this to the 3.6.0 milestone Oct 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Motor display doesn't indicate motor_output limit or idle values
4 participants