Jump to content
The simFlight Network Forums

Chatchai Suttisatid

Members
  • Posts

    11
  • Joined

  • Last visited

Posts posted by Chatchai Suttisatid

  1. hello everyone

     

    I have question about control throttle on cessna(default plane) by c#.net.when i control throttle to 100%( value = 16384) the Prop level will be come to 0. i don't know why.did you have any idea for this.

     

    ENG1_Throttle_lever = 088C

    ENG1_Prop_lever = 088E

     

    my code

     

    private Offset<int> ENG1 = new Offset<int>(0x088C);  // Basic integer read and write example

     

    ......

     

     private void button1_Click(object sender, EventArgs e)
            {
              
                this.ENG1.Value = 16384;

            }

     

    Thank you.

     

  2. I have some question about offset.this came from above. now i can control L_Wiper,AUTOBRAKE_SELECTOR and other if this have variable is "unsigned char". So I tried to control VNav,LNav and other <-- this variable is bool.

    I add this 

    ...

    private Offset<bool> controlbit = new Offset<bool>(0x3340, true);

    private Offset<int> sendControl = new Offset<int>(0x3110, true);

    ....

    sendControl.Value = EVT_VNAV;
    controlbit.Value = true;
    .....
     
    but don't work 
    1. Maybe I choose wrong offset "3340";
    2. If have other resource please advice to me.
    I'm have fun with this.
     
    Thank you.
  3. Thank you for your reply. now I can got value from "L Wiper" offset is "6494"  this offset have 4 position " 0: PARK 1: INT 2: LOW 3:HIGH"

    So I set wiper position HIGH and got Value "3". and i will control L_Wiper  with this code.This code I applied from above.

     

    private Offset<int> controlParameter = new Offset<int>(0x3114, true);

    private Offset<int> sendControl = new Offset<int>(0x3110, true);

    .....

    private readonly int LWiper = 69668;

    .....

     private void btnlight_Click(object sender, EventArgs e)
            {
               
                sendControl.Value = LWiper;
                FSUIPCConnection.Process();
            }
    .....
     
    This code can control Wiper to "PARK" or Value="0". I don't have any idea to change position with my need. Cloud you show me for some example. I'm not good English if don't understand.please tell me.
    Thank you.
  4. Thank you for your answer. I tried to check follow your advice.That work with with Beech baron58 from fsx.I can get value from Gear status ,Nav Light, etc  and control Gear Up and down , Nav Light on/off.

    after that i check value from 737ngx. I can get value from offset 642F LTS_DomeWhiteSw yes!! that's work but i cannot send value to change switch position from 0=DIM to 1=OFF by code 

     

    private Offset<byte> DimLight = new Offset<byte>(0x642F,true);

    ....

     private void btnlight_Click(object sender, EventArgs e)
            {
                try
                {
                    DimLight.Value = 1;
                    FSUIPCConnection.Process();
                }
                catch (Exception ex)
                {
                    MessageBox.Show(ex.Message, AppTitle, MessageBoxButtons.OK, MessageBoxIcon.Error);
                }
            }
     
    I read offset mapping for pmdg 737ngx.pdf. and put 
    [sDK]
    EnableDataBroadcast=1   in 737NGX_Options.ini  already
     
    1. in document wrote"All offsets are READ ONLY" that's mean I can't control back to "LTS_DomeWhiteSw"?
    2.Can i use C# 2010 to control that?
    3.I cannot find PMDG_NGX_SDK.h in sdk folder this folder have only NewWeather.h. find wrong folder?
     
     
    thank you for your advice again.
     
     
  5. Hello every one .my name is chatchai. and today I have question about get value from panel PMDG 737ngx. before I write C# FSUIPC for get some value.I will recheck address before.

    but I have some problem is when i switch Auto break to max .The Value is "0". it not change. I check value by use FS-Interrogate and pick up address 2F80 to Quick data window 1.

     

    1. did i choose true address (2F80)?

    2. if i choose wrong. how do i known which address is true?

     

    Thank you

×
×
  • 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.