Board index FlightGear Development Canvas

File not found errors.

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.

File not found errors.

Postby StuartC » Sat Aug 25, 2012 12:06 pm

Im trying to follow the wiki to use canvas with FG 2.8.

I created the Nasal/canvas folder in my aircraft folder and copied the 3 files as suggested.
i created a file called canvasloader.nas and have it starting from the nasal area of my set file as per the wiki instructions.
Im getting this error:-

Trying to load own canvas/api.nas from sub folder under $FG_AIRCRAFT:/Nasal/canvas
File not found: ( insert the correct paths to all 3 files here ).

It reading the correct paths, but not seeing the files?????????????
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: File not found errors.

Postby Hooray » Sat Aug 25, 2012 4:40 pm

It reading the correct paths, but not seeing the files?????????????


there are some things that you may need to check (depending on your OS), such as:

- case sensitivity (folders and files)
- file system/user permissions?
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: File not found errors.

Postby StuartC » Sat Aug 25, 2012 6:15 pm

Wsing Vista pro, FG runs as administrator. Case is exactly as per the WIKI
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: File not found errors.

Postby Hooray » Sat Aug 25, 2012 6:54 pm

copy/paste the paths shown, open a console (command.com/cmd.exe) and type DIR [PATH HERE] and see if the path is found there or not.

Alternatively: copy the path, open a window explorer window, paste the path into the address bar and type enter - if the path is valid, it should ask you if/how you want to open the file (unless you have a the *.nas extension already registered, so that it would open the associated program).
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: File not found errors.

Postby StuartC » Sun Aug 26, 2012 11:23 am

Done, both ways, paths are correct.
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: File not found errors.

Postby Hooray » Sun Aug 26, 2012 1:18 pm

are there any weird/non-standard characters in the path, even just whitespaces?
Could you post the whole path?
If everything is correct, that would seem to suggest that the file handling code in io.nas doesn't work as expected on non Linux systems, which would be surprising.
The code that I posted doesn't know anything about the OS at all ... except of course, that it's using forward slashes - could that be a problem on windows?

I'd like to understand what the problem is, but if all else fails - just load the canvas modules via your aircraft-set.xml file into the corresponding Nasal namespaces (canvas & std)
Last edited by Hooray on Sun Aug 26, 2012 1:21 pm, edited 1 time in total.
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: File not found errors.

Postby StuartC » Sun Aug 26, 2012 1:20 pm

This is the path as it appears in windows:-

Code: Select all
G:\games\FlightGear\FGUKaircraft\F-23C\Nasal\canvas
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: File not found errors.

Postby zakalawe » Mon Aug 27, 2012 2:48 pm

Bit confused, with 2.8, surely you don't need to copy the files into your aircraft? They're already part of the fgdata directory.
zakalawe
 
Posts: 1259
Joined: Sat Jul 19, 2008 5:48 pm
Location: Edinburgh, Scotland
Callsign: G-ZKLW
Version: next
OS: Mac

Re: File not found errors.

Postby StuartC » Mon Aug 27, 2012 2:51 pm

Well, I did the manual check and I couldnt see them.
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: File not found errors.

Postby Gijs » Mon Aug 27, 2012 3:00 pm

You're right, they didn't end up in 2.8.0: https://gitorious.org/fg/fgdata/trees/r ... .8.0/Nasal
They were added on 2 August, so after the release branches were created.
Airports: EHAM, EHLE, KSFO
Aircraft: 747-400
User avatar
Gijs
Moderator
 
Posts: 9544
Joined: Tue Jul 03, 2007 3:55 pm
Location: Delft, the Netherlands
Callsign: PH-GYS
Version: Git
OS: Windows 10

Re: File not found errors.

Postby Hooray » Mon Aug 27, 2012 9:30 pm

zakalawe wrote in Mon Aug 27, 2012 2:48 pm:Bit confused, with 2.8, surely you don't need to copy the files into your aircraft? They're already part of the fgdata directory.


Gijs is right, this is a little unfortunate, because you were actually planning to commit the Nasal modules prior to the release originally: http://www.mail-archive.com/flightgear- ... 37622.html

In fact, Stuart specifically asked about this issue shortly before the release: http://www.mail-archive.com/flightgear- ... 38080.html
I told him that he's right, but that the modules would be safe to commit, because there'd be zero chance for breakage - and suggested he should get in touch with you.

Stuart then got in touch with me and changed the release announcement to get rid of the Nasal-related lines instead.
I didn't send a message to you, because Stuart raised the issue already on the devel list, so I thought you'd be aware of it - and that it'd be a "code freeze" issue then.

Still, I added this to the "lessons learned" section in the release plan: http://wiki.flightgear.org/Release_plan#2.8

All that said, the error could be related to the aircraft not being in $FG_ROOT.
Someone else mentioned a releated issue here: https://code.google.com/p/flightgear-bu ... 0Milestone
Last edited by Hooray on Mon Aug 27, 2012 9:59 pm, edited 2 times in total.
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: File not found errors.

Postby StuartC » Mon Aug 27, 2012 9:55 pm

So, if I actually move the files into where they would have been, if they had been in the release, it should find them ?
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: File not found errors.

Postby Hooray » Mon Aug 27, 2012 9:56 pm

yes, of course.
no need for any manual loading then.
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: File not found errors.

Postby StuartC » Mon Aug 27, 2012 10:23 pm

ok, i'll give that a try tomorrow.
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: File not found errors.

Postby StuartC » Wed Aug 29, 2012 7:02 pm

Copying the 3 files into the default canvas location worked, the loader detects they are there.

Now, the canvas-test.nas file, where can that be downloaded ? Is it available on its own or can someone post the code for it???
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

Next

Return to Canvas

Who is online

Users browsing this forum: No registered users and 0 guests