Jump to content
The simFlight Network Forums

Recommended Posts

Posted
Dear Mr. Dowson
I can't create the "Warning" Macro (other Macros don't give me problems).
I follow the procedure exactly as per the FSUIPC User Guide 6.1 manual, but the area where to enter the Macro Name doesn't appear, so it's impossible to finish the Macro.
I should point out that "Message Text" is enabled by default.
I use FSUIPC 6.2, P3D 5.4, Citation Mustang 2.1 by Flight1, Win10 (obviously all licensed).
Can you help me?
  • John Dowson changed the title to The “Warning” Macro does not create
Posted

First, when pasting text, please paste as plain text so that I don't see those annoying scroll bars...

21 hours ago, GiankMustang said:

I can't create the "Warning" Macro (other Macros don't give me problems).

A macro is a macro....

If you have instructed FSUIPC to start the macro making process and the multiline simconnect message window does not appear when you click in the area that you want to create the macro for, then either the aircraft does not support macros (not all aircraft do) or there is no macro (i.e. mouse rectangle) available in the area that you clicked.

John

Posted

Thank you for your reply. 

I clarify that other Macros work, and that “Master Warning” with the mouse click works. 

However, I note that for “Warning” (and perhaps for other commands) there are no Offsets, Events or Macros.

As far as you know, is there any SW that makes up for these shortcomings? 

I tried KeyToMouse but… it is not suitable for the purpose. 

I have completed the my HomeCockpit, but due to some commands I cannot get the best out of it. 

Regarding the “annoying scroll bars”, I clarify that I pasted the translation exactly as “plain text” (the alternative was “rich text”). 

Thanks Giancarlo

Posted
1 minute ago, GiankMustang said:

I clarify that other Macros work, and that “Master Warning” with the mouse click works. 

However, I note that for “Warning” (and perhaps for other commands) there are no Offsets, Events or Macros.

If mouse-macros work for other switches, it seems strange that there is not one for this. But what exactly is "Warning"?
If you log Events, do you not see anything when you click this in the VC? If anything is logged, then you can use that.

I don't have this aircraft so I cannot look into this, sorry. You can check to see if there are any lvars available for this - try listing the available lvars and see if any look applicable (there is an FSUIPC-added control to log available lvars).
Otherwise, ask on the aircraft support forums to see if / how this can be controlled.

5 minutes ago, GiankMustang said:

Regarding the “annoying scroll bars”, I clarify that I pasted the translation exactly as “plain text” (the alternative was “rich text”). 

Well, that last message was good - no scroll bars!

John

Posted
Master Warning” and “Master Caution” are two big Lights that signal Anomalies, fundamental in real and simulated flight. 
In the attached photo I circled them in Red. You press them to turn them off.

I opened the Sim, clicked with the mouse on “Master Warning” and immediately closed the Sim.
Examining Events (FSUIPC6.log that I attach), I note the lines “16953 KEYDOWN: VK=17…” and “17391 KEYDOWN: VK=67...”, 
I think that the second of the two is “him”, but… it does not create the Macro.

About the LVars I have not found any reference on the PC about it.
Searching online, I read that Installing FSUIPC also installs WASM which includes HVars and LVars.
Is this what I have to do?

Regarding Mustang Flight1 Support, I have to say that unfortunately some time ago, after my in-depth question, 
the next day they stated on the site that the Mustang is no longer supported! There is nothing about it in the pre-existing forum.

Cessna Mustang Cockpit.jpg

.~lock.2 Mail a FSUIPC - La Macro “Warning” non si crea.doc#

Posted
38 minutes ago, GiankMustang said:

I note the lines “16953 KEYDOWN: VK=17…” and “17391 KEYDOWN: VK=67...”, I think that the second of the two is “him”, but… it does not create the Macro.

No - those log lines indicate keypresses from the keyboard (KEYDOWN).

40 minutes ago, GiankMustang said:

About the LVars I have not found any reference on the PC about it.

See the section Gauge local variable access (L:vars), by macro  in the FSUIPC6 Advanced User guide, page 39.

42 minutes ago, GiankMustang said:

Searching online, I read that Installing FSUIPC also installs WASM which includes HVars and LVars. Is this what I have to do?

No. That is for FSUIPC7 and MSFS2020 / MSFS2024 only.

