TinyShield Ambient Light Sensor Tutorial

by TinyCircuits Staff February 15, 2016

TinyShield Ambient Light Sensor Tutorial


Overview

The TinyShield Ambient Light provides ambient light sensing (ALS) that approximates human eye response to light intensity under a variety of lighting conditions. this TinyShield is based around the AMS TAOS TSL2572 Ambient Light Sensor.


Powering the System

The AMS TAOS TSL2572 is a very low power ambient light sensor IC, drawing only 200 uA during full operation and supports several sleep modes. Due to the low power, a coin cell battery is sufficient to run this board. The Ambient Light TinyShield includes a local voltage regulator and level-shifters, so your TinyDuino system can operate from 3 to 5 Volts safely.


Using the Ambient Light TinyShield

The Ambient Light TinyShield uses the I2C bus to communicate between the TinyDuino Processor and the AMS TAOS TSL2572 ambient light sensor. Below is a sample sketch to get the data for the ambient light sensor and display it on the USB serial port.

Plug in your TinyDuino to your computer with the USB TinyShield and the Ambient Light TinyShield attached.

Upload the code using Codebender directly from this webpage. Alternatively, open the Arduino IDE and copy the source code above into it, and upload to the TinyDuino.

Open up the Serial Monitor, you should see the data being read from the ambient light sensor 10 times per second:



TinyCircuits Staff
TinyCircuits Staff

Author



Also in Learn

Tiny Arcade Assembly Instructions
Tiny Arcade Assembly Instructions

by TinyCircuits Staff September 18, 2016

Learn how to assemble your Tiny Arcade. You can read the step by step guide, or there's a video tutorial...

View full article →

Tiny Arcade Menu Update
Tiny Arcade Menu Update

by TinyCircuits Staff May 18, 2016

Update your Tiny Arcade software to the latest version from your computer.

View full article →

TinyScreen+ Windows 7/8 Driver Installation
TinyScreen+ Windows 7/8 Driver Installation

by TinyCircuits Staff May 18, 2016

Install the required drivers to use TinyScreen+ with Windows 7 and Windows 8.

View full article →