User avatar
TheRobster
Posts: 19
Joined: Fri Jan 20, 2012 11:35 pm
Location: Vancouver Canada

Flight sim? [obsolete thread]

Wed Jul 04, 2012 8:07 pm

Has anyone got any flight sim to run on the Raspberry?
I think it would be a blast to fly using my big screen TV as the display.

I know flightgear is probably too resource hungry for the Raspberry PI, but surely there is a less resource hungry flight sim?
I am going to put a Raspberry PI powered HUD in my 24 year old Jeep.

User avatar
Super-Nathan
Posts: 67
Joined: Sun Jun 17, 2012 6:56 am
Location: South Korea

Re: Flight sim?

Thu Jul 05, 2012 8:17 am

I have been able to run Tie Fighter (1994) under DOSBox. Using the MAX settings and a frame-skip of about 4. In-game settings pretty low.

I am running Arch. Overclocking as follows: cpu=900;ram=500;gpu=300

All that said, Tie Fighter is slow (playable-ish). It is no-where near what I can get on my laptop, but it is running inside the DOSBox emulator. PRBoom which runs natively in Linux runs Doom at high in-game settings pretty fast.

This all leads me to believe if we can get a Linux based flight sim like FlightGear compiled and running natively I believe the RasPi can handle it. Through a layer of emulation it struggles.
echo "Something Useful" > /dev/null

User avatar
AndrewS
Posts: 3635
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK

Re: Flight sim?

Thu Jul 05, 2012 10:26 am

I suspect like most 3D games/apps, the problem will be finding a flightsim that uses OpenGLES rather than regular OpenGL...

User avatar
SN
Posts: 1014
Joined: Mon Feb 13, 2012 8:06 pm
Location: Romiley, UK

Re: Flight sim?

Thu Jul 05, 2012 10:49 am

Any kind of real world sim with a half decent rendering engine would be good - I was hoping Pifinity would bring a framework that could be used

I confess to once-upon-a-time being a "small-sized-cheese" in the MS Train Sim community to the point of a) contributing to stuff on the shelves of Game and b) getting a good way down writing my own engine in VB consuming MSTS assets. (sadly the better ORTS rewrite of the same ilk has been done in C# :roll: otherwise there could have been a port option)

One of my specific interests in Gambas2 was to see if I could port my VB code - the biggest challenge being the need to replace a friends DirectX based renderer/viewer component
Steve N – binatone mk4->intellivision->zx81->spectrum->cbm64->cpc6128->520stfm->pc->raspi ?

raspberrypivictim
Posts: 30
Joined: Sun Jan 22, 2012 10:35 pm

Re: Flight sim?

Fri Jul 06, 2012 10:44 am

Wandering around wikipedia, have found FlightGear Flight Simulator use OpenSceneGraph which has opengl es support.

We should give it a try

User avatar
TheRobster
Posts: 19
Joined: Fri Jan 20, 2012 11:35 pm
Location: Vancouver Canada

Re: Flight sim?

Mon Jul 09, 2012 6:30 pm

I got flightgear to install with:
'sudo apt-get install flightgear'

I have not got it to start up yet.
For anyone wanting to try it, I believe you need to 'startx' first.
I am going to put a Raspberry PI powered HUD in my 24 year old Jeep.

User avatar
AndrewS
Posts: 3635
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK

Re: Flight sim?

Thu Jul 12, 2012 10:29 am

I suspect that any precompiled binaries (such as those installed from a repository) will probably be compiled to use OpenGL. Getting it to use OpenGLES will probably involve configuring and compiling from sourcecode.

Bruce_C
Posts: 2
Joined: Thu Jun 07, 2012 7:15 am

Re: Flight sim?

Wed Jul 18, 2012 12:01 pm

I wondered if YS Flight http://www.ysflight.com might work on the Pi? Graphically it's not very challenging but can be great fun, especially multiplayer.

It's pre compiled and it doesn't look like the source code is available though :(

diveroli
Posts: 20
Joined: Sat Sep 08, 2012 10:20 pm

Re: Flight sim?

Wed Sep 12, 2012 8:26 pm

Today I managed to have Microsoft Flight Simulator 3.0 and 4.0b both running under DOSBox.
Irrespective of whether DOSBox is run fullscreen from the console or windowed from LXDE, FS3.0 and FS4.0b have both (measured at classical Meigs takeoff position with no weather or dynamic scenery) 4 fps. (This with the optimal DOSBOx cycle wich happens to be around 2000 to 3000. ) This is the best one can get, but using a scenery where about a dozen buildings and a few trees show (I tried my old Argentina-Uruguay scenery) the fps go down to 1 fps. Certainly these frame rates are is just enough to show that these simulators do run in the RPi, but the fps are too low for any practical use.

Will try the other simulators suggested above, but obviously one has to look outside DOSBox, for something native Linux, to achieve anything practical.

diveroli
Posts: 20
Joined: Sat Sep 08, 2012 10:20 pm

Re: Flight sim?

Wed Sep 12, 2012 11:38 pm

Thanks for the suggestion about FlightGear. Installed. Cannot run it, cannot find the command. Whether from console or from LXDE, there is an error: no flightgear command. Guess for some reason it is hidden in some folder. Would be pleased to know the full command to start Flightgear once installed on the Raspberry.

Thanks!

Decapod
Posts: 4
Joined: Mon Jul 30, 2012 9:05 am

Re: Flight sim?

Thu Sep 13, 2012 12:07 pm

SN wrote: I confess to once-upon-a-time being a "small-sized-cheese" in the MS Train Sim community to the point of a) contributing to stuff on the shelves of Game and b) getting a good way down writing my own engine in VB consuming MSTS assets. (sadly the better ORTS rewrite of the same ilk has been done in C# :roll: otherwise there could have been a port option)
Not so small Steve :) - help is at hand if I can get my pi into a reasonable state ;)

