Searched refs:valp (Results 1 – 5 of 5) sorted by relevance
28 static int max17262_reg_read(const struct device *dev, uint8_t reg_addr, int16_t *valp) in max17262_reg_read() argument39 *valp = ((int16_t)i2c_data[1] << 8) | i2c_data[0]; in max17262_reg_read()84 struct sensor_value *valp) in max17262_channel_get() argument95 valp->val1 = tmp / 1000000; in max17262_channel_get()96 valp->val2 = tmp % 1000000; in max17262_channel_get()103 valp->val1 = current / 1000000; in max17262_channel_get()104 valp->val2 = current % 1000000; in max17262_channel_get()108 valp->val1 = data->state_of_charge / 256; in max17262_channel_get()109 valp->val2 = data->state_of_charge % 256 * 1000000 / 256; in max17262_channel_get()112 valp->val1 = data->internal_temp / 256; in max17262_channel_get()[all …]
31 int16_t *valp) in max17055_reg_read() argument42 *valp = sys_get_le16(i2c_data); in max17055_reg_read()151 struct sensor_value *valp) in max17055_channel_get() argument161 valp->val1 = tmp / 1000000; in max17055_channel_get()162 valp->val2 = tmp % 1000000; in max17055_channel_get()166 valp->val1 = tmp / 1000000; in max17055_channel_get()167 valp->val2 = tmp % 1000000; in max17055_channel_get()173 set_millis(valp, current_ma); in max17055_channel_get()177 valp->val1 = priv->state_of_charge / 256; in max17055_channel_get()178 valp->val2 = priv->state_of_charge % 256 * 1000000 / 256; in max17055_channel_get()[all …]
154 struct sensor_value *valp) in calc_temp() argument162 valp->val1 = (int32_t)temp; in calc_temp()163 valp->val2 = (int32_t)(fmodf(temp, 1.f) * 1000000.f); in calc_temp()167 struct sensor_value *valp) in calc_dietemp() argument173 valp->val1 = temp / 1000; in calc_dietemp()174 valp->val2 = (temp % 1000) * 1000; in calc_dietemp()194 struct npm1300_charger_data *const data, struct sensor_value *valp) in calc_current() argument217 valp->val1 = current / 1000; in calc_current()218 valp->val2 = (current % 1000) * 1000; in calc_current()222 struct sensor_value *valp) in npm1300_charger_channel_get() argument[all …]
869 int32_t *valp) in adc_raw_to_millivolts() argument871 int32_t adc_mv = *valp * ref_mv; in adc_raw_to_millivolts()875 *valp = (adc_mv >> resolution); in adc_raw_to_millivolts()895 int32_t *valp) in adc_raw_to_millivolts_dt() argument921 resolution, valp); in adc_raw_to_millivolts_dt()
133 struct sensor_value *valp) in npm2100_vbat_channel_get() argument188 valp->val1 = tmp / 1000000; in npm2100_vbat_channel_get()189 valp->val2 = tmp % 1000000; in npm2100_vbat_channel_get()