Jump to content

sendDcsBiosMessage in FlightPanels fork and Mosquito


Recommended Posts

Posted

Hey all.
Any ideas if sendDcsBiosMessage works with FP's DCS-BIOS and the Mosquito?
I've been trying to debug some code and am trying to these to indicate the state of a flag in my code:
sendDcsBiosMessage("PORT_RAD_FLAP","1");
sendDcsBiosMessage("PORT_RAD_FLAP","0");

 

I know there's a simple switch function for the port radiator flaps, and that works, but this function is not what I need.  I'm trying to use sendDcsBiosMessage for another function, and I wanted to use that switch as an in-game indication that my code is working.
The problem is that the switch in-game doesn't respond to either of those lines.


Am I using that function incorrectly?  It's not specifically documented anywhere, and What I've tried is gleaned from "passing comments" on this forum.

Posted

UPDATE:
It seems I am using it correctly.
I've tried sendDcsBiosMessage on a few other Mosquito functions as well and they don't work either.

These DO work on the P-51:
sendDcsBiosMessage("BAT","1");
sendDcsBiosMessage("BAT","0");

And this works on the Mosquito:
DcsBios::Switch2Pos portRadFlap("PORT_RAD_FLAP", PIN);

So it seems it is a bug with sendDcsBiosMessage on the Mosquito.
I've reported it on Discord (I'm not signed up to Github).

Posted (edited)

Mossie itself works with sendBIOS also i tested some switches they work too. 
like STBD_RAD_FLAP, FUEL_PUMP_SW and 2 others were i forgot the name

Mossie motors running on parkspot
nothing changed, latest release of FP fork
also tested P-51D-25 and F-14B

full sketch:

#define DCSBIOS_IRQ_SERIAL
#include <DcsBios.h>

void onAcftNameChange(char* newValue) {
  // Change of Aircraft
  DcsBios::resetAllStates();
}
DcsBios::StringBuffer<24> AcftNameBuffer(0x0000, onAcftNameChange);


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

void loop() {
sendDcsBiosMessage("PORT_RAD_FLAP","0");
delay(500);
sendDcsBiosMessage("PORT_RAD_FLAP","1");
delay(500);
}

 

Edited by BlackLibrary
  • Recently Browsing   0 members

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