Jump to content
Sign in to follow this  
jfwharton

MU-2B-60 any way to control the condition levers with keyboard?

Recommended Posts

Hello.  I'm new to the forum and have a question regarding the MU-2B-60 by flysimware.  I using FSX SE and was trying to control the condition levers using the mouse.  Going from taxi to takeoff is easy but the other way around is giving me a little trouble.  I did discover I can put the mouse pointer over the condition lever handle and use the mouse wheel to move it forward or backward.  But backward is tricky, moving too fast feathers the engine.  Something I've done a lot lately.  On other aircraft I have programmed into my X52 controller the Ctrl-F4 and Ctrl-F1 for takeoff and taxi.  This works great on my Carenado aircraft but does not work at all on the MU-2B-60.  Has anyone found a way to control the condition levers using keyboard commands?  Thanks.

Share this post


Link to post
Share on other sites

As an update, I contacted Flysimware support.  I was told "Those levers are conditioner levers and not mixture levers so the F commands may not work unless you use F2 and F3 to adjust. maybe F4 for max. But F1 will cut engines. And since we have these lever doing specific custom lvars it might only work from the mouse. But i would think the key commands should work fine. I would start a topic at Avsim if you can't solve the issue."

I let them know that the condition lever commands Ctrl-F4 and Ctrl-F1 work correctly on other aircraft I have.  They sent back the following "Just use the commands for the mixture levers. The propellers can't be controlled on a turboprop in FSX."  Mmmm, so much for support.  I tried the mixture commands and they do work but, there is no mixture command to put the condition levers in taxi, so I can use CTRL+SHIFT+F4 for takeoff, or CTRL+SHIFT+F3 and CTRL+SHIFT+F2 to increase or decrease.  So that will work only have to be careful just like using the mouse because if I decrease too far I am in cutoff.

Share this post


Link to post
Share on other sites

I would have to double-check with the MU2B, but with their C441 the answer is correct: The condition levers are mapped to the mixture axis.

I created a .lua script for the registered version of FSUIPC4 and have mapped increasing and decreasing the condition levers to the next useful position to joystick buttons, but the script can be adapted for keys by using event.key instead of event.button:

-- Flysimware C441: handle condition levers through joystick buttons

values = {
  -16384, -- 1: emer shutoff
   -6500, -- 2: red area
    5250, -- 3: start and taxi
   14750, -- 4: cruise
   16384  -- 5: take off, climb and landing
}

function condition(offset, control, incdec)
  old = (ipc.readUW(offset) - 8192) * 2 -- map offset to axis range
  if incdec > 0 then
    for i = 2, 5 do
      if old < values[i] then
        new = values[i]
        diff = new - old
        break
      end
    end
  else
    for i = 4, 1, -1 do
      if old > values[i] then
        new = values[i]
        diff = old - new
        break
      end
    end
  end
  steps = incdec * diff / 3
  for step = old, new-steps, steps do
    ipc.control(control, step)
    ipc.sleep(50)
  end
  ipc.control(control, new)
end

joystick = "J" -- Saitek Aviator Stick

function left_inc(joynum, button, downup)
  condition(0x0890, 66422, 1) -- MIXTURE 1, AXIS_MIXTURE1_SET
end
event.button(joystick, 8, "left_inc") -- T5

function left_dec(joynum, button, downup)
  condition(0x0890, 66422, -1) -- MIXTURE 1, AXIS_MIXTURE1_SET
end
event.button(joystick, 9, "left_dec") -- T6

function right_inc(joynum, button, downup)
  condition(0x0928, 66425, 1) -- MIXTURE 2, AXIS_MIXTURE2_SET
end
event.button(joystick, 10, "right_inc") -- T7

function right_dec(joynum, button, downup)
  condition(0x0928, 66425, -1) -- MIXTURE 2, AXIS_MIXTURE2_SET
end
event.button(joystick, 11, "right_dec") -- T8

 

Share this post


Link to post
Share on other sites

Thanks for the information, but it's a bit over my head.  I did discover that while the CTRL+SHIFT+F4, CTRL+SHIFT+F3 and CTRL+SHIFT+F2 commands work with the keyboard they do now work when added to my X52 controller profiles.  Don't know why.  Other keyboard commands work with the profiles of other aircraft.  Just not with the MU-2B-60.

Share this post


Link to post
Share on other sites

OK I finally figured out what I was doing wrong and won't go into that because it's a little embarrasing.  But I have the condition levers programmed successfully into my X52 controller.  So thanks.

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...