Other Parts Discussed in Thread: LP5569, MSP430WARE
Hello TI experts,
I have been working on getting multi-byte I2C communication between two TI parts, an LP-MSP430FR2476 and an LP-5569 EVM (LED driver). I have had some success with writing basic values to the board, but I've noticed some difficulty between debug sessions. Namely, when I open a debug session for the first time, I have no problems with operating I2C communication between the two parts. However, when I close a debug session and reopen a new one, I notice that the code gets blocked in the call to EUSCI_B_I2C_masterMultiByteSendStart in the line immediately following the start generation.
I am using the basic configuration for the I2C module from the example code provided in MSP430Ware. Here's a rough sketch of the function I am using to write to the control registers of the LP5569:
EUSCI_B_I2C_masterSendMultiByteStart(EUSCI_B0_BASE, control_reg); //Optimistically waits (if no NACK or ARBITRATION LOST, continue with writing the next value to the bus __delay_cycles(100); EUSCI_B_I2C_masterSendMultiByteFinish(EUSCI_B0_BASE, value);
I find that the code typically gets stuck on the following line of code in eusci_b_i2c.c from MSP430Ware's driverlib when I make the first call to the function described above: while (!(HWREG16(baseAddress + OFS_UCBxIFG) & UCTXIFG)) ;
Any assistance is greatly appreciated!