Jump to content

Sign in to follow this  
fnav77

Simconnect working with Plan-G, but not with AI Traffic, let alone ASN

Recommended Posts

Hello fellow simmers,

 

I think I set up Simconnect correctly as it works perfectly with Plan-G (the VFR software). 

 

I read somewhere that a good way to test Simconnect is to use the AI traffic .exe from the SDK on the 2nd machine (a laptop), so I just did that.

All I get is a black window opening, with a "-" flashing, and closing within about 10-15 seconds. Nothing else. I guess it means Simconnect is not configured properly, but as I said, Simconnect works well with Plan-G, which I am very happy with. Why would it work with one application and not another?

 

I eventually want to get ASN to work with Simconnect, but I think I am still far away from it.

 

Any early suggestions please....? 

Thanks


Visit my YouTube channel https://www.youtube.com/Captain Nav

Follow me live on Twitch http://www.twitch.tv/captainnav

Share this post


Link to post
Share on other sites

Hi Fnav,

 

It's probably best to start with some of the basics about what SimConnect is and then we can move on to sorting your problem.

 

FSX basically runs around in a loop checking the state of all sorts of stuff like your control positions, engine thrust, velocities and accelerations. It also runs any AI vehicles you have in the mix, worries about what the ground looks like from where you are looking, deals with the weather and a fair bit more besides.

Somehow in all of this it can also find time to tell interested external programs the state of various controls and sensors and respond to any input they may have.

 

The role of SimConnect is to provide this interface. When installed correctly, the SimConnect server hangs around waiting for external programs to introduce themselves. They do this using the SimConnect client program and its associated configuration files. These essentially tell the client program where the server is and which technique to use to talk to it (3 options are available). So, client program talks to SimConnect client an tells it to say to the server, "Hi, my name is X", to which the server (hopefully) replies "No error occurred when you asked me that". The client says stuff like "I'm interested in position, radio frequencies and outside temperature" and again, the server tends to respond "No error occurred" - which basically means "Gotcha!". Depending on the what was asked for or sent, the server may then periodically inform the client of changed data and/or when specific things happen. To make sure that this doesn't cause your FSX session to grind to a halt, it tends to do all this without showing you the user any indication that it is going on - unless you ask it specifically to do so.

 

So let's relate this to your situation.

Firstly we must check that the server has been installed correctly.

Next that the client has been installed and that it has been configured to talk to the server.

Then we need to know that your 1st 3rd party client connects to the server.

Finally we need to identify any add in that is NOT connecting and work out why.

 

Therefore, please can you give:

1) a summary of what you have installed over and above FSX (and the edition of that would be handy).

2) a list of the addins using SimConnect that you're trying to use

3) a summary of what is and is not working

 

Depending on what that tells us, I might then talk you through producing a SimConnect log file and we can investigate further.

 

Cheers,

 

Z

Share this post


Link to post
Share on other sites

Z, thanks for your reply.

I am not currently near my set up, but I will give you the info you requested:

Fsx gold edition (maybe deluxe, i have a doubt) with acceleration pack.

Addons installed are Plan G and Active Sky Next

Plan G is working well with Simconnect, no worries there.

However, as I said in previous post, AI Traffic from the SDK just opens for about 10 seconds with a black windows and then closes. I understand this application serves as a test to see if simconnect works well.

ASN just freezes, but I need to look at it again....

Thanks


Visit my YouTube channel https://www.youtube.com/Captain Nav

Follow me live on Twitch http://www.twitch.tv/captainnav

Share this post


Link to post
Share on other sites

No problem. Shout when you're ready.

