TINKER PiEDESIGN IN INDIA

Proximity sensor APDS-9960 with TinkerPie

Notices a hand a few centimetres away: touch-free switches.

TypeSmart sensors (I2C)
Connect toSENSOR port · 0x39
Gives0-255 (closer = higher)
SimulatorYes: a control appears under the simulated board

How it works

The APDS-9960 shines invisible infrared light and measures how much bounces back from your hand. The closer the hand, the more light returns and the higher the number. The same chip can also sense colour, light level and simple swipe gestures.

How to wire it

Plug into any SENSOR 1-4 port (SDA, SCL, 3.3 V, GND). Each type has a fixed I2C address, so different types can share the bus.

Code

In blocks: Accessories category in TinkerPie Studio. As code:

// JavaScript
sensors.proximity()

// Arduino C++
sensors::proximity()

Good to know

Try it in TinkerPie Studio

Similar modules

More projects to try

Questions

Can I try the Proximity sensor APDS-9960 without buying one?

Yes. In TinkerPie Studio the simulator shows a control for it under the board, so you can test your program before you build it.

Can it work through glass or plastic?

Through thin, clear plastic it usually works, but reflections from the cover can confuse it. For touch-free switches, mount it behind a small window or leave it open.