Board index FlightGear Development Canvas

Canvas MFD Function Issues on DC-10-30

Canvas is FlightGear's new fully scriptable 2D drawing system that will allow you to easily create new instruments, HUDs and even GUI dialogs and custom GUI widgets, without having to write C++ code and without having to rebuild FlightGear.

Canvas MFD Function Issues on DC-10-30

Postby drdavid » Wed Apr 09, 2014 4:50 am

Since installing the basic Canvas MFD in the DC-10-30, I have struggled to get all the MFD functions to display correctly. I am using the MFD from the latest Canvas-ready version of the Mirage 2000 by 5H1N0B1. A gallery of the screens can be found on Canvas ND Framework page on FlightGear Wiki.

The DC-10's Git master repository can be accessed here: DC-10-30-MD-10.

By providing a list of which functions are operational and which are not, someone might be able to help me find the conflicts, errors, or missing pieces. Here's an illustration of the working portion of the MFD:

Image

Upon starting the DC-10, the Nasal Console reports this error::

Code: Select all
Nasal runtime error: nil used in numeric context
  at C:\FlightGear\data/Nasal/canvas/map/navdisplay.mfd, line 1107
  called from: C:\FlightGear\data/Nasal/canvas/map/navdisplay.mfd, line 824


When the MFD Cycle button is clicked (bottom row, far left-- labeled: "bt-b1") another error is reported:

Code: Select all
Nasal runtime error: props.setDoubleValue() with non-number
  at C:/FlightGear/data/Nasal/props.nas, line 33
  called from: C:\FlightGear\data/Nasal/canvas/map/navdisplay.mfd, line 1090
  called from: C:\FlightGear\data/Nasal/canvas/map/navdisplay.mfd, line 824


Note that this MFD has knobs in three corners of the bezel. The knob in the bottom right corner is active, and in the default "startup" screen, controls the range in NM. It works properly, but only in the PLAN mode. More on that below. The other two knobs are inactive. The buttons on the vertical sides of the border are inactive.

The white buttons on the top row are labeled bt-h1 through bt-h5 (left to right).
The buttons on the bottom row are labeled bt-b1 through bt-b5 (left to right), although bt-b5 is inactive.

Code: Select all
1. Button b1:  This button is coded to select four modes: APP, MAP, PLAN, VOR. Here are the problems:
     a. The only mode it displays is PLAN. 
     b. The airspeed, windspeed, wind direction, and DME information work only as long as no other button is selected.  When any other button is clicked on, these in-flight functions freeze.
     c. When a flight plan is loaded, the screen displays the plane icon, the departing airport, and the flight plan, but after takeoff, the plane icon moves along the flightplan, but is at a fixed angle and does not trace the plan's line in the correct       orientation.  Also, flight plan does not simultaneously move and remains locked on the departing airport.
     d. When b1 is clicked a second time, this information disappears.
     e. Third click still no flight graphics.
     f.  Fourth click, the flight info reappears positioned as it should be for the MAP mode, but the MAP mode does not display.  However, the flight plan line (when centered: bt-b3) and fixes now moves with the aircraft.  The airplane icon, though, is not displayed.
2. Button b2: This is coded to select either LCD or CRT mode.  Appears to not be functioning.  Nothing visibly happens regardless of which mode the MFD is supposed to be in.
3. Button b3: Coded to center the NavDisplay.  It works properly.
4. Button b4: Coded to display waypoint information.  It does not function
5. Button b5: Inactive.


Upper Row:

Code: Select all
1. Button h1: Coded to display Airports.  It does so when first clicked on, but does not refresh as the plane flies.  It has to be re-clicked to again display the airports.
2. Button h2: Coded to display traffic.  It displays a diamond icon with info on whether the traffic is climbing or descending, but nothing else.
3. Button h3: Coded to display waypoints.  It works properly.
4. Button h4: Coded to display position.  It does not function.
5. Button h5: Coded to display weather.  It does not function.


Thanks in advance for any assistance you can offer.

Regards
drdavid
 
Posts: 178
Joined: Sun Aug 14, 2011 7:05 am
Location: KEUG; KPDX, CYXT; KXTA
Callsign: SkyBoat
Version: 3.2.0
OS: Windows 8.1

Re: Canvas MFD Function Issues on DC-10-30

Postby Philosopher » Wed Apr 09, 2014 8:36 pm

Hi, sorry I've been a little busy, also with tracking down a bug, among other things.

