Virtual Cockpit / Remote Cockpit

Hi,

I’m developing the framework for a virtual cockpit, using C#/.Net, that can be displayed on another PC (or another monitor if you wish).

It is intended for FS2020 and allows others to design cockpit layouts for any aircraft.

The aim is to offload the graphics for displaying and updating the cockpit instruments to another PC, allowing them to be always visible on another PC or display, freeing up the main display to just display the windows of the aircraft.

This saves you having to jump the camera around the cockpit to look at various dials etc, then revert to your window view to concentrate on flying.

The cockpit dashboard has a background image and allows instruments to be placed almost anywhere on top of it.

Each instrument is a self-contained plugin that informs the virtual cockpit of the different aircraft it can be used with. One instrument can be used for several aircraft.

If a cockpit layout requires a specific type of instrument and there are no customised instruments for that aircraft, a ‘default’ instrument is used.

This approach allows others to develop their own cockpit layout, with their own instruments, each designed to look and behave exactly as the instruments would for the aircraft you’re flying.

You could even design your own layout entirely and keep it static for all aircraft if you want. Say, if you wanted it to look like the Millenium Falcon, maybe the bridge of the Starship Enterprise or be really weird and use a Delorean dashboard from Back to the Future.

The only problem I have is time and the lack of graphics skills.

Although I’ve been a developer for over 30 years, I’m still learning new things almost every day. Today I learned I’m still rubbish at drawing.

I need to research the dashboards for every aircraft, the design of each instrument in that aircraft and build them.

Just putting feelers out there to see if something like this would be of interest to others and maybe see if there’s any graphics designers or developers wanting to build plugins and design layout or instrument background images.

5 Likes

yes, that’s exactly what i would like to have, having the main screen with the external view of the plane and the landscape, and on the other screen having all instruments, even clickable to manage the flight, and avoid to switch between many views …
But… i am not developper, so i can’t help you…
Just i can say that i like th idea :slight_smile:

1 Like

Glad it’s not just something for my own benefit - I’m slowly developing the generic instrument plugins (got Altimeter, Airspeed and Attitude done so far) - I’ll update the post with some screenshots when I get time (the day job keeps getting in the way).

Thanks, nice to hear, i don’t know if i can be of some help, if some tasks can be managed by non developper, through tools quite easy to manage… I have been IT manager for 40 years… but this doesn’t make u a developper expert :slight_smile:
At least i could do some testing ?

1 Like

It’s only running on my network at the moment, as its very early in the development phase. When I’ve added a few more generic instruments and compiled it with a config editor, I’ll let you have a copy to test it.

Currently the server component runs as a console app, the cockpit display looks a bit basic.

I’m also considering how to make the instrument plugins easier to develop, maybe a single plugin that can be configured with an XML file, to produce the required component with the correct images, aspect ratio, animation, simvar variables, aircraft types etc.

A quick update for anyone interested. I have built a generic instrument.

The instrument can be used to produce any panel instrument for display, such as an Altimeter, Airspeed Indicator, Attitude Indicator and so on.

It can be used by non-developers to build their own instruments, as it is completely configured by a text file (currently only uses a JSON file, I may also add an XML file option, if it’s preferred).

The text file is structured to contain basic information about the initial layout of the instrument, such as the instrument type, author, aircraft name(s) it can be used for, background image file to use and others.

It also contains the definition of each item you want animated within the display instrument, such as an image file (or it can draw the image for you, using cartesian co-ordinates).

Animations are updated every time a trigger (e.g. Indicated Airspeed etc) changes value.

Animations can have more than 1 trigger affecting their movements, such as an Altimeter may only need the latest Altitude to change, whereas an Attitude Indicator may change for both Attitude Pitch and Attitude Bank.

Animated images are overlaid onto the background and updated for every change in a trigger value, using graphical animation to smooth the movement. For example, the altimeter needle doesn’t suddenly jump from the last reported altitude to the new altitude, it moves gradually. the speed of movement is based on how much the value has changed, so it appears more natural.

Still under development but testing looks good so far. I built an airspeed indicator in around 10 minutes (I had already created the background image beforehand).

Airspeed_Indicator_on_Textured_Background

