Lines Matching +full:time +full:- +full:out
3 * SPDX-License-Identifier: Apache-2.0
13 int32_t ret = -ENOTSUP; in bme280_decoder_get_frame_count()
19 /* This sensor lacks a FIFO; there will always only be one frame at a time. */ in bme280_decoder_get_frame_count()
22 *frame_count = edata->has_temp ? 1 : 0; in bme280_decoder_get_frame_count()
25 *frame_count = edata->has_press ? 1 : 0; in bme280_decoder_get_frame_count()
28 *frame_count = edata->has_humidity ? 1 : 0; in bme280_decoder_get_frame_count()
52 return -ENOTSUP; in bme280_decoder_get_size_info()
65 struct sensor_q31_data *out = data_out; in bme280_decoder_decode() local
67 out->header.base_timestamp_ns = edata->header.timestamp; in bme280_decoder_decode()
68 out->header.reading_count = 1; in bme280_decoder_decode()
72 if (edata->has_temp) { in bme280_decoder_decode()
73 int32_t readq = edata->reading.comp_temp * pow(2, 31 - BME280_TEMP_SHIFT); in bme280_decoder_decode()
74 int32_t convq = BME280_TEMP_CONV * pow(2, 31 - BME280_TEMP_SHIFT); in bme280_decoder_decode()
76 out->readings[0].temperature = in bme280_decoder_decode()
77 (int32_t)((((int64_t)readq) << (31 - BME280_TEMP_SHIFT)) / in bme280_decoder_decode()
79 out->shift = BME280_TEMP_SHIFT; in bme280_decoder_decode()
81 return -ENODATA; in bme280_decoder_decode()
85 if (edata->has_press) { in bme280_decoder_decode()
86 int32_t readq = edata->reading.comp_press; in bme280_decoder_decode()
87 int32_t convq = BME280_PRESS_CONV_KPA * pow(2, 31 - BME280_PRESS_SHIFT); in bme280_decoder_decode()
89 out->readings[0].pressure = in bme280_decoder_decode()
90 (int32_t)((((int64_t)readq) << (31 - BME280_PRESS_SHIFT)) / in bme280_decoder_decode()
92 out->shift = BME280_PRESS_SHIFT; in bme280_decoder_decode()
94 return -ENODATA; in bme280_decoder_decode()
98 if (edata->has_humidity) { in bme280_decoder_decode()
99 out->readings[0].humidity = edata->reading.comp_humidity; in bme280_decoder_decode()
100 out->shift = BME280_HUM_SHIFT; in bme280_decoder_decode()
102 return -ENODATA; in bme280_decoder_decode()
106 return -EINVAL; in bme280_decoder_decode()