Jump to content

Sending messages to DSC-BIOS


ramzessii

Recommended Posts

Hi,

 

I think I've mentioned before that I have zero knowledge in programming but for the sake of argument I'll mention it again :)

 

I have managed to get the very straight forward, simple things to work with DCS-BIOS (basically various individual switches). Basically items where a single line of control reference + a definition of a pin is required. I hit a brick wall when it comes to anything that requires more than above.

 

Last night I kept on experimenting with Arduino and built a tiny key matrix (3x3 tactile switches) just to prove to myself that I can do it. Obviously I used keypad library and sketch provided by author of the tutorial.

 

I realised that because of the way key matrix works I won't be able to simply define a "pin against control reference" to "map" each key to let's say get CDU keys 1-9 to work, because each key press on my keypad is a combination of row & column ID's.

 

This is the code I use so far for my keypad (there is more but I removed it as it refers to toggle switches only):

 

#include <DcsBios.h>
#include <Servo.h>
#include <Keypad.h>

DcsBios::ProtocolParser parser;

const byte ROWS = 3; //three rows
const byte COLS = 3; //three columns

char keys[ROWS][COLS] = {
 {'1','2','3'},
 {'4','5','6'},
 {'7','8','9'},
};

byte rowPins[ROWS] = {3, 7, 5}; //connect to the row pinouts of the keypad
byte colPins[COLS] = {4, 2, 6}; //connect to the column pinouts of the keypad

Keypad keypad = Keypad( makeKeymap(keys), rowPins, colPins, ROWS, COLS );


void setup() {
  // initialize serial communication with computer:
 Serial.begin(9600);                  
}


void loop() {
 // feed incoming data to the parser
 while (Serial.available()) {
     parser.processChar(Serial.read());
 }
 
 // poll inputs
 DcsBios::PollingInput::pollInputs();


 char key = keypad.getKey();

 if (key != NO_KEY){
   Serial.println(key);
 }

}


void sendDcsBiosMessage(const char* msg, const char* arg) {
 Serial.write(msg);
 Serial.write(' ');
 Serial.write(arg);
 Serial.write('\n');
}


void onDcsBiosWrite(unsigned int address, unsigned int value) {

}

