Board index FlightGear Development Aircraft

Eurocopter EC-145 current downloads

Questions and discussion about creating aircraft. Flight dynamics, 3d models, cockpits, systems, animation, textures.

Re: Eurocopter EC-145 current downloads

Postby StuartC » Sat Oct 13, 2018 1:11 pm

Only way I got it to work was by creating a sun.nas file for that code. Every time I put it in the bk117.nas file it wouldn't start the engines.
StuartC
 
Posts: 3175
Joined: Fri Jun 18, 2010 9:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2019.1
OS: W10 64 bit

Re: Eurocopter EC-145 current downloads

Postby litzi » Mon Oct 15, 2018 6:21 am

Ok, this solution will be as good. Still wonder what makes it fail when put in bk117.nas. Will have a look on it when you publish the next version.
litzi
 
Posts: 123
Joined: Sat May 03, 2014 9:59 pm
Location: AT
Version: 2018.3.1
OS: Ubuntu 14.04

Re: Eurocopter EC-145 current downloads

Postby litzi » Thu Dec 27, 2018 6:19 pm

I have made an effort to save those seats from the nasty rain penetrating through the fuselage ;-). I have started to port the Helionix 2D panels to Canvas, which works fine -in principle- as the Canvas approach combined with SVG drawing elements is a very "clean" framework. However, at least on my machine, the Canvas related Nasal code comes with a significant performance penalty (noticable frame rate "stutter" and generally reduced fps). I have tried a number of recommended (and not so recommended) Nasal performance boosters, but up to now with just limited success.

The screenshot shows the old and the new Helionix FND side by side. As one can see the issue with the panel "shining" through other 3D object is resolved, and I also expect the seats will "stay dry" once all the 2D panels have been replace by their Canvas counterparts.

Image

I can currently not predict when I can share a first Canvas version of the Helionix displays. I'll keep you updated.
litzi
 
Posts: 123
Joined: Sat May 03, 2014 9:59 pm
Location: AT
Version: 2018.3.1
OS: Ubuntu 14.04

Re: Eurocopter EC-145 current downloads

Postby StuartC » Thu Dec 27, 2018 8:42 pm

Good stuff. It was getting difficult to fly it while holding an Umbrella at the same time.
StuartC
 
Posts: 3175
Joined: Fri Jun 18, 2010 9:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2019.1
OS: W10 64 bit

Re: Eurocopter EC-145 current downloads

Postby legoboyvdlp » Thu Dec 27, 2018 11:28 pm

In terms of performance maybe post your code so we have a look? While canvas does have an impact it should be possible to run without stuttering if you can run it on high settings as evidenced by your screenshot.
User avatar
legoboyvdlp
 
Posts: 7981
Joined: Sat Jul 26, 2014 2:28 am
Location: Northern Ireland
Callsign: G-LEGO
Version: next
OS: Windows 10 HP

Re: Eurocopter EC-145 current downloads

Postby Hooray » Sat Dec 29, 2018 10:39 pm

Yeah, I kinda agree with that, and without meaning to discourage anybody - but it is extremely difficult to write "proper" Nasal/Canvas code (in terms of structuring things according to performance/modularization and reuse requirements) - usually, the few people able to do so have a significant background, either in fgfs Nasal/core development or in software development/engineering in general, i.e. holding multiple degrees (and often enough, in both).

The few exceptions to this rule are usually people with professional backgrounds in related fields (maths, physics, aeronautics or engineering in general) who can quickly pick up the corresponding concepts by working through a few tutorials, examples and code snippets and then just take it from there.

The most recent example for well-structured avionics based on Nasal/Canvas is actually Richard's MFD framework and Stuart's FG1000.

Most other code floating around here is hardly reusable/modular at all, and often enough not structured with performance considerations in mind. That way, we ended up with awesome-looking avionics/cockpits that end up causing a significant performance hit for many users, and that have come to use a structure/design that cannot be easily refactored to benefit from certain optimizations.

The challenge here is that by their very nature, Nasal and Canvas are primarily being used by people who may not have had much previous coding exposure/experience (especially people using primarily artwork created by editors like Inkscape), so that people end up "learning as they go" (which is obviously fine, but causing certain issues over time for other contributors/end-users wanting better, more reusable, and faster code or frame rates).

Thus, speaking in general, depending on the kind of avionics you are having in mind, it may be best to reach out to people who have previously already succeeded creating such avionics, and meeting the corresponding performance requirements.

For instance, if you are interested in PFD/EICAS-like avionics, it would seem like a really good idea to reach out to jsb, who is currently aggregating GPL'ed Nasal/Canvas code to incrementally grow a procedural 2D drawing library (for the time being, this is largely based on code written by rleibner originally):