My current status is that I have several changes I need to get pushed to Git regarding MapStructure and navdisplay. These are basically bug fixes, so they shouldn't impact how you use it (aka front-end code), but it may make things work better (aka reduce errors). If you're using a release version, they still should be compatible, so I would recommend downloading them after I push to keep them up-to-date. Current development is here, but I have some changes locally that haven't made it yet: https://gitorious.org/fg/canvas-hackers ... nvas-radar:

Besides that, I'll see when I can run and test your aircraft, and see what I can help with. I'll download it ASAP.
Thanks,
Philosopher
(inactive but lurking occasionally...)
Philosopher
 
Posts: 1590
Joined: Sun Aug 12, 2012 6:29 pm
Location: Stuck in my head...
Callsign: AFTI
Version: Git
OS: Mac OS X 10.7.5

Re: Canvas MFD Function Issues on DC-10-30

Postby Hooray » Wed Apr 09, 2014 8:44 pm

those errors would seem to suggest that you are using properties that have invalid types or values - we could probably harden the framework to encode required types/value-ranges as part of the setup hash, and automatically check those during setupMFD() and bail out with a self-explanatory error message.

Overall, I'd just use the property browser and navigate to the corresponding canvas tree for your ND, you'll see it probably somewhere under /instrumentation/efis, the switches there need to have valid values - if they don't, you'll get the errors you are seeing

So I'd make sure that your cockpit bindings are actually using the same properties as those that are set up for your ND (via the myCockpitswitches gash).----

(just a guess for now)
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 11427
Joined: Tue Mar 25, 2008 8:40 am

Re: Canvas MFD Function Issues on DC-10-30

Postby drdavid » Wed Apr 09, 2014 11:15 pm

Thanks for the replies.

Hooray-- From your suggestion to look at the internal properties, I found two pathway errors and went through the EFIS and ND switches and checked them one at a time. Kind of a virtual bench-test, I guess. Still only have the PLAN view, but now the display shows navaids as well as fixes. No other significant improvements, but I didn't break anything :lol:

Philosopher-- Thanks for being willing to download and test the DC-10. I'm committing my changes to Git as soon as I finish this post.

Cheers, gentlemen
drdavid
 
Posts: 178
Joined: Sun Aug 14, 2011 7:05 am
Location: KEUG; KPDX, CYXT; KXTA
Callsign: SkyBoat
Version: 3.2.0
OS: Windows 8.1

Re: Canvas MFD Function Issues on DC-10-30

Postby Hooray » Thu Apr 10, 2014 2:06 am

yes: basically, the setup hash contains the switches that your panel should reference - and once you use the property browser and navigate to the corresponding sub-tree, those should show up with valid defaults - if they don't, something isn't quite right yet.
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 11427
Joined: Tue Mar 25, 2008 8:40 am

Re: Canvas MFD Function Issues on DC-10-30

Postby drdavid » Mon Apr 21, 2014 7:58 pm

The other problem I'm having with airplane's performance is very low frame rates (often in the single digits) and continuous stuttering. I've been reading the other forum threads and going to each of the suggested wiki topics but none of them have a step-by-step procedure for fixing the issues. I've written technical manuals in my work. The FlightGear wiki pages, for the most part, are narratives that discuss the issue but do not have clear steps for where to begin, how to work through the process and end up with a successful result. Having instructions wrritten this way would make the wiki articles much more user friendly especially for new FlightGear users who enounter a problem and save a huge amount of time. Nevertheless, here is a screen shot of the DC-10-30-MD-10 with the Cycle On-screen Statics enabled.

Image


Perhaps some insight about the performance proplems can be gleaned from the stats.

@Philosopher-- when you get a chance to download and fly the plane, let me know.

Regards
drdavid
 
Posts: 178
Joined: Sun Aug 14, 2011 7:05 am
Location: KEUG; KPDX, CYXT; KXTA
Callsign: SkyBoat
Version: 3.2.0
OS: Windows 8.1

Re: Canvas MFD Function Issues on DC-10-30

Postby Hooray » Mon Apr 21, 2014 8:04 pm

what version of FG are you running, is it anything recent ? Canvas/NavDisplay stuff has recently received quite some updates, and the ND/MapStructure stuff is going to be updated soon.
There are indeed some inefficiencies sprinkled all over the place when it comes to the underlying Nasal code, but it's nothing massive, and we know how to solve it - quite a few things were already solved, others, we hope to solve in time for 3.2. You should see much better performance with next/HEAD already. But there's still stuff in the pipe.

