On 6/26/07, Maria Vega Ramirez <[EMAIL PROTECTED]> wrote:

Hi,
I´m developing in Visual Basic a monitor screen for my laptop using my own
Head Up Display, turn coordinator, speed display...
I would like to connect my laptop to a PC where I am running Flight Gear
through a socket and monitor the aircraft attitude in my own instruments but
i don´t know which is the protocol neither which is the byte order of the PC
sending frame. Could anyone help me or tell me where can i get the
information?


Hi Maria,

I can tell you that a VB interface to FlightGear is possible.  I puzzled it
out a couple summers ago (but it was for a paying contract so I can't relay
any actual VB code.)  There is a variety of ways you could approach this
problem.  What I did was have flightgear output the FGNetFDM structure as a
sequence of UDP packets.  The structure is defined in
src/Network/net_fdm.hxx.  This particular structure (not the whole project)
is public domain so you can do whatever you want with the structure
definition.

If I recall correctly, I ended up having to google around quite a bit to
figure out how to accept udp network packets in VB, and then I couldn't find
anything directly analogous to a C structure in VB, so I think I ended up
writting some pretty low level looking VB code to extract the byte
sequences, order them correctly, and convert them to VB numbers.

I did a lot of googling one day and I think I must have found an example of
something similar that I worked from.

In the end, it was all kind of tricky, working below all the standard VB
structures, but I did get it to work, so I know it is possible.

You might also take a look at the "generic" output protocol which should be
able to output data in "ascii" format which is less efficient and possibly
less precise, but should be much easier to deal with on the VB side.

Regards,

Curt.
--
Curtis Olson - University of Minnesota - FlightGear Project
http://baron.flightgear.org/~curt/  http://www.humanfirst.umn.edu/
http://www.flightgear.org
Unique text: 2f585eeea02e2c79d7b1d8c4963bae2d
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Flightgear-users mailing list
Flightgear-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-users

Reply via email to