jan737 Posted December 3, 2003 Report Share Posted December 3, 2003 Hi, I'm using the PM boeing software with fs 2002. Now I'm building my own MCP with the FDS stuff. To set my barometer to the right setting I like to use a rotary encoder, but wich offset (read and write)do I need, to set the qnh up and down in hpa or mbar's? Kind regards Jan. Link to comment Share on other sites More sharing options...
Pete Dowson Posted December 3, 2003 Report Share Posted December 3, 2003 To set my barometer to the right setting I like to use a rotary encoder, but wich offset (read and write)do I need, to set the qnh up and down in hpa or mbar's? If you just what to Increment/Decrement it, just use the standard FS controls, like you would to assign them to buttons or keypresses -- KOHSLMAN_INC and KOHLSMAN_DEC (MS have allways mis-spelled Mr. Kollsman's name :) ). If you want to write to FSUIPC rather than use it like a pair of buttons you can send the controls via 3110. see the Programmers Guide. Otherwise, probably more efficiently for a rotary, you can read the value in 0330, increment or decrement it locally, and write it back to the same offset. If you only re-read it when you've not changed it for a second or so then it should be a lot faster and you can keep up with the rotary. For airliner use the rotary should also have a push-button action which sets standard altimeter pressure (1013.2 hPa or 29.92") for flying flight levels. Ideally you should keep a copy of the previous QNH value and swap between the two on alternative presses. This enables the QNH to be pre-set whilst still flying on Standard. Internally you will notice that FS operates in mb or hPa (x 16). Whether it displays hPa or inches of mercury is a gauge display function. Regards, Pete Link to comment Share on other sites More sharing options...
jan737 Posted December 3, 2003 Author Report Share Posted December 3, 2003 Peter, Thanks for the quick reply, Works great now up and down For airliner use the rotary should also have a push-button action which sets standard altimeter pressure (1013.2 hPa or 29.92") for flying flight levels. Ideally you should keep a copy of the previous QNH value and swap between the two on alternative presses. This enables the QNH to be pre-set whilst still flying on Standard. My rotary has a push button function but I don't understand yet how to set this up, so when I push the button the value goes to standard. Maybe you can explane? Kind regards Jan Link to comment Share on other sites More sharing options...
Pete Dowson Posted December 3, 2003 Report Share Posted December 3, 2003 My rotary has a push button function but I don't understand yet how to set this up, so when I push the button the value goes to standard. Maybe you can explane? Can you detect when the button is pushed? If so, when it is pushed, set the value to standard, which is 1013.2 hPA. The value to be written to IPC offset 0330 is 16 times this (i.e. 16211), as documented in the Programmers Guide. If you want to alternate that with the QNH, you have to read the vlaue first and keep a copy, then swap them back next time. It is just a matter of programming the logic. Regards, Pete Link to comment Share on other sites More sharing options...
jan737 Posted December 8, 2003 Author Report Share Posted December 8, 2003 Hi Peter No luck yet. When I push the button, the value goes one up every time(from 1013 to 1014hpa i.e). Not to the standard value of 1013 hpa. I think that I don't understand what you mean with your explanation that you send me before. Maybe you will explane again. Kind regards Jan. Link to comment Share on other sites More sharing options...
Pete Dowson Posted December 8, 2003 Report Share Posted December 8, 2003 When I push the button, the value goes one up every time(from 1013 to 1014hpa i.e). Not to the standard value of 1013 hpa. Are you sending decimal 16211 to offset 0330? It sounds as if you are simply incrementing it instead. I think that I don't understand what you mean with your explanation that you send me before. But I don't understand whayt you are doing since you don't tell me anything. Sorry. Maybe you will explane again. Write the 2-byte decimal value 16211 to the FSUIPC offset 0330. This will set the barometer to 1013.2 (16211 = 1013.2 x 16). It is surely clear enough? Have you looked at the Programmer's Guide in the SDK? I'm afraid I don't understand what the problem is. You asked which offset to change for the altimeter setting. I told you. It is 0330, as documented. If you write values to 0330 it affects the altimeter setting. The units are 1/16ths of an hPa. Just as it says in the document. What more can I say? Sorry. Regards, Pete Link to comment Share on other sites More sharing options...
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