The Ambient Light Bricklet can be used to extend the features of Bricks with the capability to measure ambient light. The measured illuminance can be read out in lux. With configurable events it is possible to react on changing illuminance without polling.
Typical applications are illuminance dependent switching of backlights, motors etc.
| Property | Value |
|---|---|
| Sensor | TEMT6000 |
| Illumination | 0lux - 900lux in 0.1lux steps, 12bit resolution |
| Dimensions (W x D x H) | 25 x 15 x 5mm (0.98 x 0.59 x 0.19”) |
| Weight | 2g |
To test the Ambient Light Bricklet you need to have the Brick Daemon and the Brick Viewer installed (for installation guides click here and here) and the Brick Viewer has to be connected to the Brick Daemon.
Connect the Ambient Light Bricklet to a Brick with the supplied cable (see picture below).
If you connect the Brick to the PC over USB, you should see a new tab named “Ambient Light Bricklet” in the Brick Viewer after a moment. Select this tab. If everything went as expected you can now see the illuminance in lux, a graphical representation of the illuminance and a graph that shows the illuminance over time.
A good test for the sensor is to darken the room and slowly move a flashlight over the sensor, the graph should then look approximately as in the screenshot shown below.
After this test you can go on with writing your own application. See the Programming Interface section for the API of the Ambient Light Bricklet and examples in different programming languages.
See High Level Programming Interface for a detailed description.
| Language | API | Examples | Installation |
|---|---|---|---|
| Modbus | API | ||
| TCP/IP | API | ||
| C/C++ | API | Examples | Installation |
| C# | API | Examples | Installation |
| Delphi | API | Examples | Installation |
| Java | API | Examples | Installation |
| PHP | API | Examples | Installation |
| Python | API | Examples | Installation |
| Ruby | API | Examples | Installation |
| VB.NET | API | Examples | Installation |