<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: S32K146 Rx data missing when Tx Send Data Function be called too frequently in S32K</title>
    <link>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868483#M3833</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #51626f; background-color: #ffffff;"&gt;LPUART_DRV_SetRxBuffer&amp;nbsp; &amp;nbsp;have&amp;nbsp; no&amp;nbsp; setting,&amp;nbsp; then the&amp;nbsp;&lt;SPAN&gt;UART_EVENT_END_TRANSFER&amp;nbsp;event&amp;nbsp; will&amp;nbsp; &lt;SPAN style="color: #000000; background-color: #ffffff; font-size: 16px;"&gt;happen&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 05 Jul 2020 19:06:52 GMT</pubDate>
    <dc:creator>wjandsq</dc:creator>
    <dc:date>2020-07-05T19:06:52Z</dc:date>
    <item>
      <title>S32K146 Rx data missing when Tx Send Data Function be called too frequently</title>
      <link>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868479#M3829</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi expert,&lt;/P&gt;&lt;P&gt;I'm using S32K146 EVB to implement uart Rx and Tx data transfer.&lt;/P&gt;&lt;P&gt;I use LPUART in DMA mode both on Rx and Tx. I set BaudRate to 115200.&lt;/P&gt;&lt;P&gt;When I called LPUART_DRV_SendData too frequently(10ms periodly),I found that my Rx&lt;/P&gt;&lt;P&gt;Data Missing.&lt;/P&gt;&lt;P&gt;My code listed below:&lt;BR /&gt;#define MD_REC_QUEUE_LEN (100)&lt;/P&gt;&lt;P&gt;/* The rx data if from a periphal modem device connected to S32K146 through uart*/&lt;BR /&gt;rx_callback(void *driverState, uart_event event, void* userData)&lt;BR /&gt;{&lt;BR /&gt; (void)driverState;&lt;BR /&gt; (void)userData;&lt;/P&gt;&lt;P&gt;if(UART_EVENT_RX_FULL == event)&lt;BR /&gt; {&lt;BR /&gt; MdRxHandler(rxBuffer);&lt;BR /&gt; LPUART_DRV_SetRxBuffer(INST_LPUART2, rxBuffer);&lt;/P&gt;&lt;P&gt;}else if(UART_EVENT_ERROR == event) //Error event handle: to reset rx receive data.&lt;BR /&gt; {&lt;BR /&gt; LPUART_DRV_AbortReceivingData((INST_LPUART2);&lt;BR /&gt; LPUART_DRV_ReceiveData(INST_LPUART2, rxBuffer, sizeof(rxBuffer));&lt;BR /&gt; } &lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;void ModemInit() //uart init and fisrt receive data&lt;BR /&gt;{&lt;BR /&gt; /* UART configured as follows:&lt;BR /&gt; - Word Length = 8 Bits&lt;BR /&gt; - Stop Bit = One Stop bit&lt;BR /&gt; - Parity = ODD parity&lt;BR /&gt; - BaudRate = 115200 baud&lt;BR /&gt; - Hardware flow control disabled (RTS and CTS signals) */&lt;BR /&gt; LPUART_DRV_Init(INST_LPUART2, &amp;amp;lpuart2_State, &amp;amp;lpuart2_InitConfig0);&lt;BR /&gt; EDMA_DRV_Init(&amp;amp;dmaController1_State, &amp;amp;dmaController1_InitConfig0,&lt;BR /&gt; edmaChnStateArray, edmaChnConfigArray, EDMA_CONFIGURED_CHANNELS_COUNT);&lt;BR /&gt; LPUART_DRV_InstallRxCallback(INST_LPUART2, rxCallback, NULL);&lt;BR /&gt; LPUART_DRV_ReceiveData(INST_LPUART2, rxBuffer, sizeof(rxBuffer));&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;void MdRxHandler(uint8_t* data)&lt;BR /&gt;{&lt;BR /&gt; ReqInfo reqMsg;&lt;BR /&gt; memset(&amp;amp;reqMsg,0x00,sizeof(ReqInfo));&lt;BR /&gt; reqMsg.msgId = MD_CMD_RX;&lt;BR /&gt; memcpy(reqMsg.rxdata, data, MAX_RX_MSG_SIZE );&lt;BR /&gt; xQueueSendFromISR(MdRecQueue, (void*)&amp;amp;reqMsg, NULL);&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;void MdTxHandler(uint8_t* data, uint16_t length)&lt;BR /&gt;{&lt;BR /&gt; ReqInfo reqMsg;&lt;BR /&gt; memset(&amp;amp;reqMsg,0x00,sizeof(ReqInfo));&lt;BR /&gt; reqMsg.msgId = MD_CMD_TX;&lt;BR /&gt; reqMsg.txLen = length;&lt;BR /&gt; memcpy(reqMsg.txdata, data, length);&lt;BR /&gt; xQueueSend(MdRecQueue, (void*)&amp;amp;reqMsg, (TickType_t)0); &lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;ModemTask()&lt;BR /&gt;{ &lt;BR /&gt; MdTimerCreate(); //create a 10ms Timer Loopback for Tx data.&lt;/P&gt;&lt;P&gt;ReqInfo reqMsg;&lt;BR /&gt; memset(&amp;amp;reqMsg,0x00,sizeof(ReqInfo));&lt;BR /&gt; while(1)&lt;BR /&gt; {&lt;BR /&gt; xQueueReceive(MdRecQueue, (void *)&amp;amp;reqMsg, 100);&lt;/P&gt;&lt;P&gt;switch(reqMsg.Id)&lt;BR /&gt; {&lt;BR /&gt; case MD_CMD_RX:&lt;BR /&gt; {&lt;BR /&gt; XXXXXXXXXXX //this branch can not be enter when TX Loopback too frequently.&lt;BR /&gt; }&lt;BR /&gt; case MD_CMD_TX:&lt;BR /&gt; {&lt;BR /&gt; LPUART_DRV_SendData((INST_LPUART2, data, length);&lt;BR /&gt; break;&lt;BR /&gt; }&lt;BR /&gt; defalut:&lt;BR /&gt; break;&lt;BR /&gt; &lt;BR /&gt; }&lt;BR /&gt; &lt;BR /&gt; }&lt;BR /&gt;}&lt;BR /&gt;void MdTimerLoopBack(xTimerHandle pTimer) //10ms peroidly Timer Trigger&lt;BR /&gt;{&lt;BR /&gt; uint8_t txData[100] = "xxxxxx";&lt;BR /&gt; while(1)&lt;BR /&gt; {&lt;BR /&gt; if( STATUS_SUCCESS== LPUART_DRV_GetTransmitStatus(INST_LPUART2, &amp;amp;byteRemaining))&lt;BR /&gt; {&lt;BR /&gt; MdTxHandler(txData, sizeof(txData));&lt;BR /&gt; break;&lt;/P&gt;&lt;P&gt;}&lt;BR /&gt; } &lt;BR /&gt;}&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Mar 2019 02:40:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868479#M3829</guid>
      <dc:creator>317336284</dc:creator>
      <dc:date>2019-03-19T02:40:09Z</dc:date>
    </item>
    <item>
      <title>Re: S32K146 Rx data missing when Tx Send Data Function be called too frequently</title>
      <link>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868480#M3830</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Do you see the RX data from the modem on the bus using a logic analyzer?&lt;/P&gt;&lt;P&gt;Is there any error reported?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_1.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/64306iF6D9E2E7CE73B8C1/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_1.png" alt="pastedImage_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Mar 2019 13:21:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868480#M3830</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2019-03-20T13:21:41Z</dc:date>
    </item>
    <item>
      <title>Re: S32K146 Rx data missing when Tx Send Data Function be called too frequently</title>
      <link>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868481#M3831</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;static void LPUART0_Rx_Callback_IRQHandler(void *driverState, uart_event_t event, void *userData) {&lt;/P&gt;&lt;P&gt;lpuart_state_t * s_lpuartStatePtr = (lpuart_state_t *)driverState;&lt;/P&gt;&lt;P&gt;....&lt;BR /&gt; if (event == UART_EVENT_ERROR) {&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; ...... must&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;LPUART_DRV_ReceiveData(INST_LPUART0, UART0_Rx_Buf, UART0_Rx_Buf_Size);&lt;BR /&gt; } else if (event == UART_EVENT_DMA_IDLE) {&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; ......&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; LPUART_DRV_ReceiveData(INST_LPUART0, UART0_Rx_Buf, UART0_Rx_Buf_Size);&lt;/P&gt;&lt;P&gt;} else if (event == UART_EVENT_RX_FULL) {&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; ......&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; LPUART_DRV_SetRxBuffer(INST_LPUART0, UART0_Rx_Buf, UART0_Rx_Buf_Size);&lt;/P&gt;&lt;P&gt;}&amp;nbsp;else if (event == UART_EVENT_END_TRANSFER) {&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; ......&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; LPUART_DRV_ReceiveData(INST_LPUART0, UART0_Rx_Buf, UART0_Rx_Buf_Size);&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 08 Dec 2019 12:42:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868481#M3831</guid>
      <dc:creator>wjandsq</dc:creator>
      <dc:date>2019-12-08T12:42:34Z</dc:date>
    </item>
    <item>
      <title>Re: S32K146 Rx data missing when Tx Send Data Function be called too frequently</title>
      <link>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868482#M3832</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;SPAN style="font: 14px/26px Arial, 'Microsoft YaHei', '微软雅黑', '宋体', 'Malgun Gothic', Meiryo, sans-serif; text-align: justify; color: #333333; text-transform: none; text-indent: 0px; letter-spacing: normal; word-spacing: 0px; float: none; display: inline !important; white-space: normal; font-size-adjust: none; font-stretch: normal; background-color: #f7f8fa; -webkit-text-stroke-width: 0px;"&gt;I look at the code and the manual and I don't know&amp;nbsp;how to&amp;nbsp;&lt;SPAN style="color: #333333; font-family: Arial; font-size: medium; background-color: #f7f8fa;"&gt;understand&lt;/SPAN&gt;&amp;nbsp;&lt;SPAN style="color: #333333; font-family: Arial; font-size: medium; background-color: #f7f8fa;"&gt;UART_EVENT_END_TRANSFER &lt;/SPAN&gt; event,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;SPAN style="font: 14px/26px Arial, 'Microsoft YaHei', '微软雅黑', '宋体', 'Malgun Gothic', Meiryo, sans-serif; text-align: justify; color: #333333; text-transform: none; text-indent: 0px; letter-spacing: normal; word-spacing: 0px; float: none; display: inline !important; white-space: normal; font-size-adjust: none; font-stretch: normal; background-color: #f7f8fa; -webkit-text-stroke-width: 0px;"&gt;May I ask how to correctly understand the meaning of UART_EVENT_END_TRANSFER ?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font: 14px/26px Arial, 'Microsoft YaHei', '微软雅黑', '宋体', 'Malgun Gothic', Meiryo, sans-serif; text-align: justify; color: #333333; text-transform: none; text-indent: 0px; letter-spacing: normal; word-spacing: 0px; float: none; display: inline !important; white-space: normal; font-size-adjust: none; font-stretch: normal; background-color: #f7f8fa; -webkit-text-stroke-width: 0px;"&gt;And , when does the UART_EVENT_END_TRANSFER event occur?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font: 14px/26px Arial, 'Microsoft YaHei', '微软雅黑', '宋体', 'Malgun Gothic', Meiryo, sans-serif; text-align: justify; color: #333333; text-transform: none; text-indent: 0px; letter-spacing: normal; word-spacing: 0px; float: none; display: inline !important; white-space: normal; font-size-adjust: none; font-stretch: normal; background-color: #f7f8fa; -webkit-text-stroke-width: 0px;"&gt;Thanks !&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Apr 2020 01:28:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868482#M3832</guid>
      <dc:creator>2571997326</dc:creator>
      <dc:date>2020-04-29T01:28:46Z</dc:date>
    </item>
    <item>
      <title>Re: S32K146 Rx data missing when Tx Send Data Function be called too frequently</title>
      <link>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868483#M3833</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #51626f; background-color: #ffffff;"&gt;LPUART_DRV_SetRxBuffer&amp;nbsp; &amp;nbsp;have&amp;nbsp; no&amp;nbsp; setting,&amp;nbsp; then the&amp;nbsp;&lt;SPAN&gt;UART_EVENT_END_TRANSFER&amp;nbsp;event&amp;nbsp; will&amp;nbsp; &lt;SPAN style="color: #000000; background-color: #ffffff; font-size: 16px;"&gt;happen&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 05 Jul 2020 19:06:52 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K146-Rx-data-missing-when-Tx-Send-Data-Function-be-called-too/m-p/868483#M3833</guid>
      <dc:creator>wjandsq</dc:creator>
      <dc:date>2020-07-05T19:06:52Z</dc:date>
    </item>
  </channel>
</rss>

