Jump to content
The simFlight Network Forums

How to apply airbrakes?


Recommended Posts

Hi there,

I have a sailplane that has airbrakes, they can be applied with the "/" key. I used the Visual Basic command SendKeys("/") to apply them.

Now I learned that a Finnish pilot, with the default keyboard layout, but using a Finnish keyboard, has no "/" key! Instead he must use Shift-F7.

Question: can the airbrakes be applied with a direct write thru FSUIPC?

Thanks!

Link to comment
Share on other sites

I have a sailplane that has airbrakes, they can be applied with the "/" key. I used the Visual Basic command SendKeys("/") to apply them.

All FS keyboard controls can be changed anyway, by the user, in Options-Controls-Assignments, so it is always hazardous using specific keys. You should always use the controls you want, instead.

Question: can the airbrakes be applied with a direct write thru FSUIPC?

Airbrakes == speedbrakes == spoilers. Spoiler controls Spoilers_On, Spoilers_Off and Spoilers_Toggle. The '/' key is normally assigned (in FS Options-Controls-Assignments) to Spoilers Toggle.

You can either send FS the control, directly (as a WM_COMMAND) or via offset 3110 in FSUIPC (which has the advantage of also working via WideFS), or, via FSUIPC, you can control the spoiler setting directly in offset 0BD0.

Regards,

Pete

Link to comment
Share on other sites

Hmmm... writing directly thru fsuipc doesn't seem to work!

My code is:

Public Function SpoilerFull_SET() As Boolean

varLong = 16383

If FSUIPC_Read(&HBD0, 4, VarPtr(varLong), dwResult) Then

If FSUIPC_Process(dwResult) Then SpoilerFull_SET = True Else SpoilerFull_SET = False

End If

LastError = ResultText(dwResult)

End Function

The spoiler stays where it is...... someone any ideas?

Link to comment
Share on other sites

Hmmm... writing directly thru fsuipc doesn't seem to work!

My code is:

Public Function SpoilerFull_SET() As Boolean

varLong = 16383

If FSUIPC_Read(&HBD0, 4, VarPtr(varLong), dwResult) Then

If FSUIPC_Process(dwResult) Then SpoilerFull_SET = True Else SpoilerFull_SET = False

End If

LastError = ResultText(dwResult)

End Function

You could try an FSUIPC_Write call, instead of a Read?

Pete

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • 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.