Jump to content
The simFlight Network Forums

scruffyduck

Members
  • Posts

    146
  • Joined

  • Last visited

Everything posted by scruffyduck

  1. Hi Pete Apologies for another dumb question. I am looking at using the offsets 0x3127, 3128 and 312C to disable all the FSUIPC weather functions so that I can set things up externally. I am clear in setting the byte in 3127 and also rewriting the data every five seconds or so. My limited understanding of masks etc means that I am not clearwhat I need to put in the 32bits at 3128 - do I set the bit to 1 for each position that I want to effect and then set the bit to 1 in the corresponding bits at 312C? Basically I just want to turn everything off to work on controlling things myself. ALso I am writing stuff to work on FS9 as well as 2k2. I assume that since this controls FSUIPC options it will have the same effect in both? thanks in advance
  2. Hi pete Just to let you know that i have now delved into FSInterrogate and it does indeed answer all my questions - thanks again!
  3. Hi Pete Thanks for your reply - dunno what I meant by two bytes base either :? by conversion I was referring to the calculations I need to do to get the offset data into a useable form. I had realised that it is not efficient to process every single request one at a time and I am batching them up. Thanks for the info on the hex number - I did manage to figure that one out after a while - I can change the 'endianess' of my meory blocks and when I did that it all worked. Thanks also for the pointer to FSInterrogate - it is to my huge embarrasment that I did not realise what it would do for me :oops: :oops: . I'm leaving back for the UK in a few hours and when I get home I will investigate it in detail - hopefully that will stop me asking dumb questions :) :)
  4. Thanks Pete At the top of the pdf file - programmers guide to FSUIPC there are a couple of urls - I don't have my notebook with me so can't tell you which ones they are exactly - one points to a fasm related site which does not seem to have anything related to FS6IPC or FSUIPC and the other is to a danish site?? - the link given is dead - pete lillendal or somesuch? Thanks for the explanation - that is more or less as I understood it - to get it working in my language environment I needed to change the declares around - particularly the parameter types so I spent some happy hours with the Win32 API :roll: :roll: I finally figured things out today - I wanted to hide all the offset and byte size data in a class so I am now reading it from a private look-up table. The other thing I was trying to get my head araound was the sequence of read and write messages. Finally figured that for reads it is readRequest --> processRequests ---> get and convert the return data. whilst writing is writeRequest ----> convert The Data ---> process request - leastway that is how I have it and OI can black box the interface class now and forget about how it works :D :D I have another question though - and this is down to my ignorance in handling hex and binary data types. I am reading the data fine from FS but getting brain damage trying to convert it into a useful number. It is probably a combination of my ignorance of the numbers and how to manipulate themplus my lack of experience in manipulating memory directly. For example I am trying read magnetic variation - it is in two bytes base on your excellent documentation - I think the number is a signed 16 bit integer :? I have a mag variation of 3degW which is being reported in the FSUIPC log as 4A FF (from memory) but so far I cannot get the actual value out of it even though I am dividing by 65536 and multiplying by 360. Ah well if you could confirm my assumption that it is a 16bit signed integer then I have some other ideas.
  5. OK apologies before I start on this one - if I have missed the obvious place that it is documented in then just point me If it is in the c++ documentation for fsuipc then I don't have it here in Florida and I can look at it when I get back to the UK as I only brought the Visual Basic with me. I have looked in the programmers guide which is great for identifying the offsets etc but the urls shown for further info seem to be dead. I am trying to get my feeble mind around how the interface works. I understand C++ a little, Visual Basic a lot, but I use another flavor of Basic (REALBasic). I have converted the Visual Basic program into my version and have a working interface so that I can read and write data to and from FS using FSUIPC. I am not at all sure how it works though. I understand the concept of creating a filemapping object pointing at memory (I think) and that I can make read and write requests which I then process using the process routine (which uses windows messaging?). However somewhere in the middle of all this the miracle happens and that I have not gotten to the bottom of yet. I can see that the read request sets up a header and space after it to hold the returned data. A write request sets up a write header and the data to be sent. The process routine then executes the read and write and the read data ends up in the memory after the read request. At the moment the class I have for FSUIPC exposes all it's methods and properties as public. What I am trying to do is firstly understand at a more pseudocode level how things happen. Any pointers (no pun intended :wink: ) much appreciated
  6. Hi Pete Many thanks for that - at the moment I think I only need to be accurate to within +/- 10deg over relatively short distances so that should work fine
  7. Hi all I am writing a program which uses FSCUIPC to control different things like weather etc depending on location. I have an algorithm to calculated distance between two points but wondered if anyone could point me at where to find one to determine the bearing of one location (position of the aircraft) to another (waypoint). thanks in advance
×
×
  • 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.