Other Parts Discussed in Thread: UCC5870-Q1, HALCOGEN
I am using UCC5870-Q1 with TMS570LS1224PGE device. I tried configuring the MibSPI through HalCogen and code composer studio for SPI daisy chained slave devices.
According to the datasheet, the SPI daisy chain needs to be as given in the below image. I am not able to produce the SDI line output according to the datasheet.
Please tell me how to use HalCoGen and CCS to configure for transmitting data for SPI daisy chain.
I am getting the following output instead of the one required for SPI daisy chain configuration.
HalCoGen Initialization
CCS CODE:
/* USER CODE BEGIN (0) */
/* USER CODE END */
/* Include Files */
#include "sys_common.h"
/* USER CODE BEGIN (1) */
#include "mibspi.h"
/* USER CODE END */
/** @fn void main(void)
* @brief Application main function
* @note This function is empty by default.
*
* This function is called after startup.
* The user can use this function to implement the application.
*/
/* USER CODE BEGIN (2) */
/* USER CODE END */
int main(void)
{
/* USER CODE BEGIN (3) */
uint16_t txBuffer[] = {0XB900, 0XB900, 0XB900, 0XB900, 0XB900, 0XB900, 0XB900, 0XB900, 0XB900, 0XB900}; //{0x0001, 0x0002, 0x0003, 0x0004, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001} ;
mibspiInit(); /*initialize the spi */
// mibspiEnableLoopback(mibspiREG1, Digital_Lbk);
mibspiSetData(mibspiREG1, 0, txBuffer);
mibspiTransfer(mibspiREG1, 0);
while(1);
/* USER CODE END */
}