If you switch the SimConnect console window on, you'll see what version you're running at what happens (if anything) as you load your add-ons. Using Acceleration the version should be the same as mine (think it's 10.0.61637).

 

ASN freezing suggests it doesn't succeed in connecting to the server. If other things are, it suggests that the ASN configuration is the problem.   But that's for later.

 

Z

Share this post


Link to post
Share on other sites

Hi Z,

 

I have version FSX Gold Edition with Acceleration Expansion Pack

 

On both machines, I have:

SimConnect Client version 60905, 61242 and 61259

I also have MFSX Acceleration SDK version 61637

 

I have a SimConnect.ini in my Documents/Flight Simulator X Files on the main PC

I have a SimConnect.xml in AppData/Roaming/Microsoft/FSX on the main PC

I have a SimConnect.cfg in My Documents on the other machine (the client?)

 

Sorry I don't know what the SimConnect console window is and how to switch it on??


Visit my YouTube channel https://www.youtube.com/Captain Nav

Follow me live on Twitch http://www.twitch.tv/captainnav

Share this post


Link to post
Share on other sites

Hi Fnav.

 

If you edit your SimConnect.ini on your main machine (server) you'll see a line that I would imagine presently reads "console=0" or maybe ";console=1". Change it to read "console=1" without the quotes or any traces of a semi-colon and save.

 

Setting the value like this will cause a little window to display when you start FSX. As it does so, the first lines written confirm the version of SimConnect running on the server. We're both expecting 61637, right?

 

When a client program tries to connect to the server, it sends an "Open" command, and this will show in the console.

If the client program starts and there is no "Open" line, then it's a fair bet that the client program is not configured correctly. Typically the local SimConnect.cfg contains has the wrong address for the server or is using the wrong port. This can happen if the .cfg file is using an IP address to refer to the server and the server gets its IP address from a DHCP server - i.e. it can change.

 

If the "Open" line is there, then we'll want to have a more detailed look at the output to see what is happening.

 

So:

1) Set the console on

2) Start FSX and take a look at the output

3) Start your 1st 3rd party add on and take a look at the output

4) Etc for each add on.

 

If SimConnect is the source of the problem then we'll know at this point.

 

Cheers,

 

Z

Share this post


Link to post
Share on other sites

Thank you for the reply.... I think I am an hopeless case....

 

I set the console to 1, but unfortunately, the little window you mentioned does not appear, only FSX opens.... I then try to start flying around, but still nothing. I then launch Plan G on the client machine, connect it to FSX (on the server machine), it all works well, however the console/window still does not appear.

 

I don't mean to be difficult, but it just does not work as predicted, What I don't understand is that I get a connection via SimConnect with Plan G (on the client) and everything works well. I have FSX on the Server machine and Plan G on the client, and the two talk to each other no problem.

 

This is my SimConnect.ini

 

 

 

[simConnect]
level=verbose
console=1
;RedirectStdOutToConsole=1
;OutputDebugString=1
;file=c:\simconnect%03u.log
;file_next_index=0
;file_max_index=9

 

Does this look correct?

 

Thanks again.


Visit my YouTube channel https://www.youtube.com/Captain Nav

Follow me live on Twitch http://www.twitch.tv/captainnav

Share this post


Link to post
Share on other sites

Hmm. Very odd. That is exactly the setting that controls the display of the debug window.

I can't understand why it wouldn't work unless that is not the SimConnect.ini that FSX is reading.

 

Please could you search your system to see if there is more than one SimConnect.ini on the FSX machine?

 

