V1.9.0 Can't print floats from px4io mixer debug commands - only ints

#1

I’m attempting to print mixer debug statements using the debug command defined at the the top of mixer_multirotor.cpp and can’t get float values to print. For example

Adding the following to line 353 in mixer_multirotor.cpp -

debug("r: %f, p: %f, y: %f, t: %f", (double)roll, (double)pitch, (double)yaw, (double)thrust);

the output would be:

r: , p: , y: , t:

The only way I can get these to print is to static cast them to int after scaling them up:

debug("r: %d, p: %d, y: %d, t: %d", (int)(1000*roll), (int)(1000*pitch), (int)(1000*yaw), (int)(1000*thrust);

which would output:

r: 21, p: -2, y: 0 , t: 500