43 minutes ago, GiankMustang said:

Regarding Mustang Flight1 Support, I have to say that unfortunately some time ago, after my in-depth question, the next day they stated on the site that the Mustang is no longer supported! There is nothing about it in the pre-existing forum.

What is logged when you press that button in the VC? It is not the KEYDOWN. Your log seems to contain many PANEL_ID_OPEN and PANEL_ID_CLOSE events logged with different parameters - maybe these have been repurposed. But I cannot tell from just looking at the log file. You need to do this with the logging console window open so that you can see what is logged when you press the switches in the VC in real time. No point posting the log file - look yourself!

Or look into lvars to see if any are available.

I know what the master warning and caution switches and lights are - its just helpful to me if you tell me in detail what you want to do - sometimes the warning/caution lights are independent from the switches, and I am not familiar with the aircraft you are using.

John

Posted

 

[QUOTE]: “No - those log lines (16953 KEYDOWN: VK=17... and 17391 KEYDOWN: VK=67...) indicate keypresses from the keyboard (KEYDOWN).” 

I see that those two lines are the Keyboard Keys (Ctrl+C) that I use to close the Sim and P3D. 

[QUOTE]: “See the section Gauge local variable access (L:vars), by macro in the FSUIPC6 Advanced User guide, page 39.” 

I translated that Guide, it says: 

… can now be listed in the Log, written to via Macros, and manipulated with both reads and writes through extensions to the ipc Lua Library. 

The log listing is obtained for the currently loaded aircraft panels by a new assignable control in the drop-down lists called “List local panel variables” ... 

There are various Lua Library files in Documents / FSUIPC, but I don't understand how to see the Lvars: 

1 Is the Log meant FSUIPC.log ? 

2 How to install the ipc Lua Library ? 

3 What are the drop-down lists ? 

4 How to assign “List local panel variables” ? 

[QUOTE]: “Your log seems to contain many PANEL_ID_OPEN and PANEL_ID_CLOSE events logged with different parameters” 

I see that those Events are cycled every four lines (Param 231 240 250 260). I don't know what they are. 

When I click on the monitor to turn off Master Warning, in FSUIPC.log it is recorded as EVENT: Cntrl= 65568 (0x00010020), Param= 0 (0x00000000) 

HEADING_GYRO_SET and frankly I don't see the connection between Master Warning that I clicked and HEADING_GYRO_SET. 

[QUOTE]: “Warning / Caution ... its just helpful to me if you tell me in detail what you want to do” 

These lights turn on by themselves, and I should be able to turn them off with Macros. 

Thanks again for anything you can tell me. Giancarlo.

Posted
19 minutes ago, GiankMustang said:

1 Is the Log meant FSUIPC.log ? 

Yes (the FSUIPC6.log file)

19 minutes ago, GiankMustang said:

2 How to install the ipc Lua Library ? 

You don't install it. All lua facilities are always available.

19 minutes ago, GiankMustang said:

3 What are the drop-down lists ? 

4 How to assign “List local panel variables” ? 

Here (in key assignments):

image.png.32cea98656515d50e2dcf126e6263030.png

34 minutes ago, GiankMustang said:

When I click on the monitor to turn off Master Warning, in FSUIPC.log it is recorded as EVENT: Cntrl= 65568 (0x00010020), Param= 0 (0x00000000) 

HEADING_GYRO_SET and frankly I don't see the connection between Master Warning that I clicked and HEADING_GYRO_SET. 

Sometimes aircraft developers re-purpose controls that are not used for other purposes (usually the ROTOR_BRAKE control as this is never used in airplanes). You can try assigning to that to see if it works, but that may be just a coincidence or a side-effect.

36 minutes ago, GiankMustang said:

These lights turn on by themselves, and I should be able to turn them off with Macros. 

Mouse macros are only available where provided by the aircraft developer. If you are trying to create a mouse macro in an area that is not supported, then that is because the developers have not allowed this and FSUIPC cannot create a mouse macro where no support for this is provided.

John

Posted
[QUOTE]: You can try assigning to that to see if it works (MASTER WARNING → HEADING_GYRO_SET)
Unfortunately it doesn't work.

