Hello,
I have a question, which may also be a problem.
I am using EUSCI_B2 SPI, where the code I have write it's the same used to perform the interface of a SDcard in the EUSCI_B0 SPI, but in this last one te code is working the only thing I have made is change the register from EUSCI_B0 to EUSCI_B2. What could I be doing wrong, shouldn't I be working the same way?
/* Select the MSP432 SPI lines: MOSI/MISO on P3.6,7 CLK on P3.5 */
P3->SEL0 |= BIT6 | BIT7;
P3->SEL1 &= ~(BIT6 | BIT7);
P3->REN &= ~(BIT7);
P3->OUT |= BIT7;
P3->SEL0 |= BIT5;
P3->SEL1 &= ~BIT5;
// MSP432 code
EUSCI_B2->CTLW0 |= EUSCI_B_CTLW0_SWRST; // Put state machine in reset
EUSCI_B2->CTLW0 = EUSCI_B_CTLW0_SWRST |
EUSCI_B_CTLW0_MODE_0 |
EUSCI_B_CTLW0_MST |
EUSCI_B_CTLW0_SYNC |
EUSCI_B_CTLW0_CKPH |
EUSCI_B_CTLW0_MSB ;
EUSCI_B2->CTLW0 |= EUSCI_B_CTLW0_SSEL__SMCLK;
EUSCI_B2->BRW = 0x08; /*INITIAL SPI CLOCK MUST BE <400 kHz*/
EUSCI_B2->CTLW0 &= ~EUSCI_B_CTLW0_SWRST;
/* Configure the SPI CS to be on P5.1 on MSP432*/
P5->OUT |= BIT1;
P5->SEL0 &= ~BIT1;
P5->SEL1 &= ~BIT1;
P5->DIR |= BIT1;
/* 50 ms delay */
//Delay(500);
return 0;
thanks in advanced