Jump to content
The simFlight Network Forums

Introducing Pilot's Deck, a StreamDeck Plugin


Fragtality

Recommended Posts

Introduction
PilotsDeck is a Plugin for Elegato's StreamDeck with the Ability to trigger Cockpit-Controls in different Ways and especially reading & displaying a Control's State on the StreamDeck as Text, Image or even Bar/Arc. It is lean & mean, flexible, completely Open-Source and Free-to-Use. It does not do any fancy Stuff like a PFD - it does exactly what is needed to support smooth Flight Operations 😎

StreamDeck-wise it behaves like any other StreamDeck Plugin: it runs alongside other Plugins and you can Drag, Drop, Copy, Paste the Actions like any other Action in the StreamDeck Software between your Folders, Pages or even different StreamDecks. The Action Configuration is done through the standard "Property Inspector" of the StreamDeck UI and it is saved in the StreamDeck Profile. You can create, export and share Profiles with the Plugin's Actions to share their Configuration.
It can also switch StreamDeck Profiles based on the current Aircraft loaded (which is a bit tricky since not intended by the StreamDeck Software).
The Plugin supports different StreamDeck Models: Mini, Standard/15-Key, XL, Mobile and Plus. Other Models might work, but an indented Support for Non-Display Models is not planned. The Plugin runs only on Windows. There no Plans for Linux or macOS Support (the first is not supported by StreamDeck at all, both do not run or support all Sims and some essential .NET Libraries are only available on Windows).

Simulator-wise it supports all major Platforms on Windows - MS Flight Simulator, X-Plane and Prepar3D. For MS Platforms it connects through FSUIPC to the Simulator, for X-Plane it connects directly via UDP Sockets. Either way it will connect automatically as soon as a Simulator is running. All Variables and Commands these Connections allow are usable with the Plugin. You can can directly connect to another Sim without reconfiguring anything.
Not all Variables and Commands require a registered Version of FSUIPC, but a registered (bought) Copy of FSUIPC is recommended to use the full Potential. If you only fly in X-Plane, FSUIPC is not needed at all.

It is designed for advanced Sim-Users which "know how to do Stuff": it does not make any unnecessary complicated Stuff, but doesn't have Features allowing to do anything without knowing anything 😅 If you know how to read Control-States for your Plane and how to trigger these Controls, you can quickly define an Action for that on the StreamDeck. If you don't: be eager to read & learn. 😉 I'll try to give some Background in the Readme, but you have to take it from there!

Predefined Profiles/Integrations are available for FSLabs A320X, Fenix A320, ToLiss A321, FlyByWire A32NX and QualityWings 787 - which are maintained by myself. But there are also User-Contributions for MadDog MD-82, PMDG 747-8 (P3D) and PMDG 737-700 (MSFS). All Profiles are for private/own Usage only - don't reupload or share them elsewhere.

Note: PilotsDeck is 100% free and Open-Source. The Software and the Developer do not have any Affiliation to Flight Panels. Buying from Flight Panels does not support my Work in any Way.
Creating own Profiles is something anyone (knowing how a Plane can be interfaced) can do!

 

Supported Simulator Versions

  • X-Plane 12 / 11 / <=10
    • Requirement: None - does not use XUIPC
  • Flight Simulator 2020 / X / 2004
    • Requirement: FSUIPC 7 & MobiFlight WASM / FSUIPC 4 / FSUIPC 3
  • Prepar3D v5 / v4 / v1-3
    • Requirement: FSUIPC 6 / 5 / 4

Supported is understood as "technical and basically supported by the Connection Method". Support in Terms of ensured Compatibility, Fixing Issues and giving Support exists only for the latest Version of the three Major Simulators: X-Plane 12, MSFS2020, P3D v5. I'm happy if it works for older Versions, but I won't make any Effort for them. It is time to go back to the Future! 😅
And yes: the latest Version for Prepar3D is still considered v5, since v6 was just DOA with nearly every Addon-Dev announcing to not support it.

 

