SPI communication establish

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

SPI communication establish

586 Views
VamsiChava
Contributor I

Hi,

I am trying to establish SPI communication between SBC uja 1169a and MC9S12XSP100. I have done as below 

  /*Initialize SPI*/
    SPI1CR1 =  (vuint8)0x52;   /*SPIE SPE SPTIE MSTR CPOL CPHA SSOE LSBFE */
                               /* 0    1   0     1    0     0    1    0    */
   
    SPI1CR2 =  (vuint8)0x52;     /*  R   XFRW R MODFEN BIDIROE R SPISWAI SPC0 */
                                 /*  0   1    0     1      0     0    1    0 */

    SPI1BR =   (vuint8)0x11;     /*  R  SPPR2 SPPR1 SPPR0 R SPR2 SPR1 SPR0 */  //3.125Mh -8 division
                                 /*  0   0      0     1   0    0    0    1 */
 
But I am grtting 00 from SPIDR while reading from register. Please help me to resolve the issue
0 Kudos
0 Replies