20,741
edits
mNo edit summary |
m (→Feature Scaling: add a new FG1000 troubleshooting section) |
||
Line 1,110: | Line 1,110: | ||
</PropertyList> | </PropertyList> | ||
</syntaxhighlight> | </syntaxhighlight> | ||
=== FG1000 === | |||
{{Main article|FG1000}} | |||
For the time being, the FG1000 must be hardly considered usable on the RPi, i.e. ~200ms/5fps. We're currently in the process of investigating what can be done to make it possible to use the device on the RPi, since that would seem like a perfect use-case. | |||
One thing that's obvious is that initialization of the device takes unusually long. | |||
To see what's going on, we can wrap the initialization code inside $FG_ROOT/gui/menubar.xml in between profiling calls: | |||
{{See also|Built-in Profiler}} | |||
<syntaxhighlight lang="diff"> | |||
diff --git a/gui/menubar.xml b/gui/menubar.xml | |||
index ff3faa1ac..6c94b2e76 100644 | |||
--- a/gui/menubar.xml | |||
+++ b/gui/menubar.xml | |||
@@ -834,6 +834,7 @@ | |||
<binding> | |||
<command>nasal</command> | |||
<script> | |||
+ fgcommand("profiler-start"); | |||
var nasal_dir = getprop("/sim/fg-root") ~ "/Aircraft/Instruments-3d/FG1000/Nasal/"; | |||
if (! defined("fg1000")) { | |||
io.load_nasal(nasal_dir ~ 'FG1000.nas', "fg1000"); | |||
@@ -846,6 +847,7 @@ | |||
var fg1000system = fg1000.FG1000.getOrCreateInstance(); | |||
var pfdindex = fg1000system.addPFD(); | |||
fg1000system.displayGUI(pfdindex); | |||
+ fgcommand("profiler-stop"); | |||
</script> | |||
</binding> | |||
<syntaxhighlight> | |||
==Interfacing== | ==Interfacing== |