AnsweredAssumed Answered

SPI communication with TLE7242 chip

Question asked by Marceli Firlej on Aug 13, 2018
Latest reply on Nov 7, 2018 by Kerry Zhou

I can not get communication with TLE7242 (4 Channel Fixed Frequency Constant Current Control IC)
 using MKL25Z processor driver using Processor Expert.

I was trying using interrupt as well polling methods,

PWMSPIPtr = SM1_Init(NULL);

RESET_OUT_ClrVal();  // Toggle Reset TLE7242
 status.SM1_SendFlag = TRUE;
 RESET_OUT_SetVal();
 ENABLE_SetVal();

for(;;)

{

Error = SM1_ReceiveBlock(PWMSPIPtr, SPIData.InpBuffer, SPI_SIZE); /* Request data block reception */
Error = SM1_SendBlock(PWMSPIPtr, SPIData.OutBuffer, SPI_SIZE); /* Start transmission/reception */
 while (!SM1_GetBlockReceivedStatus(PWMSPIPtr))
 { /* Wait until data block is transmitted/received */
  SM1_Main(PWMSPIPtr);
  }

Outcomes