Electronic – Is this the right convention for SPI modes

communicationspi

The table shown here, under "Clock Polarity and Clock Phase" doesn't agree with my conclusions from table for SPI modes on Wikipedia.

I'd like to distinguish between whether the one on the first like is another convention, or is it just just that 11 and 10 are mistankely swapped, I'm working on a school project and the document provided is from the first website.

Best Answer

There is no SPI standard, so the Clock Polarity (CPOL) and Clock Phase (CPHA) selection bits do not need to map to modes 0-3 in any standard way. Sometimes the mode selection bits have different names so what you read about modes for one device does not apply to another device.

The point is, when you want to communicate SPI between two chips, you need to look at the timing diagrams between the chips and select matching setting to know the correct mode, instead of just looking at mode numbers.