поискавой системы для электроныых деталей
  Russian  ▼
ALLDATASHEETRU.COM

X  

SFH7773 датащи(PDF) 21 Page - OSRAM GmbH

номер детали SFH7773
подробное описание детали  (IR-LED Proximity Sensor Ambient Light Sensor)
PDF  23 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
производитель  OSRAM [OSRAM GmbH]
домашняя страница  http://www.osram.com
Logo OSRAM - OSRAM GmbH

SFH7773 датащи(HTML) 21 Page - OSRAM GmbH

Back Button SFH7773 Datasheet HTML 15Page - OSRAM GmbH SFH7773 Datasheet HTML 16Page - OSRAM GmbH SFH7773 Datasheet HTML 17Page - OSRAM GmbH SFH7773 Datasheet HTML 18Page - OSRAM GmbH SFH7773 Datasheet HTML 19Page - OSRAM GmbH SFH7773 Datasheet HTML 20Page - OSRAM GmbH SFH7773 Datasheet HTML 21Page - OSRAM GmbH SFH7773 Datasheet HTML 22Page - OSRAM GmbH SFH7773 Datasheet HTML 23Page - OSRAM GmbH  
Zoom Inzoom in Zoom Outzoom out
 21 / 23 page
background image
December 12, 2011
page 21 of 23
C-code for main program:
// ALS:
I2C_w_3
(0x38*2, 0x80, 0x03);
// ALS free running mode
I2C_w_3
(0x38*2, 0x86, 0x00);
// new data every 100 ms
I2C_w_3
(0x38*2, 0x98, LB_LL);
// setting low byte of low ALS limit
I2C_w_3
(0x38*2, 0x99, HB_LL);
// setting high byte of low ALS limit
I2C_w_3
(0x38*2, 0x96, LB_HL);
// setting low byte of high ALS limit
I2C_w_3
(0x38*2, 0x97, HB_HL);
// setting high byte of high ALS limit
// Prox:
I2C_w_3
(0x38*2, 0x81, 0x03);
// Prox free running mode
I2C_w_3
(0x38*2, 0x82, 0x1E);
// IR LED with 200 mA
I2C_w_3
(0x38*2, 0x85, 0x00);
// new data every 10 ms
I2C_w_3
(0x38*2, 0x93, Prox_Limit);
// setting byte for high prox limit
I2C_w_3
(0x38*2, 0x92, 0x03);
// interrupt triggered by PS and ALS,
latched and ground when active
// Interrupt routine:
// called when interrupt happened
I2C_w_2_r_1 (0x38*2, 0x8E);
// reading Status Register, Function returns register value as variable Content
if ( (Content & 0x80) == 0x80)
// &=bitwise AND,check whether ALS triggered interrupt
{
I2C_w_2_r_1 (0x38*2, 0x8C);
// read low byte of ADC, register 0xC
Content1 = Content;
I2C_w_2_r_1 (0x38*2, 0x8D);
// read high byte of ADC, register 0xD
Lux = Content * 256 + Content1;
}
Else
// Interrupt must be caused by prox
sensor
{
I2C_w_2_r_1 (0x38*2, 0x8F);
// read Prox data register 0x8F
Prox = Content;
// Value in uW/cm^2 =10power(Content/51)
}
// end of interrupt routine
12.4 Implementation into a Mobile Phone
Environment
Below
are
two
example
flowcharts,
describing how the SFH 7773 can be
implemented into a microcontroller based
mobile phone environment. The interrupt
function allows for low-power stand-alone
operation of the device.
The first flowchart illustrates a possible
operation of the ambient light sensor, the
second flowchart relates to the operation of
the proximity sensor.
12.4.1 Operation of the ALS
Fig. 21 illustrates a flowchart for a
microcontroller based ambient light sensing
example. The interrupt (set to active low)
alerts the microcontroller only in case the
actual ambient light value is outside of the
defined ALS window. Using the interrupt
functionality and operating the SFH 7773 in
the free-running mode helps to minimize
traffic on the I2C-bus as well as to relieve the
microcontroller from unnecessary work load.
This arrangement helps to save valuable
battery power.
By adapting dynamically new thresholds
(with hysteresis) relative to the actual ALS
value (after an interrupt event took place) it
is possible to define very fine steps for
adapting the display brightness (quasi-
continuous).
By inverting the interrupt polarity (register
0x92) the interrupt alert function can be
inverted from outside the ALS window to



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23


датащи скачать

Go To PDF Page


ссылки URL



Вашему бизинису помогли Аллдатащит?  [ DONATE ] 

Что такое Аллдатащит   |   реклама   |   контакт   |   Конфиденциальность   |   Ссылка на техническое описание    |   обмен ссыками   |   поиск по производителю
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com