I am trying to read Maxim 13362 chip, using rabbit (RCM 5700) through SPI communication. On the datasheet for the chip it states, Configure SPI for CPOL = 0, CPHA = 1, SCLK = 4Mhz.
I am able to make SCLK 4 Mhz, but do not know how to declare CPOL = 0 and CPHA = 1. Here is the code till the declaration:
#class auto
#define SPI_SER_C
#define SPI_CLK_DIVISOR 12.5
#define SPI_RX_PORT SPI_RX_PC
#use "spi.lib"
unsigned char register00[4];
unsigned char register10[4];
unsigned char register01[4];
unsigned char readingreg[4];
Can anyone direct me on how you declare these things in rabbit?