You should now be able to see the eyes follow you.

Some tips for a good demo:

  • Hold the two boards fixed in relationship to one another. If you don't have a set of Helping Hands as I've pictured here, a quick prototype option could be to tape the two boards to a piece of cardboard temporarily.
  • If the eyes don't follow you when you move your head from side to side, try turning the boards instead. Something warm behind you might be distracting the sensor.

For some debugging information, view the output on a connected computer using a serial monitor (Tools > Serial Monitor in the Arduino IDE). If it's working, you'll see repeating output that looks like this:

-0.18 -0.29 3.75
-0.19 -0.27 4.25
-0.16 -0.24 4.00
-0.19 -0.27 4.25
-0.18 -0.30 4.00
-0.21 -0.30 3.75

The first line is the current refresh rate, in frames per second.

The following lines are the X and Y coordinates of the focus point found from the sensor data, followed by an estimate of the overall magnitude, which will increase as a face gets nearer to the sensor. The coordinates are scaled from -1.0 to +1.0, and the magnitude is scaled from 0 to 50.

This guide was first published on Oct 16, 2019. It was last updated on Mar 08, 2024.

This page (Watch the Watcher) was last updated on Mar 08, 2024.

Text editor powered by tinymce.