Supported Sim-Commands & -Variables
Here a quick Overview of what you can send to the Simulator ("Command") or from what you can read Values from the Simulator ("Variable"). One of the Things which make the Plugin flexible: Variables can also be used as Commands. For Example to move a Cockpit-Control by writing a different Value to a Variable.
How Commands and Variables are configured and the different Options how they can be executed is described under 2.1 - Defining Commands & Variables.

  • MACRO | Command | MSFS*, P3D, FSX
    • Execute any Macro known to FSUIPC
  • SCRIPT | Command | MSFS, P3D, FSX
    • Run any Lua-Code known to FSUIPC
  • CONTROL | Command | MSFS, P3D, FSX, FS9
    • Send any SimEvent defined by its numerical ID (also known as FS-Controls, Control-Codes. Numerical Variant of a K-Variable/K-Event)
  • LVAR | Command & Variable | MSFS, P3D, FSX
    • Read from / Write to any L-Var ("Local Variable")
  • OFFSET | Command & Variable | MSFS, P3D, FSX, FS9
    • Read from / Write to any FSUIPC Offset
  • VJOY | Command | MSFS, P3D, FSX
    • Toggle/Clear/Set a Button of a virtual Joystick from *FSUIPC*
  • VJOYDRV | Command | ALL
    • Toggle/Clear/Set a Button of a virtual Joystick from the known *vJoy Device Driver* (if installed, not required)
  • HVAR | Command | MSFS
    • Activate any H-Variable in the Simulator
  • CALCULATOR | Command | MSFS
    • Run any Calculator/Gauge Code in the Simulator - either direct RPN Code or as Template for Increasing/Decreasing L-Vars or triggering K-Vars
  • XPCMD | Command | XP
    • Send any Command known to X-Plane (as command_once)
  • XPWREF | Command & Variable | XP
    • Read from / Write to any X-Plane DataRef
  • AVAR | Command & Variable | MSFS
    • Read from / Write to any Simulation Variable (also known as A-Var)

* = MSFS does not support Mouse-Macros
!! Please mind that the Command Types Script, Macro, Lvar and vJoy can only work with a registered Version of FSUIPC!
!! Both vJoy Command Types are independent of each other and are two different Things! "VJOY" can only be assigned within FSUIPC (and not in the Simulator). The "VJOYDRV" can be assigned by anything which understands a Joystick Button (Simulator, FSUIPC, Addons, ...).

 

Available StreamDeck Actions
All Actions work on the Keypads (the normal/square StreamDeck Buttons). The Dial/Touchpad (aka Encoder) on the SD+ is only supported by some Actions (the ones which make the most Sense).
On Keypads you can assign two different Commands, based on how long you hold it: A Short/Normal and Long Press (>= 600ms). Only one of the available Actions can be put in StreamDeck Multi-Actions.
On Encoders you can assign five different Commands for each Interaction: Left Turn, Right Turn, Touch Tap and a Short & Long Press on the Dial. The Actions can be put in StreamDeck Encoder-Stacks, but will then lose their Short/Long Press Function.
How these Actions can be configured and customized is described under 2.3 - Action specific Options.

  • Display Value (Keypad)
    • Display a Sim Variable as Number or Text (display "ON" instead of "1"). You can scale/round/format the Value as needed and customize the Font-Settings. Only for Display.
  • Display Value with Switch (Keypad / Encoder)
    • Like before, but this Action also send Commands.
  • Dynamic Button (Keypad)
    • This Action dynamically changes the displayed Image based on a Variable (in Addition to sending Commands). Different Values trigger different Images.
  • Korry Button (Keypad)
    • Intended for Korry-Switches in the Cockpit: the Action displays two "Sub-Images" independently of each other. They are shown/hidden based on their own Variable, but will not change the Image based on the Value. Can be adapted to other Use-Cases.
  • COM Radio (Keypad / Encoder)
    • Intended for Com Frequencies: the Action shows two different Variables which can be independently scaled/rounded/formatted but share the same Font-Settings. Can be adapted to other Use-Cases.
  • Display Gauge (Keypad / Encoder)
    • This Actions renders the Value dynamically on a Bar or Arc. Size, Color, Position and Font-Settings can be tweaked. It can optionally send Commands.
  • Display Gauge (Dual) (Keypad)
    • As before, but it renders two Values dynamically on the same Bar or Arc.
  • Profile Switcher (Keypad)
    • This not a "real" Action like the others, it is only there to map Profiles used for Switching.

 

