Jump to content

HMA's cockpit build


Hansolo

Recommended Posts

  • 1 month later...

Off on summer holiday

 

Thank you GSS Rain and thank you so much for the assistence on the Emergency Flight Control Panel trim switch. If you hadn't already solved it with a NAND circuit I am not sure what I would have done. Rep inbound :thumbup:

 

Alright status for the first half of 2017. Following panels have been implemented using Ian's DCS-BIOS:

 

Electrical power panel (original)

 

Aux. Avionics Panel (my old panel layout with correct toggle switches but rotary are cheap ones)

 

Light Control Panel (original but missing nose illumination siwtch)

 

Fuel Control Panel (original with selvmade fuel lever)

 

Aux. Light panel (my old panel layout but with correct toggle switches)

 

SAS Panel ( my old panel layout but with 4x mag switches working. The Monitor test switch is not the correct type though.

 

LASTE panel (new backplate made from dimension of the antenna panel. Real switches incl on mag switch working. No light plate on yet)

 

Emergency Flight Control Panel (my old panel layout. Toggle switches correct type except for the trim hat. Implemented with a NAND circuit to make the hat switch work correctly)

 

AHCP (my old panel layout. Mostly real switches except for the 3-position. Will have find some real switches at decent prices though :music_whistling:)

 

Landing gear panel (my old panel layout where indicators are via Helios, but mag switch is running)

 

So after first half of 2017 has gone by I am pretty happy to have all 7 mag switches in the pir working correctly.

 

YyKuOPBl.jpg

 

Z5nf7b7l.jpg

 

Next panels to go for is most likely IFF, Intercom panel, Antenna. Then I probably go for getting some steppers up and runnning before turning my attention to the radios. Still plenty of work but that's the fun right

 

With that I'll bid you all a very nice summer holiday.

 

Cheers

Hans

Link to comment
Share on other sites

Looking fantastic Hans! How about a peek at the underside of them panels? ;) When you used DCS-Bios, did you also use 485's or 7's, or are they still individually wired? I'm impressed! Even the toggle switches are originals! You get those from eBay? Anyway, it seems there's always something that still needs to be done on this hobby, no matter how much you do. But you're always impressing me with the amount and quality of what you've got done so far. Good luck on the rest of the year!

Buttons aren't toys! :smilewink:

 

My new Version 2 Pit: MacFevre A-10C SimPit V2

My first pit thread: A-10C Simulator Pit "The TARDIS."

Dzus Fastener tutorial, on the inexpensive side: DIY Dzus Fastener

Link to comment
Share on other sites

Sure Mac

 

Arduino Nano sitting in a terminal board. Beneath a prototype board which hold the MAX487 chip. The MAX487 is powered from the Nano, the Nano is powered by 12VDC

beAgIbsl.jpg

 

On the same prototype board is situated the 74HCT20 NAND IC.

5r55VGyl.jpg

 

On the prototype board there is also 4x IRF510 MOSFET that powers the LED's on/off

4FfGssLl.jpg

 

There is one of these setups per panel. Not all of them with the MOSFET of cause and so far only one with the NAND IC

The toggle switches I found on Ebay. Bough a bundle a while back :-)

 

Cheers

Hans

Link to comment
Share on other sites

Thanks Hans! So are you using your B256A13 anymore at all? I started with one, but haven't used it since the Arduinos became a real choice. I think the thing that really started to get to me was having to use a diode in every single circuit. Plus since DCS-Bios, don't have to worry about assigning every single device and switch to a command. ;)

Buttons aren't toys! :smilewink:

 

My new Version 2 Pit: MacFevre A-10C SimPit V2

My first pit thread: A-10C Simulator Pit "The TARDIS."

Dzus Fastener tutorial, on the inexpensive side: DIY Dzus Fastener

Link to comment
Share on other sites

Nice work Hansolo...

 

Are you still using a secondary screen and Helios software in the cockpit??

I am thinking of setting up a virtual cockpit with a second touchscreen in which to export the main instruments and MFDs, but I don´t know whether to use Helios or Ikarus with the latest versions of DCSW and windows10.

Link to comment
Share on other sites

Thanks Ikaro

 

Yes I am still using Helios on a second screen for MIP instruments. I did try out Ikarus but couldn't get it to work properly. I guess it's an issue with my PC which I haven't location yet.

