<< return to Pixycam.com

PixyCamera I2C with Arduino

Hi guys,
I’ve followed the tutorial to connect the Pixy Camera through the I2C interface to another I2C capable device (in my case an Arduino UNO because the ICSP is already used by the W5100 ethernet module) and it’s working fine.

Right now i’m powering the pixy camera through the arduino with the 3,3V pin and it’s ok, compiling the I2C sketch and working very nicely.

Can I continue using the 3,3V or i need the switch to the 5V pin from the arduino?

Thank you as always,
Marco

Hello Marco,
The Uno should have a 5V supply voltage, yes? Pixy needs a 5V supply. I wouldn’t power Pixy with a 3.3V supply.

Edward

Thank you Edward,

About the ground pins, only one in needed right? Are they all common in the module?

Cheers,
Marco

Hello Marco,
You are correct. All of the grounds are common. The ground on the Arduino needs to be connected connected to the ground on Pixy.

Edward

Hello Edward, i have another question:

I have connected the Pixy Camera through I2C (A4 and A5 on the arduino UNO)
At the same time i’m using an ethernet Shield which uses pin 10, 11, 12, 13 (and pin 4 for the Memory Card Chip Select)

The pin available for other devices are: A0, A1, A2, A3, 9, 8, 7, 6, 5, 3, 2.

Now I’m trying to connect an lcd module (16x2) in 4-bit mode but even using the pin available, when i’m initializing the lcd, PixyCamera continue to send me only “cs error” in the serial monitor.

I have already tried to change pin number, even using the analog but it is not working, what can I do?

P.s.: at the same time, using only the PixyCamera and the LCD module works fine

Hello Marco,
Have you been able to get I2C working with your Pixy-Arduino?

Once you get it working, I’d just proceed in a step-by-step fashion, so you can get a clear idea where there is a hardware conflict.

Edward

Hi Edward,

Yes, already try one module at a time.

I2C is working fine and outputting all the data correctly.

Also ICSP is working fine, I can output the data through internet with the Ethernet Shield.

Now i’m trying to use only the PixyCamera and the LCD module and as expected i’s working.

But if i take together all the three parts i have this “cs error” in the terminal emulator.

Not sure if i’m doing something wrong with the code in the arduino, but hardware speaking it’a all connected right and no one of the module are conflicting each other.

Hello Marco,
Something is interfering with the SPI communications. Try going through the initialization code and removing routines, step by step and see if you can find a routine that’s breaking the SPI communication. This is going to require some detective work.

Edward