Pete Dowson Posted June 7, 2015 Report Posted June 7, 2015 I've just used this simple Lua plugin: ipc.writeFLT(0x86B4, 0.0) ipc.writeFLT(0x86B0, 0.0) ipc.writeFLT(0x86AC, 52.0) ipc.writeFLT(0x86A8, -0.47) ipc.writeFLT(0x86A4, -0.37) ipc.writeFLT(0x86A0, 0.5) to set the same values as you cameraData.fDeltaX.Value = 0.50f; cameraData.fDeltaY.Value = -0.37f; cameraData.fDeltaZ.Value = -0.47f; cameraData.fPitchDeg.Value = 52.00f; cameraData.fBankDeg.Value = 0.00f; cameraData.fHeadingDeg.Value = 0.00f; (but note that I wroyr 86A0 last, as that is the "trigger", and it succeeds in making the current view an angled overhead one from quite a way up. Not sure if that's your intetion. It certainly doesn't do "nearly nothing" as you reported. I really don't know what it is supposed to do. What units are those Delta's in, and relative to what? If I set them to 0 I'm looking at the nose wheel for under the aircraft someplace, so I assume they are relative to the aircraft's datum point. Pete
rfresh Posted June 7, 2015 Author Report Posted June 7, 2015 Yes those values are of the over head panel. Those overhead values are relative to the default VC view...which is as if you were sitting in the Captains seat looking forward...so it sounds like it worked for you via Lua. And yes, zeros puts you outside, at the a/c reference datum point...again looks like it worked for you Pete. As for A860 being last, remember I was using Paul's DLL so maybe he can confirm his code is sending A860 last. Maybe it isn't. But, over all Pete, it looks like your 't' version is working for this DOF() call. I'll continue to work with Paul and see if I can get it to work for me with my test app and his DLL wrapper. Remember, I have already got this working in my main app using SimConnect directly. If there is anything else you would like me to test for you Pete just let me know.
Pete Dowson Posted June 7, 2015 Report Posted June 7, 2015 Attached... Your log shows you are using version p still!!!! ********* FSUIPC4, Version 4.939p by Pete Dowson ********* To use a later version you have to put it into the Modules folder BEFORE running FS!!! Additionally, you are monitoring the offsets as type S8 (8bit signed) when as you surely know they are 32 bit floats (FLT32). Pete
rfresh Posted June 7, 2015 Author Report Posted June 7, 2015 Once again Pete, you assume everyone knows FSUIPC as well as you do...I have been away from it for many months and do not remember all of of the details about how to use it's logging features, what 'S8' stands for, etc. I'm finished here.
Paul Henty Posted June 7, 2015 Report Posted June 7, 2015 I was using Paul's DLL so maybe he can confirm his code is sending A860 last. Maybe it isn't. It's writing the entire 24 bytes (all six floats) in one go, starting at 0x86A0. So it's being written last in the sense that it's the only write taking place. Testing it here I get movement, but not it's not subtle and any value over 0 seem to have the same effect. For example, any value but 0 in the heading places me looking at the back of the pilot's seat (e.g. 180 degrees). Any value over 0 in bank puts me upside down (e.g. 180 degrees). Any value over 0 in deltax (e.g. 0.01) puts me to the right but so far outside the plane I'm no longer in the airport. I also tested this writing each float individually as in Pete's Lua with the same results. Here is the write log from FSUIPC for the same values used in the Lua script: 24 Bytes at once... 2217000 WRITE0[8832] 86A0, 24 bytes: 00 00 00 3F A4 70 BD BE D7 A3 F0 BE 00 00 50 42 ...?.p........PB 2217000 00 00 00 00 00 00 00 00 ........ Individual floats... 2218422 WRITE0[8832] 86A4, 4 bytes: A4 70 BD BE .p.. 2218422 WRITE0[8832] 86A8, 4 bytes: D7 A3 F0 BE .... 2218422 WRITE0[8832] 86AC, 4 bytes: 00 00 50 42 ..PB 2218422 WRITE0[8832] 86B0, 4 bytes: 00 00 00 00 .... 2218422 WRITE0[8832] 86B4, 4 bytes: 00 00 00 00 .... 2218422 WRITE0[8832] 86A0, 4 bytes: 00 00 00 3F ...? Paul
Pete Dowson Posted June 7, 2015 Report Posted June 7, 2015 Once again Pete, you assume everyone knows FSUIPC as well as you do...I have been away from it for many months and do not remember all of of the details about how to use it's logging features, what 'S8' stands for, etc. Well, it's only about one page in the User Guide. You never need to "know" it all, just know that it is documented, as I said when I mentioned it. Anyway, the main problem was your use of 4.939p instead of the update I provided a link to. Paul's method of writing all 24 bytes at once is correct too. It's only when using separate writes that 86A0 needs to be last. Pete Pete
pellelil Posted June 10, 2015 Report Posted June 10, 2015 Strange, because previously. It was using completely the wrong offsets! Best monitor the offsets (well the first 4 anyway) and show me the log. When I get a moment I'll try writing to them from FSinterrogate, or maybe a Lua plugin. The code in FSUIPC couldn't really be simpler. The typo just made it use the wrong set of offsets in the Simconnect call -- all parameters would have been zero I think. Pete Hi Pete Glad to see FS-Interrogate is still working :-) I have just myself recently "returned to FS" (P3Dv2.5) and I am in fact struggeling with getting up to speed with SimConnect to control the camera - more or less trying to accomplish the same as "rfresh". But it's worth the try to see it it is possible with FSUIPC in stead. Pelle
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