Open kamgolabek opened 6 years ago
Sounds like a bug indeed. Can you or someone get a stack trace on what happens?
I did more investigation:
And in logs there is nothing about it..
Ok I have found in code of ExtPlane plugin: (dataref.cpp) void DataDataRef::setValue(QByteArray &newValue) { Q_UNUSED(newValue); //TODO: @dankrusi: finish this implementation and test qFatal("Writing of Data DataRefs is not yet supported"); /* // Limit number of values to write to ref length or number of given values int numberOfValuesToWrite = qMin(_length, values.size());
// Convert values to float and copy to _valueArray
for(int i=0;i<numberOfValuesToWrite;i++) {
bool ok = true;
float value = values[i].toFloat(&ok);
if(!ok) {
qDebug() << Q_FUNC_INFO << "Invalid value " << values[i] << "in array";
return;
}
_valueArray[i]=value;
}
XPLMSetDatavf(_ref, _valueArray, 0, numberOfValuesToWrite);
*/
}
Setting value seems unimplemented feature, but should never cause a crash. There should be "Writing of Data DataRefs is not yet supported" in log or console output.
okay.. but you can simply reproduce it by using telnet commands I pasted above.. and it crash..
There probably won't be any logging, since stdout and stderr do not go anywhere on Windows within X-Plane. See issue #23
Is there any progress on this? I'm looking for a way to write data datarefs to X-Plane. Do you guys have any other idea how to modify data datarefs via the network?
you can encode characters and save as int array..
you can encode characters and save as int array..
Thanks, I'll give a try
you can encode characters and save as int array..
Have you been able to do this? I tried: set xxx [1,1] But this causes a crash as well
Pushed a potential implementation of setting byte array (data) datarefs to a feature branch. See README for instructions. This has not been tested properly (coding in train on laptop without X-Plane) but at least it compiles :) . Feel free to test. If it still crashes, a stack trace would be appreciated.
Like in title, while I am trying to set any data ref with byte[] type , XPlane is crashing. For example: set sim/aircraft/view/acf_tailnum sometexthere cause XPlane crash.