Jump to content
Sign in to follow this  
guenseli

MD-11 panel state: witchery with FSUIPC

Recommended Posts

Ever wanted to have your MD-11 initially loaded with an other panel state than the Engines Running?Here's the solution :( First of all you need a registered copy of FSUIPC (I think so; maybe try it without)Since a few days Pete Dowson implemented a really cool feature that allowes you to do endless commands when an aircraft will be loaded.Here's his information at his forumThe other thing is, that he implemented the possibility via LUA programming, that you can get acces to the FS Menue by programming mouseklicks or keystrokes.The two features together gives you the possibility to load the MD-11 and get immediatelly the panel state of your wishes loadedAnd here's how you can do that:Below is what you can read at Petes Forum about the new [AUTO] function (needs latest update of FSUIPC)

9. Facilities have been added to automatically execute a list of Lua plugins or FSUIPC Macros when an aircraft is loaded. This allows switches, offsets, and other things to be set specifically for an aircraft when it is first loaded. It is done by adding new sections to the INI file with the title [Auto] or [Auto.xxxx...] where the xxxx part is the aircraft name, or part-name (as in Aircraft Specific sections), or a profile name when profiles are being used. The Auto sections thus parallel the Keys and Buttons sections -- the naming and selection follows the same system. The generic [Auto] section is carried out for all aircraft changes whilst the specific ones are only applied to matching aircraft.Each Auto section can contain a series of numbered lines (1=..., 2=... etc) each of which is either a Lua command, or a Macro call. For example:[Auto.737]1=Lua SetMyOffsets2=737 OHD:Air AllbleedsWhen Lua calls run a plug-in which doesn't self-terminate, the plug-in thread still running is kiled automatically on an aircraft change.
And here's my LUA code for the panel state loading
-- MD-11 panel status automatic --ipc.keypressplus(18,1,4)	-- ALT and focus to FSipc.keypressplus(65)			-- A for Addonsipc.sleep(50)ipc.keypressplus(80)			-- P for PMDGipc.sleep(50)ipc.keypressplus(40)			-- Cursor right for PMDG Menueipc.keypressplus(40)		-- Csr Down 7 times to get to panel stateipc.keypressplus(40)ipc.keypressplus(40)ipc.keypressplus(40)ipc.keypressplus(40)ipc.keypressplus(40)ipc.keypressplus(13)			-- Enter				-- below are the Panel States-- be sure to have the same order in your PMDG/MD11/panelstate folder-- be sure not to have any previously saved panelstates before this-- for PAX and Freighter Version maybe you have to create two different files-- Delete the entries below your prefered panelstate (now its before engine start)ipc.keypressplus(40)		-- After Engine Startipc.keypressplus(40)		-- Before Engine Start--ipc.keypressplus(40)		-- Cold and Dark--ipc.keypressplus(40)		-- Long Ground Turn--ipc.keypressplus(40)		-- Short Ground Turn--ipc.keypressplus(40)		-- Tutorial--ipc.keypressplus(40)		-- Freighter C&D--ipc.keypressplus(40)		-- Freighter Long Ground--ipc.keypressplus(40)		-- Freighter Short Groundipc.sleep(1000)			-- little pause of 1sipc.keypressplus(13)	-- ENTER to press OK button

The default engine state which will be loaded is "before engine start".You will can read inside the code some informations how to change this...Now, copy the code into a empty wordpad document and name it e.g. MD11_panelstate.lua(take care of the file-ending *.LUA!)Save it into your X:\Program Files (x86)\Microsoft Games\Microsoft Flight Simulator X\Modules folderYou have two choices now:If you want this LUA file running immediatelly after loading the aircraft, then add this into your FSUIPC4.ini[Auto.PMDG MD-11] (<-- be sure you have read all explanations for the new [AUTO] feature; the name depends on your settings)1=Lua MD11_panelstateOr you can assign of course this LUA file to a Button or keycombination what would be better if you think about loading a saved flight...You find this under the FSUIPC controls menue named "Lua MD11_panelstate" which you can easily assign it to what you want.---------------I have created an other Lua file for some initiation functions:

ipc.sleep(2000)ipc.writeLvar("L:pmdg_hide_yoke", 0)ipc.writeLvar("L:pmdg_hide_yoke", 1)ipc.writeLvar("L:HIDE_OVERHEAD_SWITCHES_var", 1)ipc.control(65574)	-- all lights onipc.control(65574)	-- all lights off

What happens here: - the Yokes will go down automatically - the "secret" Overhead switch which toggles some knobs and animations at the OHpanel to gain frames would be pressed - all lights will gon on and off to be sure that really all lights are offSame as above: new editor file, name it e.g. MD11init.lua, under [AUTO PMDG MD-11] entry write 1= Lua MD11initOr assign it to a key or button.Or make one file from panelstate and the init code... its your choicefeel free to ask!Make everything at your own risk!Don't blame PMDG, FSUIPC or most important ME if sth goes wrong...!But nothing scary could happen here...


Guenter Steiner
--------------------------------------------------------------------------------------

Betatester for: A2A, LORBY, FSR-Pillow Tester
--------------------------------------------------------------------------------------

Share this post


Link to post
Share on other sites

Thanks for the heads-up!One short question... Would this technique in theory allow for any other menu commands within the PMDG menu? So could I configure this in a way that random failures will automatically be turned on as soon as I load the MD-11?That would be amazing :)Markus


Markus Burkhard

 

Share this post


Link to post
Share on other sites

This sounds very good! I have a reg version 3.85 any issues upgrading to the latest version? Rob


Rob Prest

 

Share this post


Link to post
Share on other sites

@ markusYes, you could enter every menupoint in FSX with this method.Petes examples are for changing the payload or fuel, so you can also input numbers, etc...The failure geenrator is a good idea...Should be possible to generate some sort of random failure generator, too....@ robI don't know about any issues.if you afraid about trouble backup your current FSUIPC.dllBeside this is the support from Pete Dowson the fastest I know in FS World.You don't have to wait longer than 24 hours...normally maximum 6h or instant ;-)ATTENTION:I forgot to say that I made this for FSX version.Don't know if this works in FS9, too...Try and see...


Guenter Steiner
--------------------------------------------------------------------------------------

Betatester for: A2A, LORBY, FSR-Pillow Tester
--------------------------------------------------------------------------------------

Share this post


Link to post
Share on other sites

Great!!Will it work with JS41 to?


Mauricio Brentano

Share this post


Link to post
Share on other sites
Will it work with JS41 to?
Of course not...this feature does nothing else what you could do with your mouse in the FSX menu.And because there`s not the same PMDG menu for the J42 as for the MD-11 or any other plane it will just work with the MD11

Guenter Steiner
--------------------------------------------------------------------------------------

Betatester for: A2A, LORBY, FSR-Pillow Tester
--------------------------------------------------------------------------------------

Share this post


Link to post
Share on other sites
Of course not...this feature does nothing else what you could do with your mouse in the FSX menu.And because there`s not the same PMDG menu for the J42 as for the MD-11 or any other plane it will just work with the MD11
Ok, I understand.Thanks anyway.

Mauricio Brentano

Share this post


Link to post
Share on other sites

ATTETION: I found a little "bug"...if you use the FSUIPC Autosave function, then FSUIPC (or PMDG don't know) will also save the flights inside theF:\Program Files (x86)\Microsoft Games\Microsoft Flight Simulator X\PMDG\MD11\panelstatefolder.The files there were alphabetically sorted.So the Autosave flights will be over the panelstates and then accidently selected.to prevent this you can rename the panelstate files.I have now this names:001_PMDG MD-11 After Engine Start002_PMDG MD-11 Before Engine Start003_PMDG MD-11 Cold and Dark004_PMDG MD-11 Long Ground Turnand so on..


Guenter Steiner
--------------------------------------------------------------------------------------

Betatester for: A2A, LORBY, FSR-Pillow Tester
--------------------------------------------------------------------------------------

Share this post


Link to post
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
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...