µracoli Manual  Version foo
TSL2550 - Ambient Light Sensor

Detailed Description

Measuring ambient light intensity.

Functions

static uint8_t tsl2550_get ( uint8_t  adc)
static

return raw adc reading (valid flag, log compressed value)

Examples:
xmpl_tsl2550.c.

Definition at line 93 of file tsl2550.h.

static uint16_t tsl2550_scale ( uint8_t  adc0,
uint8_t  adc1 
)
static

derived from app note dn9b_tsl2550_lux_calculation.pdf

Examples:
xmpl_tsl2550.c.

Definition at line 105 of file tsl2550.h.

Defines

#define TSL2550_ADDR   (0x39)

the I2C address of the TSL2550

Examples:
xmpl_tsl2550.c.

Definition at line 48 of file tsl2550.h.

#define TSL2550_EXT_RANGE   (0x1D)

Write command to assert extended range mode

Examples:
xmpl_tsl2550.c.

Definition at line 54 of file tsl2550.h.

#define TSL2550_PWR_DOWN   (0x00)

Power-down state

Examples:
xmpl_tsl2550.c.

Definition at line 50 of file tsl2550.h.

#define TSL2550_RD_ADC0   (0x43)

Read ADC channel 0

Definition at line 58 of file tsl2550.h.

#define TSL2550_RD_ADC1   (0x83)

Read ADC channel 1

Definition at line 60 of file tsl2550.h.

#define TSL2550_RD_CMD   (0x03)

Power-up state/Read command register

Examples:
xmpl_tsl2550.c.

Definition at line 52 of file tsl2550.h.

#define TSL2550_STD_RANGE   (0x18)

Write command to reset or return to standard range mode

Examples:
xmpl_tsl2550.c.

Definition at line 56 of file tsl2550.h.