In this lesson, we will show what is the APDS-9960 RGB and Gesture Sensor and how to hook up it to the Arduino board.
This is the RGB and Gesture Sensor, a small breakout board with a built in APDS-9960 sensor that offers ambient light and color measuring, proximity detection, and touchless gesture sensing. With this RGB and Gesture Sensor you will be able to control a computer, microcontroller, robot, and more with a simple swipe of your hand! This is, in fact, the same sensor that the Samsung Galaxy S5 uses and is probably one of the best gesture sensors on the market for the price.
|VL||Optional power to the IR LED if PS jumper is disconnected. Must be 3.0 – 4.5V|
|GND||Connect to ground.|
|VCC||Used to power the APDS-9960 sensor. Must be 2.4 – 3.6V|
|INT||External interrupt pin. Active LOW on interrupt event|
Before getting started with the APDS-9960, there are a few concepts that you should be familiar with. Consider reading some of these tutorials before continuing.
On the front of the breakout board are 2 solder jumpers:
Solder a row of break away male headers to the 6 headers holes on the board.
We will be using the Arduino Pro’s regulated 3.3V power and I2C bus with the APDS-9960. Note that we are leaving VL on the breakout board unconnected.
IMPORTANT: You must use 3.3V! If you try to use a 5V power supply you risk damaging the APDS-9960.
Connect the breakout board to the following pins on the Arduino:
|APDS-9960 Breakout Board||OSOYOO UNO|
To use the APDS-9960, you will need some supporting software. If you are using an Arduino, then you are in luck! We created an Arduino library that makes the APDS-9960 easy to use. Click the button below to download the latest version of the APDS-9960 breakout board project, which includes the Arduino library.
Follow this guide on installing Arduino libraries to install the files within the APDS9960 directory as an Arduino library.
After above operations are completed, connect the Arduino board to your computer using the USB cable. The green power LED (labelled PWR) should go on.
You can copy below code to your Arduino IDE window, then select corresponding board type and port type for your Arduino board.
Click the Upload button and wait for the program to finish uploading to the Arduino. Once uploaded to your Adruino, open up the serial monitor at 115200 baud speed.More info on the Serial Terminal can be found here. You should see a messages noting that “Device initialized! ”
Hover your hand 4 to 8 inches (10 to 20 cm) above the sensor but off to one side (i.e. not directly above the sensor). While maintaining the same height, swipe your hand over the sensor (into and then immediately out of range of the sensor). If you move too fast, the sensor will not recognize the gesture.
DownLoad Url osoyoo.com