Need support with logging float

Hi,
I am currently working with the NRF7002DK and attempting to log float numbers.
However, I seem to be encountering some issues.

It's important to note that the sensors are not yet transmitting values, so the output displaying '0' is expected at this stage.

Here's the Kconfig relevant to the log:

CONFIG_LOG=y
CONFIG_IMU_LOG_LEVEL_DBG=y

Here's the code used for logging. Printf is working, but log_dbg is not.

    LOG_DBG("LSM6DSO: Accel (m.s-2): x: %.3f, y: %.3f, z: %.3f\n",
            sensor_value_to_double(&sensors_hub_accel[0]),
            sensor_value_to_double(&sensors_hub_accel[1]),
            sensor_value_to_double(&sensors_hub_accel[2]));

    printf("LSM6DSO: Accel (m.s-2): x: %.3f, y: %.3f, z: %.3f\n",
           sensor_value_to_double(&sensors_hub_accel[0]),
           sensor_value_to_double(&sensors_hub_accel[1]),
           sensor_value_to_double(&sensors_hub_accel[2]));

    LOG_DBG("LSM6DSO: Gyro (dps): x: %.3f, y: %.3f, z: %.3f\n",
            sensor_value_to_double(&sensors_hub_gyro[0]),
            sensor_value_to_double(&sensors_hub_gyro[1]),
            sensor_value_to_double(&sensors_hub_gyro[2]));

    printf("LSM6DSO: Gyro (dps): x: %.3f, y: %.3f, z: %.3f\n",
           sensor_value_to_double(&sensors_hub_gyro[0]),
           sensor_value_to_double(&sensors_hub_gyro[1]),
           sensor_value_to_double(&sensors_hub_gyro[2]));


Here's the console output:

[00:08:06.484,283] <dbg> imu: sensors_hub_get: LSM6DSO: Accel (m.s-2): x: %.3f, y: %.3f, z: %.3f

[00:08:06.489,135] <dbg> imu: sensors_hub_get: LSM6DSO: Gyro (dps): x: %.3f, y: %.3f, z: %.3f

LSM6DSO: Accel (m.s-2): x: 0.000, y: 0.000, z: 0.000
LSM6DSO: Gyro (dps): x: 0.000, y: 0.000, z: 0.000

Related