Installation & Requirements
The best Way to Install and Update the Plugin is via the Installer: Download, Execute and click Install! It will check the Requirements, informs & links what it missing and installs the Plugin in the correct Location if the Requirements are met (the StreamDeck Software will be automatically stopped).
It is highly likely that you need to Unblock/Exclude the Installer & Plugin from BitDefender and other AV-/Security-Software. It's the number one Reason for "the Plugin is not working"-Issues.
If it still does not work right or at all, please check 3.3 - Troubleshooting.
The Requirements for the Plugin to run:

  • Windows 10 or 11 (updated)
  • StreamDeck Software v6
  • .NET 7 x64 Runtime (.NET Runtime and .NET Desktop Runtime) installed & updated
  • IF used for MSFS/P3D/FSX: The latest Release of the FSUIPC Version specific to your Simulator (e.g. FSUIPC 7 for MSFS2020)
  • IF used for MSFS: The latest Release of the WASM-Module from MobiFlight installed in your Community-Folder
  • Optional: If you want to use VJOYDRV Commands you need Version v2.2.1.1 for Windows 10 and Version 2.1.9.1 for Windows 11. It is not checked by the Installer (since it is not a Requirement for the Plugin).


The full README is on GitHub - please read it to understand how you configure Actions. If you still have Problems or Questions, feel free to contact me on any Platform/Forum 🙂

Here Example Images of what it can look like:
Example01.png?raw=true

image.jpeg.313e932d8ce26ff0f400e527738a0260.jpeg

image.jpeg.788c89c3f8e6cf006c0d3351d85413f3.jpeg

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...
  • 3 months later...

*Version-bump* 🙂

The Plugin was ported to .NET 6 and x64 only. Be sure to read the Requirements and the Upgrade Procedure in the Readme! (It is NOT just dropping it in)

