Jump to content
Sign in to follow this  
kenny584

3 way switch in SD+

Recommended Posts

Hi Folks.

I have been doing well with directly entering the Script group and name into the K: Event section. However, this three way switch has me stumped. It is used to activate the AMPS volt meter. The code works in AAO when I use the Run Script feature. I see the switch moving as it should. The Script Group has multiple scripts to operate the switch. By that I mean there is one to move Up, one to move Down and others to move up and down cyclic. I have tried various buttons from the Lorby-SI AxisAndOhs list within the Stream Deck software, however, I cannot get the switch to activate in the 3d cockpit. I have also tried using a rotary encoder but that also did not work.

Which 'button' would I choose to activate a three way switch operating as 1,2,3,2,1,. L ALT, R ALT, BATT VOLTS and back down again? I hope this is enough information. I've read the section in the manual that references 'Calling a script with parameters' but I'm not creatiing a script as such. I wish to use a script that I have downloaded.

Regards...Kenny.

Share this post


Link to post
Share on other sites
17 minutes ago, kenny584 said:

Which 'button' would I choose to activate a three way switch operating as 1,2,3,2,1,. L ALT, R ALT, BATT VOLTS and back down again?

You need a script that does it for you. Isn't there one in the download? Aren't the "and others to move up and down cyclic." doing what you want? Don't you have a ready made profile that you can grab that action from and pull it onto your SD Plus?

It doesn't matter what Action you use on the StreamDeck, they all work the same way. It ultimately depends on what you want, do you need a visual feedback on the SD Action itself or not? Visuals means, creating the appropriate graphics, finding the correct feedback variable(s) and deciding on an Action that displays them. A three state switch would probably be implemented either as a MultiGauge Action or a SliderGauge Action.

What aircraft is this and what switch exactly? They are all different.

Edited by Lorby_SI

LORBY-SI

Share this post


Link to post
Share on other sites

Hello again. I have confused things slightly when I used the word 'code'. I always find it diffficult to put into words what I mean. I do have a profile that I have downloaded. It is for the Cessna 414 from Flysimware, and I am trying to activate the AMPs switch which then displays a reading on a volt meter beside it. I don't want a visual feedback in the SD+, I am happy to simply press a button or use a rotary to move the switch up and down the three settings. I am using your 'Script group-scriptname' option that you told me about a few days ago.

Here is the script for the 'voltammeter_up_cyclic'   1 (L:VOLTAMMETER_KNOB, Bool) + 4 % (>L:VOLTAMMETER_KNOB, Bool)  

The Script group is C414 and the script name is voltammeter_up_cyclic

I enter that into the Key Down event using K:

I'll try again using the actions you suggest.

Regards...Kenny.

Share this post


Link to post
Share on other sites
15 minutes ago, kenny584 said:

The Script group is C414 and the script name is voltammeter_up_cyclic

I enter that into the Key Down event using K:

You probably have a typo in there, because that is how it is supposed to work. Easiest test is with the "Event" Action. 

Be mindful that this is case sensitive and that there cannot even be a surplus space character in there. You have to type it in precisely how it is named in AAO. Don't forget to supply an "event value". Use "1" if nothing specific is required, but don't leave that box empty.
If the names are as you say, the call would be
"K:" and in the textbox "C414-voltammeter_up_cyclic" event value "1"

The way that I read it this will only cycle in one direction though, not "up and down" like you wrote. The script would need an iseq command or something.

 

Edited by Lorby_SI

LORBY-SI

Share this post


Link to post
Share on other sites

Alternatively:

Use type "S:" on the StreamDeck Key Down
Copy the entire script code into the box "1 (L:VOLTAMMETER_KNOB, Bool) + 4 % (>L:VOLTAMMETER_KNOB, Bool)"
Supply the event value "1"

When you copy code or script names from a web page like this one, make sure that there are no hidden characters copied with it. I always paste the code into Notepad++ first, then copy and paste it from there.


LORBY-SI

Share this post


Link to post
Share on other sites

Btw. to copy script names correctly, use this trick:

Start AAO (no need to connect it)
Go to "Scripting->Edit RPN Scripts"
Click on "Insert sim event":
Now, in the treelist, find the script that you want to call, then left-click -> right-click on its name in the list.
This will copy the proper script name, including the group, into the Windows clipboard, and you can insert it on the StreamDeck action using Ctrl&V

Edited by Lorby_SI

LORBY-SI

Share this post


Link to post
Share on other sites

Finally, did you download the Cessna 414 Streamdeck profile made by Chris_PU_A320 from flightsim.to? That one should have all the actions that you need.

Edited by Lorby_SI

LORBY-SI

Share this post


Link to post
Share on other sites

Hi there, thanks so much for taking the time to look into this for me. I'm not aware of a typo, but we never are until something doesn't work. I'll double check. There are eight scripts for the voltammeter. I just used one as an example. There are 'down, down_cyclic, up, up_cyclic, batt, left_alt, right_alt, and volt. all preceded by 'voltammeter_'

I'll double check them all again, they must work, it will be my lack of knowledge I'm sure. The script I am using is the one by APE42. I have now downloaded the one you suggested by Chris_PU_A320

Thanks again...Kenny.

Oh Gosh. It is working now, using the up_cyclic script. I used the Event tree as you suggested and it simply worked!! Happy days. You are a star. I'll do the down_cyclic one also. In fact the  up_cyclic goes back on its own after another press of the button, even simpler.

Edited by kenny584

Share this post


Link to post
Share on other sites

Are you familiar with my LorbyStreamDeckEditor app?

In the Elgato software you can install profiles that were made of the StreamDeckXL (or any other type), regardless of what hardware you have yourself. But you won't be able to access all the actions, because the GUI is limited to what fits on your device.
But you will see them all full size in my editor app, and you can for example drag/copy actions from the XL profiles onto the profiles of your "Plus". That way you can utilize any SD action that has been made for any device.

Edited by Lorby_SI

LORBY-SI

Share this post


Link to post
Share on other sites

Yes, I have it installed and have tried it a few times. However, I must be doing something incorrectly, as I am unable to drag and drop from another profile into my ones. I am also puzzled as to why in the screenshots, the profiles have actual names, whereas in my editor, they are all a long series of numbers.

I'll have another read of the manual to figure out what I am doing incorrectly.

 

Share this post


Link to post
Share on other sites
31 minutes ago, kenny584 said:

whereas in my editor, they are all a long series of numbers.

That's what it is since Elgato released StreamDeck V6. It is no longer possible to do certain things (like creating new empty profiles externally) because Elgato decided to encrypt parts of the data. The editor can now only work with what is already there.

31 minutes ago, kenny584 said:

I am unable to drag and drop from another profile into my ones

?? please specify in detail what "unable" means. Can't pull them over with the mouse? Can't apply, can't save? What do you mean?

Edited by Lorby_SI

LORBY-SI

Share this post


Link to post
Share on other sites

Whatever I was doing wrongly, seems to have sorted itself out now. I suspect that previously I had not been running it in administrator mode. I have selected that option now in the properties section and the Profile Editor is working now. I'll go for a long walk to clear my head now. You have been so patient with me. Thank you.

Regards...Kenny.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...