MikroElektronika
Ambient 8 click
Ambient 8 click
SKU:MIKROE-3452
Out of stock
Couldn't load pickup availability
Share
The LTR-329ALS-01 offers six programmable gain settings, ranging from 1x up to 96x. This allows operating flexibility, as the sensor can be used in both very bright and very dim environments. Ambient 8 click can be used for a rapid development of various cost-effective applications that rely on light intensity sensing, including optical switches, backlight dimming applications for mobile and handheld devices, light metering applications (lux meters), and similar.
How does it work?
The main component of the Ambient 8 click is the LTR-329ALS-01, a high accuracy ambient light sensor (ALS) with I2C interface, from LiteOn. This sensor has an excellent IR filtering capability, offering a spectral response similar to a response of a human eye. By utilizing two sensitive photo-diodes (PDs), of which one is sensitive to IR light only, the ALS IC is able cancel out the effect of the IR light spectrum. The dynamic range for the ambient light sensor is very large, starting down from 0.01 lx up to about 64 klx. Besides two PDs, the IC incorporates a temperature compensation, and a logic section with the I2C interface. A high dynamic range along with a linear response over the entire range, allows this sensor to be placed behind a dark glass or panels made of other semi-transparent materials.
The LTR-329ALS-01 sensor uses a set of configuration registers, which allow very simple operation. By default, the ALS sensor is set to the standby mode. It does not perform any conversions until set up in the active mode. The Click board™ is supported by the mikroSDK compatible library, which simplifies the development by offering simple functions. However, more detailed explanation of each register and its function can be found in the datasheet of the LTR-329ALS-01.
There is also a set of four 8-bit output registers, which contain the conversion data from both PDs. Once the firmware starts reading their value, all four output registers will become locked, preventing any further changes. This allows for data consistency during the I2C reading sequence. There is also a status register, which indicates availability of new conversion data at the output registers. The output data is in LSB/MSB format, 16-bit value which is spread across two 8-bit registers.
There are two parameters that affect the overall sensing speed and the output rate: the LTR-329ALS-01 allows to set up both the integration time, and the measurement rate. The integration time improves the noise and the accuracy at the cost of reduced output data rate, while the measurement rate is the rate at which the measurements are made. The maximum value of the integration time is 350ms, while the slowest measurement rate is 2 seconds.
A selectable sensitivity allows a very wide dynamic range for the ALS measurement. There are three sensitivity bits, allowing the sensitivity to be set to six different values: 1x, 2x, 4x, 8x, 48x, and 96x. This offers six different luminosity ranges to be covered. When the gain is set to 1x, the ALS sensor can read the whole range from 1 lx up to 65535 lx (1 lx/LSB sensitivity). By increasing the gain setting, the resolution is increased, but the upper measurement limit is reduced. For example, gain 2x will reduce the maximum value to 32768 lx, resulting with 0.5 lx/LSB.
The Click board™ is supported by the mikroSDK library, which contains functions for simplified development. The mikroSDK functions are well-documented, but there is still a need, the datasheet of the LTR-329ALS-01 offers listing of all the registers and their specific functions.
The Click board™ is designed to work with 3.3V only. When using it with MCUs that use 5V levels for their communication, a proper level translation circuit should be used.
Specifications
Type | Optical |
Applications | It can be used for a rapid development of various cost-effective applications that rely on light intensity sensing, including optical switches, screen dimming applications for mobile and handheld devices, light metering applications (lux meters), and similar. |
On-board modules | LTR-329ALS-01, a high accuracy ambient light sensor (ALS) with I2C interface, from LiteOn. |
Key Features | High resolution and range of light intensity that can be measured, spectral response similar to human eye, low power consumption, compact design ideal for building of IoT applications, immune to flickering and fluorescent light sources, independent of the light source type, and more. |
Interface | I2C |
Input Voltage | 3.3V |
Click board size | M (42.9 x 25.4 mm) |
Pinout Diagram
This table shows how the pinout on Ambient 8 click corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Onboard Settings And Indicators
Label | Name | Default | Description |
---|---|---|---|
LD1 | PWR | - | Power LED indicator |
Software Support
We provide a library for the Ambient 8 click on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Library Description
Library contains function for reading data from device registers Library contains function for writing data to device registers Libraty contains function for setting constants ( gain and integration time ) for Lux calculations Library contains function for device initialization Library contains function for reading ALS data ( channel 0 and channel 1 ) Library contains function for calculating Lux level based on ALS data from channels 0 and 1, window factor and IR factor.
Key functions:
-
void ambient8_setConstants( void )
- sets constants (gain and integration time) for lux level calculation. -
void ambient8_init( void )
- initializes the device, sets gain to 8X, sets integration time to 400ms. -
uint8_t ambient8_getLuxLevel( float * luxLevel_, float windowFactor_, float IRfactor_ )
- reads and data and performs lux level calculation.
Examples description
The application is composed of the three sections :
- System Initialization - Initializes LOG and I2C.
- Application Initialization - Initializes device and I2C driver.
- Application Task - Performs Lux calculation based on window and IR factor and log results.
void applicationTask( ) { statusFlag = ambient8_getLuxLevel( &luxLevel, windowFactor, IRfactor ); if (statusFlag == 0) { mikrobus_logWrite( "lux Level : ", _LOG_TEXT ); FloatToStr( luxLevel, text ); mikrobus_logWrite( text, _LOG_TEXT ); mikrobus_logWrite( " lx", _LOG_LINE ); mikrobus_logWrite( " ", _LOG_LINE ); } }
The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
I2C
UART
Conversions
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
MIKROSDK
This click board is supported with mikroSDK - MikroElektronika Software Development Kit. To ensure proper operation of mikroSDK compliant click board demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.




