Jump to content
The simFlight Network Forums

PMDG 747X commands (upd 9th April)


guenseli

Recommended Posts

I have made some little LUA and MACRO files for different aircrafts the last weeks and d'like to share them here.

With the LUA commands below you have the possibility to control ND Range and ND Mode!

upd 9th April: I accidently inserted a wrong MACRO (from the 767) sorry!

And ND Mode CTR in the LUA was implemented but wrong named

LUA commands

Here's a very short tutorial how to "install" LUA files

To get acces to the single commands you have to do the following:

1) copy the code below

2) insert it into an empty editor or wordpad file and save it as e.g. J41.LUA into the FSX - Modules Folder

3) open FSUIPC menu and choose LUA J41 from the drop down

4) insert different parameter numbers depending on the action you want (green field)

fr6tcbg5.jpg

(this example picture is for the J41. For the 747 you have to name the file of course 747.LUA or whatever. Them the name in the dropdown (red field) will be Lua 747)

Here is the list of 747X parameter numbers:

-- 1 EFIS WXR

-- 2 EFIS STA

-- 3 EFIS WPT

-- 4 EFIS ARPT

-- 5 EFIS DATA

-- 6 EFIS POS

--7 EFIS FPV

-- 8 EFIS MTRS

-- 9 EFIS Minimums reset

-- 10 EFIS IN/HPA

-- 11 EFIS BARO Std

-- 12 EFIS VOR L inc

-- 13 EFIS VOR L dec

-- 14 EFIS VOR R inc

-- 15 EFIS VOR R dec

-- 16 EFIS ND Mode inc

-- 17 EFIS ND Mode dec

-- 18 EFIS ND Range inc

-- 19 EFIS ND Range dec

-- 20 EFIS Minimums inc

-- 21 EFIS Minimums dec

-- 22 TOGA

-- 23 EFIS TFC

-- 24 EFIS ND Mode CTR

-- 1 EFIS WXR
-- 2 EFIS STA
-- 3 EFIS WPT
-- 4 EFIS ARPT
-- 5 EFIS DATA
-- 6 EFIS POS
--7 EFIS FPV
-- 8 EFIS MTRS
-- 9 EFIS Minimums reset
-- 10 EFIS IN/HPA
-- 11 EFIS BARO Std
-- 12 EFIS VOR L inc
-- 13 EFIS VOR L dec
-- 14 EFIS VOR R inc
-- 15 EFIS VOR R dec
-- 16 EFIS ND Mode inc
-- 17 EFIS ND Mode dec
-- 18 EFIS ND Range inc
-- 19 EFIS ND Range dec
-- 20 EFIS Minimums inc
-- 21 EFIS Minimums dec
-- 22 TOGA
-- 23 EFIS TFC
-- 24 EFIS ND Mode CTR



-- EFIS WXR
	if ipcPARAM == 1 then   

	ipc.control(72020) 


	end

-- EFIS STA
	if ipcPARAM == 2 then   

	ipc.control(72021) 

	end

-- EFIS WPT
	if ipcPARAM == 3 then   

	ipc.control(72022) 


	end

-- EFIS ARPT
	if ipcPARAM == 4 then   

	ipc.control(72023) 


	end

-- EFIS DATA
	if ipcPARAM == 5 then   

	ipc.control(72024) 

	end

-- EFIS POS
	if ipcPARAM == 6 then   

	ipc.control(72025) 


	end

-- EFIS FPV
	if ipcPARAM == 7 then   
	ipc.control(72000)

	end

-- EFIS MTRS
	if ipcPARAM == 8 then   

	ipc.control(72001) 

	end

-- EFIS MINS_RST
	if ipcPARAM == 9 then   

	ipc.writeLvar("L:EFIS_L_MINS_RST_Switch_var", 1)
	ipc.sleep(250)
	ipc.writeLvar("L:EFIS_L_MINS_RST_Switch_var", 0) 

	end

-- EFIS IN HPA
	if ipcPARAM == 10 then   

	ipc.control(72007)

	end

-- EFIS BARO_STD
	if ipcPARAM == 11 then   

	ipc.writeLvar("L:EFIS_L_BARO_STD_Switch_var", 1)
	ipc.sleep(250)
	ipc.writeLvar("L:EFIS_L_BARO_STD_Switch_var", 0) 

	end

-- EFIS VOR L inc
	if ipcPARAM == 12 then   

	ipc.control(66587, 72010)

	end

-- EFIS VOR L dec
	if ipcPARAM == 13 then   

	ipc.control(66587, 72011)

	end



-- EFIS VOR R inc
	if ipcPARAM == 14 then   

	ipc.control(66587, 72018)

	end

-- EFIS VOR R dec
	if ipcPARAM == 15 then   

	ipc.control(66587, 72019)

	end


-- EFIS ND Mode inc
	if ipcPARAM == 16 then   

	ipc.control(66587, 72013)

	end

