January 27, 20233 yr The way I have done this for my simpit is with 2 AAO commands. The first command is for the "up" position. This AAO command has the desired function on the button press "on" and the middle function of the switch on the button release "off". The second command is for the "down" position. Again, The AAO command as the desired function on the button press "on" and the middle function of the switch on the button release "off". There may be other ways that are more elegant, for example with a script, but this way works in my application. Edited January 27, 20233 yr by hs118 My MSFS 2020 repaints: Flightsim.to - Profile of HStreet Working on MSFS 2024 versions.
January 27, 20233 yr Commercial Member 1 hour ago, Sky Flyer said: Hi! Any idea how best to make a three-way switch on the a320? Thanx ! What simulator? What switch in which A320? For what kind of external control? Momentary button on a yoke, switch on a switchbox, StreamDeck? Edited January 27, 20233 yr by Lorby_SI LORBY-SI
January 28, 20233 yr Author Thanks for answers ! I use x-touch mini - I have no problems with it. Now I'm trying to set up Streamdeck XL - no problems with toggle and two way buttons, but I can't figure out how to cycle through 3 values. prepar3d 5.3 simulator, fslabs.
January 28, 20233 yr Commercial Member 1 hour ago, Sky Flyer said: Thanks for answers ! I use x-touch mini - I have no problems with it. Now I'm trying to set up Streamdeck XL - no problems with toggle and two way buttons, but I can't figure out how to cycle through 3 values. prepar3d 5.3 simulator, fslabs. This must be done with RPN scripts. The actual script code depends on what that switch is supposed to do, there is no generic solution. Cycle an LVar through 3 values? Trigger a K-Event with three different values? Something else entirely? LORBY-SI
January 28, 20233 yr Author I tried to write 3 values through LVAR , but the switch position changes only visually, without triggering the event. I do not quite understand how to do the same through K-rotors. The command must depend on the actual starting position of the switch.
January 28, 20233 yr 37 minutes ago, Sky Flyer said: ...but the switch position changes only visually, without triggering the event. Which switch??
January 28, 20233 yr Commercial Member 44 minutes ago, Sky Flyer said: I tried to write 3 values through LVAR , but the switch position changes only visually, without triggering the event. I do not quite understand how to do the same through K-rotors. The command must depend on the actual starting position of the switch. As @Noncon says: we need to know EXACTLY what you are trying to do. There is no generic approach. This is potentially different for every switch (and every aircraft - and every sim). LORBY-SI
January 28, 20233 yr Commercial Member 1 hour ago, Sky Flyer said: I tried to write 3 values through LVAR , but the switch position changes only visually, without triggering the event That is quite normal. LVars traditionally control (only) the animation. I'm not sure what kind of logic the FSLabs A320 uses or if it has an SDK/API (I think that it doesn't). But your answer suggests that it uses the ROTOR_BRAKE event somehow. So your script would have to read the LVar, which will give you the current position of the switch. Depending on that value you send the appropriate ROTOR_BRAKE event. I don't own the FSLabs myself, so I can only guess. Assuming (= not actually knowing) that the LVar goes through 0, 1, 2 for the three positions, you make one script like this (L:whatever, Number) 0 == if{ whatever_gets_the_switch_to_position_1 (>K:ROTOR_BRAKE) } (L:whatever, Number) 1 == if{ whatever_gets_the_switch_to_position_2 (>K:ROTOR_BRAKE) } (L:whatever, Number) 2 == if{ whatever_gets_the_switch_to_position_0 (>K:ROTOR_BRAKE) } Or something like that. Edited January 28, 20233 yr by Lorby_SI LORBY-SI
Archived
This topic is now archived and is closed to further replies.