[QUOTE]: Mouse macros are only available where provided by the aircraft developer. 
Bad news! 
Ultimately I can only turn off those Warning Lights with the Mouse.
I tried Key2Mouse which simulates the mouse click, but unfortunately it only works on the active window (= which has the Focus). 
The owner of K2M, Mr. Luciano Napolitano, confirmed this to me.
My Cockpit panel has various instruments and therefore various windows, only one of which is active, and it is not the MASTER WARNING one.

I tried with AutoHotKey, but it is a programming language that is rather difficult for me.
As far as you know, is there any SW capable of clicking on the coordinates even without the active window?

Thanks again for your availability. Giancarlo
Posted
3 hours ago, GiankMustang said:

As far as you know, is there any SW capable of clicking on the coordinates even without the active window?

No, and I don't think this is even possible. Windows itself receives mouse-clicks and then
  1. If the mouse-click is in the window that has the focus, then it will send the mouse-click to the application that owns the window with the focus
  2. If the mouse-click is in the window without the focus, it gives the application/window the focus
Therefore for the FS to receive the mouse-click, it will need the focus first.

If the place you want to send a mouse-click to is always in the same position or same relative position, you could write a small lua scrip to do this for you.
The lua script should:
   1. First ensure that the FS has the focus by calling ext.focus()
   2. Move the mouse cursor to the correct position using mouse.move(x, y, method)
   3. Send the mouse-click using mouse.click(button)

You can then assign a button or key to activate the lua script.

See the FSUIPC Lua Library documentation for details on these functions, and the FSUIPC Lua Plug-Ins document if not familiar with lua scripts.

John

 

  • 3 weeks later...
Posted

@GiankMustang Please DO NOT ask for support via DM/PM or email. Always use the support forum. I will ignore any future messages sent via DM/PM.
This was your message:

Quote
I refer to my thread “The Warning Macro does not create” of 9/4/2025.
I continued to study and try. I discovered with great pleasure, that "List local panel vars", suggested by you, contains three Lua scripts 
DEDICATED TO THE MUSTANG, they contain all those Commands absent in the “standard” Mustang Flight1, and the three files are present in 
C: / FSUIPC6 / FSUIPC6.ini / [LuaFiles].
This fortunately makes it unnecessary to create new Lua Macros.

These Lua.Macros perform two types of actions on the Mustang. 
The first, at the beginning, rightly turns off the Engines and those Instruments that instead by default would start on, and it works very well.
The second one allows you to use Lua.Macro for about fifteen Tools that by default do not allow you to create FSUIPC Macros. 
But I can't get it to work. 

I translated "FSUIPC for Advanced User" and I made several attempts, but unfortunately my poor knowledge of English and the Translators' 
shortcomings do not allow me to "see" and use those Lua macros prepared for Mustang. 
That is, in practice I do not know how to assign Commands from KeyPresses / drop-down lists / "List local panel vars" to Mustang. 
I can't even figure out if it has to be done through KeyBoardControls... 

Please can you help me again? Thanks.  

First this:

Quote

that "List local panel vars", suggested by you, contains three Lua scripts DEDICATED TO THE MUSTANG

No!. "List local panel vars" shows local panel variables, or lvars, NOT lua scripts.

Quote

and the three files are present in 😄 / FSUIPC6 / FSUIPC6.ini / [LuaFiles].

This cannot be correct. Lvars are NOT listed under [LuaFiles]. That section only shows lua scripts in your installation folder.

Quote

These Lua.Macros perform two types of actions on the Mustang.

Again, they are not 'lua macros'. Lua scripts (NOT macros) are files ending in .lua, macros are files ending in .mcro, and lvars are internal variables (local) to the aircraft.
the easiest way to use lvars is to write a macro - see the section 'Gauge local variable access (L:vars)' on page 39 of the Advanced User guide on how to use lvars in macro files.

Once you have created a macro to control the lvar, you can then assign to a button or key press.

John

 

Posted
49 minutes ago, GiankMustang said:

 I can't post.

My email are blank.

I copy and paste from the traslator.

Can you tell me which FONT I should use?

The font you used for that message looked ok...

Sorry, but I have no idea why cutting and pasting from your translator program doesn't work. When you paste, you should see a black box below the text entry panel asking to paste in text original format (or rich text) or plain text. Just click plain text after pasting and that usually works. 

 

Posted

I see the black box Text Original or Plain again... 

Ok, thank you, now I understand the difference between file.lua file.mcro and lvars. 

