Datasheet

Ambient and Infrared Proximity Sensor
Interrupt Pin Voltage Compliance
The interrupt pin can withstand external voltages up
to 4V when in high-impedance mode per the absolute
maximum ratings of the IC. However, when the voltage
on the INT pin is higher than the V
DD
of the part (such as
when external pullup voltage is greater than V
DD
of part),
there is a small leakage current of 25µA sink into INT. This
additional current drawn through the INT pin should also
be accounted for in power-sensitive applications.
Typical Operating Sequence
The typical operating sequence for the master to com-
municate to the IC is shown below:
1) Read the Interrupt Status register (0x00) to confirm
only the PWRON bit is set. This also clears a hard-
ware interrupt. Note: For Rev-1 devices, a PWRON
interrupt does not trigger a hardware interrupt.
2) Set the Threshold and Threshold Persist Timer
registers for ambient and proximity sensor mea-
surements (Registers 0x06–0x0C). Note: For Rev-1
devices, leave the Threshold Persist Timer register
(Register 0x0A) set to 0.
3) Write F0 to the Receive Configuration register
(Register 0x02) to set the ALS sensor in the high-
est gain setting and ALS ADCs in 14-bit modes of
operation.
4) Set the IR LED current to a suitable level by writing
to the Transmit Configuration register (0x03).
5) Write 0x13 to Main Configuration register (register
0x01) to set the part in ALS + proximity mode, and
to enable ALS and proximity interrupts.
6) Set the new green channel gains and infrared
channel gains, if necessary, to customize ALS
operation for application conditions. Ensure the
TRIM bit is set to 0 when not using default factory-
trim settings.
7) Wait for interrupt.
8) Read the Interrupt Status register (0x00) to confirm
the IC to be the source of interrupt, and to check
for the type of interrupt. If set, this should clear the
hardware interrupt on the part.
9) If an ALS interrupt has occurred, read the ADC
High Byte (ALS) and ADC Low Byte (ALS) registers
(registers 0x04, 0x05) to confirm if data is valid (i.e.,
OFL = 0), and take appropriate action (e.g., sets
new backlight strength). Set new ALS thresholds, if
necessary.
10) If a PROX interrupt has occurred, read the PROX
ADC registers (register 0x15) and take appropriate
action (typically, turn off or turn on touch screen
and backlight). Set new proximity thresholds, if
necessary.
11) Return to step 7.
I
2
C Serial Interface
The IC features an I
2
C/SMBus-compatible, 2-wire serial
interface consisting of a serial-data line (SDA) and a
serial-clock line (SCL). SDA and SCL facilitate commu-
nication between the IC and the master at clock rates
up to 400kHz. Figure 4 shows the 2-wire interface tim-
ing diagram. The master generates SCL and initiates
data transfer on the bus. A master device writes data
to the IC by transmitting the proper slave address fol-
lowed by the register address and then the data word.
Each transmit sequence is framed by a START (S) or
Repeated START condition and a STOP condition. Each
word transmitted to the IC is 8 bits long and is followed
by an acknowledge clock pulse. A master reading data
from the IC transmits the proper slave address followed
by a series of nine SCL pulses. The IC transmits data
on SDA in sync with the master-generated SCL pulses.
The master acknowledges receipt of each byte of data.
Each read sequence is framed by a START or Repeated
START condition, a not acknowledge, and a STOP condi-
tion. SDA operates as both an input and an open-drain
output. A pullup resistor, typically greater than 500I, is
required on the SDA bus. SCL operates as only an input.
A pullup resistor, typically greater than 500I, is required
on SCL if there are multiple masters on the bus, or if the
master in a single-master system has an open-drain SCL
output. Series resistors in line with SDA and SCL are
optional. Series resistors protect the digital inputs of the
IC from high-voltage spikes on the bus lines, and mini-
mize crosstalk and undershoot of the bus signal.
Table 4. Slave Address
SLAVE ADDRESS FOR WRITING SLAVE ADDRESS FOR READING
1001 0100 1001 0101
MAX44000
18
Maxim Integrated