Good morning, everyone.
I've been using the Condor Simulator version 1 for several years now and this year I've decided to take the whole thing to a new level for myself. So I bought an old glider body and built my own simulator. Basically I have a good technical understanding (computer, joystick, etc) but now I have a problem and need your help.
For the controls in the simulator I want to use my own joystick. For this I decided to use an Arduino Leonardo. There are several instructions and sample code on the internet, so I followed this trend! Currently I have created a prototype which shows the main functions (elevator, aileron, rudder and some buttons).
My problem:
The Arduino joystick is recognized by Windows 7 and Windows 10 as a game controller. I can also try it out and calibrate it properly. As soon as I open the Condor Simulator it is not recognized and I cannot use it!
My question:
What do I have to consider or change / perform so that the Arduino Joystick can be used by the Condor Simulator. Other simulators like Microsoft Flight Simulator or UbiSoft IL2 recognize it without problems.
Funfact:
The Condor Simulator version 1.0.5 recognizes the Arduino joystick, but does not allow configuration. With each following version the support is no longer given.
Condor 1.0.5 - works!
Condor 1.0.6 - does not work!
Condor 1.0.12 - does not work!
Condor 1.0.14 - does not work!
Condor 1.0.15 - does not work!
Condor 2.0.7 - does not work!
Condor 2.0.8 - does not work!
I'd be very happy if you could help me with my problem. There is surely someone here who has done a similar project or problem.
Thank you very much for your support.
391P
Instructions for the Arduino Joystick:
https://www.instructables.com/id/Arduin ... rJoystick/
Program code / library for the Arduino:
https://github.com/MHeironimus/ArduinoJ ... ersion-2.0
My customized Code:
Code: Select all
// Program JoyStick für Flugsimulator
//
//------------------------------------------------------------
#include "Joystick.h"
// Create Joystick
Joystick_ Joystick;
// Set to true to test "Auto Send" mode or false to test "Manual Send" mode.
const bool testAutoSendMode = true;
//const bool testAutoSendMode = false;
const unsigned long gcCycleDelta = 1000;
const unsigned long gcAnalogDelta = 25;
const unsigned long gcButtonDelta = 500;
unsigned long gNextTime = 0;
unsigned int gCurrentStep = 0;
int xAxis = 0;
int yAxis =0;
int rzAxis = 0;
int Throttle = 0;
int RudderRange = 0;
boolean taster1;
boolean taster2;
boolean taster3;
boolean taster4;
boolean taster5;
boolean taster6;
void setup() {
Serial.begin(9600);
// Set Range Values
Joystick.setXAxisRange(0, 1023);
Joystick.setYAxisRange(0, 1023);
Joystick.setRzAxisRange(0, 1023);
Joystick.setThrottleRange(0, 1023);
Joystick.setRudderRange(0, 1023);
if (testAutoSendMode)
{
Joystick.begin();
}
else
{
Joystick.begin(false);
}
//pinMode(A0, INPUT);
pinMode(13, OUTPUT);
pinMode(12, INPUT_PULLUP);
pinMode(11, INPUT_PULLUP);
pinMode(10, INPUT_PULLUP);
pinMode(9, INPUT_PULLUP);
pinMode(8, INPUT_PULLUP);
pinMode(7, INPUT_PULLUP);
}
void loop() {
xAxis = analogRead(A0);
yAxis = analogRead(A1);
rzAxis = analogRead(A2);
Throttle = analogRead(A3);
RudderRange = analogRead(A4);
taster1=digitalRead(12);
taster2=digitalRead(11);
taster3=digitalRead(10);
taster4=digitalRead(9);
taster5=digitalRead(8);
taster6=digitalRead(7);
// Turn indicator light on.
digitalWrite(13, 1);
//xAxis = int((bA0-512)/2);
Serial.print("xAchse=");
Serial.print(xAxis,DEC);
Serial.print(" yAchse=");
Serial.print(yAxis,DEC);
Serial.print(" rzAchse=");
Serial.println(rzAxis,DEC);
Serial.print("Throttle=");
Serial.print(Throttle,DEC);
Serial.print(" RudderRange=");
Serial.println(RudderRange,DEC);
Serial.print(" Taster1=");
Serial.print(taster1);
Serial.print(" Taster2=");
Serial.print(taster2);
Serial.print(" Taster3=");
Serial.println(taster3);
Serial.print(" Taster4=");
Serial.print(taster4);
Serial.print(" Taster5=");
Serial.print(taster5);
Serial.print(" Taster6=");
Serial.println(taster6);
Joystick.setXAxis(xAxis);
Joystick.setYAxis(yAxis);
Joystick.setRzAxis(rzAxis);
Joystick.setThrottle(Throttle);
Joystick.setRudder(RudderRange);
if (taster1) {
Joystick.releaseButton(0);
} else {
Joystick.pressButton(0);
}
if (taster2) {
Joystick.releaseButton(1);
} else {
Joystick.pressButton(1);
}
if (taster3) {
Joystick.releaseButton(2);
} else {
Joystick.pressButton(2);
}
if (taster4) {
Joystick.releaseButton(3);
} else {
Joystick.pressButton(3);
}
if (taster5) {
Joystick.releaseButton(4);
} else {
Joystick.pressButton(4);
}
if (taster6) {
Joystick.releaseButton(5);
} else {
Joystick.pressButton(5);
}
Joystick.sendState();
delay(0);
}
Guten morgen zusammen.
Ich nutze den Condor Simulator bereits seit einigen Jahren in der Version 1 und habe mich in diesem Jahr dazu entschlossen, das ganze Thema für mich auf ein neues Level zu heben. Entsprechend habe ich mir einen alten Segelflugzeug-Rumpf gekauft und baue mir meinen eigenen Simulator. Grundsätzlich habe ich ein gutes Technik-Verständnis (Computer, Joystick, etc) jedoch habe ich nun ein Problem und benötige Eure Hilfe.
Für die Steuerung im Simulator möchte ich einen eigenen Joystick benutzen. Hierzu habe ich mich für einen Arduino Leonardo entschieden. Es gibt im Internet hierzu diverse Anleitungen und Beispielcode, sodass ich diesem Trend gefolgt bin! Derzeit habe ich ein Prototyp erstellt, der die wesentlichen Funktionen (Höhenruder, Querruder, Seitenruder und ein paar Knöpfe) abbildet.
Mein Problem:
Der Arduino Joystick wird von Windows 7 und Windows 10 als Gamecontroller erkannt. Ich kann auch diesen ordnungsgemäß ausprobieren und kalibrieren. Sobald ich den Condor Simulator öffne wird er jedoch nicht erkannt und ich kann ihn nicht benutzen!
Meine Fragestellung:
Was muss ich beachten oder ändern / durchführen, damit der Arduino Joystick vom Condor Simulator verwendet werden kann. Andere Simulatoren wie z.B. Microsoft Flight Simulator oder UbiSoft IL2 erkennen ihn problemlos.
Funfact:
Der Condor Simulator in der Version 1.0.5 erkennt den Arduino Joystick, lässt jedoch die Konfiguration nicht zu. Mit jeder Folgeversion ist die Unterstützung nicht mehr gegeben.
Condor 1.0.5 - funktioniert!
Condor 1.0.6 – funktioniert nicht!
Condor 1.0.12 – funktioniert nicht!
Condor 1.0.14 – funktioniert nicht!
Condor 1.0.15 – funktioniert nicht!
Condor 2.0.7 – funktioniert nicht!
Condor 2.0.8 – funktioniert nicht!
Ich würde mich sehr freuen, wenn ihr mir bei meinem Problem helfen könntet. Es gibt sicherlich hier jemanden, der ein ähnliches Problem oder ein ähnliches Projekt durchgeführt hat.
Vielen Dank für Eure Unterstützung.
391P
Anleitung für den Arduino Joystick:
https://www.instructables.com/id/Arduin ... rJoystick/
Programm-Code / Library für den Arduino:
https://github.com/MHeironimus/ArduinoJ ... ersion-2.0
Code: Select all
// Program JoyStick für Flugsimulator
//
//------------------------------------------------------------
#include "Joystick.h"
// Create Joystick
Joystick_ Joystick;
// Set to true to test "Auto Send" mode or false to test "Manual Send" mode.
const bool testAutoSendMode = true;
//const bool testAutoSendMode = false;
const unsigned long gcCycleDelta = 1000;
const unsigned long gcAnalogDelta = 25;
const unsigned long gcButtonDelta = 500;
unsigned long gNextTime = 0;
unsigned int gCurrentStep = 0;
int xAxis = 0;
int yAxis =0;
int rzAxis = 0;
int Throttle = 0;
int RudderRange = 0;
boolean taster1;
boolean taster2;
boolean taster3;
boolean taster4;
boolean taster5;
boolean taster6;
void setup() {
Serial.begin(9600);
// Set Range Values
Joystick.setXAxisRange(0, 1023);
Joystick.setYAxisRange(0, 1023);
Joystick.setRzAxisRange(0, 1023);
Joystick.setThrottleRange(0, 1023);
Joystick.setRudderRange(0, 1023);
if (testAutoSendMode)
{
Joystick.begin();
}
else
{
Joystick.begin(false);
}
//pinMode(A0, INPUT);
pinMode(13, OUTPUT);
pinMode(12, INPUT_PULLUP);
pinMode(11, INPUT_PULLUP);
pinMode(10, INPUT_PULLUP);
pinMode(9, INPUT_PULLUP);
pinMode(8, INPUT_PULLUP);
pinMode(7, INPUT_PULLUP);
}
void loop() {
xAxis = analogRead(A0);
yAxis = analogRead(A1);
rzAxis = analogRead(A2);
Throttle = analogRead(A3);
RudderRange = analogRead(A4);
taster1=digitalRead(12);
taster2=digitalRead(11);
taster3=digitalRead(10);
taster4=digitalRead(9);
taster5=digitalRead(8);
taster6=digitalRead(7);
// Turn indicator light on.
digitalWrite(13, 1);
//xAxis = int((bA0-512)/2);
Serial.print("xAchse=");
Serial.print(xAxis,DEC);
Serial.print(" yAchse=");
Serial.print(yAxis,DEC);
Serial.print(" rzAchse=");
Serial.println(rzAxis,DEC);
Serial.print("Throttle=");
Serial.print(Throttle,DEC);
Serial.print(" RudderRange=");
Serial.println(RudderRange,DEC);
Serial.print(" Taster1=");
Serial.print(taster1);
Serial.print(" Taster2=");
Serial.print(taster2);
Serial.print(" Taster3=");
Serial.println(taster3);
Serial.print(" Taster4=");
Serial.print(taster4);
Serial.print(" Taster5=");
Serial.print(taster5);
Serial.print(" Taster6=");
Serial.println(taster6);
Joystick.setXAxis(xAxis);
Joystick.setYAxis(yAxis);
Joystick.setRzAxis(rzAxis);
Joystick.setThrottle(Throttle);
Joystick.setRudder(RudderRange);
if (taster1) {
Joystick.releaseButton(0);
} else {
Joystick.pressButton(0);
}
if (taster2) {
Joystick.releaseButton(1);
} else {
Joystick.pressButton(1);
}
if (taster3) {
Joystick.releaseButton(2);
} else {
Joystick.pressButton(2);
}
if (taster4) {
Joystick.releaseButton(3);
} else {
Joystick.pressButton(3);
}
if (taster5) {
Joystick.releaseButton(4);
} else {
Joystick.pressButton(4);
}
if (taster6) {
Joystick.releaseButton(5);
} else {
Joystick.pressButton(5);
}
Joystick.sendState();
delay(0);
}