« Previous - Version 4/16 (diff) - Next » - Current version
Rich LeGrand, 02/17/2014 10:35 pm


Teach Pixy an object

Teaching Pixy an object is super easy, but first let's talk about which objects will work well with Pixy. Pixy uses a hue-based color filtering
algorithm to detect objects. Since Pixy uses hue (color), the object needs to have a distinct hue. Here are some objects that are good because
they have good, distrinct hues.

** **

Here are some bad objects because either there is no hue (black, white or gray) or the hue is not distinct.

**

**

Keeping these guidelines in mind, choose an object to teach Pixy. (Apply power to Pixy via battery or USB cable if you haven't already. When you power up Pixy, it will go through a series of LED flashes. Wait for the led to turn off before teaching Pixy.) Hold down the
button on top of Pixy. After about 1.5 seconds, the LED will turn on, first white, then red,
(then other colors), but when it turns red, release the button.

When you release the button, Pixy will enter what's called
"light pipe" mode, where the LED color is the color of the center pixels of Pixy's image frame.

  • quick video

Use the LED color as feedback to determine if your object is in the center of Pixy's image frame. When you are satisfied that the LED color
matches your object color) release the button. If Pixy determines that the hue of
your object is "good enough" (has enough color saturation), the LED will flash several times and you're done. Pixy has "learned" your object
and will start tracking objects of the same color. If the hue is not good enough, the LED will simply turn off and Pixy will not have learned your object. You should possibly choose another object that has a better color saturation, or consult the Pixy troubleshooting section**.