1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

FSX Pushback in C#

Discussion in 'SimConnect' started by JardY, 28/3/11.

  1. JardY

    JardY

    Joined:
    20/8/10
    Messages:
    45
    Country:
    france
    Hi everybody, I'm searching for about 2 hours now to know how can I start the pushback by clicking a button on an C# application...

    I write this code (piece of shi*) :

    PHP:
    Struct3 lStruct3 = new Struct3();
                    
    lStruct3.PUSHBACK_STATE 1;
                    
    gSimConnectHandle.AddToDataDefinition(DEFINITIONS.Struct3"TOGGLE_PUSHBACK""number"SIMCONNECT_DATATYPE.FLOAT640.0fSimConnect.SIMCONNECT_UNUSED);
                    
    gSimConnectHandle.SetDataOnSimObject(DEFINITIONS.Struct3SimConnect.SIMCONNECT_OBJECT_ID_USER0lStruct3);
                    
    gSimConnectHandle.ClearDataDefinition(DEFINITIONS.Struct3);
    Can someone tell me just what I have to use to make this action work ?

    Thanks !
  2. JardY

    JardY

    Joined:
    20/8/10
    Messages:
    45
    Country:
    france
    I'm still working on it with the following functions :

    The EVENTS are TOGGLE_PUSHBACK, KEY_TUG_HEADING and TUG_DISABLE.

    In fact, I don't really understand the heading I have to set with the TUG_HEADING... :-/

    PHP:
    gSimConnectHandle.TransmitClientEvent(SimConnect.SIMCONNECT_OBJECT_ID_USEREVENTS.PUSHBACK10,
                       
    GROUP_ID.GROUP1SIMCONNECT_EVENT_FLAG.GROUPID_IS_PRIORITY);
                    
    gSimConnectHandle.TransmitClientEvent(SimConnect.SIMCONNECT_OBJECT_ID_USEREVENTS.PUSHBACK2lCap,
                       
    GROUP_ID.GROUP1SIMCONNECT_EVENT_FLAG.GROUPID_IS_PRIORITY);

    gSimConnectHandle.TransmitClientEvent(SimConnect.SIMCONNECT_OBJECT_ID_USEREVENTS.PUSHBACK30,
                      
    GROUP_ID.GROUP1SIMCONNECT_EVENT_FLAG.GROUPID_IS_PRIORITY);
  3. Vitus

    Vitus

    Joined:
    29/11/06
    Messages:
    699
    Country:
    newzealand
    Hey JardY,

    just want to say: you are not alone! It seems like this heading variable is actually really strange. Fingers crossed that you'll find a solution (and share it with us ;))

    Cheers,
    Vitus
  4. JPC06240

    JPC06240

    Joined:
    23/6/11
    Messages:
    14
    Country:
    france
    [FSX] simConnect

    Hello,
    I am also trying to work with SimConnect, with VB .NET in my case. I can now read most of the FS X variables and process them to display them on a separate form. That's OK, except for ambiant temperature, which refuses to be displayed. I don't understand why, but I'll see that later.

    What I am looking for now is to transmit data (commands) from my client program to FSX. So I read your post with interrest, and I tried to translate it into VB. I failed, because several keywords are unknown from me : PUSHBACK_STATE, lcap.

    The documentation of the SimConnect SDK is confusing, and I desperatly search the web to find help.

    Thanks in advance.

    Jean-Paul

Share This Page