dcs-bios-arduino-library
dcs-bios-arduino-library copied to clipboard
[BUG] KA-50 Targeting Mode Control Panel - Head-on airborne target button issue
DCS Unified 2.9.3 (DCSBIOS Fork)
Ka-50 Black Shark 3 - Targeting Mode Control Panel
WEAPONS_FORWARD_HEMI_TARGET_BTN
Testing the Bort snippet in Socat (with no DCS running) pushing the button I expect to read the messages:
WEAPONS_FORWARD_HEMI_TARGET_BTN 1 WEAPONS_FORWARD_HEMI_TARGET_BTN 0
but I get instead only:
1 0
and, if I run DCS, I don't see the virtual button moving.
To Reproduce
Expected behavior
I expect tho read the messages sent WEAPONS_FORWARD_HEMI_TARGET_BTN 1 WEAPONS_FORWARD_HEMI_TARGET_BTN 0 but I get only 1 0
Screenshots
Additional context
With the support (and effort and time) of Vinc_Vega, I found that there's some internal DCSBIOS issue, as if I load a simple sketch like: ` #define DCSBIOS_IRQ_SERIAL #include "DcsBios.h"
/* paste code snippets from the reference documentation here */ DcsBios::Switch2Pos weaponsForwardHemiTargetBtn("WEAPONS_FORWARD_HEMI_TARGET_BTN", 3);
void setup() { DcsBios::setup(); }
void loop() { DcsBios::loop(); }
`
I get the correct behaviour (the full messages sent correctly).
But switching to RS_485 bus (as per my system):
`//#define DCSBIOS_IRQ_SERIAL
#define DCSBIOS_RS485_SLAVE 126 //Nr. massimo: 126
/* The Arduino pin that is connected to the /RE and DE pins on the RS-485 transceiver. */ #define TXENABLE_PIN 2 //PIN RISERVATO PER PROTOCOLLO 487
#include "DcsBios.h"
/* paste code snippets from the reference documentation here */ DcsBios::Switch2Pos weaponsForwardHemiTargetBtn("WEAPONS_FORWARD_HEMI_TARGET_BTN", 3);
void setup() { DcsBios::setup(); }
void loop() { DcsBios::loop(); }`
I get only 1 and 0
The issue seems be limited to RS_485 bus, as in IRQ_SERIAL mode it works correctly.