1: a gentle start

let’s configure FlightGear’s output
So, lets look at the communication options FG lays in our hands. All we’ll have to do is startup FlightGear with the ‘generic’- flag (or adjust it through some gui). The flag should look in general something like this:

--generic= [file|socket|serial],

Note: I’ll exclusively talk about a socket- connection.

as you can see we’ll have to specify seven params
1) I/O type: for our example we need to talk to a socket.
2) Direction
3) How often send/fetch information?
4) Target- machine
5) Port
6) Network- protocol
7) A .xml-file (see below)

let’s look on a example
I’ve two machines in a LAN. The machine running FlightGear has the IP To talk to a second machine, which has the IP, we need to pass FlightGear following argument:


what does this mean in detail?
The trailing six parameters tell FlightGear to try to connect to a socket which lives on the machine with the IP-Address @ port 5555. The protocol used is tcp. Outgoing information is send every 1000 ms – pretty self-explanantory!
The last Parameter is the name of a .xml-file located in the
/Protocols folder of your FlightGear- install.
FlightGear ships with some protocol-specs. To build one of your own, a good try is to open an existing one and modify it, so that it fits your needs. Again, it’s kind of self-explanantory, but look by yourself:

Mainly, we have a few chunks here – each is representing a value that we’re interested in. E.g. look at the ‘Incoming Msg.’-Chunk. We have to specify of what type and format it is and were it comes from. The factor node of the speed-chunk is optional.
To get a list of available nodes (chunks), simply run

fgfs --httpd=5555

which starts FlightGear and a Http-Deamon @ port 5555. Now you can point your favourite browser to

et voilà: Information at your fingertips.

isn’t that hard, isn’t it?
FlightGear’s documentation file README.Protocol (located in the /Protocols folder) may give you some additional information.

That’s all for now. Keep on reading to see what happens ‘on the other side’…

%d bloggers like this: