
Pixy2 can learn seven color signatures, numbered 1-7. It will then use this statistical model to find objects with similar color signatures in its frame from then on. Release the button and Pixy2 generates a statistical model of the colors contained in the object and stores them in flash. For example, the LED turns orange when an orange ball is placed directly in front of Pixy2. While doing this, the RGB LED under the lens provides feedback regarding which object it is looking at directly. More specifically, you teach Pixy2 by holding the object in front of its lens while holding down the button located on top. Orange ball? Place the ball in front of Pixy2 and press the button. Purple dinosaur? Place the dinosaur in front of Pixy2 and press the button. Pixy2 is unique because you can physically teach it what you are interested in sensing. Or use Pixy2 without a microcontroller and use the digital or analog outputs to trigger events, switches, servos, etc. It’s possible to hook up multiple Pixys to your microcontroller - for example, a robot with 4 Pixy2's and omnidirectional sensing. So your Arduino or other microcontroller can talk easily with Pixy2 and still have plenty of CPU available for other tasks.

The information is available through one of several interfaces: UART serial, SPI, I2C, USB, or digital/analog output. purple dinosaur detected at x=54, y=103) to your microcontroller. Pixy2 processes images from the image sensor and only sends the useful information (e.g. Pixy2 addresses these problems by pairing a powerful dedicated processor with the image sensor. And if the processor can keep up with the data, much of its processing power won’t be available for other tasks. But there are two drawbacks with image sensors: 1) they output lots of data, dozens of megabytes per second, and 2) processing this amount of data can overwhelm many processors. With the right algorithm, an image sensor can sense or detect practically anything. Vision (image) sensors are useful because they are so flexible.

If you want your robot to perform a task such as picking up an object, chasing a ball, locating a charging station, etc., and you want a single sensor to help accomplish all of these tasks, then vision is your sensor.
