This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

C5505 SPI falling edge

I'm trying to send out spi data on the falling clock edge of my C5505 EZdsp chip. 

I looked at the output of my signal, and it seemed that the data was transitioning on the falling edge and not holding its point.

I have captured an image of sending spi data 0x5 where the blue signal is the spi clock, the magenta signal is the data, and the yellow signal is my chip select.

Furthermore, by looking at the falling edge it seems that the spi is sending out 0b1011 instead of 0b0101. 

 

Following the SPI datasheet, I have the following values to my registers.

 

    SPICDR = 0x3; // Seting clock to 25 MHz

    SPICCR = 0x8000; // enable clock

    SPIDCR1 = 0x10;  // delay SPI_0 by 2.5 clock cycles and transmit on falling clock edge

    SPIDCR2 = 0;  

    SPICMD1 = 0;  // transmit 1 character per frame

    SPICMD2 = 0x007A; // transmit on CS0, 16 bit characters, with a write

 

Please let me know if you have any comments, correction or any other help that could be applicable.

 

Thanks,

 

Tommy