Jump to content

Recommended Posts

Posted

Where the Rad Alt knobs work in the cockpit with mouse clicks etc.    Either i'm searching for the wrong keybind - tried alt, rad and all things like that.. I cant find a keybind.  I'd like to map a rotary encoder to the Hi/Lo Rad Alt settings.

Has anyone figured this out - I'm betting @jonsky7 has the answer!!

Posted
13 hours ago, Gabreil said:

Where the Rad Alt knobs work in the cockpit with mouse clicks etc.    Either i'm searching for the wrong keybind - tried alt, rad and all things like that.. I cant find a keybind.  I'd like to map a rotary encoder to the Hi/Lo Rad Alt settings.

Has anyone figured this out - I'm betting @jonsky7 has the answer!!

I don't see any binding for this, only its brightness dial

Posted

@JohnW71 yep.    I was reading back through other posts and comments and someone commented that it seems rather strainge that the circuit breakers (which i very much doubt are used by many are all modelled - yet keybinds for functions we want to use are omitted.   

I just wish i had the skills to understand how to map functional items to keyboard/joystick actions..  One day no doubt we'll see all keybinds.

  • Like 1
  • Solution
Posted (edited)
On 6/28/2025 at 8:43 PM, Gabreil said:

Has anyone figured this out - I'm betting @jonsky7 has the answer!!

Well you're not wrong 😎
 

	{pressed = device_commands.Button_2, up = device_commands.Button_2, value_pressed = 0.01, 	value_up = 0, cockpit_device_id = devices.APN_209, name = _('RAD ALT LO SET DOWN'), category = {_("RAD ALT")}},
	{pressed = device_commands.Button_2, up = device_commands.Button_2, value_pressed = -0.01, 	value_up = 0, cockpit_device_id = devices.APN_209, name = _('RAD ALT LO SET UP'), category = {_("RAD ALT")}},
	{pressed = device_commands.Button_3, up = device_commands.Button_3, value_pressed = 0.01, 	value_up = 0, cockpit_device_id = devices.APN_209, name = _('RAD ALT HI SET DOWN'), category = {_("RAD ALT")}},
	{pressed = device_commands.Button_3, up = device_commands.Button_3, value_pressed = -0.01, 	value_up = 0, cockpit_device_id = devices.APN_209, name = _('RAD ALT HI SET UP'), category = {_("RAD ALT")}},

 

You can adjust the values in the part
value_pressed = 0.01
value_pressed = -0.01

0.05 seemed too fast to me, but 0.01 may be a little slow. Maybe 0.02 would be good.

Copy into both keyboard and joystick "default.lua" files.

"Pressed" means the action will be repeated as long as the key/button is held down

or you could change that to 
{down = device_commands.Button_2, up = device_commands.Button_2, value_down = 0.01,     value_up = 0
(probably better for a rotary encoder)

if you want to move the setting a certain amount each key press, like the notch in the mouse wheel

Regards
Jon.

Edited by jonsky7
  • Like 2
Posted (edited)

@jonsky7  Awesome!   I'll get those added in the morning.   both will be bound to a rotary - so i doubt i'll need to make any changes.

I did do a bit of a dive into this to see if i could do it.. but got hoplessly lost. As i was digging around i found the refrernce in the CH47 clickabledata.lua for the alt hi/lo - i think i got pre-occupied by the the args which if i recall were 1193,1194 and 1195..  

I found the reference to APN_209.   How did you determine these - or are they just relevant names?   

RAD ALT LO SET DOWN
RAD ALT LO SET UP
RAD ALT HI SET DOWN
RAD ALT HI SET UP 
Edited by Gabreil
  • Like 1
Posted
6 hours ago, Gabreil said:

@jonsky7  Awesome!   I'll get those added in the morning.   both will be bound to a rotary - so i doubt i'll need to make any changes.

I did do a bit of a dive into this to see if i could do it.. but got hoplessly lost. As i was digging around i found the refrernce in the CH47 clickabledata.lua for the alt hi/lo - i think i got pre-occupied by the the args which if i recall were 1193,1194 and 1195..  

I found the reference to APN_209.   How did you determine these - or are they just relevant names?   

RAD ALT LO SET DOWN
RAD ALT LO SET UP
RAD ALT HI SET DOWN
RAD ALT HI SET UP 

The 'name' and the 'category' can be anything you like, they are just what shows up in the controls menu, first and second columns.

You weren't far away though. 

In the clickable data you have the device name, devices.APN_209, and also there's reference to the buttons.

The low setting was easier

device_commands.Button_2

But the high setting said buttons 1, and 3, I just had to test them. There was also some reference to some values, 0, 0.1, 1 IIRC. 

Button 1 is the push to test on the HI Knob.

Like I mentioned, for a rotary encoder, you might have to change them to 'down' rather than 'pressed'.

  • Like 1
Posted (edited)

@jonsky7   So i got things working adding your code..   Got the Hi & Lo on a rotary which work nicely.  The values work nicely to move the Hi & Lo markers around the dial

 

I added the following for the RAlt Test

    {pressed = device_commands.Button_1, up = device_commands.Button_1, value_pressed = 1,         value_up = 0, cockpit_device_id = devices.APN_209, name = _('RAD ALT Test'), category = {_("RAD ALT")}},
 

That also works nicely for the test function

** I'll add this as happend to me when i added the changes to DCSWorld\Mods\aircraft\CH-47\Input\Keyboard & Joystick default.lua...  After adding the lines above and starting DCS, when assigning a keybind/button i was asked to restart DCS when i id done that.

What i didnt realise was it pretty much wiped all my other keybindings and joystick buttons - the ones located in Saved Games\DCCS\Config\Input\CH-47\Joystick & Keyboard.     I recomemend backing these up before making the changes to

It may or may not have been something i did wrong.. but dont take the chance!

Edited by Gabreil
  • Like 1
Posted
10 hours ago, Gabreil said:

@jonsky7   So i got things working adding your code..   Got the Hi & Lo on a rotary which work nicely.  The values work nicely to move the Hi & Lo markers around the dial

 

I added the following for the RAlt Test

    {pressed = device_commands.Button_1, up = device_commands.Button_1, value_pressed = 1,         value_up = 0, cockpit_device_id = devices.APN_209, name = _('RAD ALT Test'), category = {_("RAD ALT")}},
 

That also works nicely for the test function

** I'll add this as happend to me when i added the changes to DCSWorld\Mods\aircraft\CH-47\Input\Keyboard & Joystick default.lua...  After adding the lines above and starting DCS, when assigning a keybind/button i was asked to restart DCS when i id done that.

What i didnt realise was it pretty much wiped all my other keybindings and joystick buttons - the ones located in Saved Games\DCCS\Config\Input\CH-47\Joystick & Keyboard.     I recomemend backing these up before making the changes to

It may or may not have been something i did wrong.. but dont take the chance!

Sorry to hear that it wiped your keybinds.

I use the Quaggles input command injector.

You can make modifications in a separate file and it leaves the default keybindings files alone. Added benefit is that there is no need to modify the default files each update.

  • Like 1
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...