Here’s another image showing how instruments are overlaid on a Cockpit display.
Screenshot 2020-11-07 122817

Isn‘t this what Siminnovations airmanager does?

Yes, but not currently for FS2020 and it’s 65 bucks per computer!

Yes Dragonlaird,
it is somehow expensive, but works for FS2020 when using the Beta (which you can test for free at the moment). You have to know some scripting and Simevents, but i guess, you also have to know this, when programming it completely from scratch.

Some gauges work for FS2020 in the beta without tweaking.

Don’t be offended. I think that the software siminnovations offers is worth it’s money. Works well with a touchscreen and the Knobster (which you can also build yourself) and several peripherals like arduino uno and so on… There are plenty auf gauges and frames for G1000 which you can download inside the program.

Feel freee to develop it yourself. I also thought about developing a tool like this, before i saw airmanager, which i really like. But i have tracked this thread and I am really excited to hear news from your project. Please keep going!

1 Like

Hi Cupiii,

No offence taken, I’m always happy to hear comments and opinions from others, even if sometimes I don’t agree. In fact, I welcome it, as that’s often the best way to hear of new ideas, improvements, suggestions, etc.

There is at least 1 other app of a similar nature too, so I know this project isn’t a new concept in its current guise, let me explain my intentions and the plan for it, so you can see why I’m doing this. My aim is to empower others to design and build their own stuff, not just those who can program, but almost anyone, allowing users to tailor their Sim experience as much or as little as they wish.

First I want to simplify creating cockpit layouts and gauges so that anyone can design & build their own, with literally no programming experience. Just a couple of images and some config details (via an easy-to-use application) and it’s ready to go.

Secondly, I want to make it extensible, allowing others to add extra features, such as integration with Arduinos or R-Pi or Saitek or almost anything else you can think of that’s Sim-related. All whilst removing the complexities and intricacies of working with the SimConnect SDK. You want a switch to raise/lower the landing gear? Request it via a much simpler network API and it just works.

Finally, I want to make it cross-platform enabled, allow it to be used via multiple PCs, laptops, tablets (even a phone if you’re masochistic), to permit multiple displays and real-world interactions, all to be displayed or controlled remotely and simply drip-fed to/from the Sim PC.

There should be very little overhead for your main PC, making the server-component of this project lightweight, having (virtually) no impact on the Sim itself, allowing users to design/build a cockpit, with all the bells & whistles of a real cockpit (if they want to go that far), without any additional strain placed on the main PC, in fact, it may even make it more performant by freeing it to simply update your window displays (no need to display a cockpit layout, etc) and provide a near real-life experience as possible.

It’s an ambitious project that’s going to take time and it has to start somewhere, hence why I started talking about displaying remote gauges as a concept.

Does that all start to make sense as to why I’m doing this now? There are rigs out there that can cost upwards of 15,000 to build (more if you pay someone to build it) and yet, with something like this you can build your own and it’s not static, it can auto-switch to become any cockpit you want.

Memo to self: How about a VR interface… If we can overlay the Sim display with the virtual cockpit - Something else to add to the wishlist.

I dont know if im on the right page here, but i have a question concearning virtual cockpit. I like to know is it possible to diconnect them from the airplane than i have outside view.
The thing is i used to fly fs2004 in the panel file i was able to // in front of vc or 2d panels, and it would not show up in the plane, having free view.
This if possible i would like to use in combination with a second pc through fsuipc7/widefs7 registered version and an old program called freefd, which i’ve tested and worked with msfs2020 despite the age of the program.

Best of regards

Hi PHSepp,

This isn’t the right page but I can see why you thought it might be. This thread is discussing a project I’m building, to do exactly what you’re looking for (and hopefully much more), in FS2020.

Sadly I’m not familiar with the apps you’re using, so I can’t really help - Perhaps you could try asking in another area of the forum.

Thanks Dragonlaird for your Quick reply, for sure i wil track this thread, if you need testing to do just let me know.
In the mean time good luck with your project.

1 Like

Latest weekly update.

It’s been a busy week with real work, however I did manage to continue with this project, quite a bit in fact.

The Virtual Cockpit now has an Instrument Editor!!!