http://wiki.flightgear.org/Canvas_draw_library
Image

Bottom line, even if someone is able to create a proper set of avionics using Inkscape and Nasal/Canvas, there is a certain structure required to avoid redundant code, and to use efficient coding patterns - e.g. to reduce the amount of property I/O and unnecessary Canvas updates/redrawing.

More often than not, this structure is likely to look similar regardless of the aircraft/cockpit that is being modeled - i.e. a coding pattern that helps the shuttle perform faster by being more selective about updates and data I/O is likely to also work for complex airliners, and vice versa.


In other words, if you don't mind reinventing the wheel and solving problems that have already been solved by others, you are obviously free to ignore such advice (that also applies if you have a corresponding coding background), but if you'd like to benefit from certain lessons learnt over time, it would definitely be a good idea to stop coding for a while, and simply do a bit of research to see what we've got already in terms of similar avionics/aircraft, and how these perform for most people - so that you can at least look at the various approaches and concepts being used by different folks.

Personally, I would definitely suggest to look at Richard's MFD framework, and at Stuart's FG1000.
For moving-map purposes, I would suggest to look at Philosopher's MFD framework.
And for anything involving PFD/EICAS-like avionics, I would suggest to look at jsb/rleibner's groundwork respectively.

It is very unfortunate that the Canvas system is not exposing the sc::Element class itself to scripting space, so that this could be used by people to implement new elements by sub-classing existing ones - but for the time being, the cleanest approach to deal with these challenges is indeed coming up with a layered set of scripting space frameworks that encapsulate higher level concepts.

Anybody creating Nasal/Canvas- avionics from scratch not looking at the aforementioned efforts is very likely to do tons of redundant work, with the outcome almost certainly being less flexible and more of a resource hog than what we currently have. As a matter of fact, even the current "state of the art" will not easily support certain multi-instance use-cases, but at least Richard's MFD framework is prepared to do so (via Emesary).

Originally, D-LEON summed up the issue quite well when he presented the awesome Extra500 avionics suite on the forum, saying:

extra500 - Avidyne Entegra 9 IFD - approach
D-Leon wrote:NOTE: This sounds like a reusable framework but the encapsulation isn't as far and its optimised for the internal need.
There are some calls going over parents where no interface is "rechable" or defined.
Image



There is a more detailed summary of the issues surrounding most Nasal/Canvas avionics we have come to see over the years: http://wiki.flightgear.org/Canvas_Devel ... FlightGear
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: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: Eurocopter EC-145 current downloads

Postby litzi » Sun Jan 20, 2019 8:37 pm

Dear all,

I am certainly interested in the support you offer! (However, I missed your posts during christmas holidays.)

You can download the code from:

https://www.dropbox.com/s/t5djksqqzt9l8 ... 2.zip?dl=1

I tried to implement things found on other places: e.g. "Sensor" concept of Thorsten in ZIVKO EDGE to reduce property IO. Property rules for all the linear transformations, with the drawback the Canvas updates do not react to alised properties' changes. Nasal threading, however it seems not recommended to use it for cases including property IOs.

I am thankful for any specific hint or suggestion on my code, and will also check out the places you pointed me at.

litzi

[edit: replaced download link for a slightly improved canvas code]
Last edited by litzi on Sun Feb 10, 2019 10:33 am, edited 1 time in total.
litzi
 
Posts: 123
Joined: Sat May 03, 2014 9:59 pm
Location: AT
Version: 2018.3.1
OS: Ubuntu 14.04

Re: Eurocopter EC-145 current downloads

Postby litzi » Sun Jan 20, 2019 8:52 pm

Hmmm, degrees .. got some of those. Don't know if it helps me in better coding ;-)
litzi
 
Posts: 123
Joined: Sat May 03, 2014 9:59 pm
Location: AT
Version: 2018.3.1
OS: Ubuntu 14.04

Re: Eurocopter EC-145 current downloads

Postby StuartC » Fri Feb 01, 2019 3:06 pm

V1.2 now available. see first post.
StuartC
 
Posts: 3175
Joined: Fri Jun 18, 2010 9:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2019.1
OS: W10 64 bit

Re: Eurocopter EC-145 current downloads

Postby VicMar » Mon Feb 04, 2019 12:12 pm

Hi Stuart,

Thanks for another (vic)flyable helicopter added to my collection.

Please pass my thanks to all who have contributed.

Cheers,

Vic
Time flies like an arrow
Fruit flies like a banana
User avatar
VicMar
 
Posts: 2044
Joined: Sun Apr 06, 2008 6:53 pm
Location: Lancing. UK (EGKA)
Callsign: VicMar
Version: 2018.3.1
OS: OS X 10.12.6

