Author Topic: Extract Telemetry from FSO  (Read 6129 times)

0 Members and 1 Guest are viewing this topic.

Offline coffeesoft

  • 28
  • Bip Bip
Extract Telemetry from FSO
Hi.

I want to ask if is possible and which would be the way to extract the telemetry of the game to build a custom control pannel, i mean, speed, shield, weapons, etc ...

I want to know if with the Lua is possible to do, other guy from the forum, Podoo, he makes a good prototype but if i understood well, this program works like a mirror running on another pc, but is not using the real telemetry of the game.

I want to build a little control pannel from first, may be there are more people interesed, many thanks.

 

Offline MatthTheGeek

  • Captain Obvious
  • 212
  • Frenchie McFrenchface
Re: Extract Telemetry from FSO
You should be able to write stuff in a file, and then read this file from another process, or if this file is on a shared network or something, from a process running on another PC.

Have not actually tested this of course, but that's how I'd start.
People are stupid, therefore anything popular is at best suspicious.

Mod management tools     -     Wiki stuff!     -     Help us help you

666maslo666: Releasing a finished product is not a good thing! It is a modern fad.

SpardaSon21: it seems like you exist in a permanent state of half-joking misanthropy

Axem: when you put it like that, i sound like an insane person

bigchunk1: it's not retarded it's american!
bigchunk1: ...

batwota: steele's maneuvering for the coup de gras
MatthTheGeek: you mispelled grâce
Awaesaar: grace
batwota: oh right :P
Darius: ah!
Darius: yes, i like that
MatthTheGeek: the way you just spelled it it means fat
Awaesaar: +accent I forgot how to keyboard
MatthTheGeek: or grease
Darius: the killing fat!
Axem: jabba does the coup de gras
MatthTheGeek: XD
Axem: bring me solo and a cookie

 
 

Offline m!m

  • 211
Re: Extract Telemetry from FSO
You can also use LuaSocket to do network communication but as far as I know that needs the lua dll in the location where your FSO executable is located to actually work.

 

Offline coffeesoft

  • 28
  • Bip Bip
Re: Extract Telemetry from FSO
The DLL´s are not a problem i think, i want to investigate how to use this data with for example an Arduino, to make some Digital Led display to indicate some values or other similar things.

Would be good to control some relays as well  :)


 

Offline coffeesoft

  • 28
  • Bip Bip
Re: Extract Telemetry from FSO
Now looking on the Script of Podoo, i saw that may be is using LUA Socket as well, inside the code there is this line.

socket=require("socket")

 

Offline Kopachris

  • 28
  • send penguins
    • Steam
    • Twitter
Re: Extract Telemetry from FSO
Interesting idea.  I'd love to have telemetry exported to a file which could be read later with a Python script to make a 3D plot of an object's path throughout a mission.
----
My Bandcamp | Discord: Kopachris#0001 | My GitHub

 
 

Offline coffeesoft

  • 28
  • Bip Bip
Re: Extract Telemetry from FSO
May be we can build together a standard telemetry file with all the data of the game, and after that the users can decide wich kind of hardware or software uses for his project.

The only problem from my side is that i don´t know how to program  :banghead:, but any test are welcome.

 

Offline coffeesoft

  • 28
  • Bip Bip
Re: Extract Telemetry from FSO
The idea is build something like this ...

https://code.google.com/p/arduino-fs/

I like the digital displays for some values of the game ...  :)

 

Offline Echelon9

  • 210
Re: Extract Telemetry from FSO
Did we ever see the Maker Diaspora flight sim developer on these forums?

Presumably they came up with a system of exporting telemetry data out of engine to their control panels and actuators. From the few interviews I saw, they did have more difficulty getting telemetry from FSOpen vs. the prior FlightGear-based system.

I would have assumed they used Lua in some way.

 

Offline coffeesoft

  • 28
  • Bip Bip
Re: Extract Telemetry from FSO
Wuau, nice project, but big for my room  ;), anyway thanks for the info, i didn´t know.
My project is less complex, i want to use an arduino to use some displays, but the pannel inputs may be a keyboard hacked is ok.
For other data i want to use the Script from Frodo, a guy from the forum.

After the control pannel is finished ( someday... ), i will try to build a X-Sim cockpit, to do something similar but with less rotation.
For example a 3 DOF motion platform using X-Sim.

http://www.x-sim.de/forum/portal.php


