Remote debugfing with Qtcreator, displays double floats/doubles incorrectly
-
I successfully compiled qt and have a complete remote debugging with single steps working, with the exception of float/double.
I use QSettings to read a double value from a in file, and this is always wrong.. getting 1,50129.. e-45 for Floats and 4.9... e-313 tipically. Even the old 'C' atf () does not work, however , if I compile and run this on the arm itself, every thing works.I even tried to write a swap byte function (big-little endian) but this also does not work.
@
if (!config.contains(QString("calib/analog_output_a_m")))
config.setValue (QString("calib/analog_output_a_m"), QVariant(double(1.00)));
QString temp =config.value("calib/analog_output_a_m").toString();
// print the string out, for debugging only, this is fine "1.0022541213"
qDebug (">> Tmp = %s", temp.toLatin1().data());
float dum =config.value("calib/analog_output_a_m").toFloat(&ok);
// the above float displays bogus value .1,40129.. e-45 in debugger
master->scale.output_m_0 = swap_bytes(dum);
// the above answer is yet another bogus value
qDebug(">> Tmp = %s %7.5f", temp.toLatin1().data(), master->scale.output_m_0);
@
Note I use Derek Molloy RemoteQT way and for the beagleboneblack setup on a raspberryPi.Is the reals different for the two ARM devices, and if so, how can I fix that?
Thanks in advance
Gerrie