-- EFIS ND Mode dec
	if ipcPARAM == 17 then   

	ipc.control(66587, 72012)

	end


-- EFIS ND Range inc
	if ipcPARAM == 18 then   

	ipc.control(66587, 72016)

	end


-- EFIS ND Range dec
	if ipcPARAM == 19 then   

	ipc.control(66587, 72015)

	end


-- EFIS Minimums inc
	if ipcPARAM == 20 then   

	ipc.control(66587, 72005)

	end

-- EFIS Minimums dec
	if ipcPARAM == 21 then   

	ipc.control(66587, 72004)

	end


-- TOGA
	if ipcPARAM == 22 then   

	ipc.control(73010)

	end

-- EFIS TFC
	if ipcPARAM == 23 then   

	ipc.control(72017)

	end


-- EFIS ND Mode CTR
	if ipcPARAM == 24 then   

	ipc.control(72014)

	end




Macros

[Macros]
Module="PMDG_747400_Overhead.DLL"
1=OHD: APU on=RX3700*X53cc,31
2=OHD: APU off=RX3700*X53cc
3=OHD: Batt on=RX3800*X8bcc
4=OHD: Batt Off
4.1=RX3800*X8bcc,31
4.2=RX3800*X8bcc
5=STBY Power on=RX3780*X53cc,31
6=STBY Power off=RX3780*X53cc
7=OHD: Gen
7.1=RX34f0*Xf7cc
7.2=RX3530*Xf7cc
7.3=RX3570*Xf7cc
7.4=RX35b0*Xf7cc
12=Start Eng1=RXd760*X8bcc
13=Start Eng2=RXd790*X8bcc
14=Start Eng3=RXd7c0*X8bcc
15=Start Eng4=RXd7f0*X8bcc
16=Light BCN=RX9600*X8bcc
17=Light Nav=RX95d0*X8bcc
18=Light Strobe=RX95a0*X8bcc
19=Light Wing=RX9570*X8bcc
20=Light Logo=RX9540*X8bcc
21=Light Taxi=RX9630*X8bcc
22=Light Runway=RX9660*X8bcc
23=Light LDG inb=RX96c0*X8bcc
24=Light LDG outb=RX9690*X8bcc
25=Light Dome=RX9770*X53cc
26=Light Storm=RX98f0*X8bcc
27=Light Panel
27.1=RX9870*X53cc,31
27.2=RX97f0*X53cc,31
27.3=RX96f0*X53cc,31
30=Light Panel dec
30.1=RX9870*X53cc
30.2=RX97f0*X53cc
30.3=RX96f0*X53cc
Module1="PMDG_747400_Center.DLL"
8=Fuel Eng1=R1:1
9=Fuel Eng2=R1:2
10=Fuel Eng3=R1:3
11=Fuel Eng4=R1:4
56=Spoiler inc=R1:X16f0*X68cc,31
57=Spoiler dec=R1:X16f0*X68cc
Module2="PMDG_747400_Main.DLL"
28=MCP F/D=R2:X4820*X8b00
29=MCP AT Arm=R2:X4860*X8bcc
31=MCP THR=R2:X4870*X8b00
32=MCP SPD=R2:X4880*X8b00
33=MCP LNAV=R2:X4b30*X8b00
34=MCP VNAV=R2:X49d0*X8bcc
35=MCP FLC=R2:X49e0*X8b00
36=MCP HDG hold=R2:X4b20*X8b00
37=MCP HDG sel=R2:X4b10*X8bcc
38=MCP SPD push=R2:X4de0*X8bcc
39=MCP ALT push=R2:X4df0*X8b00
40=MCP VS=R2:X4db0*X8bcc
41=MCP ALT hold=R2:X4c60*X8bcc
42=MCP LOC=R2:X4b40*X8b00
43=MCP APP=R2:X4b50*X8b00
44=MCP CMD L=R2:X47b0*X8bcc
45=MCP CMD C=R2:X47d0*X8bcc
46=MCP CMD R=R2:X47f0*X8bcc
47=MCP Disengage=R2:X4810*X8bcc
48=MCP VS dn=R2:X4c70*X5700
49=MCP VS up=R2:X4c70*X5700,31
50=MCP ALT dn=R2:X4b60*X5300,13
51=MCP ALT up=R2:X4b60*X5300,14
52=MCP HDG inc=R2:X4a30*X53cc,14
53=MCP HD dec=R2:X4a30*X53cc,13
54=MCP SPD inc=R2:X48b0*X57cc,14
55=MCP SPD dec=R2:X48b0*X57cc,13
58=MAster warn=R2:Xd8e0*X8b00
59=ABrk inc=R2:Xf330*X56cc,31
60=ABrk dec=R2:Xf330*X56cc
61=TFC inc=R2:Xf0d0*X56cc,31
62=TFC dec=R2:Xf0d0*X56cc
63=no smoking inc=R2:Xf3c0*X56cc,31
64=mo smoking dec=R2:Xf3c0*X56cc
65=seat inc=R2:Xf410*X56cc,31
66=seat dec=R2:Xf410*X56cc

