3-way switch without Knobster

Questions about deployment and use of Air Manager Instruments

Moderators: russ, Ralph

Message
Author
Roxus
Posts: 58
Joined: Wed Sep 02, 2020 7:30 pm

3-way switch without Knobster

#1 Post by Roxus »

My panel is using Knobster. But I dont want to use Knobster for any of my 3-way switches (or rocker switches, are they called ?).

Is there a way to do that ?

I'm using button_add(nil,nil) just above and just below the switch for me to switch up/down without Knobster.
I guess I could create a small panel that is not Knobster aware and put the instrument in that panel and place it above the other panel ?
Seems more awkward tho than using button_add() tho

User avatar
Sling
Posts: 5237
Joined: Mon Sep 11, 2017 2:37 pm
Contact:

Re: 3-way switch without Knobster

#2 Post by Sling »

Hi,

By default AM will not apply the knobster focus to anything less than a 3 way switch so normal up/dn or left/right toggle switches do not need to use knobster. Note that you can force these to give knobster focus in code. Dials and switches of 3 ways or more will always take knobster focus. The solution if you don’t want knobster to operate the control is to use something else as the control and manage the graphics in code just as you have done with using buttons.

doog
Posts: 38
Joined: Wed Sep 18, 2019 2:52 am

Re: 3-way switch without Knobster

#3 Post by doog »

I'm also not sure why the 3 position switch becomes a knobster region. Doesn't seem to work well, if at all. My 3 position works great as a touch, but with knobster it highlights and the knobster doesn't even move it. Shouldn't the knobster should be for knobs and not switches?

User avatar
Ralph
Posts: 7878
Joined: Tue Oct 27, 2015 7:02 pm
Location: De Steeg
Contact:

Re: 3-way switch without Knobster

#4 Post by Ralph »

I've never heard that it doesn't do 3 positions. Do you have an example of an instrument?

doog
Posts: 38
Joined: Wed Sep 18, 2019 2:52 am

Re: 3-way switch without Knobster

#5 Post by doog »

demo_issue.zip
(31.82 KiB) Downloaded 184 times
Sure here is an example of the 3 way C90 inverter switch for x-plane. If you run the instrument, you'll see it works great in the instrument running tool... but if you put it on a knobster panel it work work at all.

User avatar
Ralph
Posts: 7878
Joined: Tue Oct 27, 2015 7:02 pm
Location: De Steeg
Contact:

Re: 3-way switch without Knobster

#6 Post by Ralph »

What do you mean with a Knobster panel?

doog
Posts: 38
Joined: Wed Sep 18, 2019 2:52 am

Re: 3-way switch without Knobster

#7 Post by doog »

Ralph wrote: Mon Aug 30, 2021 6:47 am What do you mean with a Knobster panel?
Test it as a stand alone instrument… works. Now put it on a panel with knobster enabled and run the panel and you’ll see the problem.

User avatar
Sling
Posts: 5237
Joined: Mon Sep 11, 2017 2:37 pm
Contact:

Re: 3-way switch without Knobster

#8 Post by Sling »

doog,

Your instrument has coding errors that is why it doesn't work. if you try to click the switch before the subscribe is running errors are reported. A few of notes to help you out.

When posting instruments to the forum its best to use the Air Manager export function to generate a .siff file so others can easily import to help you. .zip requires extra work and may put some off.

The switch_add() function should not use a subscribe callback as its callback and unless you are intending on specifically using the optional press and release callbacks the switch_add function should only have one callback.

The knobster not working may be related to the fact you are not using the switch positions sequencially. Try making up position 0, off position 1 and down position 2 and try it again. The Knobster is just a dial that increments or decrements the position by one with each click so lt needs sequential positions I think. Sorry don't have time to check it myself.

Tony

doog
Posts: 38
Joined: Wed Sep 18, 2019 2:52 am

Re: 3-way switch without Knobster

#9 Post by doog »

Sling wrote: Fri Sep 03, 2021 7:26 am
The switch_add() function should not use a subscribe callback as its callback and unless you are intending on specifically using the optional press and release callbacks the switch_add function should only have one callback.

The knobster not working may be related to the fact you are not using the switch positions sequencially. Try making up position 0, off position 1 and down position 2 and try it again. The Knobster is just a dial that increments or decrements the position by one with each click so lt needs sequential positions I think. Sorry don't have time to check it myself.

Tony
The console error is just a missing sound file, cause i threwit together quick but it's not relevant to the discussion. Same issue without that line. The subscribe is needed to put the switch in the correct position if it’s moved in the sim and not the panel. The sequence order doesn't matter. I also think in general it’s weird to force knobster focus on a switch… it’s not how switches should move in my opinion.
Last edited by doog on Sat Sep 04, 2021 10:28 pm, edited 2 times in total.

User avatar
Keith Baxter
Posts: 4674
Joined: Wed Dec 20, 2017 11:00 am
Location: Botswana

Re: 3-way switch without Knobster

#10 Post by Keith Baxter »

Hi,

IMHO only switches assigned <mode> 'CIRCULAR' should attract knobster functionality,

I don't use knobster so this is just my perception.

Keith
AMD RYZEN 9 5950X CPU, Corsair H80I cooler, ASUS TUF GAMING B550-PLUS AMD Ryzen Mother Board,  32Gb ram Corsair Vengeance 3000Mh, MSI GTX960 4G graphics card 

Post Reply