BME68x_SensorAPI icon indicating copy to clipboard operation
BME68x_SensorAPI copied to clipboard

Fixed comment of float humidity

Open NaCl5alt opened this issue 2 years ago • 3 comments

Overview

The comment for humidity of type float was written as x1000 even though the value was not multiplied by 1000, so the comment has been corrected to prevent confusion.

Basis

  • As shown in the example code below, the value of humidity is not divided by 1000 when FPU is not used. https://github.com/boschsensortec/BME68x-Sensor-API/blob/80ea120a8b8ac987d7d79eb68a9ed796736be845/examples/forced_mode/forced_mode.c#L82-L100
  • Because in the uint32_t calc_humidity method, calc_hum is capped at 100000, but in the float calc_humidity method, calc_hum is capped at 100.0f. https://github.com/boschsensortec/BME68x-Sensor-API/blob/80ea120a8b8ac987d7d79eb68a9ed796736be845/bme68x.c#L927-L938 https://github.com/boschsensortec/BME68x-Sensor-API/blob/80ea120a8b8ac987d7d79eb68a9ed796736be845/bme68x.c#L1093-L1103

NaCl5alt avatar Dec 22 '23 07:12 NaCl5alt

If you need to create an Issue, please reply to me. I'll create an Issue with the contents of this issue.

NaCl5alt avatar Dec 22 '23 07:12 NaCl5alt

Hi @BST-Github-Admin, @kegov. Could you please check the PR?

NaCl5alt avatar Jan 06 '24 09:01 NaCl5alt

@Deepak-Mvk , fyi.

kegov avatar Mar 18 '24 21:03 kegov