Jump to content

Recommended Posts

Posted

Hi, I'm very new to this whole situation and I am struggling to make my new 8 way rotary switch (SP8T) have any function. I am attempting to use this switch for the INS knob on the F-16 Avionics Panel. I have the center pin wired to ground on an Arduino mega and pins 1-7 wired to digital pins 22, 24, 26, 28, 30, 32 and 34. This is the code I am currently using, I have had to add a ";" following "const byte insKnbPins[13] = {22, 24, 26, 28, 30, 32, 34}" as the code failed to compile without it. When I turn the switch nothing happens, the tx light doesn't blink like it does for the other switches. I am sure I have made some idiotic beginners mistake and am looking for some guidance, thank you for any help.

 

/*
  Tell DCS-BIOS to use a serial connection and use interrupt-driven
  communication. The main program will be interrupted to prioritize
  processing incoming data.
 
  This should work on any Arduino that has an ATMega328 controller
  (Uno, Pro Mini, many others).
 */
#define DCSBIOS_IRQ_SERIAL
 
#include "DcsBios.h"
 
/* paste code snippets from the reference documentation here */
const byte insKnbPins[13] = {22, 24, 26, 28, 30, 32, 34};
DcsBios::SwitchMultiPos insKnb("INS_KNB", insKnbPins, 13);
 
void setup() {
  DcsBios::setup();
}
 
void loop() {
  DcsBios::loop();
}
Posted

ins knob.JPG

2 minutes ago, crash test pilot said:

ins knob.JPG

Stupid Pic ate my text. So here we go again:

 

Are you using the (no longer maintained) hub version? The flightpanel fork gets constant updates. Hub contained several mistakes and errors like missing semikolons and wrong numbers. Correct syntax for ins knob is like the pic above.

Posted
7 hours ago, crash test pilot said:

Are you using the (no longer maintained) hub version? The flightpanel fork gets constant updates. Hub contained several mistakes and errors like missing semikolons and wrong numbers. Correct syntax for ins knob is like the pic above.

I just looked at the Hub control ref - it has the [13] in it.

Posted

Thank you, that solved my issue, one more question though. When I go to launch the flight panels app for DCS bios from chrome, it warns me that I will no longer be able to open apps from chrome after December 2022. So far nothing has changed even though it is January 2023 I just hope my controls wont studently become useless due to an update.

Posted (edited)

It's not the controls that will stop working, it's that app which shows the data that is going to be unavailable.

 

IIRC, someone has crated an alternative for that.

 

 

Edited by No1sonuk
  • 3 weeks later...
Posted (edited)

Just for anyone wondering, here is the DCS BIOS Interface alternative now that chrome apps are not supported.

Edited by Slammansam
Clarification
  • Thanks 1
  • Recently Browsing   0 members

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