Part Number: MSP430FR5869
Dear Sir,
In my project, MSP430FR5869 is connecting to CPU through SPI interface. MSP430FR5869 is the slave, CPU is the master.
Below is setting for SPI on MSP430FR5869:
void config_spi(void)
{
//select spi gpio
P2SEL1 |= BIT4 | BIT5 | BIT6;
UCA1CTLW0 |= UCSWRST;
UCA1CTLW0 |= UCMSB + UCSYNC;
// UCA1BRW = 4; // prescale
UCA1CTLW0 &= ~UCSWRST;
UCA1IE |= UCRXIE;
UCA1IE |= UCTXIE;
}
Sometime, MSP430 is incorrect working. After investigate, I find that although CPU send 0x03 code but MSP430 only receive 0x01 code. Or CPU send 0x03 but MSP430 only receive 0x30.
Please help me fix it if possible.
