Lines Matching refs:lux
3 * Device driver for monitoring ambient light intensity (lux)
65 u16 lux;
145 /* Default lux table. */
151 * Reads and calculates current lux value.
161 * calculate the lux.
166 u32 lux; /* raw lux calculated from device data */
185 ret = chip->als_cur_info.lux; /* return LAST VALUE */
215 /* extract ALS/lux data */
228 * calculated lux to 0 and return early to avoid a division by
232 chip->als_cur_info.lux = 0;
239 /* convert to unscaled lux using the pointer to the table */
245 lux = 0;
256 /* note: lux is 31 bit max at this point */
261 chip->als_cur_info.lux = 0;
265 lux = ch0lux - ch1lux;
270 lux = 0;
272 lux = (lux + (chip->als_time_scale >> 1)) /
284 lux64 = lux;
287 lux = lux64;
288 lux = DIV_ROUND_CLOSEST(lux, 1000);
290 if (lux > TSL2583_LUX_CALC_OVER_FLOW) { /* check for overflow */
292 lux = TSL2583_LUX_CALC_OVER_FLOW;
295 /* Update the structure with the latest VALID lux. */
296 chip->als_cur_info.lux = lux;
297 ret = lux;
305 * to derive actual lux).
339 dev_err(&chip->client->dev, "%s: failed to get lux\n",
579 "%s: The number of entries in the lux table must be a multiple of 3 and within the range [6, %d]\n",
584 dev_err(dev, "%s: The last 3 entries in the lux table must be zeros.\n",