Archived

This topic is now archived and is closed to further replies.

Guest Trevor de S

XML/C++ Gauges in FSX

Recommended Posts

Has anyone managed to get the example Cabin Comfort gauge to run in FSX.When I complile it and install it according to the instructions - taking a few liberties since a number of the files which are supposed to be there are missing, I can manage to get the XML gauge to display but not to operate as it appears not to be loading the C++ gauge.I changed the manual load line in the dll.xml file to true so that I should be prompted to load the gauge when the aircraft loads but I do not get any prompt.One possible source of my problem - I am unable to locate the simconnect.dll file anywhere in my system. Maybe it didn't make it down this far.Any help which anyone can offer would be appreciated.Cheers,Trevor

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

Simconnect.dll should be installed in your C:WINDOWSWindowsSxS folder, as it is designed to take advantage of the SideBySide versioning system.I currently have three versions of simconnect.dll so that SimConnect clients can choose whichever version they were designed to work with. ;)You may have to enable "hidden files and folders" in order to see it.ACES made the decision to use thw WindowsSxS scheme so they can continue to add and/or fix content in SimConnect without "breaking" any client code already developed and working properly.As for the sample project I haven't taken the time to look at it myself, since I've no immediate need for the technique.

Share this post


Link to post
Share on other sites

Thanks for the help Bill - I've found Simconnect.dll alright, I'm obviously somewhat deprived as I only have one copy.However I'm still looking for some help on why the system doesn't seem to load and use the C++ element of the gauge. I have not specifically referenced it in the panel.cfg file - Is this necessary?Cheers,Trevor.

Share this post


Link to post
Share on other sites

>Hope this helps,>-->Tom Gibson>Sorry Tom - Not really because the whole structure of the C++ file is so different from anything used in the C/C++ gauges with older versions of Flight Sim. To some extent it seems that listing the .dll file in the DLL.XML file should take care of that requirement, but not certain what lets the FS engine know that you want to use that particular LoadAddOn for the particular aircraft.The SDK says to load the new panel.cfg file to test it with the Lear45 but they failed to provide a panel.cfg file.Cheers,Trevor.

Share this post


Link to post
Share on other sites

Trevor,Had a quick look at the C++ portion of the Cabin Comfort example. What you are looking at is not a gauge. It is an FS module, so is not referenced in panel.cfg. The reference in dll.xml is required to load the module when FS itself is loaded.Doug

Share this post


Link to post
Share on other sites

Thank you, but this still gets me no closer to finding out how to get the example to work so I can progress to developing other C++/XML gauges for FSX.CheersTrevor.

Share this post


Link to post
Share on other sites

Ok, you put the Cabin_Comfort.dll in the FSX folder, right?You added the code to the dll.xml file:

<Launch.Addon>   <Name>Cabin Comfort</Name>   <Disabled>False</Disabled>   <ManualLoad>False</ManualLoad>   <Path>Cabin_Comfort.dll</Path>   <DllStartName>module_init</DllStartName>   <DllStopName>module_deinit</DllStopName></Launch.Addon>

I just compiled it and installed the xml gauge on a test panel. It worked right away...

Share this post


Link to post
Share on other sites

Yes to both of your queries, then copied CabinComfort folder to FSXGauges folder and changed section in the Lear45 panel.cfg to read://--------------------------------------------------------[ Window08 ]size_mm=225,145position=2visible=0ident=Testno_luminous=1gauge00=CabinComfort!CabinComfort, 0,0//--------------------------------------------------------Gauge displays perfectly under the Shift-9 toggle but all values are0.0 for the numeric values and 0 for the string values.Cheers,Trevor.

Share this post


Link to post
Share on other sites

Doug,>Had a quick look at the C++ portion of the Cabin Comfort>example. What you are looking at is not a gauge. It>is an FS module, so is not referenced in panel.cfg. The>reference in dll.xml is required to load the module when FS>itself is loaded.What do you see as the pluses and minuses of implementation of a "gauge" as a module vs. gauge?Patrick

Share this post


Link to post
Share on other sites

Hi all,Hope people are still reading/responding to this thread.I've been exploring the whole gauges/simconnect thing, and have managed to get most of the SDK examples running--SDK.Temperature.cpp, DialogBoxMode.cpp, SDK.Fuel_Selector.cpp, etc. I have the source for Cabin_Comfort but can't find any documentation as to how to install it and what ancillary files are required. For example, I don't know where the dll.xml file should go, and the edit of it that is listed doesn't look like XML to me. So I'm a bit confused!Is there a step-by-step readme somewhere that I need to get?Thanks!--John

Share this post


Link to post
Share on other sites

:(

Hope people are still reading/responding to this thread.I've been exploring the whole gauges/simconnect thing, and have managed to get most of the SDK examples running--SDK.Temperature.cpp, DialogBoxMode.cpp, SDK.Fuel_Selector.cpp, etc. I have the source for Cabin_Comfort but can't find any documentation as to how to install it and what ancillary files are required. For example, I don't know where the dll.xml file should go, and the edit of it that is listed doesn't look like XML to me. So I'm a bit confused!
It's highly unlikely that anyone would read a two year old thread, unless they have found it during a search... :( In any case, since the forums have gone through two software migrations in the past few years, a lot of the "code snippets" are now "hidden from view" because the forum software misinterprets the XML <tags> unless they are encapsulated in a {code} tag-pair. In fact, I can't even use a "[" symbol for the "code" in the last sentence, but have to substitute a curly-brace instead! :Thinking: Here is the (recovered) entry for the dll.xml file:
<Launch.Addon>   <Name>Cabin Comfort</Name>   <Disabled>False</Disabled>   <ManualLoad>False</ManualLoad>   <Path>Cabin_Comfort.dll</Path>   <DllStartName>module_init</DllStartName>   <DllStopName>module_deinit</DllStopName></Launch.Addon>

The dll.xml file goes in the same folder where the active copy of fsx.cfg is kept.

Share this post


Link to post
Share on other sites

Well! Happy someone was doing a search then :( Putting the CabinComfort reference into dll.xml definitely got it loaded, as I was querried about whether I wanted to trust the module, etc. But I don't get anything new in the 'tools' or 'add-ons' drop-down menus. How do I actually get to the beast?--John

:( It's highly unlikely that anyone would read a two year old thread, unless they have found it during a search... :( In any case, since the forums have gone through two software migrations in the past few years, a lot of the "code snippets" are now "hidden from view" because the forum software misinterprets the XML <tags> unless they are encapsulated in a {code} tag-pair. In fact, I can't even use a "[" symbol for the "code" in the last sentence, but have to substitute a curly-brace instead! :Thinking: Here is the (recovered) entry for the dll.xml file:
<Launch.Addon>   <Name>Cabin Comfort</Name>   <Disabled>False</Disabled>   <ManualLoad>False</ManualLoad>   <Path>Cabin_Comfort.dll</Path>   <DllStartName>module_init</DllStartName>   <DllStopName>module_deinit</DllStopName></Launch.Addon>

The dll.xml file goes in the same folder where the active copy of fsx.cfg is kept.

Share this post


Link to post
Share on other sites
Well! Happy someone was doing a search then :( Putting the CabinComfort reference into dll.xml definitely got it loaded, as I was querried about whether I wanted to trust the module, etc. But I don't get anything new in the 'tools' or 'add-ons' drop-down menus. How do I actually get to the beast?--John
You get the "beast" via the XML half of the system. That's all the module is good for!

Share this post


Link to post
Share on other sites