Jump to content

CDU Pushbutton Control through Export.lua


Levinsky

Recommended Posts

Hi all,

 

I've got an OpenCockpits CDU I'm doing testing with in my pit and just wanted to double check my understanding of how push buttons work (as opposed to toggle switches) in the Export.lua script.

 

Let's say you want to simulate a 'Z' on the CDU, that means you set Device 9 (CDU) Button 3052 to value 1.0. I then have to immediately send through another command to the CDU to set that button back to 0.0. I guess this simulates the action of pressing and releasing the button. If I don't send the 0.0 through, the in game CDU gets an endless line of 'Z's.

 

Is this the best way of handling the control of push buttons in the sim (sending two commands through for each button press)? Or can it be achieved in a simpler manner?

 

Thanks,

Ken.

Link to comment
Share on other sites

I realized it his way:

You push your real button -> Send the 1.0 (or is it 0.1? don't remember...)

You release your real butoon -> Send the 0.0

 

This way you keep the repeating funtionality of the ingame CDU (if it has one...)

 

If you come to the problem with repeating letters, just programm a short trigger, that send changing values.

visit my build thread Gremlin's A-10 :thumbup:

http://forums.eagle.ru/showthread.php?t=86916

Link to comment
Share on other sites

Hi Gremlin,

 

yup just what I thought - thanks for the quick response. I just finished programming up all the buttons on the CDU (it's really meant for a 737 but you can make it work). Actually just being able to press real buttons and program a CDU is just cool :).

 

Ken.

Link to comment
Share on other sites

  • 1 month later...

Does this ave a working LCD output as well?

 

Pics?

ASUS Tuf Gaming Pro x570 / AMD Ryzen 7 5800X @ 3.8 / XFX Radeon 6900 XT / 64 GB DDR4 3200 

"This was not in the Manual I did not read", cried the Noob" - BMBM, WWIIOL

Link to comment
Share on other sites

Hi,

 

yup it has a LCD screen which is technically larger then the actual A-10C CDU screen (certainly has more buttons on each side of the screen). However it is quick to get up and working and I have it setup to fully emulate all of the A-10C CDU buttons. I may in the future laser engrave some new buttons to replace a few to make it more like the A-10C. I will get some photos or video of the working CDU and post probably tomorrow. I wrote a simple C# program that connects to the SOIC server and uses a Dictionary for quick lookups for mappings of button to DCS LUA commands. Has no real performance impact.

 

Ken.

Link to comment
Share on other sites

  • 1 month later...

i'm still interested to hear how this panned out

ASUS Tuf Gaming Pro x570 / AMD Ryzen 7 5800X @ 3.8 / XFX Radeon 6900 XT / 64 GB DDR4 3200 

"This was not in the Manual I did not read", cried the Noob" - BMBM, WWIIOL

Link to comment
Share on other sites

Hi Dooom,

 

I put together a quick video showing the Open Cockpits 737NG CDU in action under DCS World/A-10C. It's not the best video (my first youtube upload) but you'll get the idea. I hope to add a better video soon.

 

I am working on integrating the CDU back lighting into DCS as well and this should be working in the next few days - you flick in the in-cockpit lighting switches and the CDU back lighting is enabled.

 

I also plan on using a CNC laser engraver to redo the buttons that control the CDU pages to the correct A-10C buttons. I will then remove/blank out the unused buttons so there wont be any confusion during flight :).

 

Ken.


Edited by Levinsky
Link to comment
Share on other sites

  • 9 months later...

Yo Levinsky,

 

I have an opportunity to buy the same CDU - do you have a resource available to point me towards the keyfile export and directions to get the LCD working? i'd like to follow your lead on this one.

ASUS Tuf Gaming Pro x570 / AMD Ryzen 7 5800X @ 3.8 / XFX Radeon 6900 XT / 64 GB DDR4 3200 

"This was not in the Manual I did not read", cried the Noob" - BMBM, WWIIOL

Link to comment
Share on other sites

  • 1 year later...

DCS and Opencockpits CDU

 

Yo Levinsky,

 

I have an opportunity to buy the same CDU - do you have a resource available to point me towards the keyfile export and directions to get the LCD working? i'd like to follow your lead on this one.

 

Sorry to bother but did you get it working and can share, I have the same for a 737 and have started flying the A-10C. Thank you in advance, Lus

Link to comment
Share on other sites

Hi Dooom,

 

I put together a quick video showing the Open Cockpits 737NG CDU in action under DCS World/A-10C. It's not the best video (my first youtube upload) but you'll get the idea. I hope to add a better video soon.

 

I am working on integrating the CDU back lighting into DCS as well and this should be working in the next few days - you flick in the in-cockpit lighting switches and the CDU back lighting is enabled.

 

I also plan on using a CNC laser engraver to redo the buttons that control the CDU pages to the correct A-10C buttons. I will then remove/blank out the unused buttons so there wont be any confusion during flight :).

 

Ken.

 

 

Sorry to bother but did you get it working and can share, I have the same for a 737 and have started flying the A-10C. Thank you in advance, Lus

Link to comment
Share on other sites

  • Recently Browsing   0 members

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