Jump to content
Sign in to follow this  
n4gix

XML gauge crashes FS

Recommended Posts

HI, I have written a large complex XML gauge but it is unstable, with occasional crashes of FS, either to a black screen or back to desktop.I seem to remember that this can be caused by a corrupt bitmap.Any ideas?cheers,nick

Share this post


Link to post
Share on other sites

Well, a bit of expanded information would be great, however:-If crashes are occasional, it is possible that they happen for a given conditon. Maybe a corrupted bmp is called then, so replacing all "conditional" bmps with a known-good bmp could help to find the problem.-Are nested macros used? Could be that in some case they are called recursively, starving resources. Other thing to consider is whether "goto" operator (g0,g1,etc) is used, it is done properly.-Is there any call to a C gauge inside your gauge? (like DDawson's Sound Gauge).I've never got a blue screen or fatal crash of FS with my gauges, though I did get hungs because of bad macro coding. Hope this helps.Tom

Share this post


Link to post
Share on other sites

Thanks Tom for the help. This has never happened before so I guess that's why I'm a bit confused. I use the standard map macros, C:fs9gpsC:fs9gpsand no goto's. There's no calls to C gauges. I suppose it must be a bitmap. Is there any way to test them, and what parameters would constitute corruption?cheers,nick

Share this post


Link to post
Share on other sites
Guest ridgell

im out of my league with you guys, but.....i did have a problem with a CTD. after pouring through my code, and begging for help i found it was a gauge placed -2 off the screen, it did not always crash, just perhaps 1 in 4 runs...was maddening. i first thought it must be something to do with the last gauge i added ( normal reaction) but...are you getting an error message ?mine threw an error that i was out of available memory...really misleading...i thought i had programmed some kind of loop. check the panell cfg...for any gauge going over the display edge even -1 can mess things up.

Share this post


Link to post
Share on other sites

OK, I'll check for that. However, I put invisible gauges off the normal viewing area, that is no bitmaps or click areas. These gauges just control functions. I've been employing this method for ages with no problems, but maybe that's ok so long as they do not have any bitmaps.Someone else has loaded the bitmaps, changed colour depth, changed it back and saved. I thought doing this on another computer might 'clean-up' a corrupted bitmap. The CTD still happens. I think it's in the code somewhere.If I use

Share this post


Link to post
Share on other sites

>>It would crash everytime. Removing the colour switch made it>more stable. I've always found XML very robust, so this seems>very strange.Nick, that sounds similar to the problem I've had with some systems CTDing with any gauge that uses either "Transparency" or "Transparent" as keyword attributes. Clearly, some systems have issues with filling polygons with transparent color!In fact, I've still not 100% bulletproofed my GNS530, as even without "Transparency" or "Transparent" attributes, it will still crash on some systems!What is truly strange is that if I follow this sequence, the gauge WILL load and run, reserving the crash until trying to change the aircraft (i.e., unload the panel).1) Comment out all instances of the GNS530, start then stop FS92) Enable the GNS530 on the sub-panel popup window, start FS9. Normal load, no crash, popup GNS530 works perfectly.3) Enable the GNS530 on the main panel, change a/c and reload. Normal load, no crash, both main panel and popup work perfectly.4) Enable the GNS530 on the VC, change a/c and reload. Instant CTD!I'm ready to call in Ghostbusters! ;)


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

>>>>>It would crash everytime. Removing the colour switch made it>>more stable. I've always found XML very robust, so this>seems>>very strange.>>Nick, that sounds similar to the problem I've had with some>systems CTDing with any gauge that uses either "Transparency">or "Transparent" as keyword attributes. Clearly, some systems>have issues with filling polygons with transparent color!BINGO!!!!I did a global search and replace for #000000 and substituted #000001...No more crashes on panel load with all three operational: main, zoom, and vc.Clearly there is an issue with some systems (perhaps video card and/or drivers) that choke on filling polygons with transparency...


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

