DuckyLucky 11 Posted January 20, 2011 Share Posted January 20, 2011 Here is a solution for those who prefer to use the keyboard for throttle control. No need to purchase a hardware joystick/throttle if you don't have one! Note that this solution will require you to download, install and configure a few pieces of free software (see Download and Install the following free Software below). You will also need to modify keyboard assignments in FSX. Note 1: in order for this solution to work there must be NO HARDWARE JOYSTICK/THROTTLE plugged in. Note 2: the required modifications to your FSX keyboard assignments will affect ALL aircraft - not only Airbus X. This is not a problem if you run the script every time you fly (recommended) or if you are okay with the new assignments. Download and Install the following free Software -------------------------------------------------------------------------------- 1. PPJoy (Virtual Joystick Driver) (info) After you download and install PPJoy, you must run the Configure Joysticks utility to add a virtual joystick. Ensure you choose "Controller 1" . 2. AutoHotkey (Scripting Utility for Controlling Input Devices) (info) Straightforward - just download and install 3. AutoHotkey-PPJoy Library (Allows AutoHotkey to talk to PPJoy) (info) After you download the zip file, unzip it to a folder on your desktop then just copy the PPJoy.dll and Lib folder to the same folder that AutoHotkey.exe is installed (eg. C:\Programs Files\AutoHotkey\) . Create the Script ------------------------------------ Next create the script that will enable the custom keyboard throttle functions within FSX. Copy/cut the following code below then open notepad text editor and paste the code. Save the file anywhere you wish and name it "PPJoy Throttle.ahk". After saving, execute it! #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. SendMode Input ; Recommended for new scripts due to its superior speed and reliability. SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory. #Persistent #InstallKeybdHook OnExit, ExitHandler FullFwd := 0 Idle := 100 Step := 1 ThrottleAxis := 3 Pos := Idle #IfWinActive, Microsoft Flight ; Keyboard Throttle PPJ_Init() ; Grab the Joystick PPJ_SetAxis(ThrottleAxis, Pos) $F1:: if (Pos < Idle) return Send {F1} return ~F2:: Pos := Idle PPJ_SetAxis(ThrottleAxis, Pos) return F3:: Pos += Step if (Pos > Idle) Pos := Idle PPJ_SetAxis(ThrottleAxis, Pos) if (Pos = Idle) Send {F2} return $F4:: Pos -= Step if (Pos < FullFwd) Pos := FullFwd PPJ_SetAxis(ThrottleAxis, Pos) if (Pos = FullFwd) Send {F4} return ExitHandler: PPJ_Term() ; Release the Joystick ExitApp #IfWinActive Here are the actions the script assigns to funcction keys F1..F4: F1 - Throttle reverse thrust (Note that F1 is used only for engaging thrust reversers. It will have no effect unless throttles are first moved to idle) F2 - Throttle cut (i.e. Idle thrust or disengage reverse thrust) F3 - Throttle decrease thrust (does not allow you to enter reverse range. Instead, use F1 to engage reverse thrust. See F1 above) F4 - Throttle increase thrust You will also need to modify assignments within FSX's controls options. In FSX go to SETTINGS -> CONTROLS -> BUTTONS/KEYS: F1 - Throttle (decrease quickly) F2 - Throttle (cut) F3 - Throttle (decrease) F4 - Throttle (increase) Link to comment Share on other sites More sharing options...
Andrey-AFL 0 Posted March 27, 2011 Share Posted March 27, 2011 Thank u much for solution) I've done everything as u describe but only F4 - throttle increase isn't working! Is the scrip right? Link to comment Share on other sites More sharing options...
DuckyLucky 11 Posted March 28, 2011 Author Share Posted March 28, 2011 Hi Andrey Yes the script is working for me. If you can post some screenshots of your setup maybe I can figure out what went wrong. I would need to see screenshots of the following : 1) Your PPJoy configuration - Start Menu -> Programs -> PPJoy Joystick Driver -> Configure Joysticks 2) Your FSX controls settings - In FSX go to SETTINGS -> CONTROLS -> BUTTONS/KEYS 3) Your running AutoHotkey session - double-click the AutoHotkey tray icon Link to comment Share on other sites More sharing options...
Udit Kalia 0 Posted April 15, 2011 Share Posted April 15, 2011 Even I tried this but no luck, the F4 key is moving the throttle smoothly, it is stuck . Please Help !!!!!!! Thanks Udit Kalia Link to comment Share on other sites More sharing options...
DuckyLucky 11 Posted April 25, 2011 Author Share Posted April 25, 2011 Even I tried this but no luck, the F4 key is moving the throttle smoothly, it is stuck . Please Help !!!!!!! Thanks Udit Kalia Hi Udit I need some more information. If you can post some screenshots of your setup maybe I can figure out what went wrong. I would need to see screenshots of the following : 1) Your PPJoy configuration - Start Menu -> Programs -> PPJoy Joystick Driver -> Configure Joysticks 2) Your FSX controls settings - In FSX go to SETTINGS -> CONTROLS -> BUTTONS/KEYS 3) Your running AutoHotkey session - double-click the AutoHotkey tray icon Link to comment Share on other sites More sharing options...
dg350z 0 Posted May 16, 2011 Share Posted May 16, 2011 Even I tried this but no luck, the F4 key is moving the throttle smoothly, it is stuck . Please Help !!!!!!! Thanks dg350z Link to comment Share on other sites More sharing options...
emmeth 58 Posted May 18, 2011 Share Posted May 18, 2011 Hi, this evening I'll give the procedure a try. In case it worked, is there any chance to set the F1, F2, F3, F4 to default FSX ones ? .. . therefore F1 cut, F4 full, F2 and F3 decrease and increase respectively. I am reading here almost no feedbacks, does the above procedure work guys ? Thx Link to comment Share on other sites More sharing options...
emmeth 58 Posted May 18, 2011 Share Posted May 18, 2011 I have followed the instructions but when I launch the Configure Joystick my w7 tells me : " Cannot open the PPJoy Device driver, please install PPjoybus.sys first... ??? Any hints please ? Link to comment Share on other sites More sharing options...
emmeth 58 Posted May 18, 2011 Share Posted May 18, 2011 I have manged to fix the problem above but to no avail, throttle is always stuck....... How about to release a patch ? I consider the throttle quite important in a plane, like wings and engines, if one of this components does not work, well, the plane becomes difficult to fly...you know what I mean.... Link to comment Share on other sites More sharing options...
emmeth 58 Posted May 19, 2011 Share Posted May 19, 2011 The script where has to be launched ? Within the OS or within another software example Hotkey ? In case it was Hotkey the correct environment , where are please the instructions on how to use that script within Hotkey software ? Thanks in advance about the details Link to comment Share on other sites More sharing options...
Aerosoft Aerosoft Team [Inactive Account] 51558 Posted May 19, 2011 Aerosoft Share Posted May 19, 2011 I have manged to fix the problem above but to no avail, throttle is always stuck....... How about to release a patch ? I consider the throttle quite important in a plane, like wings and engines, if one of this components does not work, well, the plane becomes difficult to fly...you know what I mean.... The problem is that we do not really know what to fix. We created he system to work on a standard FSX where the throttle channel can be intercepted and interpreted differently. Now some people do not let FSX handle the joystick axis (for example using FSUIPC) or have joystick drivers that send multiple channels for the same axis. Some people also do not have a throttle (even though it simply is part of the product requirements). System requirements: Microsoft Flight Simulator X (SP2, Acceleration or Gold Edition) Windows XP / Vista (32Bit or 64Bit) / Windows 7 with the latest Service Packs Microsoft Visual C 2005 SP1 Redistributable Package Microsoft Visual C 2008 SP1 Redistributable Package Intel Core 2 Duo CPU (2x 2666Mhz) or equivalent (Core 2 Quad CPU recommended) 2 GB RAM DX9 Graphic Card with at least 256 MB (512 MB highly recommended) Mouse with mouse wheel Joystick with throttle (The systems expect the default FSX throttle axis to be used) Download-Size: 240 MB Installations-Size: 500 MB Link to comment Share on other sites More sharing options...
emmeth 58 Posted May 19, 2011 Share Posted May 19, 2011 The problem is that we do not really know what to fix. We created he system to work on a standard FSX where the throttle channel can be intercepted and interpreted differently. Now some people do not let FSX handle the joystick axis (for example using FSUIPC) or have joystick drivers that send multiple channels for the same axis. Some people also do not have a throttle (even though it simply is part of the product requirements). System requirements: Microsoft Flight Simulator X (SP2, Acceleration or Gold Edition) Windows XP / Vista (32Bit or 64Bit) / Windows 7 with the latest Service Packs Microsoft Visual C 2005 SP1 Redistributable Package Microsoft Visual C 2008 SP1 Redistributable Package Intel Core 2 Duo CPU (2x 2666Mhz) or equivalent (Core 2 Quad CPU recommended) 2 GB RAM DX9 Graphic Card with at least 256 MB (512 MB highly recommended) Mouse with mouse wheel Joystick with throttle (The systems expect the default FSX throttle axis to be used) Download-Size: 240 MB Installations-Size: 500 MB I suggest to let your products use 100% what FSX uses, if FSX use a keyboard your products must use it as well, if FSX uses a external controller your products must use them as well, if FSX uses a Kinetic controller ( ! ) 3rd party add ons must use them as well. Diversions from this rule will lead into lot of tech/marketing troubles IMHO. Link to comment Share on other sites More sharing options...
Matt_Smith 1116 Posted May 19, 2011 Share Posted May 19, 2011 hmm Link to comment Share on other sites More sharing options...
DuckyLucky 11 Posted May 19, 2011 Author Share Posted May 19, 2011 The script where has to be launched ? Within the OS or within another software example Hotkey ? In case it was Hotkey the correct environment , where are please the instructions on how to use that script within Hotkey software ? Thanks in advance about the details Hi emmeth Yes, the script must be run within the AutoHotkey environment. You need to save the script as a text file: Right-click an empty spot on your desktop or in a folder of your choice.In the menu that appears, select New -> AutoHotkey Script (this menu will appear only if AutoHotkey is installed). (Alternatively, select New -> Text Document.)Type a name for the file, ensuring that it ends in .ahk. For example: Test.ahk Note that renaming file extensions in windows can be tricky. Please follow the procedures here to ensure the file extension was renamed properly. is there any chance to set the F1, F2, F3, F4 to default FSX ones ? .. . therefore F1 cut, F4 full, F2 and F3 decrease and increase respectively. Yes. It would require changing the keys in the script to match your FSX configuration. I will make the necessary modifications and post them a bit later. Link to comment Share on other sites More sharing options...
emmeth 58 Posted May 20, 2011 Share Posted May 20, 2011 Hi, your explanation is as complete as detailed but still It doesn't work for me. For example, once everything is up and running ( installations, configurations, script within Hotkey etc etc.. ) do I have to see the virtual joystick under the section " Device and Printers " of W7 64 ? I don't, hence I can't calibrate it and therefore, I suppose, FSX can't recognize there is a ( virtual ) joystick to use and therefore all the stuff doesn't work into FSX. ( I guess ) The script is properly named and properly loaded into the Hotkey software. It took also the icon with the " H " in it. Only the reverse function is recognized into FSX, using the keyboard. Any help is really much appreciated. Thanks in advance Link to comment Share on other sites More sharing options...
DuckyLucky 11 Posted May 21, 2011 Author Share Posted May 21, 2011 Hi, your explanation is as complete as detailed but still It doesn't work for me. For example, once everything is up and running ( installations, configurations, script within Hotkey etc etc.. ) do I have to see the virtual joystick under the section " Device and Printers " of W7 64 ? I don't, hence I can't calibrate it and therefore, I suppose, FSX can't recognize there is a ( virtual ) joystick to use and therefore all the stuff doesn't work into FSX. ( I guess ) The script is properly named and properly loaded into the Hotkey software. It took also the icon with the " H " in it. Only the reverse function is recognized into FSX, using the keyboard. Any help is really much appreciated. Thanks in advance emmeth Try this newer version of PPJoy: PPJoy 0.8.4.6. I recommend also watching this video tutorial on installing the new PPJoy as it is a bit involved on 64-bit windows. The modified script is below. Let me know if it works out. Note that I am unable to test it myself (I am currently abroad and no longer have access to my FSX computer.) #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. SendMode Input ; Recommended for new scripts due to its superior speed and reliability. SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory. #Persistent #InstallKeybdHook OnExit, ExitHandler FullFwd := 0 Idle := 100 Step := 1 ThrottleAxis := 3 Pos := Idle #IfWinActive, Microsoft Flight ; Keyboard Throttle PPJ_Init() ; Grab the Joystick PPJ_SetAxis(ThrottleAxis, Pos) $F1:: Pos := Idle PPJ_SetAxis(ThrottleAxis, Pos) return ~F2:: Pos += Step if (Pos > Idle) { Pos := Idle Send {F2} return } PPJ_SetAxis(ThrottleAxis, Pos) return $F3:: Pos -= Step if (Pos < FullFwd) Pos := FullFwd PPJ_SetAxis(ThrottleAxis, Pos) if (Pos = FullFwd) Send {F4} return $F4:: Pos := FullFwd PPJ_SetAxis(ThrottleAxis, Pos) return ExitHandler: PPJ_Term() ; Release the Joystick ExitApp #IfWinActive Link to comment Share on other sites More sharing options...
rdane042 0 Posted May 21, 2011 Share Posted May 21, 2011 Hello and thanks for your help on this issue. I followed your instruction carefully and used your latest script, but I get the attached error message when I run it! Your advice will be much appreciated. Regards, Ross Link to comment Share on other sites More sharing options...
DuckyLucky 11 Posted May 22, 2011 Author Share Posted May 22, 2011 Hello and thanks for your help on this issue. I followed your instruction carefully and used your latest script, but I get the attached error message when I run it! Your advice will be much appreciated. Regards, Ross Ensure that PPJoy.dll and the Lib folder are present in the same folder that AutoHotkey.exe is installed in (eg. C:\Program Files\AutoHotkey\). These files are in the AutoHotkey-PPJoy Library (Allows AutoHotkey to talk to PPJoy) which you need to download. After you download the zip file, unzip it to a folder on your desktop then just copy the PPJoy.dll and Lib folder to the same folder that AutoHotkey.exe is installed (eg. C:\Program Files\AutoHotkey\) . Link to comment Share on other sites More sharing options...
rdane042 0 Posted May 22, 2011 Share Posted May 22, 2011 Hi and thanks for your reply. I have done exactly as instructed and have attached a snap shot of the folder containing the files, yet, the problem persists. It seems something is not right about the PPJ_Init() function! Again, thanks for your help. Regards, Link to comment Share on other sites More sharing options...
StefWyn 0 Posted September 28, 2011 Share Posted September 28, 2011 Hey there. Thank you very much for the solution. I have managed to get the throttle to work, only thing is, hoe do I get the throttle to stay there? I have to hold the F4 button in for the throttle to apply power, as soon as I have to rotate the throttle goes down, and looses power. Can you help me with this? Kind regards Link to comment Share on other sites More sharing options...
umer11 0 Posted May 16, 2012 Share Posted May 16, 2012 Please tell me about the mapping configuration of virtual joystick i cant understand it. Link to comment Share on other sites More sharing options...
DMACNZ 0 Posted November 21, 2012 Share Posted November 21, 2012 i cannot download the script file for the ppjoy and auto key to work together as there is no link to it no more can someone give me another solution or give me a new link to the file that works please Link to comment Share on other sites More sharing options...
B737Fans 0 Posted December 11, 2012 Share Posted December 11, 2012 please, can anyone to reupload the autohotkey ppjoy library..?? cause the link was invalid now.. thx Link to comment Share on other sites More sharing options...
Pratama 0 Posted December 20, 2012 Share Posted December 20, 2012 please, can anyone to reupload the autohotkey ppjoy library? THX Link to comment Share on other sites More sharing options...
Shaun Fletcher 570 Posted January 7, 2013 Share Posted January 7, 2013 please, can anyone to reupload the autohotkey ppjoy library? THX Anyone have this file available. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.