Jump to content

HUD brightness rotary knob


Go to solution Solved by LeCuvier,

Recommended Posts

Posted (edited)

Hello,

Is there any way to speed up the rotation? lua or any other variants. I have a custom keyboard with rotary knobs, but after assigning as buttons to to the HUD brightness increase/decrease controls the knob is spinning very slowly, not as fast as I would spin using the mouse. Thanks

Edited by IR.Clutch

i7-11700K 5GHz, 64GB DDR4@3200, ZOTAC RTX4090, iiyama 34 Red Eagle  || Quest 3  || Thrustmaster TQS,  Tianhang M-FSSB PRO base, VPC Interceptor rudder pedals  || Simshaker Jetpad || F-16 cockpit

 

 

  • Solution
Posted

There is a way. I understand you want to use a rotary encoder on your keyboard. Therefore you need to modify the file "default.lua" under "DRIVE:\Eagle Dynamics\DCS World OpenBeta\Mods\aircraft\F-16C\Input\F-16C\keyboard". It has 2 relevant lines of code:

{pressed = ufc_commands.SYM_Knob_ITER, cockpit_device_id = devices.UFC,	value_pressed =  0.3, name = _('ICP HUD Symbology Intensity Knob - Up/Increase'), category = {_('Instrument Panel'), _('ICP')}},
{pressed = ufc_commands.SYM_Knob_ITER, cockpit_device_id = devices.UFC,	value_pressed = -0.3, name = _('ICP HUD Symbology Intensity Knob - Down/Decrease'), category = {_('Instrument Panel'), _('ICP')}},

The value of the parameter "value_pressed" determines how fast the knob in the cockpit rotates. I recommend you leave the original lines alone and add the two lines below for a "fast" version of the command:

{pressed = ufc_commands.SYM_Knob_ITER, cockpit_device_id = devices.UFC,	value_pressed =  1.0, name = _('ICP HUD Symbology Intensity Knob - Up/Increase Fast'), category = {_('Instrument Panel'), _('ICP')}},
{pressed = ufc_commands.SYM_Knob_ITER, cockpit_device_id = devices.UFC,	value_pressed = -1.0, name = _('ICP HUD Symbology Intensity Knob - Down/Decrease Fast'), category = {_('Instrument Panel'), _('ICP')}},

Alternatively, you could change the values of the original lines. If you do that you must still change the name so it's different from that of the original command. This is because the command also exists in the "default.lua" under "DRIVE:\Eagle Dynamics\DCS World OpenBeta\Mods\aircraft\F-16C\Input\F-16C\joystick". So, if you change just the values and not the names, the Options/Controls screen would show you duplicate lines in orange font, because you have different commands with the same name. And you would not know which lines to bind.

And don't forget: Any update or repair will restore the original file. So you need to back up your modified file.
 

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Posted
2 часа назад, LeCuvier сказал:

And you would not know which lines to bind.

Amazing! Thanks a lot!🤩 it worked

i7-11700K 5GHz, 64GB DDR4@3200, ZOTAC RTX4090, iiyama 34 Red Eagle  || Quest 3  || Thrustmaster TQS,  Tianhang M-FSSB PRO base, VPC Interceptor rudder pedals  || Simshaker Jetpad || F-16 cockpit

 

 

Posted
22 часа назад, LeCuvier сказал:

There is a way

Do you maybe know what is the best setting for CRS SET and HDG SET? This does not work well at all with the encoder

i7-11700K 5GHz, 64GB DDR4@3200, ZOTAC RTX4090, iiyama 34 Red Eagle  || Quest 3  || Thrustmaster TQS,  Tianhang M-FSSB PRO base, VPC Interceptor rudder pedals  || Simshaker Jetpad || F-16 cockpit

 

 

Posted

You need to try what works best for yourself. Your encoders may not have the same spec as mine. You can set up a series of test versions in "default.lua" and then try out in an instant action which works best. Example with just 2 versions for HDG SET:

{pressed = ehsi_commands.RightKnob, cockpit_device_id = devices.EHSI,	value_pressed = -0.03, name = _('CRS Set / Brightness Control Knob - CCW/Decrease Fast1'), category = {_('Instrument Panel')}},
{pressed = ehsi_commands.RightKnob, cockpit_device_id = devices.EHSI,	value_pressed =  0.03, name = _('CRS Set / Brightness Control Knob - CW/Increase Fast1'),	category = {_('Instrument Panel')}},
{pressed = ehsi_commands.RightKnob, cockpit_device_id = devices.EHSI,	value_pressed = -0.06, name = _('CRS Set / Brightness Control Knob - CCW/Decrease Fast2'), category = {_('Instrument Panel')}},
{pressed = ehsi_commands.RightKnob, cockpit_device_id = devices.EHSI,	value_pressed =  0.06, name = _('CRS Set / Brightness Control Knob - CW/Increase Fast2'),	category = {_('Instrument Panel')}},

You can set it up with versions for all values between 0.1 and 1.0, so you don't need to restart the game for each test. Just make sure every version has a distinct name.
The 0.3 seemed slow for me, and the 0.6 a bit fast. So maybe 0.5 would be right, but it's subjective. I don't use these as I have only two rotary encoders on my button box and they are taken for other commands.

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Posted
В 28.04.2023 в 19:08, LeCuvier сказал:

You can set it up

I have the feeling that sometimes DCS fails to work, but the encoder itself is sending commands. There are skips on the DCS side. Not 100% sure.

i7-11700K 5GHz, 64GB DDR4@3200, ZOTAC RTX4090, iiyama 34 Red Eagle  || Quest 3  || Thrustmaster TQS,  Tianhang M-FSSB PRO base, VPC Interceptor rudder pedals  || Simshaker Jetpad || F-16 cockpit

 

 

  • Recently Browsing   0 members

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