Read FSUIPC Manual for more information about LUA!!

Do everything at your own risk; don't blame PMDG, Pete Dowson or (most important) me for any errors!

Have fun!

Link to comment
Share on other sites

  • 1 month later...

Hi guenseli. Just thought I'd drop you a note to thank you for the wonderful job you have done for the 747 EFIS! It works superbly! I bought the Flight Sim Labs GF-MCP Pro add on just so I could use it with my PMDG 747, but the EFIS never worked until using your files. Well Done! and I will be watching for more from you, and thanks a lot and Cheers!

Steve Ark

Link to comment
Share on other sites

  • 7 months later...

I don't know how GoFlight modules work.

But as long as you can assign a button in FSUIPC to your hardware you can use LUAs or Macros.

Yes, all buttons and switches on the GoFlight EFIS are assignable in FSUIPC, provided the GoFlight software (or at least its GFDev.dll) is installed. In case only the GFDev.dll is missing, or out of date, a very recent one which certainly works with the EFIS, is available in the "Useful Additional Programs" topic in the "Download Links" subforum.

Regards

Pete

Link to comment
Share on other sites

  • 2 months later...

Is this only if you own a panel or other equipment out side of my computer? Can I use these macros and assignments with just a keyboard and G940 joystick, pedals, and throttle? If so how do I assign them? I have read and tried to understand how to do the most basic of things, like how do I get this into my registered copy of FSUIPC4657? I have copied with Notepad the --1 EFIS WXR etc as 747.LUA and copied it into my FSX Modules folder. I started FSX, loaded the 747X, addons, FSUIPC, opened the FSUIPC menu, clicked on Buttons + switches, (the only way I see to get to the screen with the Control sent when button pressed and it does not bring up the LUA 747 in the box, nor is there anything to select in the drop down.

LUA commands

Here's a very short tutorial how to "install" LUA files

To get acces to the single commands you have to do the following:

1) copy the code below

2) insert it into an empty editor or wordpad file and save it as e.g. J41.LUA into the FSX - Modules Folder

3) open FSUIPC menu and choose LUA J41 from the drop down

4) insert different parameter numbers depending on the action you want (green field)<br style=""> <br style="">

I want to use Voice Commands to trigger the actions in the LUA you have written. I do not comprehend

Thank you,

Lynn

Link to comment
Share on other sites

  • 1 month later...

Thank you very much for this info,I know it is an old post but I have just spent 4 days(sad, but I'm hopeless with programming/offsets etc).I could not find a way to operate fs9 pmdg747 "on screen" fuel switches with my homemade quad switches(to get the correct eicas message/magenta line startup etc),all entries with macros were R1:1 so only no 1 lever worked,so I just simply added the 2,3,4 to the macro file and voila.

Thanks again

regards Jim

Link to comment
Share on other sites

  • 1 month later...

I don't know how GoFlight modules work.

But as long as you can assign a button in FSUIPC to your hardware you can use LUAs or Macros.

Guenseli

I could program almost all the functions of my GoFlight Module using the Lua files you kindly posted, but couldnt do it with the Mode and Range knobs,as there are only increasing and decreasing parameters for both.- The mode knob has 4 positions and the range knob has 7, all of them are recognized with diferent button numbers at FSUIPC.-

Pete Dowson said that, as they are written, your Lua files doesnt work for that functions in the GF Efis.- He posted: "I suspect that's because the Lua program you are calling looks to be quite long and has to be loaded, compiled and executed for each line in the INI. A shorter one with just the entries you want might do the job, but I doubt it. In the end the only sane way would be to program the sequences themselves properly in a Lua plug-in. Maybe an appeal to the original Lua programmer for the one you are using might elicit results"

Maybe you have the patience to do that, and share it with us.-

Thanks

Jorge

Link to comment
Share on other sites

  • 1 month later...

Hi guys,

I am new to the LUA language but I have a basic question that may have been answered somewhere else..

The code at the beginning of the topic has two area.

Do both parts of the code get put into one file?

Sorry to ask but I was not sure just by reading the simple instructions.

Regards,

Alex Boyd

Link to comment
Share on other sites

  • 7 months later...

Hi regarding to pmdg 747 lua I can't get it work why I am sure mistake is on my side just can't figer out what am I doing wrong. I did happened to download pmdg 4100 lua mcp pro + macro and Work like charm on jst 4100 ,but 747 I get nothing .

I am sorry but if is not too much to ask could you plaese write down the steps how to and where to . I think I folow same steps as for pmdg 4100 , but no luck . Thank you Petr

Link to comment
Share on other sites

  • 8 months later...

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.