fanda Posted April 19, 2007 Report Posted April 19, 2007 Hello Everyone It seems that the new FSUIPC 4.09 no longer returns the air file name in the offset 0x3c00. The result is always empty (no errors reported). Replacing dll with 4.01 solves the problem. Any idea ? Thank you With best regards, Oleksiy Frolov
Pete Dowson Posted April 19, 2007 Report Posted April 19, 2007 It seems that the new FSUIPC 4.09 no longer returns the air file name in the offset 0x3c00. The result is always empty (no errors reported). Hmm. It works fine here. The AIR file details are read directly to that offset from SimConnect, and that hasn't been changed at all in any version. How about a Log file, please? The AIR file details are logged at the very same time as 3C00 is populated. Did you look? How are you checking this? Try FSInterrogate2. Here are relevant parts of a log I've just obtained, and also checked via FSInterrogate2 with IPC logging enabled: ********* FSUIPC4, Version 4.09 by Pete Dowson ********* User Name=... User Addr=... FSUIPC4 Key is provided WideFS7 Key is provided Running inside FSX ... 14043 SimStart Event: Initialising SimConnect data requests 14045 FSUIPC Menu entry added 14278 i:\my documents\flight simulator x files\738 at EGCC.FLT 14279 G:\FSX\SimObjects\Airplanes\B737_800\Boeing737-800.AIR 14806 System time = 13:12:18, FSX time = 13:12:16 (12:12Z) 15265 Aircraft="Boeing 737-800 Paint1" 16616 Advanced Weather Interface Enabled 140623 READ0 3C00, 256 bytes: 47 3A 5C 46 53 58 5C 53 69 6D 4F 62 6A 65 63 74 G:\FSX\SimObject 140623 73 5C 41 69 72 70 6C 61 6E 65 73 5C 42 37 33 37 s\Airplanes\B737 140623 5F 38 30 30 5C 42 6F 65 69 6E 67 37 33 37 2D 38 _800\Boeing737-8 140623 30 30 2E 41 49 52 00 00 00 00 00 00 00 00 00 00 00.AIR.......... ... 158886 G:\FSX\SimObjects\Airplanes\Extra300\Extra300S.AIR 159798 Aircraft="Extra 300S Paint1" 165816 READ0 3C00, 256 bytes: 47 3A 5C 46 53 58 5C 53 69 6D 4F 62 6A 65 63 74 G:\FSX\SimObject 165816 73 5C 41 69 72 70 6C 61 6E 65 73 5C 45 78 74 72 s\Airplanes\Extr 165816 61 33 30 30 5C 45 78 74 72 61 33 30 30 53 2E 41 a300\Extra300S.A 165816 49 52 00 00 00 00 00 00 00 00 00 00 00 00 00 00 IR.............. 178702 System time = 13:15:02, FSX time = 13:13:20 (12:13Z) 178703 *** FSUIPC log file being closed Memory managed: 56 Allocs, 56 Freed ********* FSUIPC Log file closed *********** Regards Pete
fanda Posted April 19, 2007 Author Report Posted April 19, 2007 Found the problem, sorry for the trouble I was not waiting for FSUIPC to initialize. Somehow it worked in FS9, but no longer did in FSX. So I added a check for 0xFFFF in 0x4D2 and it works . Thank you With best regards, Oleksiy
Pete Dowson Posted April 19, 2007 Report Posted April 19, 2007 I was not waiting for FSUIPC to initialize. Somehow it worked in FS9, but no longer did in FSX. It would probably have been available earlier in FSUIPC4 before 4.03, when this change occurred: * Re-arranged SimConnect initialisation sequences to avoid doing anything much at all until after the first “SimStart” event. This is to avoid an apparently serious SimConnect bug which causes crashes and other problems with FSX when more than one SimConnect client program is being started and one or more comes up with the security warning. On this: So I added a check for 0xFFFF in 0x4D2 and it works . This is only coincidence. FSUIPC4 has no control over exactly when SimConnect information arrives. The path for the currently loaded aircraft is requested as part of the Initialisation after "SimStart", along with a multitude of other things, but when it then arrives is another matter. If you want to be sure your code works no matter what might be holding up SimConnect data, best to just test the first byte of 3C00 for non-zero -- it will read zero (null string) until the path is obtained. And of course always either operate a timeout or allow interruption, just in case! ;-) Regards Pete
fanda Posted April 20, 2007 Author Report Posted April 20, 2007 actually it is a brilliant idea. One can use the non-null air file path as an indication that FSUIPC has began receiving the data. Thanks regards, Oleksiy
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now