New Products
-
Sold out
OAK 4 D Pro Wide
Vendor:LuxonisRegular price Rs. 117,969.00Regular priceUnit price / perSold out -
Sold out
OAK 4 D Pro Fixed Focus
Vendor:LuxonisRegular price Rs. 106,719.00Regular priceUnit price / perSold out -
Sold out
OAK 4 D Pro Auto Focus
Vendor:LuxonisRegular price Rs. 106,719.00Regular priceUnit price / perSold out -
Sold out
OAK 4 D Auto Focus
Vendor:LuxonisRegular price Rs. 95,479.00Regular priceUnit price / perSold out -
Sold out
OAK 4 D Fixed Focus
Vendor:LuxonisRegular price Rs. 95,479.00Regular priceUnit price / perSold out -
Sold out
OAK 4 D Wide
Vendor:LuxonisRegular price Rs. 106,719.00Regular priceUnit price / perSold out -
Sold out
OAK-FFC IMX577 M12
Vendor:POLOLURegular price Rs. 8,499.00Regular priceUnit price / perSold out -
Pololu Ideal Diode Reverse Voltage Protector, 4-60V, 20A
Vendor:POLOLURegular price Rs. 329.00Regular priceUnit price / perSold out -
Pololu Ideal Diode Reverse Voltage Protector, 4-60V, 25A
Vendor:POLOLURegular price Rs. 439.00Regular priceUnit price / perSold out -
Pololu I²C Isolator, ISO1640
Vendor:POLOLURegular price Rs. 449.00Regular priceUnit price / per -
3pi+ 32U4 OLED Robot Kit with 30:1 MP Motors (Standard Edition Kit)
Vendor:POLOLURegular price Rs. 15,549.00Regular priceUnit price / per -
Conductivity Calibration K 1.0 Set (4 pouches)
Vendor:Atlas ScientificRegular price Rs. 1,599.00Regular priceUnit price / perSold out -
Analog Discovery 3 Pro Bundle
Vendor:DigilentRegular price Rs. 42,569.00Regular priceUnit price / per -
Lighthouse swarm bundle - Crazyflie 2.1+ (250mAh batteries)
Vendor:BitcrazeRegular price Rs. 474,999.00Regular priceUnit price / perSold out -
Loco Swarm bundle - Crazyflie 2.1+ (250mAh batteries)
Vendor:BitcrazeRegular price Rs. 544,999.00Regular priceUnit price / per -
Kopis X8 Cinelifter 5" Kit - Caged (Frame Kit)
Vendor:HolybroRegular price Rs. 28,199.00Regular priceUnit price / per -
Atlas Scientific i3 InterLink
Vendor:Atlas ScientificRegular price Rs. 6,349.00Regular priceUnit price / per -
PoE Injector
Vendor:LuxonisRegular price Rs. 2,099.00Regular priceUnit price / per -
1-Port VINT Hub Phidget
Vendor:PhidgetsRegular price Rs. 2,699.00Regular priceUnit price / per -
Power Distribution Board (PDB) Board (With XT30 Pre-soldered)
Vendor:HolybroRegular price Rs. 1,099.00Regular priceUnit price / per -
Holybro 1045 Propeller 2 Pair CW+CCW-Black
Vendor:HolybroRegular price Rs. 1,549.00Regular priceUnit price / per -
ACS37220LEZATR-100B3 Current Sensor Large Carrier -100A to +100A, 3.3V
Vendor:POLOLURegular price Rs. 829.00Regular priceUnit price / per -
CT433-HSWF50MR TMR Current Sensor Compact Carrier -50A to +50A, 3.3V
Vendor:POLOLURegular price Rs. 1,039.00Regular priceUnit price / per -
A5984 Stepper Motor Driver Carrier, Adjustable Current, Blue Edition
Vendor:POLOLURegular price Rs. 409.00Regular priceUnit price / per -
A5984 Stepper Motor Driver Carrier, Fixed 1A@5V / 660mA@3.3V, Blue Edition (Soldered Header Pins)
Vendor:POLOLURegular price Rs. 489.00Regular priceUnit price / per