Jump to content
The simFlight Network Forums

mrpubnight

Members
  • Posts

    3
  • Joined

  • Last visited

mrpubnight's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Hello everyone, I was wondering if anyone has experienced anything like this: In trying to debug a problem I noticed that the values that I'm writing to an offset appear to be different when I read them immediately after. Initially I thought, because the difference in value is so small that it was either a rounding problem or the FS engine was actually moving the plane (I'm setting Lat/Long) but I tried it again last night in Slew Mode which I would think should keep the plane stationary. Anyway, below is the log. Specifically look at the 0x0560 and 0x0568 offsets. I've included all the READs in case there is something else there that hints at why this is going on. You'll see that the READ values after the WRITE commands are differnt. I would have hoped to believe that the value I write (assuming it's a legal value) would be the value that is actually set. Please note: The differences here do not amount to any real spatial differnce, however, this discovery was made during the development of a workaround for a problem I'm having with WRITE commands not processing at all - which will be a different post :). Any help would be appreciated. Thanks, Frank. ********* FSUIPC, Version 3.75 by Pete Dowson ********* Running inside FS2004(original release) FSUIPC Key is provided WideFS Key is provided [Continuation log requested by user] Module base=61000000 ClassOptions: UIPCMAIN=FF7F, FS98MAIN=FF7F, FS2KMAIN=FF5E WeatherOptions(Orig)=40003605[40003605] InitDelay: 0 seconds WeatherReadInterval=4 LogOptions=0000000D 47950078 READ0 0570, 8 bytes: 00 00 45 FB FB 00 00 00 47950078 READ0 0020, 4 bytes: 9B 7C 00 00 47950078 READ0 02B4, 4 bytes: 00 00 00 00 47950078 READ0 0580, 4 bytes: 01 42 00 FA 47950078 READ0 02BC, 4 bytes: 00 00 00 00 47950078 READ0 0560, 8 bytes: 00 00 49 36 65 1C C0 FF 47950078 READ0 0568, 8 bytes: 00 00 A4 4F FA 64 13 67 47950078 READ0 02A0, 2 bytes: 06 08 47950078 READ0 0578, 4 bytes: 39 31 DA FD 47950078 READ0 057C, 4 bytes: 3B B1 03 00 47950078 READ0 02C8, 2 bytes: 00 00 47950078 READ0 0264, 2 bytes: 00 00 47950078 READ0 05DC, 2 bytes: 01 00 47950141 WRITE0 0560, 8 bytes: 8E 63 82 7E B3 41 C0 FF 47950187 WRITE0 0568, 8 bytes: 00 04 5B B0 05 1B FC 66 47950234 READ0 0568, 8 bytes: 00 00 5B B0 05 1B FC 66 47953859 READ0 0570, 8 bytes: 00 00 45 FB FB 00 00 00 47953859 READ0 0020, 4 bytes: 6D B7 00 00 47953859 READ0 02B4, 4 bytes: 00 00 00 00 47953859 READ0 0580, 4 bytes: 7F 36 00 FA 47953859 READ0 02BC, 4 bytes: 00 00 00 00 47953859 READ0 0560, 8 bytes: 00 00 82 7E B3 41 C0 FF 47953859 READ0 0568, 8 bytes: 00 00 5B B0 05 1B FC 66 47953859 READ0 02A0, 2 bytes: F7 07 47953859 READ0 0578, 4 bytes: EE 2C DA FD 47953859 READ0 057C, 4 bytes: 4D 99 04 00 47953859 READ0 02C8, 2 bytes: 00 00 47953859 READ0 0264, 2 bytes: 00 00 47953859 READ0 05DC, 2 bytes: 01 00 47953906 READ0 0238, 2 bytes: 00 27 47953969 READ0 0238, 2 bytes: 00 27 47954219 READ0 0570, 8 bytes: 00 00 45 FB FB 00 00 00 47954219 READ0 0020, 4 bytes: 6D B7 00 00 47954219 READ0 02B4, 4 bytes: 00 00 00 00 47954219 READ0 0580, 4 bytes: 7F 36 00 FA 47954219 READ0 02BC, 4 bytes: 00 00 00 00 47954219 READ0 0560, 8 bytes: 00 00 82 7E B3 41 C0 FF 47954219 READ0 0568, 8 bytes: 00 00 5B B0 05 1B FC 66 47954219 READ0 02A0, 2 bytes: F7 07 47954219 READ0 0578, 4 bytes: EE 2C DA FD 47954219 READ0 057C, 4 bytes: 4D 99 04 00 47954219 READ0 02C8, 2 bytes: 00 00 47954219 READ0 0264, 2 bytes: 00 00 47954219 READ0 05DC, 2 bytes: 01 00
  2. Pete thank you for the quick reply. Let me please start by saying that your endless devotion to this is nothing short of incredible and very much appreciated. Thanks. Now back to my headache ;)... To answer your questions: Version: 3.75 Library: C# I'm running FSUIPC v3.75 and using the provided C# library. I'm getting an return code of 7 when trying to connect which, from my understanding is meant to represent FSUIPC_ERR_VERSION, however, upon review of the read/write log it appears as though there is another, different problem (see below). Well, it's probably related as the error code I'm getting from the code and the error reported by the logging don't exactly match but if, as the log states, FSUIPC can't create a file mapping then that may explain why it can't read information, namely the FS version. Strangely though, when it tries to read the offsets for FSUIPC_Version,FSUIPC_FS_Version, and FSUIPC_Lib_Version the "read" and "get" results all come back ok (0) although the results of the FSUIPC_Get command are 0 for FSUIPC_Version and FSUIPC_FS_Version and 2 for FSUIPC_Lib_Version. With regards to my implementation, I'm simply trying to connect (at this stage) to FSUIPC from within a window's service. As you probably already know, window's services normally DON'T like to interact with running applications (i.e. running applications on the desktop) as they are generally designed to work in a non-interactive manner, however, there is an option to have the service "Interact with the desktop". This allows the service to communicate (in theory) with currently running applications at the user-session level. Honestly, I figured if I could get the window handle for the FSUIPC module then everything else would be ok. As I mentioned in my original post, I am able to get the window handle for FS but it can't seem to connect, apparently because it can't create or open the filemapping. Oddly though, when I debug the code and step through the FSUIPC library code, it does appear to be able to create a file mapping (a handle is returned for it). Admittedly I don't necessarily understand all the ins and outs of user32.dll API. I was hoping someone else in this forum had experience with this but given the lack of responses I'm guessing they haven't - or perhaps are too shy to discuss. Either way, any information you can provide would be helpful. Thanks, Frank PS I've removed the name and email address of the registrar for this version of FSUIPC as this is a client application and I don't know if they would want their information posted online. I can provide it to you privately if you require it. ********* FSUIPC, Version 3.75 by Pete Dowson ********* Running inside FS2004(original release) FSUIPC Key is provided WideFS Key is provided [Continuation log requested by user] Module base=61000000 ClassOptions: UIPCMAIN=FF7F, FS98MAIN=FF7F, FS2KMAIN=FF5E WeatherOptions(Orig)=40003605[40003605] InitDelay: 0 seconds WeatherReadInterval=4 LogOptions=0000000D 49411734 System time = 06:04:11, FS2004 time = 01:02:50 (16:02Z) 49492000 IPC ERROR: Cannot OpenFileMapping (Error=5) 49492094 IPC ERROR: Cannot OpenFileMapping (Error=5)
  3. Hi there, I'm a first time poster but long time reader. I'm trying to get FSIUPC data to be read and written from a Windows service. So far I've been met with limited success. Initially I was having problems getting any responsiveness from FSUIPC but realized that it wasn't getting the window handle to the FSUIPC module in FS. Having resolved that I'm still having problems getting FSUIPC connected. Currently it's getting hung up on retrieving the FSUIPC version which I'm assuming is because it may be having a problem reading data. Again, FSUIPC can get the window handle for the module but can't seem to connect (ERROR: FSUIPC_ERR_VERSION). Has anyone else had any success (or failure) getting this to work? Any insight would be appreciated. Thank you, Frank.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.