Regarding the quality of the wiki articles, you are unfortunately right - but it's obviously taking time to write good docs, any help would be appreciated. But as you have probably noticed already, it isn't exacctly a priority, most of us are more interested in other aspects of FG, not so much documentation writing ... still, any help/advice/feedback would obviously be appreciated.

There's another guy who is a technical writer who wanted to help with things, but -as is usual- pointing out deficiencies takes less time than actual fixing them yourself :lol:
And as you may remember, even the ND integration article you've been working on extending still needs some work, despite your contributions (hint!) ;-)

The other problem I'm having with airplane's performance is very low frame rates (often in the single digits) and continuous stuttering. I've been reading the other forum threads and going to each of the suggested wiki topics but none of them have a step-by-step procedure for fixing the issues. I've written technical manuals in my work. The FlightGear wiki pages, for the most part, are narratives that discuss the issue but do not have clear steps for where to begin, how to work through the process and end up with a successful result.


the main problem is that we're still lacking good tools to provide aircraft developers with informative and reliable runtime diagnostics, that would go a long way actually - and should help make most of these articles obsolete, but it requires some changes in the C++ code: http://wiki.flightgear.org/Subsystem-le ... FlightGear

While that articles focus on one specific resource, namely RAM, the same things could/should be done for other important resources, such as CPU/GPU time. It is doable, but currently not a priority or on anybody's agenda unfortunately - but it keeps being brought up - so it will eventually need to be tackled, but it may take a few more "crippled" releases to actually make it a priority :?
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 11427
Joined: Tue Mar 25, 2008 8:40 am

Re: Canvas MFD Function Issues on DC-10-30

Postby drdavid » Tue Apr 29, 2014 3:15 am

Been having some health issues, so I'm attempting to get caught up on my correspondance.

I'm running Windows 8.1, 16GB RAM, Core i7, NVIDIA GEFORCE 630M w/ 1GB on a HP Envy dv6.

In short, I should have plenty of computing power to handle FlightGear 3.0.

I've wondered, as I have been making changes to the aircraft that puts more demand on FG to run it, if I'm bumping up against an upper limit where the two lines cross? First, has my computer's capacity to handle the demand FG requires to render the aircraft optimally in the environment reached its peak, while secondly, has FG maxed out its capacity to handle the computing load my aircraft demands to run well in the environment? Am I at the point of diminishing returns on both accounts? If I had $4000 to spend on a dedicated FG computer (I don't) with top-of-the-line components and a huge amount of RAM, would it make any difference to the performance numbers I currently am seeing?

And as you may remember, even the ND integration article you've been working on extending still needs some work, despite your contributions (hint!) ;-)


I made a few more edits about three weeks ago, but am needing someone with the technical expertise to "bench-test" the airplane and provide me with a description what yet needs to be fixed so the canvas ND functions correctly in all four modes as I've detailed in an above post. Once I get that, I'll keep updating the ND integration article. I'm confident we'll get it done. Philosopher said he would look at it. I've also contacted 5H10NB1 about testing the airplane, but haven't heard anything from him in over a month. So, it's a slow process.

On the positive side, the canvas MFD is partially working. I added the 777's EFIS panel, and that gave it more of the options in the PLAN mode. One of these days I may accidentally get it right :shock:

I guess, in the mean time, we look forward to each new release and hope that the new version is a little less "crippled" than the last one.

But I would ask the Adminstrators and Global Moderators, as we limp along in this manner, how many potentially loyal FlightGear users are we losing on a weekly basis (to MS or X-planes, despite their cost) because our airplanes just don't perform well enough to retain these newest users and they leave us in frustration? I'd like to see 3000 pilots on the FG server online maps at peak periods instead of 70. :?:

Regards
drdavid
 
Posts: 178
Joined: Sun Aug 14, 2011 7:05 am
Location: KEUG; KPDX, CYXT; KXTA
Callsign: SkyBoat
Version: 3.2.0
OS: Windows 8.1

Re: Canvas MFD Function Issues on DC-10-30

Postby Hooray » Tue Apr 29, 2014 4:12 am