I struggle to understand as to how do I route my key presses so that they are unnderstood by DCS-BIOS as key presses on CDU (or anywhere else for that matter - it's just a test)

 

Also it seems that if I use Serial.begin(9600); then my toggle switches stop working in DCS. If I change it to Serial.begin(500000); my toggle switches work, but my keypad doesn't.

 

I would be glad if somebody could guide me in the right direction. Thanks.

 

Regards,

Janis

Link to comment
Share on other sites

I struggle to understand as to how do I route my key presses so that they are unnderstood by DCS-BIOS as key presses on CDU (or anywhere else for that matter - it's just a test)

 

The import protocol is described in the DCS-BIOS Developer Guide:

Commands are sent to DCS-BIOS as lines of plain text.

 

A command consists of a control identifier, a space, an argument and a newline character.

 

To find out the arguments that a certain control accepts, refer to the reference documentation and look up input interfaces in the User Guide.

 

Let's look at the "0" button on the CDU as an example. The control reference in "advanced" view has the following to say:

Input Interface: set_state Message: CDU_0 <new_value> Value Range: 0 ... 1 Description: set position

 

To push the button, send "CDU_0 1\n" by calling sendDcsBiosMessage("CDU_0", "1"). To release the button, send "CDU_0 0\n" by calling sendDcsBiosMessage("CDU_0", "0").

 

Also it seems that if I use Serial.begin(9600); then my toggle switches stop working in DCS. If I change it to Serial.begin(500000); my toggle switches work, but my keypad doesn't.

 

The connect-serial-port.cmd script that comes with DCS-BIOS expects to communicate with your Arduino at 500000 bps. The default mode of the serial monitor in the Arduino IDE expects 9600 bps (but it can be told to communicate at up to 115200 bps). When the speed that your Arduino is transmitting at does not match the speed your PC is receiving at, the serial communication will fail.

Link to comment
Share on other sites

Ian,

 

User guide was the first thing I read through as soon as I got my first arduino board. I have looked into developer guide too but most of it is chinese to me anyway. I have looken into both simple and advanced control references but you know - with no programming background it is like reading a book in chinese.

Thanks for your input but what seems straight forward to you is not at all so for me :( Seems the only way is to get on and learn programming.

 

Regards,

Janis

Link to comment
Share on other sites

Seems the only way is to get on and learn programming.

 

Yes, it is. You have discovered my secret master plan.

 

You get a few switches and LEDs up and running within an hour using copy&paste. Then you want to do something more advanced like using a display or a button matrix. At that point, I have already tricked you into putting an Arduino board on your desk, so you might as well play around with it.

 

Once you start writing your own Arduino code, you can never stop thinking of even more things you can build outside of your simpit -- just ask WarHog :devil_2:

Link to comment
Share on other sites

Ian;2343641']Yes, it is. You have discovered my secret master plan.

 

You get a few switches and LEDs up and running within an hour using copy&paste. Then you want to do something more advanced like using a display or a button matrix. At that point, I have already tricked you into putting an Arduino board on your desk, so you might as well play around with it.

 

Once you start writing your own Arduino code, you can never stop thinking of even more things you can build outside of your simpit -- just ask WarHog :devil_2:

 

Its true. He turned me into a monster:animals_bunny: . I spend every waking moment thinking about electronics and programming. Not so much programming yet as my brain couldn't handle the combined input of both disciplines at the same time. I don't have the band width to handle the data stream. And I don't want to end up like my poor Pro Mini yesterday... FRIED and smoking.:(

 

:pilotfly:

Regards

John W

aka WarHog.

 

My Cockpit Build Pictures...



John Wall

 

My Arduino Sketches ... https://drive.google.com/drive/folders/1-Dc0Wd9C5l3uY-cPj1iQD3iAEHY6EuHg?usp=sharing

 

 

WIN 10 Pro, i8-8700k @ 5.0ghz, ASUS Maximus x Code, 16GB Corsair Dominator Platinum Ram,



AIO Water Cooler, M.2 512GB NVMe,

500gb SSD, EVGA GTX 1080 ti (11gb), Sony 65” 4K Display

VPC MongoosT-50, TM Warthog Throttle, TRK IR 5.0, Slaw Viper Pedals

Link to comment
Share on other sites

Ian,

 

User guide was the first thing I read through as soon as I got my first arduino board. I have looked into developer guide too but most of it is chinese to me anyway. I have looken into both simple and advanced control references but you know - with no programming background it is like reading a book in chinese.

Thanks for your input but what seems straight forward to you is not at all so for me :( Seems the only way is to get on and learn programming.

 

Regards,

Janis

 

Janis, just keep at it m8, I'm in exactly the same boat. I knew nothing about programming and had little interest in electronics until, 5 people came into my life through DCS. Hans (HMA), FSF(Ian), Gadroc, Boltz and Warhog. Each one played a significant part in getting me into Programming, Arduinos, Chinese knockoffs, lasers, etc etc. I am still in my infancy with it all but once it got a hold of me I just can't stop. If I have a query any of them will help, the support on this forum is extraordinary. I went onto ebay and just bought a huge collection of breadboards, prototype boards, jumper wires, switches of all kinds, rotaries, power supplies, unos, megas, (Chinese ones are cheap as chips) and equally good if you don't mind waiting a week or two. I'm still overwhelmed with it all but I try and make a point of learning at least a couple of new things every day. Who knows? 6 months down the line I might actually become competent in it all. :thumbup:

Windows 7 64 Home Premium, i5 3570K (3.4 @ 4.4GHz), Asus P8Z77-V LX, 16GB dual channel 1600 ram, EVGA Nvidia GTX980ti, 240 GB OCZ SSD, 3 TB Raptor, Thrustmaster Warthog Hotas and Throttle, Saitek Pro Combat Rudder pedals.

Link to comment
Share on other sites

Ian,

 

User guide was the first thing I read through as soon as I got my first arduino board. I have looked into developer guide too but most of it is chinese to me anyway. I have looken into both simple and advanced control references but you know - with no programming background it is like reading a book in chinese.

Thanks for your input but what seems straight forward to you is not at all so for me :( Seems the only way is to get on and learn programming.

 

Regards,

Janis

 

I'm not sure I understand what the problem is. I'm a newbie at this as well. And in that light I helped Ian write the Users Guide so laypeople like you and I could understand what to do without needing to learn much at all. The developers guide to me is unbelievably foreign. I have no idea what it means, does or whatever. Maybe one day but not today. You shouldn't have even looked at it or anything in the advanced level of the Chrome app.

 

If you want to start making panels, adding some LED indicator lights and have the ability to adjust volumes or change channels in the cockpit then all you have to do is cut and paste stuff that has no meaning to me at all. All you need to know is that if you do exactly whats in the Users Guide...IT WORKS. Its step by step. Just follow the steps and have faith that if you follow the steps in the correct order and do only what your told to do then all will be well. And don't try to bite off more than you can chew as your still learning. If you jump too far ahead you will probably get frustrated. Start with implementing everything in the Users Guide first as in all the basic controls that are documented. Once you have a handle on all of that, then move on to the more complicated stuff.

 

If there is something that is unclear, ask us. We are all here to learn, to help each other and to grow in our knowledge, in our skills and our abilities and to pass on to others the same:).


Edited by Warhog

Regards

John W

aka WarHog.

 

My Cockpit Build Pictures...



John Wall

 

My Arduino Sketches ... https://drive.google.com/drive/folders/1-Dc0Wd9C5l3uY-cPj1iQD3iAEHY6EuHg?usp=sharing

 

 

WIN 10 Pro, i8-8700k @ 5.0ghz, ASUS Maximus x Code, 16GB Corsair Dominator Platinum Ram,



AIO Water Cooler, M.2 512GB NVMe,

500gb SSD, EVGA GTX 1080 ti (11gb), Sony 65” 4K Display

VPC MongoosT-50, TM Warthog Throttle, TRK IR 5.0, Slaw Viper Pedals

Link to comment
Share on other sites

You shouldn't have even looked at it or anything in the advanced level of the Chrome app.

 

If you want to start making panels, adding some LED indicator lights and have the ability to adjust volumes or change channels in the cockpit then all you have to do is cut and paste stuff

 

True until you want to do things like button matrices or displays, which the Arduino library does not support out of the box. As far as I understand it, there is no problem, just the need for confirmation that yes, to do these things you have to learn how to write Arduino code.

Link to comment
Share on other sites

  • 4 months later...

FYI, push button for MiG-21bis, the engine starter using sendDcsBiosMessage("ENG_START", "1");

 

here is my code;

#include <DcsBios.h>
#include <Servo.h>

int BUTTON1 = 4;

DcsBios::ProtocolParser parser;

// DCS: MiG-21bis
DcsBios::Switch2Pos engStart("ENG_START", BUTTON1);

void setup() {
 Serial.begin(500000);
}

void loop() {
 // feed incoming data to the parser
 while (Serial.available()) {
     parser.processChar(Serial.read());               

     if(digitalRead(BUTTON1) == HIGH)
     {
        sendDcsBiosMessage("ENG_START", "1");
     }
     else
     {
        sendDcsBiosMessage("ENG_START", "0");
     }
     
 }

 // poll inputs
 DcsBios::PollingInput::pollInputs();
}

void sendDcsBiosMessage(const char* msg, const char* arg) {
 Serial.write(msg);
 Serial.write(' ');
 Serial.write(arg);
 Serial.write('\n');
}

void onDcsBiosWrite(unsigned int address, unsigned int value) {
 
}


Edited by pappavis

met vriendelijke groet,

Михель

 

"умный, спортсмен, комсомолетс"

 

[sIGPIC]159th_pappavis.jpg[/sIGPIC]

 

[TABLE]SPECS: i9-9900K 32gigs RAM, Geforce 2070RTX, Creative XFi Fata1ity, TIR5, Valve Index & HP Reverb, HOTAS Warthog, Logitech G933 Headset, 10Tb storage.[/TABLE]

Link to comment
Share on other sites

FYI, push button for MiG-21bis, the engine starter using sendDcsBiosMessage("ENG_START", "1");

 

here is my code;

 

To get that switch to work, all you need is this line (and the rest of the TemplateSketch):

 

// DCS: MiG-21bis
DcsBios::Switch2Pos engStart("ENG_START", BUTTON1);

 

You do not need to write any calls to sendDcsBiosMessage() unless you are dealing with something that the Arduino library does not support out of the box, like a button matrix or shift register.

 

(People in the future (a few months from now): this information applies to the v0.1.x of the Arduino library. If by the time you read this v0.2 or later is out, there will be a better abstraction for those cases and the behavior of sendDcsBiosMessage() will have changed slightly.)

Link to comment
Share on other sites

By only using this engStart-command the button in cockpit remains pushed.

In order to verify if its correct i installed a LED with the button, so when the button is pushed a blue LED goes on. Which it does.

My if-else code solves the problem of the button remaining pushed. Could also be that i mixed the polarity on the Arduino' breadboard?

 

Ian;2443844']To get that switch to work, all you need is this line (and the rest of the TemplateSketch):

 

// DCS: MiG-21bis
DcsBios::Switch2Pos engStart("ENG_START", BUTTON1);

 

This is my layout.

tVGSfEM.png

 

EDIT 1-okt-2015: fixed PCB layout uploaded.


Edited by pappavis

met vriendelijke groet,

Михель

 

"умный, спортсмен, комсомолетс"

 

[sIGPIC]159th_pappavis.jpg[/sIGPIC]

 

[TABLE]SPECS: i9-9900K 32gigs RAM, Geforce 2070RTX, Creative XFi Fata1ity, TIR5, Valve Index & HP Reverb, HOTAS Warthog, Logitech G933 Headset, 10Tb storage.[/TABLE]

Link to comment
Share on other sites

You are right, the polarity is reversed here. Your circuit uses a pull-down resistor to make the Arduino pin default to logic low and your push button connects it to +5V to make it logic high.

 

It should be the other way around -- have a pull-up resistor to +5V to make the Arduino pin default to logic high and have the push button connect it to ground. Why are we doing it this way (obviously you can write the software to work with either arrangement)? Because the AVR chip has the pull-up resistor already built in, so you don't need to add it as separate component.

 

All you need is the DcsBios::Switch2Pos line and your push button between the Arduino pin and ground.

 

By the way, the LED on the button is lacking a current limiting resistor.

Link to comment
Share on other sites

  • 3 months later...

Hello Friends*

After tinkering arround for almost two weeks and reading (though reading - not understanding) user and developer guide (Google says "You visited this page 295 times" :) I brought my Keypad to send messages to DCS.

 

This is my construct inside the DCS-BIOS template sketch. It's just a skeletton, later will be there more than 70 buttons in a 8x9 matrix and several rotarys and LEDs (all to mount on my 18").

 

I think all here know how to make a keypad using Arduino's keypad library. So I cut this part of the code.

void loop() {

/// ---------------------------	
char leftKey = MFDL.getKey();	
 if  (leftKey) {
switch (leftKey){
	case '1':
	sendDcsBiosMessage("LMFD_01", "1"); // button pressed
	delay(50);
	sendDcsBiosMessage("LMFD_01", "0"); // button released after 50 ms
	break;
	case '2':
	sendDcsBiosMessage("LMFD_02", "1");
	delay(50);
	sendDcsBiosMessage("LMFD_02", "0");
	break;
	case '3':
	sendDcsBiosMessage("LMFD_03", "1");
	delay(50);
	sendDcsBiosMessage("LMFD_03", "0");
	break;
               // and so on
} // end switch (leftKey)
} // end if (leftKey)

Some of you high skilled programmer pros will smile after seeing that.

 

I found no other way to bring the output of the keypad into the holy DCS-BIOS-Mashine.

So I can't hold a button ATM (important to reload DSMS e.g) And a 65 switch-case construction doesn't look like a good solution. And it makes me a stomachache cause I know I worked arround the intention of DCS-BIOS.

 

But I'm happy that moves sth. ;)

 

Could some (or one) of you bring me on the right lane?

I think there is just a small step to go (but the wall seems to be very high to me)

 

* I count on that

 

PS: Take a look at the pic. It's a sad view. Isn't it? (I mean the central 18" TFT still without any controls)

(The LeftSideController works with a Leonardo under MMJoy2)

1635361879_2015-11-1516_12_34.thumb.jpg.2230351c674603e913a1a22d436807d6.jpg


Edited by Tekkx

Manual for my version of RS485-Hardware, contact: tekkx@dresi.de

Please do not PM me with DCS-BIOS-related questions. If the answer might also be useful to someone else, it belongs in a public thread where it can be discovered by everyone using the search function. Thank You.

Link to comment
Share on other sites

"PS: Take a look at the pic. It's a sad view. Isn't it?

 

(The LeftSideController works with a Leonardo under MMJoy2)"

 

Tekkx: Not at all. It rocks m8, you have integrated a lot of stuff there, it's not easy is it?

Nobody in this thread will ever slag someones pit off. The problem is, now you got that working together, I bet you decide! maybe I'll make some new switch panels and then you are lost alongside us.

I was invited to a quiz the other night locally, and whilst there I had to go for a piss. In the toilet I couldn't hose because a servo pattern came into my head. You know what I mean.

 

weeb

 

:pilotfly:

Windows 7 64 Home Premium, i5 3570K (3.4 @ 4.4GHz), Asus P8Z77-V LX, 16GB dual channel 1600 ram, EVGA Nvidia GTX980ti, 240 GB OCZ SSD, 3 TB Raptor, Thrustmaster Warthog Hotas and Throttle, Saitek Pro Combat Rudder pedals.

Link to comment
Share on other sites

Dear weeb.

This was a missunderstanding. :D

The "sad view" arises from the 18" (center dash) still without any working knobs and other gismos. And no idea in sight how to get this into business.

 

And I know what you're saying. I do not sleep very well with unsolved "problems" in mind.

There is also the paractically working, but still unfinished magnetic switch at my workbench...

 

So I pray for the key to the secrets of The World of DCS-BIOS.

Manual for my version of RS485-Hardware, contact: tekkx@dresi.de

Please do not PM me with DCS-BIOS-related questions. If the answer might also be useful to someone else, it belongs in a public thread where it can be discovered by everyone using the search function. Thank You.

Link to comment
Share on other sites

Hi Tekkx

 

I'm not sure what it is you are wanting to do and what DCS-BIOS isn't doing for you. Could you describe what you would like to see happen.

 

Try and be rather specific as if you were sitting in your cockpit when its all done.

:)

John

Regards

John W

aka WarHog.

 

My Cockpit Build Pictures...



John Wall

 

My Arduino Sketches ... https://drive.google.com/drive/folders/1-Dc0Wd9C5l3uY-cPj1iQD3iAEHY6EuHg?usp=sharing

 

 

WIN 10 Pro, i8-8700k @ 5.0ghz, ASUS Maximus x Code, 16GB Corsair Dominator Platinum Ram,



AIO Water Cooler, M.2 512GB NVMe,

500gb SSD, EVGA GTX 1080 ti (11gb), Sony 65” 4K Display

VPC MongoosT-50, TM Warthog Throttle, TRK IR 5.0, Slaw Viper Pedals

Link to comment
Share on other sites

Hey John.

As I wrote at #14 I want to bring a button matrix to run.

This should become 2 MFCDs and some other stuff.

At the pic at #14 is my 18" to be seen where all these stuff should be screwed on.

 

This all will be connected to a Mega 2560 which is partially configured as a button matrix by keypad.h (one of the latest Arduino Librarys).

The Mega is already running and communicating with DCS like a charm.

 

The goal (and also the biggest problem) is to find the interface between output of the matrix and the functions of DCS-BIOS.

 

At post #14 is a very short part of my code to be seen. Just as an example, how far and in which direction I already went. This code isn't a beauty but it works in some degree.

 

Meanwhile I found the function Eventlistener (part of keypad.h) as a better way. (this brings other issues with it... I think this is to diskuss at Arduino Forum)

 

Otherwise that all doesn't makes me happy cause its just a workaround. Not clean DCS-BIOS.

... and what DCS-BIOS isn't doing for you ...

It's not DCS-BIOS where the fault is! It's me cause I can't understand so much of this :(


Edited by Tekkx

Manual for my version of RS485-Hardware, contact: tekkx@dresi.de

Please do not PM me with DCS-BIOS-related questions. If the answer might also be useful to someone else, it belongs in a public thread where it can be discovered by everyone using the search function. Thank You.

Link to comment
Share on other sites

So, my Friends.

Sometimes is it enough to know that there is someone with you.

I found a solution. And it works.

The code based on an example at Arduino Playground and DCS-BIOS tempate sketch.

// an attempt to realize ButtonMatrix in DCS-BIOS by Tekkx :)

#include <Keypad2.h>
#include <DcsBios.h>
#include <Servo.h>

/**** Make your changes after this line ****/ 
const byte ROWS = 3; // quantity of rows (later 8)
const byte COLS = 3; // quantity of columns (later 9)
int PWM_Pin = 12; // Backlighting AUX (Buttons of MFCDs
int MCB = A5;
// all other Non-Matrix-Buttons and rotarys follows here

char OSB[ROWS][COLS] = {  // Define the Keymap
 {'1','2','3'},
 {'4','5','6'},
 {'7','8','9'},
 //{'0','a','b'}, Still under construction
 //{'c','d','e'},
 //{'f','g','h'},
 //{'i','j','k'},
 //{'l','m','n'}
};
// Connect MFD Rows and Columns to these Arduino pins.
byte rowPins[ROWS] = { A8, A9, A10 };
byte colPins[COLS] = { 7, 6, 5 }; 

// Create the Keypad, initialize an instance of class NewKeypad
Keypad MFD = Keypad( makeKeymap(OSB), rowPins, colPins, ROWS, COLS );
/* Instantiate a ProtocolParser object to parse the DCS-BIOS export stream */
DcsBios::ProtocolParser parser;

DcsBios::Switch2Pos masterCautionBtn("UFC_MASTER_CAUTION", MCB);
DcsBios::LED masterCaution(0x1012, 0x0800, 10);

/**** In most cases, you do not have to change anything below this line ****/

/* Instantiate a ProtocolParser object to parse the DCS-BIOS export stream */
//DcsBios::ProtocolParser parser;

void setup() {
MFD.addEventListener(keypadEvent); //add an event listener for this leftMFD
Serial.begin(115200);
MFD.setDebounceTime(50); // maybe needless
 

} // end setup

/*
Your main loop needs to pass data from the DCS-BIOS export
stream to the parser object you instantiated above.

It also needs to call DcsBios::PollingInput::pollInputs()
to detect changes in the state of connected controls and
pass them on to DCS.
*/
void loop() {
char OSB = MFD.getKey();
// feed incoming data to the parser
while (Serial.available()) {
     parser.processChar(Serial.read());
}
 // poll inputs
 DcsBios::PollingInput::pollInputs();
 //if (OSB) {
   //Serial.println(OSB);
 //}
}
/// ---------------------------	
void keypadEvent(KeypadEvent OSB){	
 	switch(OSB) {
	case '1': sendDcsBiosMessage("LMFD_01", "1"); break;
	case '2': sendDcsBiosMessage("LMFD_02", "1"); break;
	case '3': sendDcsBiosMessage("LMFD_03", "1"); break;
}
switch (MFD.getState()){	
case RELEASED: 
switch(OSB) {
	case '1': sendDcsBiosMessage("LMFD_01", "0"); break;
	case '2': sendDcsBiosMessage("LMFD_02", "0"); break;
	case '3': sendDcsBiosMessage("LMFD_03", "0"); break;
} // end switch 
}
}  ;  // end void
  
	
/// ----------------------------  

/*
You need to define
void sendDcsBiosMessage(const char* msg, const char* arg)
so that the string msg, followed by a space, the string arg
and a newline gets sent to the DCS-BIOS import stream.

In this example we send it to the serial port, so you need to
run socat to read the data from the serial port and send it
over UDP to DCS-BIOS.

If you are using an Ethernet Shield, you would probably want
to send a UDP packet from this subroutine.
*/
void sendDcsBiosMessage(const char* msg, const char* arg) {
 Serial.write(msg);
 Serial.write(' ');
 Serial.write(arg);
 Serial.write('\n');
}

/*
This subroutine gets called every time a message is received
from the export stream (you need to define it even if it
does nothing).

Use this to handle outputs which are not covered by the
DcsBios Arduino library (e.g. displays).
*/
void onDcsBiosWrite(unsigned int address, unsigned int value) {

}

There maybe some unnecessary code inside. E.G. it sends tho ON-Signal twice on button press before it sends the OFF-Signal when button is released.

But this is the closest approach my brain is able to :)

 

Please give me a hand if you find something to improve.

If not: Use and adopt it to your own matters.


Edited by Tekkx

Manual for my version of RS485-Hardware, contact: tekkx@dresi.de

Please do not PM me with DCS-BIOS-related questions. If the answer might also be useful to someone else, it belongs in a public thread where it can be discovered by everyone using the search function. Thank You.

Link to comment
Share on other sites

It's not DCS-BIOS where the fault is! It's me cause I can't understand so much of this :(

 

You know Tekkx, I don't think it's a problem to mix and match whatever works best for you based on your skill set or even how are building your cockpit. For instance, I could use DCS-BIOS to export the information from the DCS CDU screen to my CDU screen but I don't want to do it that way. For one, I don't know how but I do know how to export the info via a graphics card. So thats what I am doing. When I build my MFCD's I intend to use MMjoy and a matrix. I see no point in using all of those pins (Arduino pins) for 40 odd buttons when I can use a matrix and reduce the number of pins I need.

 

If you new how much I have had to learn just to get this far you would fall over. No one would expect that I should learn everything I need to make all this happen and thats why we have a forum. We get to draw from a wide variety of expertise just so you don't have to learn everything.

 

BTW, when you mentioned attaching stuff to the sides of the monitor... this is what I started with before I decided to build a complete cockpit. Its a touch screen monitor with indicators on the top and radio controls and some other commands at the side and then an X-Keys 16 key key pad on the bottom. This mostly runs off a Bodnar BB32 board and a Phidgets board and a mix of some other stuff. Its a little dark as I wanted the backlighting to show but save it and zoom in to see the detailing. More here...http://s221.photobucket.com/user/MRAR15/media/A10%20Cockpit%20Panels/LR-4.jpg.html?sort=3&o=350

 

LR-4.jpg

Regards

John W

aka WarHog.

 

My Cockpit Build Pictures...



John Wall

 

My Arduino Sketches ... https://drive.google.com/drive/folders/1-Dc0Wd9C5l3uY-cPj1iQD3iAEHY6EuHg?usp=sharing

 

 

WIN 10 Pro, i8-8700k @ 5.0ghz, ASUS Maximus x Code, 16GB Corsair Dominator Platinum Ram,



AIO Water Cooler, M.2 512GB NVMe,

500gb SSD, EVGA GTX 1080 ti (11gb), Sony 65” 4K Display

VPC MongoosT-50, TM Warthog Throttle, TRK IR 5.0, Slaw Viper Pedals

Link to comment
Share on other sites

At the first look I thought this was my cockpit :)

 

My CDU Screen is also on VGA. I'll keep it that way also.

But since the first day I don't want to go by Touchscreen. Too expensive. Meanwhile I have so much money spent to parts and tools that I would be able to afford 3 Touchscreens instead of that.

 

My LeftSideController (inspired by the original UFC) is driven by an Arduino Leonardo with MMJoy2. It works very well, but just in one direction. There is no Backlight e.g. Thats why I'm so happy with and grateful for this priceless tool named DCS-BIOS :)

 

Right now I have more Flight-Equipment as I ever wanted. If I remember: A little more than one year ago it was a good experience to fly arround with Helikopters in BC4... That's history.

Now I finish my 18" with MFD and some Knobs to manipulate shown instruments as Clock, VVI, Fuel Indicator and some others. The most important gimmick is, I can remove the whole flight-stuff with two hand movements :)

Then will follow just(!) an AAP and an Electric and an Laste and an Comm and an...

 

I CAN'T SEE AN END (sorry for screaming) :D

 

... and a new GPU. My FPS are less than 20 :(


Edited by Tekkx

Manual for my version of RS485-Hardware, contact: tekkx@dresi.de

Please do not PM me with DCS-BIOS-related questions. If the answer might also be useful to someone else, it belongs in a public thread where it can be discovered by everyone using the search function. Thank You.

Link to comment
Share on other sites

I did a small cosmetic to my code (relative to Post #19)

...
  void loop() {
char OSB = MFD.getKey(); // weist OSB den Wert der gedrückten Taste zu
while (Serial.available()) { // feed incoming data to the parser
     parser.processChar(Serial.read());
	}
DcsBios::PollingInput::pollInputs();
}
/// ---------------------------	
void keypadEvent(KeypadEvent OSB){	
switch (MFD.getState()) {
case PRESSED:	
	switch(OSB) { // 
	case '1': sendDcsBiosMessage("LMFD_01", "1"); break;
 	case '2': sendDcsBiosMessage("LMFD_02", "1"); break;
	case '3': sendDcsBiosMessage("LMFD_03", "1"); break;
              //.... other 65 cases will follow here
}}
   switch (MFD.getState()){	// gives PRESSED, HOLD or RELEASED
case RELEASED: 
	switch(OSB) {
	case '1': sendDcsBiosMessage("LMFD_01", "0"); break;
	case '2': sendDcsBiosMessage("LMFD_02", "0"); break;
	case '3': sendDcsBiosMessage("LMFD_03", "0"); break;
            //....
}} 
} ;
...

 

This works like hell :) If I could put the "message" in the matrix it would be more easy.

This afternoon I spent with crimping 0.1 connectors... :crazy:

Manual for my version of RS485-Hardware, contact: tekkx@dresi.de

Please do not PM me with DCS-BIOS-related questions. If the answer might also be useful to someone else, it belongs in a public thread where it can be discovered by everyone using the search function. Thank You.

Link to comment
Share on other sites

 

I CAN'T SEE AN END

 

End????? There is no end. Sorry but nobody has found a cure for this so you will just have to make the best of it. I"m starting to gather data on my next pit and my A10C isn't even 75% complete.

 

It could be worse. Just think about the guys who are building two pits at at at the same t t t time.:cry:

 

:helpsmilie:

Regards

John W

aka WarHog.

 

My Cockpit Build Pictures...



John Wall

 

My Arduino Sketches ... https://drive.google.com/drive/folders/1-Dc0Wd9C5l3uY-cPj1iQD3iAEHY6EuHg?usp=sharing

 

 

WIN 10 Pro, i8-8700k @ 5.0ghz, ASUS Maximus x Code, 16GB Corsair Dominator Platinum Ram,



AIO Water Cooler, M.2 512GB NVMe,

500gb SSD, EVGA GTX 1080 ti (11gb), Sony 65” 4K Display

VPC MongoosT-50, TM Warthog Throttle, TRK IR 5.0, Slaw Viper Pedals

Link to comment
Share on other sites

End? :) I have been at it for months and it's only the beginning for me. I think I have bought every type of available electrical component, LCD, LED, acrylic, bonding glue, oh and a laser, also £300.00 uk of aluminium, £600 upgrade for laser, some actual military flight components and gauges, so far £200.00 in arduinos, megas, minis, project boards, power supplies et all. Once it gets a hold of you, there is no going back my friend and do you know something, i wouldn't change it for anything. ;)

Windows 7 64 Home Premium, i5 3570K (3.4 @ 4.4GHz), Asus P8Z77-V LX, 16GB dual channel 1600 ram, EVGA Nvidia GTX980ti, 240 GB OCZ SSD, 3 TB Raptor, Thrustmaster Warthog Hotas and Throttle, Saitek Pro Combat Rudder pedals.

Link to comment
Share on other sites

End? :) I have been at it for months and it's only the beginning for me. I think I have bought every type of available electrical component, LCD, LED

 

My wife suggested we factor the cockpit building into the household budget, under the section 'hobbies' :smartass:.

met vriendelijke groet,

Михель

 

"умный, спортсмен, комсомолетс"

 

[sIGPIC]159th_pappavis.jpg[/sIGPIC]

 

[TABLE]SPECS: i9-9900K 32gigs RAM, Geforce 2070RTX, Creative XFi Fata1ity, TIR5, Valve Index & HP Reverb, HOTAS Warthog, Logitech G933 Headset, 10Tb storage.[/TABLE]

Link to comment
Share on other sites

  • Recently Browsing   0 members

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