View Full Version : What a great looking tool, I'm looking forward to playing with it

06-06-2012, 03:20 PM

I started the day trying to figure out how I would build a motion platform to interface with FSX only to figure out it would be immensely expensive to get all the high power pack changes I would need for 6DOF. Scaling down the project size a bit I figured I should do something with what I already have. I happen to have lying around several arduino boards, servos, some switches, and some other stuff, and when I found this site I was really excited since they now have an easy way of using this with FSX (or rather prepar3D). Already have experience with arduino, doing some Lego train automation and also some home automation. Perhaps I should combine this and let my office door control the door of the aircraft :-).

I am not so much into doing all the gauges since I have trackIR, and unlike knowing where to look in the cockpit for the relevant information. However, using the mouse to switch all the switches is a real pain. I am therefore planning to use this system to build a set of physical switches and levers to control the basic functionality I need. I haven't exactly identified what this should be yet, but I am thinking the basic switches for the electric and hydraulic systems, parking brake, and some autopilot controls. I guess that defines rotary controls to deal with heading and altitude input.

Trouble is, is very neat to move things in the real world, so I am toying with the idea of building a model aeroplane which will be controlled by three motors for full freedom and all the rotational axis. I could then use this system to always position of playing in the same attitude as the simulator plane. Flaps position display (using a server), and some gear leds and stuff could also be fun.

The problem we have installed it is how to mount all the switches in some kind of panel. How do people do this? I fly lots of different aircraft so doesn't have to resemble any specific system, but there are certain patterns that recur between aeroplanes, i.e. an electrical panel, autopilot panel, radio panel/stack, et cetera.

Finally, a brief to read through the forum without getting a real sense of what people are using this for. For instance, how is the setup for the developer of the application? What kinds of input and output are you guys using, and how does the hardware end look?

I'm really looking forward to starting to play with this, and I will surely report back when/if I get anything working.

06-06-2012, 04:36 PM
I've been a commercial pilot on the GA side of things, and I can tell you that I never flew two airplanes with the same exact cockpit layout. You could make a generic cockpit for GA and it would NOT be incorrect.
As far as your other questions, all the information is in front of you. Download Jims beginner starter pack, do the tutorials, and then start doing your own stuff. You'll never really know until you dive into it!
Model airplane to display what the sim is doing. That sounds really neat but in the end what purpose does it serve? You are correct, you want rotary encoders, or pulse switches for anything that requires a dial that rotates without stops.
You should get to know the very basics of electrical engineering, just the very basics, at least know how to wire up a switch, what a diode is, what a resistor does, etc.
This is a lot of work and is a hobby for most of us, so we don't mind spending many hours doing this and learning along the way.

06-09-2012, 06:06 AM
Just a short update. I have done some searching and reading, and I figure that the best option was actually to use lua with fsuipc to communicate with my arduino. I'm not saying anything bad about link2fs, but it simply wasn't versatile enough to allow me to do what I wanted.

I have now successfully weighed up a hardware switch to control the parking brake in the simulator with code to automatically ensure that the simulator and a switch is always in sync. This involves capturing events from the simulator that concerned the parking brake state and checking whether this is the same as the state of the hardware switch. If this is not the case, the hardware switch state is sent to the simulator to reaffirm the setting. I have made a post under the welcome forum that details this, but it is currently awaiting moderation.

AK Mongo
06-09-2012, 02:07 PM

To answer your first post, I am using simple HID cards to make toggle switches work.(BUO836 and Desktop Aviator cards). i don't have the problem with switches being out of sync, as I always start filghts "cold and dark" and end them by shutting everything down to that state.

I fly all GA flights though so my switches are much less complicated than your average airliner.

I am still trying to find an ideal solution for the radio stack rotaries. The buo836 card will handle encoders, but require some fancy Lua work to make function correctly. WJH308 just posted a topic yesterday about getting them to work well with Arduino, that I will be trying when I get some time to play with it.

I really like your idea of using fsuipc and Lua. It will save JimNZ a great deal of work because all the work of making variables available for use has been done by Pete Dowson. I don't like the idea of having to learn LUA... but a man has to do what a man has to do.


06-09-2012, 02:22 PM

Thanks for your reply. See action managed to have every switch in the correct position, even when you switch between different aircraft? To me that sounds like a headache which is why I want to make a solution we don't have to think about it :-)

There are some pretty neat libraries for arduino to handle rotaries, even multiple rotaries using interrupts. I'm planning to connect five rotaries, I think, for the autopilot and radio dials.

As for Lua, it is not a very complex scripting language, and if you have enough programming experience to deal with the arduino, then doing the scripting is well is hardly a challenge ;-)

Jim NZ
06-09-2012, 03:59 PM
Great post ,, another option which is marvelous.

Neat stuff and thanks ,, Jim