regarding the hardware issue, you may want t run a forum search - FG simply isn't quite there yet in terms of capabilities, i.e. not even a high-end system for $4k may be put to good use properly.
As for having 3k MP pilots, FG also isn't quite there yet - there are technical issues, such as the underlying MP protocol, but obviously also lack of usability.
So we really are better off without having thousands (or even just hundreds!) of MP pilots. And we're also much better off not buying hardware specifically for FG.
there are quite a few algorithmic issues that prevent FG from using modern hardware properly, people are working on fixing some of these, but that's obviously another construction site that needs time, i.e. slow but steady progress :-)

As for airplane/scenery performance, that is mostly an issue of middleware/content developers not being aware of the impact of their additions and what to look out for - here again, FG fails to provide good runtime diagnostics to tell non-developers what's going on under the hood, which is why some of our best aircraft are the worst in terms of performance, e.g. the 747/777 or 787 airliners.

There's quite a bit of inefficient stuff done by airplane developers, not just in terms of Nasal coding, but also in terms of texturing and 3D modeling, which is having an impact here.
At the end of the day, this prevents the underlying OSG layers to do certain optimizations, so this is primarily a problem on the FG side of things. osgviewer and even fgviewer do not suffer from certain problems.

It isn't uncommon for certain challenges to be addressed only after years, the recent reset/re-init work was first brought up almost a decade ago, and it's only in the last 2 years that it's taking shape, thanks to a single developer. Canvas -as a feature- has been discussed for almost 2 years, and was first brought up 5+ years prior to being turned into a working feature.

So a "second" on the FlightGear clock may very well be one (or more) weeks for us mere mortals ;-)

But I would ask the Adminstrators and Global Moderators, as we limp along in this manner, how many potentially loyal FlightGear users are we losing on a weekly basis (to MS or X-planes, despite their cost) because our airplanes just don't perform well enough to retain these newest users and they leave us in frustration?


To be honest, I think you can -and should- answer this for yourself. To clarify: A "moderator" or "administrator" is just another contributor, exactly like you are one. The same applies to wiki admins, fgdata committers or even core developers. These roles, such as "moderator", "admin", "committer" etc are really just expressing a single thing: someone has been around & involved long enough to gain some trust to help with certain chores (which really is what this is all about)- Often, not even that is the case, but someone ends up gaining such trust because it's the very person who came up with a certain feature or piece of infrastructure.
It takes a single mouse click to make you an admin/moderator/committer - yet, nothing would have changed for you, right ? Then again, people would perceive "you" as being a "part" of the project all of a sudden, and start posing questions like yours :D A moderator, admin or committer is no different from any other FG contributor, and there's no "powers" involved to change something for the better, beyond just "being the change you want to see", no matter how much "we" may agree with such sentiments. It's a damn tough lesson, but that's the way it is. If you don't believe me, we can surely make you a wiki and forum admin, so that you can get a taste :lol: It is a kinda overwhelming feeling actually, and the core developer community is obviously suffering some kind of burnout ... and has been for years
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 11427
Joined: Tue Mar 25, 2008 8:40 am

Re: Canvas MFD Function Issues on DC-10-30

Postby Philosopher » Tue Apr 29, 2014 4:33 am

I'm so sorry that I've been forgetting about this, but I haven't been too active around FG these past weeks (took me a whole week to commit the MapStructure changes, and Hyde says it doesn't work! I didn't test it though) and I think I have a reminder to do this on a sticky note somewhere in the cloud ;).

If the model is the problem, you could see if I-NEMO's instructions in their (new) 777-Seattle thread help to speed things up there. If it's something with the ND (like someone reported this week on the forum), then I should definitely take a look at that. I can also help with any more integration you don't know how to do. Maybe my new iPod will let me work on it from there... ;)
Thanks,
Philosopher
(inactive but lurking occasionally...)
Philosopher
 
Posts: 1590
Joined: Sun Aug 12, 2012 6:29 pm
Location: Stuck in my head...
Callsign: AFTI
Version: Git
OS: Mac OS X 10.7.5

Re: Canvas MFD Function Issues on DC-10-30

Postby drdavid » Wed Apr 30, 2014 1:02 am

I just updated the repository in Git Hub: DrDavid/DC-10-30-MD-10
drdavid
 
Posts: 178
Joined: Sun Aug 14, 2011 7:05 am
Location: KEUG; KPDX, CYXT; KXTA
Callsign: SkyBoat
Version: 3.2.0
OS: Windows 8.1


Return to Canvas

Who is online

Users browsing this forum: No registered users and 1 guest