Yes, it has a separate application that can be used for creating and editing your own custom cockpit instruments. It may look a little confusing at first as it actually allows you to do quite a lot, but I’ll break it down into simpler chunks to make it easy to follow.

In the main window (in the background) there’s 3 sections:

  • Instrument Details
  • Background
  • Animations
    “Instrument Details” is where you define the simple things about your Instrument, like what it’s for, who created it, which Aircraft it can be used with and the speed you want it to animate.
    “Background” is really simple - just the background image you want your instrument to have - It displays the image so you can verify you selected the right one.
    “Animations” is where it starts to get complicated, it allows you to add animations to update your instrument on various actions.

The Animation window pops up if you want to edit an animation for your Instrument. Here you would define the image or a cartesian plot of a drawing you want to animate (That’s defined in the “What” tab), then you select the trigger or triggers that will control your animation (the “When” tab - visible in the screenshot), such as Sim Variables (Client Requests), a Timer, a Mouse Click, etc.

At the moment, the Editor only works for Client Requests - I’ll add the rest when they’re fully developed.

In the image above the “ATTITUDE INDICATOR PITCH DEGREES” variable (I didn’t name these, they’re defined by the SimConnect SDK) is how we would want to control the Pitch amount of our animation.

In the “How” tab, we define how we want to change our animation, based on the value we received from the trigger. For Pitch, we would move the foreground image up/down, relative to the radians value from FS then we would crop the image in a circle, so it sits nicely in the middle of our background.

When any Client Request value is updated, the animation process applies all animations in the order displayed, using the last received value of the previous Client Requests for animations that don’t rely on the new value.

So, our Attitude Indicator image (below) would first rotate, based on the last value of the Roll Client Request, then it would move up/down based on the Pitch Clint Request and then finally it would be cropped to a circle to sit nicely on top of our background image.

The animation speed I mentioned earlier allows you to control how smooth these changes are when displaying the instrument. It would appear quite jerky if we simply “jumped” our foreground image around, every time we received an new Client Request value change, so the Instrument will move the image gradually, based on the animation speed value you set in the “Instrument Details” section.

The result is a much smoother movement from previous values to new values and looks quite effective in the cockpit display.

Every instrument in the cockpit may have different animation speeds, use different background and foreground images and respond to different triggers, they all work independently from each other an give the look of a cockpit responding to your virtual aircraft movements etc.

So there it is in a nutshell, so far. There’s more being developed but for now, this allows the creation of simple instruments, with a static background image, and one or more items overlaid in the foreground, reacting to real events from the server.

Getting there slowly - I’ll update again when more progress is made.

2 Likes

So I may have gone a bit overboard with the implementation of the first objective I mentioned (allowing people to easily create their own instruments).

Although it does remove much of the complexity of defining the configuration files and applying images etc, it does look a bit confusing at first glance.

Maybe in a future update, I’ll create a timeline-driven approach, asking the user simple questions at each step, then moving on to the next part, to drip-feed the values needed and build the resulting config once they reach the end.

scott-vincent/instrument-panel: An instrument panel for Microsoft Flight Simulator 2020 (github.com)

1 Like

looking very nice. Thanks fir the update.

1 Like

Hi Krok,

Welcome to the community and thanks for posting the link.

I’ll use this reply to comment on your supplied link and include my weekly update, for those following this thread.

That application uses a similar approach to what I’m developing. That variant is written in C++ and (from an initial glance) is intended to display cockpit instruments using a specific layout, using a separate monitor or a remote PC - very similar indeed.

Mine is slightly different in its aims and approach, however.

Written in C# (DotNet / DotNet Core), my intention is to allow the entire cockpit layout (or ultimately, layouts) to be displayed (including the cockpit background) and permit any instrument to be placed in almost any location, based on how they were intended to appear in the real cockpit of the aircraft you’re flying, even able to auto-change the cockpit layout if you switch aircraft in the sim (that can be turned off by the user if they prefer).

It also allows you to design your own cockpit layouts (without code) and your own instruments (again, no coding required).

