Jump to content
The simFlight Network Forums


  • Content Count

  • Joined

  • Last visited

Community Reputation

0 Neutral

About Mikock

  • Rank
  1. Mikock

    Getting CG value

    Thank you! Now it works :)
  2. Hi! I have a small problem reading the current CG value from FSUIPC. I always get very hight values. For example: 4596416700483633152 And here is my source code: [...] long long int Value=0; DWORD dwResult; FSUIPC_Read(0x2EF8, 8, &Value, &dwResult); !FSUIPC_Process(&dwResult); return double(Value); [...] Maybe there is something wrong with my data type? Thank you for your help in advance!
  3. Hi Pete! Where can I find some examples? I studied the docs and the forum, but there is nothing exactly what I want to do?
  4. Hi! I am trying to write some weight on one specific station, but it doesm't work. Maybe I didn't understand the documentation about offset 0x1400. My code is: I like to write 1000lbs to station number 2. My airplane has 8 stations. I think there is something wrong on my code ;). Thanks you very much!
  5. Hi! Is there any function or offset, which I can check, if the connection to FSUIPC is still active? I am able to connect to the FS and to close this connection. But I like to check in a timer function every second, that the connection is active. Otherwise the user should be informed. I am using the C++ files. Or should I alway try to connect to the FS every second? But I think this isn't the best solution. ;)
  6. I am just starting with the programming with FSUIPC. I have corrected some things now, and I'll get now some strange characters in the label. (better than nothing :)) I think my problem is still to convert the result into a normal string. What is the data typ of the result (chTime)? Here is my corrected code: if(FSUIPC_Open(SIM_ANY, &dwResult)){ char chTime[3]; if(FSUIPC_Read(0x0238, 3, chTime, &dwResult)){ !FSUIPC_Process(&dwResult); ui->labelFSUIPC->setText(chTime); } } [/CODE]
  7. Good morning! Since some days I am tryingto read out some values from the FS2004 via FSUIPC. I am using the QT Creator to show my result in a small and simple form. I think my problem is an easy one. Here is my code: (It's a SLOT function connected with a pushButton) void MainWindow::connectFSUIPC(){ DWORD dwResult; if(FSUIPC_Open(SIM_ANY, &dwResult)){ char *chTime; if(FSUIPC_Read(0x0238, 1, &chTime, &dwResult)){ !FSUIPC_Process(&dwResult); QString str; str = *chTime; ui->labelFSUIPC->setText(str); } } } [/CODE] The connection and read out from the FS is successfully. I've tested it. But the variable str is empty. My label shows nothing. Maybe I made a conversion mistake? Thank you for your help! Michael
  8. Hi! I have some problems with two values of the vertical speed. I read out to values: Vertical Speed: 02C8 ( Output = VS * 60 * 3.28084 / 256 ) Vertical Speed at Touchdown: 030C ( Output = VS at TD * 60 * 3.28084 / 256 ) When I am airborn both values show me the vertical speed. But they have a significant difference. If the VSI is round 1 - 400 ft/min, the difference will be round about 50-100ft/min and if the VSI increase, the difference will also increase. When I am flying Cessna to compare the values with my VSI indicator, only the value of "Vertical Speed at Touchdown" (030C) seems to be correct! What is the difference between these two values? Thanks for your help! Michael
  9. Thanks to Paul and Pete, now it works fine!
  10. Good day! I am writing a small tool for my Flight Simulator. It should log some flight data. I am using the development language C#Sharp. With the help of FSUIPC I am trying ti get the data from the simulator. Some data works very good like airspeed, heading or lights switching. Today I have tried to read out my actual altitude. In FSUIPC there are some variables to get them (e.g. 0x0020 or 0x0570) But in this case I am only getting very strange values. I am cruising on 38000ft and I am only getting value = 0 When I am climbing to another level, I will get other strange values. It will change every second. Does anybody have an idea? Here are some code of it: [...] //Getting values from FSUIPC Offset agl = new Offset(0x0570); [...] //Transforming in feets double valagl = agl.Value * 3.28084 / (65536 * 65536); //Printing in label this.lblAGL.Text = valagl.ToString("f0"); [...] Thanks!

Important Information
