<< return to Pixycam.com

Pixy SPI SS Troubleshooting

I am attempting to use the Pixy SPI with “SS” functionality.
I used the example sketch provided editing the “//” accordingly.
I changed the settings in pixymon from ISCP SPI to SPI SS
The settings is Color Connected Components
When I open arduino IDE Serial monitor i get error: no responsive however
through pixymon I can see the pixy is detecting the object I thought it.
When I revert back to the basic “hello world” settings I get all parameters: signature,age etc
in the serial monitor.
The intention is to connect Pixy2 and another SPI Device device but I need first the basics
to work which is Pixy and the arduino only.

Hello,
Getting SPI with SS can be challenging because you need to make your own connections/cabling. This is conceptually simple, but any small oversight will lead to non-working communication.

This page has some information on hooking up SPI with SS:

https://docs.pixycam.com/wiki/doku.php?id=wiki:v2:porting_guide

Do you have an oscilloscope? This can be helpful when trying to track down these issues.

Edward

Hello,
I’ve read this section
“Here’s how to hook up your controller’s SPI to Pixy2 (if you are not using an Arduino and the supplied cable):”
I am using arduino and I have the provided cable. Is it that this is incorrect and to use SPI SS you do in fact need to create a separate cable?

Hello,
The supplied cable uses the Arduino ICMP connector, which doesn’t include an SS signal. So you will need to make your own cable/connections if you wish to use SPI with SS.

Edward

I now understand what you mean. “SS” is Pin 7 via the Pixy2 connector but the cable only has pin options for 6 pin out. This is really unfortunate, i blindly assumed this would be apart of the 6.

Hello,
The Arduino cable has 6 conductors because the ICMP connector has 6 pins. :wink:

Not many people use SPI with SS mode. It’s supported though – you just need to make your own connections.

Edward

Do you know if a shift register is required to store the data from the Pixy2 after it is read in slave select.
My intention is to transfer this data read from the pixy to a transmitter module which also uses SS. I would have to enable it thereby disabling the pixy2. My concern is that the data will be lost in between disabling and enabling the 2 SS components

Hello,
I’m not sure what you mean by a shift register… there’s a shift register in the Arduino’s SPI controller.

I’d get the SPI with SS working with Pixy2 and Arduino first. It will probably help to familiarize yourself with the SPI with SS communications. Use the Pixy2SPI_SS class:

which is included in the Pixy2 Arduino distribution.

Edward