For those keen on developing their own instruments with code, it allows for that too, loading any assemblies (e.g. DLLs) that inherit the required fields and methods exposed by the Remote Cockpit Instruments Interface (that probably only makes sense to programmers). So basically, others can create their own instruments, using whichever programming language they prefer (C++, C#, etc) and it should be available for use in a cockpit.

Instruments are auto-selected from all the available instruments the cockpit has, both built plugins and user-defined instruments (those created with no code). In the event it cannot find a specific instrument for the current cockpit layout, it will substitute a generic instrument (if one exists).

It has the same approach as the instrument panel you provided the link to, allowing a cockpit to be displayed on a separate monitor or on another PC via the network (mine is intended to allow multiple displays to be useable if the user wants to split their cockpit layout on different monitors). I also tested something this week, it can overlay on the actual FS display so the dashboard is always on-screen, no matter where you look in the cockpit.

It wasn’t designed to do that, it just works that way. There are some limitations to doing that (the mouse and keyboard events are currently captured by the cockpit overlay), I’ll need to investigate if I can pass them on to the FS app itself, although other FS controls (yoke, rudder, switches, etc.) still work fine.

This week I’ve been snowed under with real work, so I’ve not had a chance to make much progress, I’m mostly bug fixing and testing the Instrument Designer, ensuring the user-generated config output can be used by the cockpit without any errors.

Also added 2 animation options to the designer, moving the animation up/down and left/right, based on the trigger value received (e.g. a requested SimVar result from SimConnect).

I still need to code these into the Generic Instrument application, to actually perform the movement but the config file can now be populated.

I also noticed a slight bug in the Generic Instrument code, if multiple animations use the same trigger, resulting in none of those animations working - I’m considering a slight re-write of the approach taken to update all animations at the same time, regardless of which trigger was received, allowing all animations to be applied each time. I’ll need to check if this has any impact on performance.

I’m in the process of adding a “Publish” feature to the designer, that allows you to copy your config and images to the cockpit plugins and images folders, meaning you can simply add your new instrument to the cockpit itself, without the need to manually copy files.

I’m also planning to add a “Test” feature, that will display your plugin and allow it to respond to values you supply, so you can see if it behaves as you expect.

Other than that, the remaining work will involve designing plenty of generic cockpit instruments (via the designer) so you always have plenty of default instruments for any layout you create, and also add some additional cockpit layouts for different aircraft for you to choose from.

Once the above is complete, it should be ready for Beta Testing.

That’s about it for this week, as always, feel free to comment and post, even if you disagree with anything or have any ideas for future enhancements.

Dragonlaird

1 Like

Hi all,

This week’s update from me on progress.

Progress has been slow this week, due to other commitments, and because half-way through the week, I made a decision to remove a feature that I’ve never used and can’t see a use for.

Basically, the Generic Instrument component had 2 options for drawing images, either relative to the displayed size of the instrument, or using fixed, actual positions.

The latter option has never been used and to be honest, I can’t think of any scenario where a static, fixed-sized image would be required, so I have removed it. The consequence of this was to remove a lot of code in several elements of the project (the Instrument Designer, the Generic Instrument plugin, and core classes used throughout the solution).

This means all measurements, such as an Offset position, Centrepoint, Drawing Plot Points, and more are now relative to the size of the instrument. making it much easier to design instruments, as every value is now basically a percentage of the height/width of the displayed instrument.

Apart from that, the Instrument Designer code is now stable enough to be merged with the rest of the main code (master branch).

There’s still a lot of work to do, some of the work outstanding is:

  • Allow Client (cockpit) to transmit values back to the Server (MSFS PC)
  • Remove unused variables from the Server, when a Client disconnects
  • Add code to move a Generic Instrument animation up/down/left/right
  • Display description of a variable in the Instrument Designer (fairly simple)
  • Add new triggers to a Generic Instrument, such as mouse clicks
  • Find a definitive list of all available instrument types
  • Allow generic Instruments to connect to other services (such as fetching maps for GPS)

Having said all that, the basic instruments I have created using the Instrument Designer seem to work very well and animate very smoothly. These are:

  • Altimeter, using 2 needles for 1 & 1000 feet increments
  • Attitude Indicator (need to add Move-Y feature to complete this)
  • Airspeed Indicator

Dragonlaird

This is good work. I can’t wait to test an early version.
Keep going!

I am a fan of Air Manager in this space, but having more choices is always good

1 Like