The Plugin now uses the WASM/WAPI Module from FSUIPC7 on MSFS2020. With that:
- The Lvar Access is now faster and more reliable (not reporting the last Lvar's Value for unknown/inaccessible Lvars)
- Hvars are also available as an additional Action-/Command-Type
- CalculatorCode can be now directly be run from the StreamDeck as Action-/Command-Type (can't really imagine a Use-Case for that, but it was possible so why not^^)
This only affects / is only available with MSFS2020 / FSUIPC7. 

Link to comment
Share on other sites

  • 3 months later...

*Version-bump*

Version 0.7.3 Released!

MSFS SU10 Compatibility:
- Compiled against FSUIPC 7.3.9h Beta (available here in the Forum)

X-Plane Support:
- The Plugin now connects directly to X-Plane via WebSocket
- DataRefs can directly be entered (Commands, Value Access for read/write) 
- Profile Switching is supported based on the Livery Path

Comparisons:
- Value Mappings now support multiple Comparisons (greater/lesser) and can be mixed with discrete Mappings (equality)
- Values used for Image display can also be expressed as a comparison, e.g. ">=0.3"

Fenix PilotsDeck Integration:
- Added more Switches & Buttons
- Updated to new Icons (Black/Round)
- GSX Integration
- Updated for SU10

  • Thanks 1
Link to comment
Share on other sites

Hey @Fragtality, okay i try to explain what I need:

f.e. the EGT (engine exhaust gas temperature) for my cessna profile. I find a value for that in the manuel of FSUIPC: 0x3B70 - General engine 1 EGT in degrees Rankine, as a double (FLOAT64). Convert to Fahrenheit by Rankine – 459.67. FS default gauges show Centigrade.

I have no option to correct the read value. I would like to subtract 459.67 from that. I can only manipulate the value by the scalar:

image.png.414e8e9f331d776cacc84b95093fa207.png 

I would like an option like this to convert the value in the right way.

I have a similar problem with the N1 value on the Fenix. I cannot correct the values.

 

---

And I dont understand the LVAR logic: I created a dynamic button for the nav lights for the cessna 172. As action address: LIGHTING_NAV_0 (as read by FSUIPC). Also as Control Status Value: LIGHTING_NAV_0. When I press the light switch in the cockpit, the value is read back correctly. The image is changing. When I press the button on the stream deck, the value also seems to change but the switch in the cockpit does not change. What do i wrong?

Edited by filldasbill
Link to comment
Share on other sites

2 hours ago, filldasbill said:

And I dont understand the LVAR logic: I created a dynamic button for the nav lights for the cessna 172. As action address: LIGHTING_NAV_0 (as read by FSUIPC). Also as Control Status Value: LIGHTING_NAV_0. When I press the light switch in the cockpit, the value is read back correctly. The image is changing. When I press the button on the stream deck, the value also seems to change but the switch in the cockpit does not change. What do i wrong?

You're assuming that manipulating Cockpit Controls means always "writing to LVars" - but that assumption is wrong. For some Planes LVars (or Offsets for that matter) are only there to read the State of a Control, but not manipulating it (if existing at all ...). Instead these Planes use standard (or custom) Control Codes.

Sounds like you have found the right LVar to read from, but not the way to manipulate the Control. What about the standard Control for that: 66379 (TOGGLE_NAV_LIGHTS)? Maybe you also read my Answer on avsim again (Nav Lights should have not been an Issue if you understood the Beacon Light Example) 😉 

 

2 hours ago, filldasbill said:

f.e. the EGT (engine exhaust gas temperature) for my cessna profile. I find a value for that in the manuel of FSUIPC: 0x3B70 - General engine 1 EGT in degrees Rankine, as a double (FLOAT64). Convert to Fahrenheit by Rankine – 459.67. FS default gauges show Centigrade.

I have no option to correct the read value. I would like to subtract 459.67 from that. I can only manipulate the value by the scalar:

image.png.414e8e9f331d776cacc84b95093fa207.png 

I would like an option like this to convert the value in the right way.

I have a similar problem with the N1 value on the Fenix. I cannot correct the values.

Nope, something like that wont be added. For Use-Cases like this I described the "Lua Values" Mechanic. You need to have a Script which (continuously) reads the Offset, does whatever Calculation/Conversion/Logic is needed and writes the Result back to another Offset. Then you can let the Plugin read from that Offset.

Link to comment
Share on other sites

The Problem: what if an absolute value would be needed? Or a logarithmic calculation? What if some logic would be needed to determine the Value? What if some calculations on two or more Offset/Lvars are needed? The List can grow endlessly and still for all that there is a Solution.

It really only 3 Lines of Code that would need to be added to the "template" Script provided with the Plugin (PilotsDeck.lua):

local eng1egt = ipc.readDBL(0x3B70)
eng1egt = eng1egt - 459.67
ipc.writeDBL(0x66CB, eng1egt)

 

  • Like 1
Link to comment
Share on other sites

Hi @Fragtality,

thanks for the nice plugin! Unfortunately, the dropdowns do not work for "Action Types".

I have already done everything as described in the readme. Also made an exception in the Windows Defender on the whole Streamdeck folder. No Log is created by the plugin, so I can't attach it. What else can I try?

Plugin version 0.7.6 -FSUIPC 7.3.10 registered version - MSFS SU10 - Win10 - Streamdeck is installed on C and FSUIPC on E:/.

StreamDeck0.log

Link to comment
Share on other sites

3 hours ago, eagle11 said:

I have already done everything as described in the readme. Also made an exception in the Windows Defender on the whole Streamdeck folder. No Log is created by the plugin, so I can't attach it. What else can I try?

Did you also try that Unblock Command described in the Readme? Both .NET 6 Runtimes are installed?

Please open a Command/Powershell Window and go to the Plugin Directory (where the PilotsDeck.exe is located). Start the Executable on the Command Line.
What does it say / show there?

Link to comment
Share on other sites

  • 2 months later...

Hi Danielle (Fragtality), I am using FSUIPC since more then 10 years and want to use now your StreamDeck Plugin.

But it's not running. Here are my findings:

Version of Plugin = 0.7.6.0

Version of StreamDeck  =  6.0.2.17735

Excerpt of the LogFile with error message:

2022-12-21 12:05:45.702 [FTL] PLUGIN CRASHED

2022-12-21 12:05:45.703 [FTL] StreamDeckLib

2022-12-21 12:05:45.703 [FTL] commandLineArgs must be the commandline args that the StreamDeck application calls this program with.

2022-12-21 12:05:45.709 [FTL]    at StreamDeckLib.ConnectionManager.Initialize(String[] commandLineArgs, ILoggerFactory loggerFactory, IActionController actionController, IStreamDeckProxy streamDeckProxy)

at PilotsDeck.Plugin.Main(String[] args)

I checked all what you mentioned in your installation and troubleshoot manual.

My System is WIN10 PRO with 64GB RAM   and P3D and MSFS

The Log Files are attached

 

PilotsDeck20221221.zip StreamDeck0.zip

Link to comment
Share on other sites

  • 3 weeks later...

*Version Bump* 

Version 0.7.7 Released:

- Toggle Switch Option for Control and XP-Commands added (toggle a Switch with two different Controls/Commands)
- XP-Commands can now be chained
- HVars can now be chained
- Updated Libraries (full SU11 Compatibility)
- Now compiled for .NET 7 (Update your Runtime!)
- Improved Sim-Connection/-State Handling
- Fixed Bug with XP-DataRefs where they would not update when a DataRef is used multiple times on one Profile/Folder
- Fixed Bug with Profile Switching with XP12
- Fixed Bug with Comparisons/Value Matching
- Fixed Bug where Actions would stay in Error State

 

  • Thanks 1
Link to comment
Share on other sites

  • 1 month later...

*Version Bump*

The Release with a big Plus 😄

Version 0.7.8:

  • Added Support for the SD Plus!
    • The Actions "Display Value with Switch", "COM Radio" and "Display Gauge" are also available on the Encoders
    • You can set separate Commands for Left, Right and TouchTap (no Hold or Long-Touch)
    • The Normal/Long Press (called Main and Second Command now) are mapped to pressing the Dial
    • Besides having more Commands to set, they behave the same as their KeyPad Variant
  • Simple "Value Manipulations" possible on all Variables used as Command
    • Increasing/Decreasing by a defined Step with an optional Limit
    • Sending a Sequence of Values
    • The Calculator Command now understands two Templates for increasing/decreasing L-Vars and triggering K-Vars (SimEvents) without the Need to write full RPN Code. Especially the Template for inc/decreasing is very useful on the Encoders for Left & Right (on L-Var based Aircrafts. Else prefer Controls/K-Vars).
  • "Toggle Switch" now available on all Actions and all non-Variable based Commands (except vJoys)
    • A separate Variable to Monitor can now be configured
    • But still only available for the Main Command
  • Reset Value renamed to "Reset Switch." Available on all Variable-based Commands (except vJoys) and all Actions 
  • A new Option called "Hold Switch" available on all Commands except vJoys. Because it will act like a vJoy! With that Option but you can directly configure the Commands (or Values) for down/pressed and up/unpressed in the StreamDeck UI!
  • The Dynamic Button now allows to define an "Image Map". It works roughly like the Value-to-Text Mappings: You can map Values to Images, as many as you like (so more than 3 States are possible now!)
  • The Format options now also allows to add leading Zeros
  • The Plugin now has an Installer as the recommended Way to install it. It will check the basic Requirements and informs which are missing.
  • The Plugin now uses the WASM Module from Mobi-Flight (Requirement now)
    • Situations where new L-Vars could not be read because FSUIPC ran into its Limit are gone now!
    • That also enables the Plugin to read any A-Var (SimVar) -they can be accessed without the Need for the myOffsets File. And generally accessing them by Name instead of an arbitrary Hex-Number - but you have to get the Units right, though.
    • FSUIPC is still the main Connection Method (and thus Requirement) for anything but X-Plane.
    • The Plugin is just using something else in the Background for LVars, HVars and Calculator. Nothing to reconfigure in your Profiles.
  • The Plugin now includes ImportProfiles Tool to make it a little bit easier to use your own/downloaded Profiles for Switching
    • It asks for the DeckType and imports every Profile from the \Profiles Subfolder to the Plugin manifest
    • The selections are saved on each run. It will only ask for new Profiles (handy on Plugin Updates)
    • The old empty and preconfigured Profiles Whiskey, X-Ray and so on are not needed anymore. They can be deleted if never used.
  • Some Improvements in the Property Inspector
    • Added a small Image Preview in the Property Inspector for every Image Selection
    • Renamed and Reordered some Options so that there is a bit more commonality, e.g. using the Terms Command and Variable throughout 
    • Tried to improve the Appearance a little bit, but my CSS-Skills are just INOP ^^
  • The Default Image drawn when not connected is now closer to the current Configuration so that changes can be better previewed. A Value of 0 is assumed.
  • The Readme was completely overhauled ... which is hopefully an Improvement!
  • Much Rewrites/Refactors in the Background and Bugs I found on the Way ;D
  • Airbus Profiles/Integrations with the new Features: FSLabs, Fenix, ToLiss. The FBW too, within the possibilities given ...
  • Thanks 1
Link to comment
Share on other sites

  • 1 month later...

*Version Bump*

Just a little Maintenance
Name User GIF

Version 0.7.9

  • L-Var Names can now contain Colons : and Dots .
    (For Names like A32NX_ENGINE_N1:1 or A320.audio.1.tone)
  • Version-Checks for the Installer improved, i.e. does not fail with StreamDeck SW 6.1
  • Requirements increased: FSUIPC 7.3.19, NET 7.0.4
  • Libraries updated
  • Like 1
  • Thanks 1
Link to comment
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
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.