- Posts: 7
Custom Display Units
- nknotts
- Topic Author
- Offline
Less
More
22 Nov 2017 21:30 #66075
by nknotts
Custom Display Units was created by nknotts
Hello, I just came across deviation and have been really impressed.
I have deviation 5.0.0 loaded on my devo 7e and have begun configuring the main page. I have it configured such that the thrust value is displayed in "Box1". My question is, is it possible to change the display units of the thrust command (or any other output) to be something other than [-100, 100]%. Ideally, the display value could be translated with something simple like a scale factor or linear curve. I apologize if this question has been already asked (I did a few searches) or if this is the wrong board.
Thanks,
Nate
I have deviation 5.0.0 loaded on my devo 7e and have begun configuring the main page. I have it configured such that the thrust value is displayed in "Box1". My question is, is it possible to change the display units of the thrust command (or any other output) to be something other than [-100, 100]%. Ideally, the display value could be translated with something simple like a scale factor or linear curve. I apologize if this question has been already asked (I did a few searches) or if this is the wrong board.
Thanks,
Nate
Please Log in or Create an account to join the conversation.
- FDR
- Offline
22 Nov 2017 21:43 #66076
by FDR
Replied by FDR on topic Custom Display Units
You can rescale it to 0..100 in a virtual channel and display that if you like...
Please Log in or Create an account to join the conversation.
- nknotts
- Topic Author
- Offline
Less
More
- Posts: 7
22 Nov 2017 22:04 #66077
by nknotts
Replied by nknotts on topic Custom Display Units
How flexible is the rescaling? I was hoping for [-2000, 2000] for one channel, [-20, 20] for another.
Please Log in or Create an account to join the conversation.
- Deal57
- Offline
Less
More
- Posts: 857
23 Nov 2017 02:05 #66084
by Deal57
Deviation Devo7e 3way switch mod, A7105, NRF24L01
Devo6s 2x2 switch mod, trim mod, haptic, multimodule, A7105, NRF24L01, CC2500
Devo12e 4-in-1 with voice mod -- it speaks!!
Replied by Deal57 on topic Custom Display Units
The typical virtual channel set up for a 0% to 100% view is below. You are just changing the way the value is displayed, so you have to take the channel 3 (throttle) output as your source, then scale and offset that value. Change your scalar and offset and display this channel in the box.:
I was able to create a complex mixer using this with several Mux type "mult" on a fixed 125 value (up to 10 mixers), but in reality the box would display from -297% to 297% or 0 to 327%. No matter how many more times I tried to multiply, the value showed 327%.
Is there another alternative to show up to 2000? Is the % always shown for channel values?
[virtchan3]
name=TPercent
template=simple
[mixer]
src=Ch3
dest=Virt3
scalar=50
offset=50
I was able to create a complex mixer using this with several Mux type "mult" on a fixed 125 value (up to 10 mixers), but in reality the box would display from -297% to 297% or 0 to 327%. No matter how many more times I tried to multiply, the value showed 327%.
Is there another alternative to show up to 2000? Is the % always shown for channel values?
Deviation Devo7e 3way switch mod, A7105, NRF24L01
Devo6s 2x2 switch mod, trim mod, haptic, multimodule, A7105, NRF24L01, CC2500
Devo12e 4-in-1 with voice mod -- it speaks!!
Please Log in or Create an account to join the conversation.
- nknotts
- Topic Author
- Offline
Less
More
- Posts: 7
27 Nov 2017 19:33 #66212
by nknotts
Replied by nknotts on topic Custom Display Units
I ended up hacking in the ability to specify both the scale factor and sprintf format from model.ini which suits my needs perfectly.
github.com/nknotts/deviation/tree/display-scale
I'm not sure if this has much utility upstream. If people find this useful, I can issue a pull request.
I'm not sure if this has much utility upstream. If people find this useful, I can issue a pull request.
Please Log in or Create an account to join the conversation.
- FDR
- Offline
27 Nov 2017 19:51 #66213
by FDR
Replied by FDR on topic Custom Display Units
Looks good.
Have you try to build it for the 7E also?
Have you try to build it for the 7E also?
Please Log in or Create an account to join the conversation.
- nknotts
- Topic Author
- Offline
Less
More
- Posts: 7
27 Nov 2017 20:03 #66214
by nknotts
Replied by nknotts on topic Custom Display Units
I've built and tested for the 7E and the windows 7E emulator.
As is, the options are only available via hand editing the model.ini file. I'm not quite sure how/where these options would appear within the gui.
Are there other options that are ini only? Would a feature be accepted without being exposed in the ui?
As is, the options are only available via hand editing the model.ini file. I'm not quite sure how/where these options would appear within the gui.
Are there other options that are ini only? Would a feature be accepted without being exposed in the ui?
Please Log in or Create an account to join the conversation.
- FDR
- Offline
27 Nov 2017 21:11 #66215
by FDR
Replied by FDR on topic Custom Display Units
So far only the safety options were without GUI support, and in case of the 7E you could configure the main page layout only in the emulator.
As far as I see this option would use default settings, which are the same as the current behavior, so those who don't need it don't have to worry about...
As far as I see this option would use default settings, which are the same as the current behavior, so those who don't need it don't have to worry about...
Please Log in or Create an account to join the conversation.
- FDR
- Offline
17 Jan 2018 07:46 #66921
by FDR
Replied by FDR on topic Custom Display Units
Are you aware, that there is a problem with your changes?
Can you help to resolve this issue?:
www.deviationtx.com/forum/builds/7571-st...-behavior-of-devo-10
github.com/DeviationTX/deviation/issues/340
Can you help to resolve this issue?:
www.deviationtx.com/forum/builds/7571-st...-behavior-of-devo-10
github.com/DeviationTX/deviation/issues/340
Please Log in or Create an account to join the conversation.
- nknotts
- Topic Author
- Offline
Less
More
- Posts: 7
17 Jan 2018 11:12 #66927
by nknotts
Replied by nknotts on topic Custom Display Units
I was not aware of this. I will investigate.
Please Log in or Create an account to join the conversation.
- FDR
- Offline
17 Jan 2018 11:23 #66929
by FDR
Replied by FDR on topic Custom Display Units
Thanks!
Please Log in or Create an account to join the conversation.
Time to create page: 0.048 seconds
- Home
- Forum
- General
- General Discussions
- Custom Display Units