[QUOTE] “the easiest way to use lvars is to write a macro”. 

But for some Commands I can't make the Macro, because the area where to insert the Name doesn't appear. 

Lua was born precisely to make up for this deficiency (but also others...). 

In fact the Guide “FSUIPC Lua Plug-Ins”, of the “F1MustangSwCtl.zip” says: “Contains a Lua plugin to emulate certain mouse click controls for the Mustang subpanel and console switches”. 

But unfortunately despite the many tests done, even on other Commands, I can't make it work. 

I report the Script part of the file “F1MustangSwCtl.lua” regarding the “MASTER WARNING” Command: 

elseif ipc.testflag(17) then      -- Emulate the MASTER WARNING switch mouse area. 

                                              -- Using a pushbutton switch, 

                                              -- Assign parameter = 17 to Switch "pressed" only 

clearflag(17) 

ipc.control(65823,32)             -- send 32 (>L:ENGINE4_SET) 

I have inserted in various ways: (17), (65823), (32), etc., with no result, and I don't understand where I am going wrong. 

From the Guides and Translators I have squeezed everything there was to squeeze... 

Could you please give me a short tutorial? 

Otherwise I should seriously consider having to throw away so much work... and money... 

Thanks.

Posted
1 hour ago, GiankMustang said:

But for some Commands I can't make the Macro, because the area where to insert the Name doesn't appear. 

That is for mouse macros. Macros are also used for sending compound (i.e. multiple) commands, AND for using lvars. Please see the documentation that I referenced:

On 5/2/2025 at 10:02 AM, John Dowson said:

the easiest way to use lvars is to write a macro - see the section 'Gauge local variable access (L:vars)' on page 39 of the Advanced User guide on how to use lvars in macro files

Please translate/read that section to understand how to use macros to set/control lvars.

1 hour ago, GiankMustang said:

In fact the Guide “FSUIPC Lua Plug-Ins”, of the “F1MustangSwCtl.zip” says: “Contains a Lua plugin to emulate certain mouse click controls for the Mustang subpanel and console switches”. 

But unfortunately despite the many tests done, even on other Commands, I can't make it work. 

I think that script was for the FSX version. It may work in P3D, but check that the lvars it is using exist, and check the script is actually running. If you have followed the installation instructions, the script will only start when the aircraft name is "F1_Cessna_Mustang1". The name is probably different in P3D, so you will need to change this in the ipc.ready script. Try logging offset 0x3D00 to see what name is reported when the aircraft is loaded, and use that name to update the ipc.reasdy script.

1 hour ago, GiankMustang said:

I report the Script part of the file “F1MustangSwCtl.lua” regarding the “MASTER WARNING” Command: 

elseif ipc.testflag(17) then      -- Emulate the MASTER WARNING switch mouse area. 

                                              -- Using a pushbutton switch, 

                                              -- Assign parameter = 17 to Switch "pressed" only 

clearflag(17) 

ipc.control(65823,32)             -- send 32 (>L:ENGINE4_SET) 

I have inserted in various ways: (17), (65823), (32), etc., with no result, and I don't understand where I am going wrong. 

Control number 65823 is Throttle4 Set so I do not understand that comment. To test if that control works, you don't need the lua scripts. Just assign to the FS control Throttle4 Set with a parameter of 32. If that doesn't work, then the script will not work either as that is all that does. If there is an lvar called ENGINE4_SET, then you could try setting that lvar to 32 using a macro file (NOT a mouse macro). But again, this seems to be for FSX and I am not sure it will work in the P3D version.

Can you show me/attach a log file where you have listed the lvars so I can see what lvars are actually available for this aircraft. That would help. Also please attach your FSUIPC6.ini file.

John

 

Posted
Quote

Can you show me/attach a log file where you have listed the lvars so I can see what lvars are actually available for this aircraft. That would help. Also please attach your FSUIPC6.ini file.

To make this clear:
   - start P3D/FSUIPC and load the aircraft
  - set logging  for both Events (non-axis controls) and Axis controls in the FSUIPC logging panel
  - list the lvars / Local Panel variables
  - press the master warning switch in the VC using the mouse
  - list the lvars/local panel variables again
  - exit P3D/FSUIPC and then show me / attach both your FSUIPC6.log and FSUIPC6.ini files.

