codatcri Posted January 13, 2019 Report Posted January 13, 2019 Can't find the right ident for a321 ecams submenus. Can anybody help me, please?
Pete Dowson Posted January 14, 2019 Report Posted January 14, 2019 15 hours ago, codatcri said: Can't find the right ident for a321 ecams submenus. Do you mean the panel ID? Or do you mean assigning events to buttons or keys? Panel IDs are specified in the aircraft's PANEL.CFG. What do you want to use those for? Not sure what you mean by "submenus". If this is in the sim's main menu dropdowns then there are probably no "idents". If you really mean buttons or switches on the panel, then enable event logging in FSUIPC's Logging tab, then operate those buttons or switches. If the panel uses an FS controls to trigger the action then the the name will be logged. Then you can assign to it. But some panels have internal processing for their switches. In that case the only way might be via mouse macros, or local variables (L:Vars). If the A321 is an add-on, then you should be able to get more help on the add-on maker's support forum. Pete
codatcri Posted January 14, 2019 Author Report Posted January 14, 2019 Talking about A321 FXsteam default aircraft. In the lower side of the ecams display (ident =503) there are 7 buttons that allow to change the display information: ENG - BLEED - PRESS - APU - HYD - FUEL - FCTL I already tried in the logging tab but it doesn't show any param/ident, so i guess I have to try via mouse macro. I'll let you know! Thanks by now. Cristiano
Pete Dowson Posted January 14, 2019 Report Posted January 14, 2019 2 hours ago, codatcri said: In the lower side of the ecams display (ident =503) there are 7 buttons that allow to change the display information: Ah. If they only change the display local to the panel then they are local to that panel so have no real input from the rest of the simluation. The panel simply grabs the values and displays them. Unfortunately, with FSX (FSX-SE is the same of course) Mouse Macros only work on panels which have been written to Microsoft's SDK rules for C/C++ panels. Very few of those produced by Microsoft themselves do so. But it is worth trying. Some panels are written in XML. They use "Local variables" (L:Vars). You can get a list of those using the assignable control in FSUIPC called List LVars or simular. You can also get a real time display of them changing by using the provided Lua example plug-in Log LVars. Pete
spokes2112 Posted January 15, 2019 Report Posted January 15, 2019 They are L:Vars, here's a list I have on hand for the 321- 0 = Engine 1 = Bleed 2 = Pressurization 3 = APU 4 = Hydraulics 5 = Fuel 6 = Flt Controls (>L:ECAMS Display, number) Roman
codatcri Posted January 16, 2019 Author Report Posted January 16, 2019 Thanks Roman, but I'm pretty new with lua (started yesterday!). If I understood well I should: - create a lua file with that local vars: but which script must it contain? - save it in FSX/Modules; It's clear! - open fsuipc and assign to my buttons; It's clear!
spokes2112 Posted January 17, 2019 Report Posted January 17, 2019 The document needed is Modules\FSUIPC Documents\FSUIPC Lua Library.pdf with the command needed on page 10 at the top. For any lua scripting in FSUIPC this will be the "go-to" document with others as references. (... List of FSX and P3D Controls & ... Offsets Status are the main ones) If... And only if this is the only operation you want done via lua then you can get away with a "run once, self killing" lua script with no major consequences. A plus? 1 line. ipc.writeLvar("ECAMS Display", ipcPARAM) 1) copy the above code and save as 321ECAMS.lua in the modules folder 2) use the command "Lua 321ECAMS" and then the number (shown above) of the display wanted in the parameter field of the FSUIPC dialog
codatcri Posted January 17, 2019 Author Report Posted January 17, 2019 If I wel understtod: I wrote 321ECAMS.lua with only the line ipc.writeLvar("ECAMS Display", ipcparam) copied in the module folder and assigned to a button with a parameter (a number from 0 to 5) in the FSUIPC dialog a got different controls choices : Lua toggle 321ECAMS Lua set 321ECAMS Lua value 321ECAMS I tried with alll of them but nothing happened. If I select Lua debug 321 EICAM when i press the buttom i got this in the log window: LUA.0: beginning"C:\.... 321ecams.lua" LUA.0: Global: ipcPARAM =5 LUA.0: ended "C:\.... 321ecams.lua" but nothing happens in FSX What am I doing wrong???
Pete Dowson Posted January 17, 2019 Report Posted January 17, 2019 1 hour ago, codatcri said: in the FSUIPC dialog a got different controls choices : Lua toggle 321ECAMS Lua set 321ECAMS Lua value 321ECAMS I tried with alll of them but nothing happened. None of those load and run the plug-in. Please do take a look at the Lua plug-ins document in your FSUIPC Documernts folder. The FSUIPC control which loads, compiles, and executes the plug-in is: Lua 321ECAMS Quote If I select Lua debug 321 EICAM when i press the buttom i got this in the log window: LUA.0: beginning"C:\.... 321ecams.lua" LUA.0: Global: ipcPARAM =5 LUA.0: ended "C:\.... 321ecams.lua" but nothing happens in FSX Well, whilst LuaDebug does load the plug--in, using rather superseded debug code (use the Debug option in FSUIPC's Logging for that), I think one possible reason is that your plug-in line is: ipc.writeLvar("ECAMS Display", ipcparam) whereas, as you can see, the parameter is called ipcPARAM. Like most programming lanugages, Lua is case sensitive. Of course, other possible reasons include a misspelling of the L:Var name, and value 5 not meaning anything for it. Pete
codatcri Posted January 18, 2019 Author Report Posted January 18, 2019 GOT IT!!! I used lua log lvars and i found out that there was one first mistake "ECAMS Display" instead of "ECAMS2 Display" Then the second mistake was the case sensitive issue that Pete indicated: ipcPARAM was the right one. Thanks a lot to all of you for your help!
spokes2112 Posted January 18, 2019 Report Posted January 18, 2019 Good deal... 😄 My apologies on the L:Var, and good find! Took a closer look at the A321 in FSX (boxed) and sure enough, there is a long standing bug! Never noticed because I've never flown the A321. An example of the ECAM controller buttons for ECAMS2 popup. (ECAMS 1 has no controller) [Window11] Background_color=0,0,0 size_mm=1024,768 position=0 visible=0 ident=503 gauge01=Airbus_A321!popup_ecams_screen_bezel, 683,415,341,353 <-- Stock example below gauge02=Airbus_A321!ecams2, 707,441,289,289 <-- Stock example below popup_ecams_screen_bezel - ... <Script> (M:Event) 'LeftSingle' scmp 0 == if{ 1 (>G:Var1) 0 (>L:ECAMS Display, number) } (M:Event) 'LeftRelease' scmp 0 == if{ 0 (>G:Var1) } </Script> ... <Script> (M:Event) 'LeftSingle' scmp 0 == if{ 2 (>G:Var1) 1 (>L:ECAMS Display, number) } (M:Event) 'LeftRelease' scmp 0 == if{ 0 (>G:Var1) } </Script> ... <Script> (M:Event) 'LeftSingle' scmp 0 == if{ 3 (>G:Var1) 2 (>L:ECAMS Display, number) } (M:Event) 'LeftRelease' scmp 0 == if{ 0 (>G:Var1) } </Script> ecams2 - ... <Visibility>(L:ECAMS2 Display,number) 0 == (A:CIRCUIT GENERAL PANEL ON, bool) &&</Visibility> ... <Visibility>(L:ECAMS2 Display,number) 1 == (A:CIRCUIT GENERAL PANEL ON, bool) &&</Visibility> ... <Visibility>(L:ECAMS2 Display,number) 2 == (A:CIRCUIT GENERAL PANEL ON, bool) &&</Visibility> ... As you can see.. The Controller cannot even control ECAMS 2! 1 (>L:ECAMS Display, number) <!-- VERSUS --> (L:ECAMS2 Display,number) 1 == Again my apologies 😥 but glad it is working for you. 👍 Roman
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now