Jump to content
The simFlight Network Forums

FS2020 - SPEED_SLOT_INDEX_SET & VRI MCP Combi


Recommended Posts

Posted

Hi,

on A320neo (same A320nx)  the knobs ALT, HDG and SPD can be pushed or pulled using mouse.

Using FSUIPC7 log, I see an event related to these knobs is raised:

HEADING_SLOT_INDEX_SET
SPEED_SLOT_INDEX_SET
ALTITUDE_SLOT_INDEX_SET

trying to set a value to those variables using LINDA, Lua encounters an error (nil value).

The questions are: "Are some  kind of variable the three voice above?  How can I set the value using a button on a VRI MCP Combi?"

Thanks a lot

Posted

Hi,

those are only to set the Index, current value to the window, and not the value itself. At the moment those Set Value controls are not supported in MSFS via SimConnect. The working controls for those are only available via INC / DEC, i.e. 

HEADING_BUG_INC or HEADING_BUG_IDEC
 
Or you use the corresponding Offsets to set the values like
 
07CC 2 Autopilot heading value, as degrees*65536/360
 
Thomas
Posted

Ok, I'll explain better
On my VRI MCP Combi, rotating those knobs runs fine but I would like to simulate the two different actions for the HDG, ALT and SPD:
pushing and pulling
for change from Managed to Selected
Is it possible?
Thanks in advance

 

Posted

Hi John,

thanks a lot for your answer. Reading that post I done a big step forward.

Testing on my registered version of FSUIPC7 i found that variables in dropdownList and assigned to one kob and to one button on MCP this values for A320nx:

Altitude Slot Index Set = 2 -> MANAGED

Altitude Slot Index Set = 1 -> SELECTED

It seem that they change correctly from Managed to Selected but both require a double push. Is possible to remove the double push?

Many thanks

 

 

Selected.jpg

Managed.jpg

Posted

I tested also sending the command in the button release event but it seems to enter in a loop.

What I have noted in Button & Switch Assignements popUp is any buttons I push on MCP Combi is ignored first push but I need to push it a second time because appears the values in the "Joy#" and "Btn#"  field. Is it correct?

Many thanks for your attention

Posted
1 hour ago, grigna said:

What I have noted in Button & Switch Assignements popUp is any buttons I push on MCP Combi is ignored first push but I need to push it a second time because appears the values in the "Joy#" and "Btn#"  field. Is it correct?

Sounds like you are trying to program to a "sticky button", i.e. one that sends a key press when you first press, then a release when you press it again (i.e. like an on/off..
You can test what it seeing and sending by activating logging for events and buttons & keypresses. See what that looks like and compare the events to when you control on screen using the mouse.

Posted

This is what happens by VRI MCP Combi, taken from FSUIPC's LOG:

"ALT" knob:
1st push:
  6255015 14148 Button changed: bRef=0, Joy=257, Btn=31, Released
2nd push:
  6257968 14148 Button changed: bRef=0, Joy=257, Btn=31, Pressed
  6257968 14148 [Buttons] 3=P257,31,C68067,2
  6257968 14148 FS Control Sent: Ctrl=68067, Param=2 ALTITUDE_SLOT_INDEX_SET
  6257968 14148 *** EVENT: Cntrl= 68067 (0x000109e3), Param= 2 (0x00000002) ALTITUDE_SLOT_INDEX_SET
 
"ALTHLD" button:
1st push:
  6263843 14148 Button changed: bRef=0, Joy=257, Btn=3, Released
2nd push:
  6265375 14148 Button changed: bRef=0, Joy=257, Btn=3, Pressed
  6265375 14148 [Buttons] 4=P257,3,C68067,1
  6265375 14148 FS Control Sent: Ctrl=68067, Param=1 ALTITUDE_SLOT_INDEX_SET
  6265390 14148 *** EVENT: Cntrl= 68067 (0x000109e3), Param= 1 (0x00000001) ALTITUDE_SLOT_INDEX_SET

Posted

Yes, so its a sticky button. Its in one state on one press (on_, and a different state on another press (off), so its sends a press event on first press, then a release on second (although the other way around in your log as it was already depressed).

Knowing how the button works, you should program it how you want to use it, with the control sent on the press for to change to the state you want when it is depressed/on, and a control sent when it is released to change the state to the state you want when it is off.

  • 3 weeks later...
Posted
Hi John, I'm starting to understand how FSUIPC7 works with Linda and VRI MCP Combi.
For those who use MCP Combi with FS2020 & A320neo, binding these Functions to the three Knobs and to three Buttons can simulate Push & Pull

function  Engage_Managed_Speed_Mode ()
   -- PUSH SPEED KNOB
     ipc.control("68066", 2)
end

function  Engage_Selected_Air_Speed_Mode ()
    -- PULL SPEED  KNOB
     ipc.control("68066", 1)
end

function  Engage_Managed_Altitude_Mode ()
    -- PUSH ALT  KNOB
     ipc.control("68067", 2)
end

function Engage_Selected_Altitude_Mode ()
    -- PULL ALT  KNOB
     ipc.control("68067", 1)
end

function  Engage_Managed_Heading_Mode ()
    -- PUSH HDG  KNOB
     ipc.control("68065", 2)
end

function Engage_Selected_Heading_Mode ()
    -- PULL HDG  KNOB
     ipc.control("68065", 1)
end

 

  • Like 1
  • grigna changed the title to FS2020 - SPEED_SLOT_INDEX_SET & VRI MCP Combi

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.