John

  • John Dowson changed the title to Assignment for the Flight1 Citation Mustang “Master Warning” button
Posted

Dear John

Finally, thanks to your encouragement, I managed to assign some of the LUA package Commands for Mustang Flight1. 

[QUOTE] see the section “Gauge local variable access (L:vars)” on page 39 of the Advanced User Guide

I had translated and read that Guide a long time ago, but unfortunately it is not user friendly. Furthermore, there are some things for which I do not find confirmation. For example: 

“Lvars can now be Listed in the Log”, and as an example it shows the list of the Cessna 172. But I do not find the Mustang List in any Log (neither in F1MustangSwCtl.log nor in FSUIPC6.log). I can extract only FEW Commands from the Script “F1MustangSwCtl.lua” (but it is neither .log nor List). 

In which Log is the complete list of the Mustang contained? 

[QUOTE] the aircraft name is "F1_Cessna_Mustang1". The name is probably different in P3D

The name is the same in both FSX and P3D. 

[QUOTE] control number 65823 is Throttle4 Set so I do not understand that comment 

That number is present in almost all 20 Controls of the F1MustangSwCtl.lua script with parameters from 1 to 326 (See the attached file F1MustangSwCtl.lua). It certainly represents a Command not used in the Mustang, in fact I remember your explanation of 15/4/2025 “Sometimes aircraft developpers re-purpose controls that are not used for other purposes”

I’ll show you how I did it (I hope it can be useful to someone): 

Master WARNING (pushbutton) 

FSUIPC: KeyPress / ProfileSpecific / Set: Shift+Alt+F2 (example) / Control: Throttle4 Set / Confirm 

MobiFlight: Action: eventID / Throttle4 Set / Use (eventID: 65823) / Para: 32

Can you tell me if you think there is a better way?

Now I will have to complete the assignment of all the other Commands present in the F1MustangSwCtl.lua and all the other non-Lua ones. If I encounter other obstacles, I will consult you again… 

Thanks for everything. 

Giancarlo

F1MustangSwCtl.lua

Posted
16 hours ago, GiankMustang said:

I had translated and read that Guide a long time ago, but unfortunately it is not user friendly. Furthermore, there are some things for which I do not find confirmation. For example: 

“Lvars can now be Listed in the Log”, and as an example it shows the list of the Cessna 172. But I do not find the Mustang List in any Log (neither in F1MustangSwCtl.log nor in FSUIPC6.log). I can extract only FEW Commands from the Script “F1MustangSwCtl.lua” (but it is neither .log nor List). 

In which Log is the complete list of the Mustang contained? 

In the FSUIPC log file (i.e. FSUIPC6.log for FSUIPC6), exactly as it says in the documentation. Did you assign a button or keypress to the "List local panel variables" control, and then press that button/key to list the lvars? If there are no lvars, you should still see the aircraft name logged - do you see this in the log when you activate that assigned control? If not, you are doing something wrong. I have asked to see your files so that I can help you but you still have not showed me anything...I really can't help that much if I cannot see your files as these show me what you are doing.

And I do not see this as not user friendly - looks pretty simple and straightforward to me, and would be to any native english speakers. If its a language issue, there is not much I can do about that. There is a french translation available for an older version of this document (for FSUIPC4) but still mostly valid.

16 hours ago, GiankMustang said:

The name is the same in both FSX and P3D. 

[QUOTE] control number 65823 is Throttle4 Set so I do not understand that comment 

That number is present in almost all 20 Controls of the F1MustangSwCtl.lua script with parameters from 1 to 326 (See the attached file F1MustangSwCtl.lua). It certainly represents a Command not used in the Mustang, in fact I remember your explanation of 15/4/2025 “Sometimes aircraft developpers re-purpose controls that are not used for other purposes”

If the name is the same and the custom controls (using the Throttle4 Set control) are the same, I suspect that the lvars are also the same and those scripts should work if/when configured correctly. And no need to attach files that I provide - I (obviously) already have them.

16 hours ago, GiankMustang said:

Can you tell me if you think there is a better way?

You could always use the lua scripts as provided. As I say, they should work if configured correctly. You need to read & understand the comments in the lua script to use this script.
For example, If the script was running correctly, to control the master warning switch you would assign to "LuaSet F1MustangSwCtl" with a parameter of 17 on the press only.

John

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.