Re: Eurocopter EC-145 current downloads

Postby StuartC » Mon Feb 04, 2019 2:44 pm

Your welcome
StuartC
 
Posts: 3175
Joined: Fri Jun 18, 2010 9:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2019.1
OS: W10 64 bit

Re: Eurocopter EC-145 current downloads

Postby legoboyvdlp » Fri Feb 08, 2019 4:49 pm

Code: Select all
   22.68 [ALRT]:systems    FlightRecorder: Property '/orientation/pitch-deg' specified multiple times. Check flight recorder configuration.
   22.68 [ALRT]:systems    FlightRecorder: Property '/orientation/roll-deg' specified multiple times. Check flight recorder configuration.
   22.69 [ALRT]:systems    FlightRecorder: Property '/rotors/main/torque' specified multiple times. Check flight recorder configuration.
   25.65 [ALRT]:io         C:/Users/redpa/Documents/FlightGear/Custom Aircraft/ec145/Models/mainrotor/mainrotor.xml: Use of <global> in material animation is no longer supported.
   26.71 [ALRT]:io         Cannot find image file ""
   34.66 [ALRT]:io         Could not find at least one of the following objects for animation: 'Plane'
   38.66 [ALRT]:io         Could not find at least one of the following objects for animation: 'screw.000', 'screw.001', 'screw.002', 'screw.003', 'Lamp1', 'Lamp2', 'Lamp3', 'Lamp4'
   38.66 [ALRT]:io         Could not find at least one of the following objects for animation: 'Panel', 'AsSwitchNav', 'NavOuter', 'NavInner', 'HDG', 'AltOuter', 'AltInner', 'VolNAV', 'VolCom', 'AsSwitchCOM', 'ComOuter', 'ComInner', 'CRS', 'BARO', 'PAN', 'PANUp', 'PANLeft', 'PANRight', 'PanDown', 'DidectTo', 'MENU', 'FPL', 'PROC', 'CLR', 'ENT', 'FmsOuter', 'FmsInner', 'SoftKey.000', 'SoftKey.001', 'SoftKey.002', 'SoftKey.003', 'SoftKey.004', 'SoftKey.005', 'SoftKey.006', 'SoftKey.007', 'SoftKey.008', 'SoftKey.009', 'SoftKey.010', 'SoftKey.011', 'Cover'
   38.66 [ALRT]:io         Could not find at least one of the following objects for animation: 'Cover', 'AP.L0', 'AP.L1', 'AP.L2', 'AP.L3', 'AP.L4', 'AP.L5', 'AP.R0', 'AP.R1', 'AP.R2', 'AP.R3', 'AP.R4', 'AP.R5'

Nasal runtime error: non-objects have no members
   64.61 [ALRT]:nasal        at C:/Users/redpa/Documents/Programs/FlightGear 2018.3.0/data/Aircraft/Instruments-3d/radar2/radar2.nas, line 46
User avatar
legoboyvdlp
 
Posts: 7981
Joined: Sat Jul 26, 2014 2:28 am
Location: Northern Ireland
Callsign: G-LEGO
Version: next
OS: Windows 10 HP

Re: Eurocopter EC-145 current downloads

Postby StuartC » Fri Feb 08, 2019 9:09 pm

Most of those objects are present and are working. For some reason, FG says it cant find them, but does. The errors go away if you change the object path to an absolute path. Happens on multiple aircraft.
StuartC
 
Posts: 3175
Joined: Fri Jun 18, 2010 9:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2019.1
OS: W10 64 bit

Re: Eurocopter EC-145 current downloads

Postby legoboyvdlp » Mon Feb 11, 2019 4:23 pm

litzi wrote in Sun Jan 20, 2019 8:37 pm:Dear all,
I am thankful for any specific hint or suggestion on my code, and will also check out the places you pointed me at.

litzi

[edit: replaced download link for a slightly improved canvas code]



Are you still having the stuttering? I didn't notice it when I took the ec145 for a fly.
User avatar
legoboyvdlp
 
Posts: 7981
Joined: Sat Jul 26, 2014 2:28 am
Location: Northern Ireland
Callsign: G-LEGO
Version: next
OS: Windows 10 HP

Re: Eurocopter EC-145 current downloads

Postby StuartC » Mon Feb 11, 2019 7:27 pm

The old terrain height map can cause a loss of framerates some times.
StuartC
 
Posts: 3175
Joined: Fri Jun 18, 2010 9:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2019.1
OS: W10 64 bit

PreviousNext

Return to Aircraft

Who is online

Users browsing this forum: Octal450 and 17 guests