(Also a keen flight sim modeller and 3D programmer)

Paul

User avatar
TheRobster
Posts: 19
Joined: Fri Jan 20, 2012 11:35 pm
Location: Vancouver Canada

Re: Flight sim?

Thu Sep 13, 2012 12:44 pm

diveroli wrote:Thanks for the suggestion about FlightGear. Installed. Cannot run it, cannot find the command. Whether from console or from LXDE, there is an error: no flightgear command. Guess for some reason it is hidden in some folder. Would be pleased to know the full command to start Flightgear once installed on the Raspberry.

Thanks!
fgfs is the command if I recall correctly.
Not that I ever got it to run.
I am going to put a Raspberry PI powered HUD in my 24 year old Jeep.

User avatar
RaTTuS
Posts: 10828
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK

Re: Flight sim?

Thu Sep 13, 2012 12:55 pm

umm,
I've written too many of those to even think about doing one now ....
ummm
no I'll not dig out he old code
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV

1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe

User avatar
SN
Posts: 1014
Joined: Mon Feb 13, 2012 8:06 pm
Location: Romiley, UK

Re: Flight sim?

Thu Sep 13, 2012 1:09 pm

Decapod wrote:
SN wrote: I confess to once-upon-a-time being a "small-sized-cheese" in the MS Train Sim community to the point of a) contributing to stuff on the shelves of Game and b) getting a good way down writing my own engine in VB consuming MSTS assets. (sadly the better ORTS rewrite of the same ilk has been done in C# :roll: otherwise there could have been a port option)
Not so small Steve :) - help is at hand if I can get my pi into a reasonable state ;)

(Also a keen flight sim modeller and 3D programmer)

Paul
Hi Paul - really good to hear from you again. Fancy rewriting/recompiling your viewer in C or C++ and OpenGL ES for the Pi?
Steve N – binatone mk4->intellivision->zx81->spectrum->cbm64->cpc6128->520stfm->pc->raspi ?

diveroli
Posts: 20
Joined: Sat Sep 08, 2012 10:20 pm

Re: Flight sim?

Thu Sep 13, 2012 3:31 pm

FlightGear:

Thanks for the useful info! I issued
sudo fgfs
with no result, then I fired up a LXDE LX console, started Midnight Commander there, performed a full search and found a few fgfs* files, the main one in /usr/games. So I issued
sudo /usr/games/fgfs
and after about 5 seconds I got the following reply:
Error: :0.0 has no GLS extension.
getdefaultwindow: failed to create GraphicsContent
I was then back to the console prompt.
It looks as if the available version we are installing in the RPi is not GLE compatible.
Any ideas?

Joe

Decapod
Posts: 4
Joined: Mon Jul 30, 2012 9:05 am

Re: Flight sim?

Thu Sep 13, 2012 4:17 pm

SN wrote: Hi Paul - really good to hear from you again. Fancy rewriting/recompiling your viewer in C or C++ and OpenGL ES for the Pi?
I re-wrote it once with DX9 and .NET to read FSX models, it can't be too hard to convert to Open GL ES.
Time to start reading.

The Pi is missing a decent "sim" of any sort :)

User avatar
TheRobster
Posts: 19
Joined: Fri Jan 20, 2012 11:35 pm
Location: Vancouver Canada

Re: Flight sim?

Thu Sep 13, 2012 4:39 pm

diveroli wrote:FlightGear:

It looks as if the available version we are installing in the RPi is not GLE compatible.
Any ideas?

Joe
I am afraid that is about as far as I got.
I believe someone with some programming skill will be needed to sort this out.
I am going to put a Raspberry PI powered HUD in my 24 year old Jeep.

diveroli
Posts: 20
Joined: Sat Sep 08, 2012 10:20 pm

Re: Flight sim?

Fri Sep 14, 2012 1:49 pm

Thanks TheRobster!

"somebody with programming skills"...