RATS!!!After some additional testing, even with #000001 changed, the gauge is generating a CTD again on panel load.Oddly enough, one can load to the VC with no problem, but switching view to the 2d will cause an ntdll.dll error.Here are the results of a debug session I ran, perhaps someone can shed some light on this:Unhandled exception at 0x77f8353b in FS9.EXE: 0xC0000005: Access violation reading location 0x04ae9118.77F8351C mov edi,dword ptr [ecx+8] 77F8351F mov ecx,dword ptr [ebp-4] 77F83522 add edi,dword ptr [ecx+4] 77F83525 test byte ptr [edi+5],10h 77F83529 jne 77F83547 77F8352B mov ecx,dword ptr [ebx+24h] 77F8352E movzx edx,word ptr [edi] 77F83531 mov dword ptr [ebp-4],edi 77F83534 lea edi,[edi+edx*8] 77F83537 cmp edi,ecx 77F83539 jae 77F83568 77F8353B cmp word ptr [edi],0 //falls over dead here!Call Stack> ntdll.dll!77f8353b() //error here! ntdll.dll!77f5752c() ntdll.dll!77f5818d() ntdll.dll!77f944a8() ntdll.dll!77f57d70() ntdll.dll!77f58a3a() ntdll.dll!77f944cb() ntdll.dll!77f58bcd() ntdll.dll!77f59037() kernel32.dll!77e82441() ntdll.dll!77f5d8e2() ntdll.dll!77f59b7d() ntdll.dll!77f59037() FS9.EXE!00445067() FS9.EXE!00438349() FS9.EXE!00435ffa() ntdll.dll!77f59037() ntdll.dll!77f939de() ntdll.dll!77f939e3() kernel32.dll!77e74e36() FS9.EXE!00436221() FS9.EXE!0044b28f() FS9.EXE!0044b298() Here is the log of FS9's loading:'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9FS9.EXE', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32ntdll.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32kernel32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32user32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32gdi32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32advapi32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32rpcrt4.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32comctl32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9shfolder.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32winmm.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32imm32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32msacm32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32msvcrt.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32version.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9msvcr70.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9mfc70.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9oleacc.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32shlwapi.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32shell32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32ole32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32oleaut32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9msvcp70.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSWinSxSx86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.1515_x-ww_7bb98b8acomctl32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32d3d9.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32d3d8thk.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32riched32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9riched20.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9language.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32clbcatq.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32comres.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32dsound.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32ddraw.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32dciman32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32d3dim.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32wtsapi32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32winsta.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesABLSCPT.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesACONTAIN.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesUTIL.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesAI_PLAYR.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesATC.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesCONTROLS.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesFSUI.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32comdlg32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32MSCTF.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesDEMO.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesDYNAMIC.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesFACILITIES.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesFE.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesFLIGHT.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesG2D.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9pixomatic.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesG3D.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesGLOBAL.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9Modulesgps.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9Modulesgps_export.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesINSTRUCTOR.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesMAIN.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9Modulesmpchat.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesMULTIPLAYER.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesPANELS.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesREALITY.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9Modulessb3gaugebridge.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesSIM1.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesSimScheduler.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesSOUND.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesSYMMAP.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesTERRAIN.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesTraffic.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesVISUALFX.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesWeather.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9ModulesWINDOW.DLL', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32wdmaud.drv', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32msacm32.drv', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32midimap.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32ksuser.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32msxml4.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32urlmon.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32dinput.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32hid.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32setupapi.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32dpnet.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32ws2_32.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32ws2help.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32rsaenh.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32msadp32.acm', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9GaugesESLibertyXL2.gau', Symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSWinSxSx86_Microsoft.Windows.GdiPlus_6595b64144ccf1df_1.0.10.0_x-ww_712befd8GdiPlus.dll', No symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9GaugesES_XMLSound.gau', Symbols loaded.'FS9.EXE': Loaded 'C:Program FilesMicrosoft GamesFlight Simulator 9GaugeSound.dll', No symbols loaded.'FS9.EXE': Loaded 'C:WINDOWSsystem32apphelp.dll', No symbols loaded.The thread 'Win32 Thread' (0xec8) has exited with code 0 (0x0).Unhandled exception at 0x77f8353b in FS9.EXE: 0xC0000005: Access violation reading location 0x04ae9118.First-chance exception at 0x77f8353b in FS9.EXE: 0xC0000005: Access violation reading location 0x04ae9118.The thread 'Win32 Thread' (0x8d8) has exited with code 0 (0x0).The thread 'Win32 Thread' (0x8dc) has exited with code 0 (0x0).The thread 'Win32 Thread' (0x948) has exited with code 0 (0x0).The thread 'Win32 Thread' (0x94c) has exited with code 0 (0x0).The thread 'Win32 Thread' (0x950) has exited with code 0 (0x0).The thread 'Win32 Thread' (0x9c0) has exited with code 0 (0x0).The thread 'Win32 Thread' (0x9c4) has exited with code 0 (0x0).The thread 'Win32 Thread' (0x914) has exited with code 0 (0x0).The thread 'Win32 Thread' (0x98c) has exited with code 0 (0x0).The thread 'Win32 Thread' (0x9c8) has exited with code 0 (0x0).The thread 'Win32 Thread' (0xab4) has exited with code 0 (0x0).The thread 'Win32 Thread' (0xac8) has exited with code 0 (0x0).The program '[2240] FS9.EXE: Native' has exited with code 0 (0x0).


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

>Hi Bill, what did you use to generate the list?>cheers,When the "crash window" offered the option to "Debug," I selected it. This lauched MSVC++ .NET 2003 and reloaded FS9 inside the debug routine.MSVC++ "decompiled" FS9.exe and allowed me to see what instruction was falling over dead with an "unrecoverable exception."I suspect that there is a problem executing the transparency instruction, but I'll be darned if I know (a) why, or (:( how to avoid it.The error only occurs on some machines, but there's no common hardware that I can identify. Among those that choke-and-puke are AMD and Intel both, ATI and nVidea cards, etc. It has failed on humble P4 2.1 GHz machine (my office machine) and a brand new, top of the line Toshiba laptop... :-erks :-roll


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

Hi Bill, I think I'm sorted. I had a couple of syntax errors although the gauge fired up. But what appears to be the fix is that I had 3 click areas covered by one total area for visibility, and then used Left and Right to split the total area into 3 areas. I've now converted these into 3 seperate areas.cheers,nick

Share this post


Link to post
Share on other sites

>Hi Bill, I think I'm sorted. I had a couple of syntax errors>although the gauge fired up. But what appears to be the fix is>that I had 3 click areas covered by one total area for>visibility, and then used Left and Right to split the total>area into 3 areas. I've now converted these into 3 seperate>areas.Interesting! I'll comment out my entire routine to see if the crashing syndrome goes away on my GNS530 gauge.It's GOT to be a hidden syntax error I suspect, because the precise SAME code (mostly) is used for the GNS430 which DOESN'T ever crash! ;)


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

Well, well, well...As it happens, there was no problem in the area, but I did find two .... sections of code for the "popup Menus" that for some reason were causing the CTD on my test machine.Funny that the exact same code works perfectly with many systems, but not all systems!In any case, I wound up having to nest a list of text string stuff's within a single ....structure to stop the crashing!


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...