I briefly tried Windows Creator but that messed up my DCS-BIOS. The Socat wouldn't connect so back on plain Windows 10. Probably time for a complete reinstall of everything :music_whistling:

 

Cheers

Hans

Link to comment
Share on other sites

  • 1 month later...

DCS-BIOS with AAP, F-16 MFD & C-130 CDU

 

Finally managed to get a little further with the pit. Very productive weekend so far (HQ and Minime are on tour )

 

First I got a real AAP up and running on DCS-BIOS. It was a fairly simple task of remove boards and wires from the old self made panel and then hook them up to the real one. The CDU ON and EGI ON switches are ON-ON switches but that is no problem for DCS-BIOS

umg1RdAl.jpg

 

OyzBInYl.jpg

 

 

Back in November last year I did some test with Arduino Keypad library (https://playground.arduino.cc/Code/Keypad) and a C-130 CDU pinout (https://forums.eagle.ru/showpost.php?p=2958104&postcount=109). I just used the serial monitor to confirm that inputs were working not establishing communication with DCS-BIOS.

 

Tekkx got his Keypad library working with DCS-BIOS so yesterday I tried to get my F-16 MFD’s up at running using Tekkx’s work as reference and the Keypad library.

After remarkably little trial and error I got it working. I left out some of Tekkx’s code as I was unsure what it did, but perhaps it is needed with an older version of DCS-BIOS.

 

/*
 The following #define tells DCS-BIOS that this is a RS-485 slave device.
 It also sets the address of this slave device. The slave address should be
 between 1 and 126 and must be unique among all devices on the same bus.
*/
#define DCSBIOS_RS485_SLAVE 16

/*
 The Arduino pin that is connected to the
 /RE and DE pins on the RS-485 transceiver.
*/
#define TXENABLE_PIN 2
#include <Keypad.h>
#include "DcsBios.h"

/* paste code snippets from the reference documentation here */
const byte ROWS = 7; //four rows
const byte COLS = 4; //three columns
char keys[ROWS][COLS] = {
 {'a','b','c','d'},
 {'e','f','g','h'},
 {'i','j','k','l'},
 {'m','n','o','p'},
 {'q','r','s','t'},
 {'u','v','w','x'},
 {'y','z','$','&'},
};
byte rowPins[ROWS] = {A5, 3, A4, 4, A3, 5, A2}; //connect to the row pinouts of the keypad
byte colPins[COLS] = {A1, 11,A0,12}; //connect to the column pinouts of the keypad

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

//PWR OFF - NT - DAY
const byte LMFDPwrPins[3] = {6, 7, 8};
DcsBios::SwitchMultiPos LMFDPwr("LMFD_PWR", LMFDPwrPins, 3);

//Master Caution
DcsBios::LED masterCaution(0x1012, 0x0800, 13);

void setup() {
 DcsBios::setup();
 keypad.addEventListener(keypadEvent);  // Add an event listener.
 keypad.setHoldTime(100);               // Default is 1000mS
 keypad.setDebounceTime(50);           // Default is 50mS
}

void loop() {
 DcsBios::loop();
  char key = keypad.getKey();
}

void keypadEvent(KeypadEvent KEY){  
 switch (keypad.getState()) { // gives PRESSED, HOLD or RELEASED
 case PRESSED: 
   switch(KEY) { 
     // LMFD
   case 'y': sendDcsBiosMessage("LMFD_01", "1"); break; 
   case 'z': sendDcsBiosMessage("LMFD_02", "1"); break; 
   case '$': sendDcsBiosMessage("LMFD_03", "1"); break; 
   case '&': sendDcsBiosMessage("LMFD_04", "1"); break; 
   case 'u': sendDcsBiosMessage("LMFD_05", "1"); break; 
   
   case 'v': sendDcsBiosMessage("LMFD_06", "1"); break; 
   case 'w': sendDcsBiosMessage("LMFD_07", "1"); break; 
   case 'x': sendDcsBiosMessage("LMFD_08", "1"); break; 
   case 'q': sendDcsBiosMessage("LMFD_09", "1"); break; 
   case 'r': sendDcsBiosMessage("LMFD_10", "1"); break; 

   case 's': sendDcsBiosMessage("LMFD_11", "1"); break; 
   case 't': sendDcsBiosMessage("LMFD_12", "1"); break; 
   case 'm': sendDcsBiosMessage("LMFD_13", "1"); break; 
   case 'n': sendDcsBiosMessage("LMFD_14", "1"); break; 
   case 'o': sendDcsBiosMessage("LMFD_15", "1"); break; 
   
   case 'p': sendDcsBiosMessage("LMFD_16", "1"); break; 
   case 'i': sendDcsBiosMessage("LMFD_17", "1"); break; 
   case 'j': sendDcsBiosMessage("LMFD_18", "1"); break; 
   case 'k': sendDcsBiosMessage("LMFD_19", "1"); break; 
   case 'l': sendDcsBiosMessage("LMFD_20", "1"); break; 

//Adjust
   case 'h': sendDcsBiosMessage("LMFD_ADJ", "0"); break; // R_ADJ_-dn
   case 'd': sendDcsBiosMessage("LMFD_ADJ", "2"); break; // R_ADJ_+up

//Contrast
   case 'e': sendDcsBiosMessage("LMFD_CON", "0"); break; // R_CON_-dn
   case 'a': sendDcsBiosMessage("LMFD_CON", "2"); break; // R_CON+up

//Display
   case 'c': sendDcsBiosMessage("LMFD_DSP", "2"); break; // R_DSP_+up
   case 'g': sendDcsBiosMessage("LMFD_DSP", "0"); break; // R_DSP_-dn
   
//Brightness
   case 'b': sendDcsBiosMessage("LMFD_BRT", "2"); break; // R_BRT_+up
   case 'f': sendDcsBiosMessage("LMFD_BRT", "0"); break; // R_BRT_-dn
   
 }}
   switch (keypad.getState()){  // gives PRESSED, HOLD or RELEASED
 case RELEASED: // LMFD 
   switch(KEY) { // Released OSBs or Neutral Rockers signal is sent
   case 'y': sendDcsBiosMessage("LMFD_01", "0"); break; 
   case 'z': sendDcsBiosMessage("LMFD_02", "0"); break; 
   case '$': sendDcsBiosMessage("LMFD_03", "0"); break; 
   case '&': sendDcsBiosMessage("LMFD_04", "0"); break; 
   case 'u': sendDcsBiosMessage("LMFD_05", "0"); break; 
   
   case 'v': sendDcsBiosMessage("LMFD_06", "0"); break; 
   case 'w': sendDcsBiosMessage("LMFD_07", "0"); break; 
   case 'x': sendDcsBiosMessage("LMFD_08", "0"); break; 
   case 'q': sendDcsBiosMessage("LMFD_09", "0"); break; 
   case 'r': sendDcsBiosMessage("LMFD_10", "0"); break; 
   
   case 's': sendDcsBiosMessage("LMFD_11", "0"); break; 
   case 't': sendDcsBiosMessage("LMFD_12", "0"); break; 
   case 'm': sendDcsBiosMessage("LMFD_13", "0"); break; 
   case 'n': sendDcsBiosMessage("LMFD_14", "0"); break; 
   case 'o': sendDcsBiosMessage("LMFD_15", "0"); break; 
   
   case 'p': sendDcsBiosMessage("LMFD_16", "0"); break; 
   case 'i': sendDcsBiosMessage("LMFD_17", "0"); break; 
   case 'j': sendDcsBiosMessage("LMFD_18", "0"); break; 
   case 'k': sendDcsBiosMessage("LMFD_19", "0"); break; 
   case 'l': sendDcsBiosMessage("LMFD_20", "0"); break; 

//Adjust
   case 'h': sendDcsBiosMessage("LMFD_ADJ", "1"); break; // R_ADJ_-dn
   case 'd': sendDcsBiosMessage("LMFD_ADJ", "1"); break; // R_ADJ_+up

//Contrast
   case 'e': sendDcsBiosMessage("LMFD_CON", "1"); break; // R_CON_-dn 
   case 'a': sendDcsBiosMessage("LMFD_CON", "1"); break; // R_CON+up 

//Display
   case 'c': sendDcsBiosMessage("LMFD_DSP", "1"); break; // R_DSP_+up
   case 'g': sendDcsBiosMessage("LMFD_DSP", "1"); break; // R_DSP_-dn

//Brightness
   case 'b': sendDcsBiosMessage("LMFD_BRT", "1"); break; // R_BRT_+up
   case 'f': sendDcsBiosMessage("LMFD_BRT", "1"); break; // R_BRT_-dn
 }}
}
   

of0ryMRl.jpg

 

C8S9bNml.jpg

 

A little clip for illustration;

 

 

Sorry the poor light conditions

 

Next task was to implement same for C-130 CDU. I quickly took the decision to leav two of the buttons out of the matrix since there were no more available pins on the Nano. Initially it didn’t work thus tried to get Master Caution light to run on pin13 LED. Didn’t work either and it turned out that the RS-487 chip was bad.

Then I noticed that the sketch stopped working when using pin13. After some Google’ing I removed the LED connected to pin13 and it worked nicely.

 

/*
 The following #define tells DCS-BIOS that this is a RS-485 slave device.
 It also sets the address of this slave device. The slave address should be
 between 1 and 126 and must be unique among all devices on the same bus.
*/
#define DCSBIOS_RS485_SLAVE 15

/*
 The Arduino pin that is connected to the
 /RE and DE pins on the RS-485 transceiver.
*/
#define TXENABLE_PIN 2
#include <Keypad.h>
#include "DcsBios.h"

/* paste code snippets from the reference documentation here */
const byte ROWS = 8; //four rows
const byte COLS = 9; //three columns
char keys[ROWS][COLS] = {
 {'!','"','#','c','%','F','L','R','X'},
 {'&','E','K','Q','W','Z'},
 {'|','D','J','P','V','Y','('},
 {')','C','I','O','U','=','@','£','$'},
 {'{','A','B','G','H','M','N','S','T'},
 {':','3','6','9','[','>','/',',','*'},
 {';','2','5','8','0','-','<','}','d'},
 {'+',']','_','a','b','1','4','7','.'},

};
byte rowPins[ROWS] = {13, A0, A1, 12, A2, A3, A4, A5}; //connect to the row pinouts of the keypad
byte colPins[COLS] = {11, 9, 7, 10, 8, 6, 5, 4, 3}; //connect to the column pinouts of the keypad

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



void setup() {
 DcsBios::setup();
 keypad.addEventListener(keypadEvent);  // Add an event listener.
 keypad.setHoldTime(100);               // Default is 1000mS
 keypad.setDebounceTime(50);           // Default is 50mS
}

void loop() {
 DcsBios::loop();
  char key = keypad.getKey();
}

void keypadEvent(KeypadEvent KEY){  
 switch (keypad.getState()) { // gives PRESSED, HOLD or RELEASED
 case PRESSED: // If someone finds a better solution as switch - case: Let me know, please :)
   switch(KEY) { // following commands are fired unique if PRESSED
   //CDU
   case 'A': sendDcsBiosMessage("CDU_A", "1"); break; 
   case 'B': sendDcsBiosMessage("CDU_B", "1"); break; 
   case 'C': sendDcsBiosMessage("CDU_C", "1"); break;     
   case 'D': sendDcsBiosMessage("CDU_D", "1"); break; 
   case 'E': sendDcsBiosMessage("CDU_E", "1"); break; 
   case 'F': sendDcsBiosMessage("CDU_F", "1"); break; 
   case 'G': sendDcsBiosMessage("CDU_G", "1"); break; 
   case 'H': sendDcsBiosMessage("CDU_H", "1"); break; 
   case 'I': sendDcsBiosMessage("CDU_I", "1"); break; 
   case 'J': sendDcsBiosMessage("CDU_J", "1"); break; 
   case 'K': sendDcsBiosMessage("CDU_K", "1"); break; 
   case 'L': sendDcsBiosMessage("CDU_L", "1"); break; 
   case 'M': sendDcsBiosMessage("CDU_M", "1"); break; 
   case 'N': sendDcsBiosMessage("CDU_N", "1"); break; 
   case 'O': sendDcsBiosMessage("CDU_O", "1"); break;
   case 'P': sendDcsBiosMessage("CDU_P", "1"); break;
   case 'Q': sendDcsBiosMessage("CDU_Q", "1"); break; 
   case 'R': sendDcsBiosMessage("CDU_R", "1"); break;   
   case 'S': sendDcsBiosMessage("CDU_S", "1"); break;     
   case 'T': sendDcsBiosMessage("CDU_T", "1"); break; 
   case 'U': sendDcsBiosMessage("CDU_U", "1"); break;        
   case 'V': sendDcsBiosMessage("CDU_V", "1"); break; 
   case 'W': sendDcsBiosMessage("CDU_W", "1"); break; 
   case 'X': sendDcsBiosMessage("CDU_X", "1"); break; 
   case 'Y': sendDcsBiosMessage("CDU_Y", "1"); break; 
   case 'Z': sendDcsBiosMessage("CDU_Z", "1"); break; 


   case '0': sendDcsBiosMessage("CDU_0", "1"); break; 
   case '1': sendDcsBiosMessage("CDU_1", "1"); break; 
   case '2': sendDcsBiosMessage("CDU_2", "1"); break; 
   case '3': sendDcsBiosMessage("CDU_3", "1"); break; 
   case '4': sendDcsBiosMessage("CDU_4", "1"); break; 
   case '5': sendDcsBiosMessage("CDU_5", "1"); break; 
   case '6': sendDcsBiosMessage("CDU_6", "1"); break; 
   case '7': sendDcsBiosMessage("CDU_7", "1"); break; 
   case '8': sendDcsBiosMessage("CDU_8", "1"); break; 
   case '9': sendDcsBiosMessage("CDU_9", "1"); break;  
   case '.': sendDcsBiosMessage("CDU_POINT", "1"); break; 
   case '/': sendDcsBiosMessage("CDU_SLASH", "1"); break; 
       
   case '!': sendDcsBiosMessage("CDU_LSK_3R", "1"); break; 
   case '"': sendDcsBiosMessage("CDU_LSK_5R", "1"); break;
   case '#': sendDcsBiosMessage("CDU_LSK_7R", "1"); break;
   case 'c': sendDcsBiosMessage("CDU_LSK_9R", "1"); break;

   case '+': sendDcsBiosMessage("CDU_LSK_3L", "1"); break; 
   case ']': sendDcsBiosMessage("CDU_LSK_5L", "1"); break;
   case '_': sendDcsBiosMessage("CDU_LSK_7L", "1"); break;
   case 'a': sendDcsBiosMessage("CDU_LSK_9L", "1"); break;
   
   case '[': sendDcsBiosMessage("CDU_PG", "2"); break; 
   case 'd': sendDcsBiosMessage("CDU_PG", "0"); break; 

   case '>': sendDcsBiosMessage("CDU_DATA", "2"); break; 
   case '<': sendDcsBiosMessage("CDU_DATA", "0"); break;
   
   case 'b': sendDcsBiosMessage("CDU_SYS", "1"); break; 
   case '{': sendDcsBiosMessage("CDU_NAV", "1"); break; 
   case ')': sendDcsBiosMessage("CDU_WP", "1"); break; 
   case '|': sendDcsBiosMessage("CDU_OSET", "1"); break; 
   case '&': sendDcsBiosMessage("CDU_FPM", "1"); break; 
   case '%': sendDcsBiosMessage("CDU_PREV", "1"); break;  

   case '(': sendDcsBiosMessage("CDU_MK", "1"); break; 
   case '}': sendDcsBiosMessage("CDU_CLR", "1"); break; 
   case '=': sendDcsBiosMessage("CDU_BCK", "1"); break; 
   case '@': sendDcsBiosMessage("CDU_SPC", "1"); break; 
   case '$': sendDcsBiosMessage("CDU_FA", "1"); break; 

   
 }}

 
   switch (keypad.getState()){  // gives PRESSED, HOLD or RELEASED
 case RELEASED: 
   switch(KEY) { // Released KEYs or Neutral Rockers signal is sent
   //CDU
   case 'A': sendDcsBiosMessage("CDU_A", "0"); break; 
   case 'B': sendDcsBiosMessage("CDU_B", "0"); break; 
   case 'C': sendDcsBiosMessage("CDU_C", "0"); break;     
   case 'D': sendDcsBiosMessage("CDU_D", "0"); break; 
   case 'E': sendDcsBiosMessage("CDU_E", "0"); break; 
   case 'F': sendDcsBiosMessage("CDU_F", "0"); break; 
   case 'G': sendDcsBiosMessage("CDU_G", "0"); break; 
   case 'H': sendDcsBiosMessage("CDU_H", "0"); break; 
   case 'I': sendDcsBiosMessage("CDU_I", "0"); break; 
   case 'J': sendDcsBiosMessage("CDU_J", "0"); break; 
   case 'K': sendDcsBiosMessage("CDU_K", "0"); break; 
   case 'L': sendDcsBiosMessage("CDU_L", "0"); break; 
   case 'M': sendDcsBiosMessage("CDU_M", "0"); break; 
   case 'N': sendDcsBiosMessage("CDU_N", "0"); break; 
   case 'O': sendDcsBiosMessage("CDU_O", "0"); break;
   case 'P': sendDcsBiosMessage("CDU_P", "0"); break;
   case 'Q': sendDcsBiosMessage("CDU_Q", "0"); break; 
   case 'R': sendDcsBiosMessage("CDU_R", "0"); break;   
   case 'S': sendDcsBiosMessage("CDU_S", "0"); break;     
   case 'T': sendDcsBiosMessage("CDU_T", "0"); break; 
   case 'U': sendDcsBiosMessage("CDU_U", "0"); break;        
   case 'V': sendDcsBiosMessage("CDU_V", "0"); break; 
   case 'W': sendDcsBiosMessage("CDU_W", "0"); break; 
   case 'X': sendDcsBiosMessage("CDU_X", "0"); break; 
   case 'Y': sendDcsBiosMessage("CDU_Y", "0"); break; 
   case 'Z': sendDcsBiosMessage("CDU_Z", "0"); break; 


   case '0': sendDcsBiosMessage("CDU_0", "0"); break; 
   case '1': sendDcsBiosMessage("CDU_1", "0"); break; 
   case '2': sendDcsBiosMessage("CDU_2", "0"); break; 
   case '3': sendDcsBiosMessage("CDU_3", "0"); break; 
   case '4': sendDcsBiosMessage("CDU_4", "0"); break; 
   case '5': sendDcsBiosMessage("CDU_5", "0"); break; 
   case '6': sendDcsBiosMessage("CDU_6", "0"); break; 
   case '7': sendDcsBiosMessage("CDU_7", "0"); break; 
   case '8': sendDcsBiosMessage("CDU_8", "0"); break; 
   case '9': sendDcsBiosMessage("CDU_9", "0"); break;  
   case '.': sendDcsBiosMessage("CDU_POINT", "0"); break; 
   case '/': sendDcsBiosMessage("CDU_SLASH", "0"); break; 
       
   case '!': sendDcsBiosMessage("CDU_LSK_3R", "0"); break; 
   case '"': sendDcsBiosMessage("CDU_LSK_5R", "0"); break;
   case '#': sendDcsBiosMessage("CDU_LSK_7R", "0"); break;
   case 'c': sendDcsBiosMessage("CDU_LSK_9R", "0"); break;

   case '+': sendDcsBiosMessage("CDU_LSK_3L", "0"); break; 
   case ']': sendDcsBiosMessage("CDU_LSK_5L", "0"); break;
   case '_': sendDcsBiosMessage("CDU_LSK_7L", "0"); break;
   case 'a': sendDcsBiosMessage("CDU_LSK_9L", "0"); break;
   
   case '[': sendDcsBiosMessage("CDU_PG", "1"); break; 
   case 'd': sendDcsBiosMessage("CDU_PG", "1"); break; 

   case '>': sendDcsBiosMessage("CDU_DATA", "1"); break; 
   case '<': sendDcsBiosMessage("CDU_DATA", "1"); break; 
   
   case 'b': sendDcsBiosMessage("CDU_SYS", "0"); break; 
   case '{': sendDcsBiosMessage("CDU_NAV", "0"); break; 
   case ')': sendDcsBiosMessage("CDU_WP", "0"); break; 
   case '|': sendDcsBiosMessage("CDU_OSET", "0"); break; 
   case '&': sendDcsBiosMessage("CDU_FPM", "0"); break; 
   case '%': sendDcsBiosMessage("CDU_PREV", "0"); break;  

   case '(': sendDcsBiosMessage("CDU_MK", "0"); break; 
   case '}': sendDcsBiosMessage("CDU_CLR", "0"); break; 
   case '=': sendDcsBiosMessage("CDU_BCK", "0"); break; 
   case '@': sendDcsBiosMessage("CDU_SPC", "0"); break; 
   case '$': sendDcsBiosMessage("CDU_FA", "0"); break; 

 }}
}
   

DoKRtVal.jpg

RfZZ9z3l.jpg

 

 

Pinout for C-130 CDU is here; https://forums.eagle.ru/showpost.php?p=2958104&postcount=109

 

Next task is to find a LCD that will work with the C-130 CDU before plugging it into the pit but I am quite please with this weekends work.

 

Thanks Tekkx for inspiration and sharing your code. Helped me a lot

 

Cheers

Hans


Edited by Hansolo
Adjusting layout, CDU sketch updated due to character error
Link to comment
Share on other sites

  • 2 weeks later...
Yes damn the cnc's..... they do not alway do what I had in mind :doh: The clearance between the top plate holes and buttons were too small. luckily it is possible to try again..

 

Will have to figure out if painint the backisde of the buttons white will work. Then it might be possible to have them backlit.

 

@Tom... the LCD is running on VGA so I expect it to be plug and play with viewport using a cheap video card just for the CDU

 

Hi! Tell me the process of making buttons. I don't

Intel Celeron - 333/2 планки DIMM по 128 мб/ATI 3D PCI 4 Mb/640х480/HDD 4ГБ/клавиатура+мышь/DSC World 2.5/ни чё не фризит/не тормозит/багов нет/картинки тоже нет :joystick:

Link to comment
Share on other sites

Hansangb and Mac you are both too kind. I am just utilizing DCS-BIOS and what Tekkx discovered.

 

Andreilo, this may be one of the best pictures I got https://forums.eagle.ru/album.php?albumid=705&pictureid=5556

 

The button was cut in in two steps. First the inner square was cut to 4mm in depth i.e. not all the way through. I then painted the top and after paint dried the text was engraved. Then finally the outer square was cut to full depth 6mm.

 

It may not be the most efficient way of making them. I suggest you check out Warhog’s thread. He has done some really beautiful buttons; https://forums.eagle.ru/showthread.php?t=138740

 

Mr. Burns, yes its for a F-16 and the click sound is awesome

Link to comment
Share on other sites

Hansangb and Mac you are both too kind. I am just utilizing DCS-BIOS and what Tekkx discovered.

 

Andreilo, this may be one of the best pictures I got https://forums.eagle.ru/album.php?albumid=705&pictureid=5556

 

The button was cut in in two steps. First the inner square was cut to 4mm in depth i.e. not all the way through. I then painted the top and after paint dried the text was engraved. Then finally the outer square was cut to full depth 6mm.

 

It may not be the most efficient way of making them. I suggest you check out Warhog’s thread. He has done some really beautiful buttons; https://forums.eagle.ru/showthread.php?t=138740

 

Mr. Burns, yes its for a F-16 and the click sound is awesome

 

Thank you very much! These links helped me a lot. Now I know how to make them yourself.

Intel Celeron - 333/2 планки DIMM по 128 мб/ATI 3D PCI 4 Mb/640х480/HDD 4ГБ/клавиатура+мышь/DSC World 2.5/ни чё не фризит/не тормозит/багов нет/картинки тоже нет :joystick:

Link to comment
Share on other sites

Deadman, Peter and Calum thanks a lot for the kind words. Means a lot comming from you fine gentlemen. Much appreciated.

 

A little more pit stuff got done today. Got the ILS panel up and running. Acquired the panel a while back by coinsident. As DCS-BIOS is already prepared for it the programming part was piece of cake but my soldering skills played tricks with me this time. Eventually I got it running

 

 

Quite satisfied with the result.

 

Code

/*
 The following #define tells DCS-BIOS that this is a RS-485 slave device.
 It also sets the address of this slave device. The slave address should be
 between 1 and 126 and must be unique among all devices on the same bus.
*/
#define DCSBIOS_RS485_SLAVE 17

/*
 The Arduino pin that is connected to the
 /RE and DE pins on the RS-485 transceiver.
*/
#define TXENABLE_PIN 2

#include "DcsBios.h"

/* paste code snippets from the reference documentation here */
//ILS Frequency KHz
const byte ilsKhzPins[10] = {3, 4, 5, 6, 7, 8, 9, 10, 11, 12};
DcsBios::SwitchMultiPos ilsKhz("ILS_KHZ", ilsKhzPins, 10);

//ILS Frequency MHz
const byte ilsMhzPins[4] = {A2, A3, A4, A5};
DcsBios::SwitchMultiPos ilsMhz("ILS_MHZ", ilsMhzPins, 4);

//ILS Power
const byte ilsPwrPins[2] = {A1, A0};
DcsBios::SwitchMultiPos ilsPwr("ILS_PWR", ilsPwrPins, 2);

//ILS Volume
DcsBios::Potentiometer ilsVol("ILS_VOL", A7);

//Master Caution light
DcsBios::LED masterCaution(0x1012, 0x0800, 13);

void setup() {
 DcsBios::setup();
}

void loop() {
 DcsBios::loop();
}

 

Panel and Arduino

XWMv8wyl.jpg

 

This is a photo of the backlighting

PCCRYlql.jpg

 

I haven't connected the backlighting yet. Tried to map out the backlighting and several of the panels have, in DCSW at least, two light sources. For the ILS the channel window is controlled by ENG INST potentiometer and panel backlighting by CONSOLE potentiometer. Thats for later :-)

 

Cheers

Hans


Edited by Hansolo
Added photo
Link to comment
Share on other sites

Excellent work Hans. :thumbup:

 

That ILS is just fantastic. I love the clicks it makes as you change channels and the backlighting is perfect. There is something to be said about using original equipment as opposed to scratch building everything.

 

You're going to have a really nice pit when all is said and done.

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

First of all many thanks for the kind words Warhog. Coming from you means a lot to me.

 

Secondly, my good friend Mac asked me a few questions and I though I might as well answer them here;

 

Q: Are you using the same RS485 expansion board on every panel now?

 

A: No I am not using the same board everytime. I kinda wing it everytime. The basic setup is the same. A MAX487 chip on a prototype board. 6 core cable comes in with communication, ground, 5VDC, 12VDC, and an unused wire.

 

12VDC is applied directly to the Arduino, The Arduino supplies regulated 5VDC to the MAX487 chip. But the rest of the setup depends on what I need the panel for.

 

Here is a closup of the standard starting point for the prototype board:

 

g9osyOWl.jpg

 

The prototype board hold the MAX487, Brown is GND, Pink is 12VDC, White is 5VDC, Grey is unused at this point, Yellow/Green is communication.

 

This is one of the simplest panels, the AAP which uses 12 inputs;

 

UHnGOUWl.jpg

 

The prototype board is also used for the common ground for all the switches. I have ordered some terminals to do this. It does make the setup a little more expensive but it’s just so much easier to get it to look nice when the wires ends in screw terminals.

 

Top view of same panel;

 

Mr2ymmsl.jpg

 

The ILS is done in a very similar way but since the panel is very narrow I had to split the setup

 

XWMv8wyl.jpg

 

Other panels are more demanding e.g. the SAS panel;

 

CwI21xAl.jpg

 

This is an older version and I think I changed this one into a two layer setup as the initial layout was too big. This board has the MOSFET’s to drive the mag switches and Trim LED.

 

Here is the Emergency flight plan which apart for MOSFET’s to drive the LED’s also have a NAND circuit to return the trim switch to neutral.

 

beAgIbsl.jpg

 

Q: Would you mind sharing your schematics and hook-up guide for the RS485 system you’re using with me

 

A: Here is the setup I am using;

 

cnJVSvK.jpg

 

DCS communicates with one Arduino Mega via USB. The Mega communicates with the remaining boards over RS485. The junction box holds DB9 female connectors and all the panels then have DB9 male connector.

 

 

Hope this is of a little assistance

 

Cheers

Hans


Edited by Hansolo
Updated schematic
Link to comment
Share on other sites

Hello, Han! I correctly understood from this picture that to connect three nano to mega you need 4 RS487. And zero RS487 is located close to the master mega?

RXc6KTT.thumb.png.91b43fe5b60b9bb0d4034fcf6379eeaf.png


Edited by Andreilo

Intel Celeron - 333/2 планки DIMM по 128 мб/ATI 3D PCI 4 Mb/640х480/HDD 4ГБ/клавиатура+мышь/DSC World 2.5/ни чё не фризит/не тормозит/багов нет/картинки тоже нет :joystick:

Link to comment
Share on other sites

Thank you! Now everything is clear.

Intel Celeron - 333/2 планки DIMM по 128 мб/ATI 3D PCI 4 Mb/640х480/HDD 4ГБ/клавиатура+мышь/DSC World 2.5/ни чё не фризит/не тормозит/багов нет/картинки тоже нет :joystick:

Link to comment
Share on other sites

  • 1 month later...

Hey Hans.

As I gazed at your work I became some kind of jealous of your Original Stuff. :)

 

Could you offer a peek under the CDU's panel? I am curious how "they" hid the Buttons, specifically those at the edge (where the CDU exceeds width of Dzus-Rails).

Even it's a CDU of a C130 the construction might be similar or equal :)

 

BTW: The Bus is named RS-485. There are Transceivers for this RS-485-Bus named MAX487. :)


Edited by Tekkx
added some smartass facts :)

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

  • Recently Browsing   0 members

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