<< return to Pixycam.com

2 ColorCode rotation/orientation angle extractions: arduino

Hello,

I am working on trying to extract the rotation/orientation angle when using two 2 cc while connected to an arduino mega. The problem I run into is when I use PixyMon to teach pixy the 2 cc’s and then run the pan tilt demo via arduino no data shows up in the serial. (as if there is no detection) However the led does glow when the 2cc object is in the FOV. Nothing happens in the serial monitor to indicate that it has detected an object. Alternatively when I use only one color signature and teach it pixy while running the arduino pan tilt demo everything works fine.

I noticed that even when I call the getBlock() and print the number of blocks, it returns 0.

The goal is to use 2cc so that I can add an extra axis of control to than tilt: Yaw Pitch and Roll…

Any advice would be great!!
Cheers!
James

Hi Jame
It sounds like you might be using an older Arduino library. Make sure you’re running the latest by deleting the current version first (delete the Pixy directory in the libraries directory), then reinstall the new Pixy Arduino library. You can find the latest version here:

http://cmucam.org/projects/cmucam5/wiki/Latest_release

Edward

Hey Edward,

You suggestion worked! Thank!