This software has good features, for example you can use the simple Joystick translations to move the cabinet and use the Force-Feedback effects to shake it when you crash, enemies are shooting you or closer engines.
Also has a plugin-option that can read the OpenGL and DirectX information to use with the cabinet.

The only problem, all the project looks expensive  :( , but step by step....

Here the test that i do with the native virtual simulator of X-Sim ...

« Last Edit: December 01, 2013, 04:57:56 pm by coffeesoft »

 

Offline coffeesoft

  • 28
  • Bip Bip
Re: Extract Telemetry from FSO
These guys are now in www.kickstarter.com, for a not too expensive price, just $50 or more, they send you a
complete instructions to build your own cabinet, that is good.  :D
Many thanks for the info again...

I will contact the staff to know if the code is fully compatible ( or more or less ) with other freespace open mods.

http://www.kickstarter.com/projects/vipersim/the-viper-full-motion-flight-simulator


 

Offline AdmiralRalwood

  • 211
  • The Cthulhu programmer himself!
    • Skype
    • Steam
    • Twitter
Re: Extract Telemetry from FSO
These guys are now in www.kickstarter.com, for a not too expensive price, just $50 or more, they send you a
complete instructions to build your own cabinet, that is good.  :D
You mean they were on kickstarter, back in 2012. You can't back a kickstarter more than a year after it ended...
Ph'nglui mglw'nafh Codethulhu GitHub wgah'nagl fhtagn.

schrödinbug (noun) - a bug that manifests itself in running software after a programmer notices that the code should never have worked in the first place.

When you gaze long into BMPMAN, BMPMAN also gazes into you.

"I am one of the best FREDders on Earth" -General Battuta

<Aesaar> literary criticism is vladimir putin

<MageKing17> "There's probably a reason the code is the way it is" is a very dangerous line of thought. :P
<MageKing17> Because the "reason" often turns out to be "nobody noticed it was wrong".
(the very next day)
<MageKing17> this ****ing code did it to me again
<MageKing17> "That doesn't really make sense to me, but I'll assume it was being done for a reason."
<MageKing17> **** ME
<MageKing17> THE REASON IS PEOPLE ARE STUPID
<MageKing17> ESPECIALLY ME

<MageKing17> God damn, I do not understand how this is breaking.
<MageKing17> Everything points to "this should work fine", and yet it's clearly not working.
<MjnMixael> 2 hours later... "God damn, how did this ever work at all?!"
(...)
<MageKing17> so
<MageKing17> more than two hours
<MageKing17> but once again we have reached the inevitable conclusion
<MageKing17> How did this code ever work in the first place!?

<@The_E> Welcome to OpenGL, where standards compliance is optional, and error reporting inconsistent

<MageKing17> It was all working perfectly until I actually tried it on an actual mission.

<IronWorks> I am useful for FSO stuff again. This is a red-letter day!
* z64555 erases "Thursday" and rewrites it in red ink

<MageKing17> TIL the entire homing code is held up by shoestrings and duct tape, basically.

 
 
 

Offline Echelon9

  • 210
Re: Extract Telemetry from FSO
Their 2013 project was the first to use Diaspora/FS2Open engine.

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
Re: Extract Telemetry from FSO
luasocket is the best way to talk to hardware i think. just use an ethernet enabled dev board, connected through a crossover cable, or a wifi enabled dev board. luacom also works but i think you have to run your packet decoding code in a co-routine, which is how i can talk to my arduino duemilanove (though ive never been able to have freespace talk directly with luacom, but i have been able to socket into loopback port and have an external script relay the data to luacom). thats kind of archaic anyway, so just use lua socket.

you can probibly do a usb interface through the cdc device class, but i dont think there is a lua module for this, you would have to build a module, use alien to talk to a dll that handles communication with usb cdc devices, or compile a middleware application as a go between between the usb device and the ip loopback port.
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 

Offline coffeesoft

  • 28
  • Bip Bip
Re: Extract Telemetry from FSO
Useful information, many thanks :)

The script from Podo is using LuaSocket and works good, but the script must be optimized for better response and is a Alpha version.

Now i have a doubt, there is a software called X-Sim to extract the data from the games, normally racing and flight simulators.
This software has a plugin that is capable to extract the data from the DirectX or OpenGL while you are playing, normally people are using for motor controlled cabinets.

My doubt is wich kind of data will extract from FSO, because i don´t know wich data manage the OpenGL and wich one is exclusive of the game.

When i have a bit of time, i will build a little platform simulator of LEGO or something just to test it ( i have two small motors on the vault   :D), anyway may be i must to buy some controllers for the motors.....