Indeed. I only have Fortran, Visual Basic, VBA, DOS batch, VBScript, HTML, a bit of Java and am now learning Python. IMHO all these are useless and we need somebody versed into advanced game programming, with 3D Glide environments. All I can forecast is that, rather than patching FlightGear for the RPi (most likely a mammoth task) what is needed is to patch Raspbian for common Glide. If this has not been done so far, it is probably because it is almost impossible. Let us hope there will be some improvement.
Good luck everybody.

diveroli
Posts: 20
Joined: Sat Sep 08, 2012 10:20 pm

Re: Flight sim?

Sat Sep 15, 2012 12:06 pm

Not any progress, but now I have the details in case somebody found a solution:

- issuing the necessary search and install statements I found that by default Raspbian installs in the RPI freeglut3, the "OpenGL Utility Toolkit".

- running FlightGear's gl-info I find that FlightGear needs instead a "GL Utility Toolkit" which "is not installed in this system".

The above shows that FlightGear needs a different GL than the one in Raspbian. I also guess that the "GL Utility Toolkit" is incompatible with Raspbian, or else it would be installed, or at least available for download and install.

Best
Joe




searching I got that the GL for the RPi is freeglut3

diveroli
Posts: 20
Joined: Sat Sep 08, 2012 10:20 pm

Re: Flight sim? Metar

Sat Sep 15, 2012 12:24 pm

Flight Gear installed a few executable utilities, not only the already-mentioned GL checker, also a Joystick checker and the "metar". Issuing metar EIDW gives you the weather in Dublin airport, metar EGLL in London Heathrow and so on all over the world.

User avatar
SN
Posts: 1014
Joined: Mon Feb 13, 2012 8:06 pm
Location: Romiley, UK

Re: Flight sim?

Sat Sep 15, 2012 8:29 pm

diveroli wrote:Thanks TheRobster!

"somebody with programming skills"...

Indeed. I only have Fortran, Visual Basic, VBA, DOS batch, VBScript, HTML, a bit of Java and am now learning Python. IMHO all these are useless and we need somebody versed into advanced game programming, with 3D Glide environments. All I can forecast is that, rather than patching FlightGear for the RPi (most likely a mammoth task) what is needed is to patch Raspbian for common Glide. If this has not been done so far, it is probably because it is almost impossible. Let us hope there will be some improvement.
Good luck everybody.
Don't bet against my mate decapod. He's done some amazing things in the PC sim world. If he can port his viewer we'll have the basis for something to build on. I have a VB code base which I may also be able to port. . . watch this space ;-)
Steve N – binatone mk4->intellivision->zx81->spectrum->cbm64->cpc6128->520stfm->pc->raspi ?

diveroli
Posts: 20
Joined: Sat Sep 08, 2012 10:20 pm

Re: Flight sim?

Sat Sep 15, 2012 11:15 pm

Sure I will!
Best
Joe

User avatar
David Chatterton
Posts: 4
Joined: Fri Feb 06, 2015 6:55 pm
Location: Winchester

Re: Flight sim?

Sun Feb 15, 2015 8:47 pm

Having got FlightGear to run under Ubuntu on an i7 processed laptop, I investigated what happens on a Raspberry Pi 2.
The version I have is 2.4.0
Using the command: fgfs in Terminal, I get the FlightGear startup screen. The CPU Usage Monitor show 25% so I guess that FGFS is only using one of the Pi 2's cores.
Eventually, FGFS exits with the following messages:
Processing command line arguments
Nasal runtime error: function/method call on uncallable object
at /usr/share/games, line 1142
Nasal runtime error: undefined symbol: (null)
at /usr/share/games/flightgear/Nasal/balloons.nas, line 4
Nasal runtime error: undefined symbol: (null)
at /usr/share/games/flightgear/Nasal/contrail.nas, line 29
Segmentation fault

I am aware that later versions of FG provide multiprocessor support but not by default. I had to edit the configuration.xml file on my Ubuntu version to get the processing load spread over the four cores. FGFS runs very stably with support for a pilot yoke and rudder pedals built in. It would be great to get a later version for Rasbian and try it out with the quad-cored Pi 2 processor.

Wishful thinking?

gigirock
Posts: 1
Joined: Fri May 22, 2015 8:06 am

Re: Flight sim?

Fri May 22, 2015 8:13 am

you can find a useful script as
download_and_compile.sh in order to compile from scratch in ubuntu and debian pc desktop.. i don't know if the relative arm versions exists.

I don't think the problem is about opengl or not libraries... i think the problem is to compile simgear for rpi.....
anyway... you can start from here....

http://wiki.flightgear.org/Scripted_Com ... ian/Ubuntu

Nigelbotts
Posts: 1
Joined: Tue Jun 09, 2015 12:19 pm

Re: Flight sim?

Tue Jun 09, 2015 12:22 pm

Can you try to use google earth? I saw this article http://www.instructables.com/id/Flight- ... /?ALLSTEPS, however it uses an arduino instead...

I would love to get the full accelerometer working too if anybody could help

Return to “General discussion”