If there is not, could I trouble you to rename the one you have to SimConnect.ini.old and create a new one in Notepad/Wordpad containing just the top 3 lines? (not a very structured step I admit but I'm just trying to eliminate any reason why the file may not be being read). Then start FSX again and once the menu is displayed cycle through open windows to confirm the existence or otherwise of the window.

 

Z

Share this post


Link to post
Share on other sites

Thank you for your reply, Z. :smile:

 

Still no luck.

I searched the system in the Windows Start menu and I only have one simconnect.ini file.

I followed your instruction and renamed the file I have to SimConnect.ini.old and created a new one (SimConnect.ini) with the top 3 lines. I started FSX, still no luck. Apart from the FSX window, no other window opens up.

What do you mean, though, by:

 

once the menu is displayed cycle through open windows to confirm the existence or otherwise of the window.

 

What menu are we talking about? FSX's?

When you talk of windows, do you mean the windows for let's say Internet Explorer, Windows Media Player, etc....that open at the bottom of the PC screen?

 

 

PS: For info, in Control Panel/Programs/Programs and Features/ I have:

Microsoft Flight Simulator SimConnect Client v.10.0.60905.0 (size 2.46MB),

61242 (2.40MB) and

61259 (2.41MB).

I also have Microsoft Flight Simulator X: Acceleration SDK version 10.0.61637 (size 332MB) and Microsoft Flight Simulator X: Acceleration version 10.0.61637.0 (no size info).

Same on Client machine with, for some reason, one extra thing, Microsoft Flight Simulator SDK version 1

 

Although all these are listed as programs, they do not seem to appear anywhere on both machines. Is this normal?

 

What I don't understand is that for PLAN G, for example, there is a FS Connection Parameters section where you basically tell Plan G what you are connecting it with (SimConnect in my case), then what network mode (IPv4, IPv6, etc...), the Server IP address and Port. Same for Aivlasoft EFB (although this one uses its own networking solution).

There is none of that with the AITraffic.exe from the SDK, for example....Anyway, I am at a loss.


Visit my YouTube channel https://www.youtube.com/Captain Nav

Follow me live on Twitch http://www.twitch.tv/captainnav

Share this post


Link to post
Share on other sites

Sadly, I am too at a loss and this is beyond my experience, so I'm hoping others may chip in with ideas at this point.

 

With regard to the AI traffic thing, the way I understand it is that the client application must refer to the SimConnect.dll library that it wishes to use. As you point out above, there may be multiple versions installed (in the WinSxS folders), each of which may communicate to FSX servers (potentially on different machines) using the parameters specified in the cfg file 

 

And yes I did mean the FSX menu.

 

The only other thing I can think to try is setting the ini file to produce an output file - but if the console isn't displaying then I can only think that the ini file is not being read.

 

Help! We need a grown up! :help::unknw:

Share this post


Link to post
Share on other sites

By way of an addendum I came across a thread on FSDeveloper (can't insert hyperlinks at the moment for some reason) that might indicate the cause of the problem.

Have you by any chance installed the Steam Edition? It seems that it does something in its installation that forces .Net programs to use a particular version of the SimConnect dll - which may be incompatible with FSXA.

 

Just a thought.

 

Z

Share this post


Link to post
Share on other sites

Even though you may have already read it once, I would suggest a re-read of the topic titled "Connecting to FSX from a Networked PC with SimConnect" in the Plan-G manual.

 

Then, assign static IP addresses to both the FSX computer and the one that has Plan-G.

 

Make sure that you have shared the directories containing scenery.cfg, fsx.cfg, and fsx.exe on the FSX computer and that they are asccessible to the Plan-G computer.

 

Install Plan-G outside of Program Files, or Program Files (.86).  This is recommended for all flight sim related files.  I have a directory C:\FlightSim\, where I put all of my fs related programs.

 

I find that creating a separate SimConnect.cfg for each program, containing only the parameters for that program and placing it within the program's directory works better for me.

 

I don't have a 'SimConnect.cfg' in the Documents\Flight Simulator X Files directory.  This is just my preference and I'm sure that others use the global simconnect.cfg file just fine.

 

On the other hand, on my FSX computer the SimConnect.xml within my fsx.cfg contains the code for all of the applications that utilize SimConnect.

 

Once everything is set up.. Start FSX, start Plan-G, hit the "connect" option, and "lock", or "sync".  Give it a moment. 

 

If you can see your aircraft then it's working.  If all is well go to the "View" tab and select "Traffic". 

 

If you can't see your aircraft, then go back and check everything because it's not quite right yet.

 

Good luck.

Ernie


Ernest Pergrem

Share this post


Link to post
Share on other sites

Hi Ernie.
 
<quote> I find that creating a separate SimConnect.cfg for each program [...etc] </quote>
 
How do you programs tell SimConnect.dll which SimConnect.cfg file to use?
 
Z

Share this post


Link to post
Share on other sites

Z,

I can't remember the sequence, but SimConnect is smart enough to look in the application's directory for the cfg file if not found in Documents\Flight Simulator X Fles for visa versa.

 

So, instead of having one simconnect.cfg with multiple ports, one for each application.   I have one section containing a single port in each applicaton's directory. 

 

I'm sure it sounds a bit confusing and somewhat redundant, but it's easier for me to remember which port is used by which application.

 

Ernie


Ernest Pergrem

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.
  • Donation Goals

    AVSIM's 2020 Fundraising Goal

    Donate to our annual general fundraising goal. This donation keeps our doors open and providing you service 24 x 7 x 365. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. We reset this goal every new year for the following year's goal.


    18%
    $4,700.00 of $25,000.00 Donate Now
×
×
  • Create New...