-
-
Notifications
You must be signed in to change notification settings - Fork 309
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
feat(telemetry): Edit Sensors: display the percentage (%) equivalent to ratio when scaling a sensor value #4648
Comments
Hi Frankie, Is there any underlying code issue that would prevent just having a decimal value used to multiply the sensor input? |
@silicongarage The scaling problems are solved by now (crossing my fingers :-). Internally as you saw the code is all done by the formula new_value = (old_value *ratio) / 255. The original purpose of the code is to adjust Voltages, and there is a formula to compute the ratio depending on RX electronics (resistors used for voltage divider). There are multiple places documenting what value of "ratio" should be used for different brands of RX (multi-module documentation). So changing to a totally new formula might affect people who use it, as well as is a deep change in both firmware and companion. A good trade off is to show the equivalent in percentage for the non electronic inclined users :-) At least gives you an idea if you are adjusting up or down, and for how much. |
Just out of curiosity, what file is the ratio formula for calculating a voltage divider value with ratio being used in? |
Is there an existing issue for this feature request?
Is your feature request related to a problem?
Not a bug, just enhancement.
The original ratio was design to correct for ADC Voltages to display the correct voltage.
Some people who knows how to compute a voltage divider knows what number to type if they know the electrical schematics of the RX voltage input.
For a big majority, they really don't know where to start unless is documented in the RX manual (or somewhere else). They just start changing the number until they get the voltage they see in a multimeter.
A "ratio" of 0 (display as "-") mean bypass the scaling logic, so it give the raw value coming from the telemetry screen.
A "ratio" of 25.5 will give you the original sensor value (or 100%).
Could be helpful to display the percentage on the side of the ratio, so if a user needs to scale up, they know to go to a value higher than 100%,
Some people are using "ratio" for sensors who are not voltages. For example, If you have a Current (A) reading, you could compute a new sensor for consumption by adding this current periodically. Then adjust "ratio" +/- until you get a consumption closer to reality at the end of the flight.
Describe the solution you'd like
Display the equivalent percentage on the side of the "ratio" field.
Example:
Describe alternatives you've considered
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: