Dropped bytes with K8x LPUART2 when J-Link disconnected

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Dropped bytes with K8x LPUART2 when J-Link disconnected

ソリューションへジャンプ
778件の閲覧回数
deniscollis
Contributor V

I have a K8x processor with its LPUART2 connected to an app on a PC.  (fsl_uart driver / 115200-N-8-1)

With MCUXpresso running debug via J-Link, the communication channel is robust and reliable.  However, when the debug is terminated, then transmitted bytes (MCU-to-PC) are dropped.  If I remove the J-Link probe, then the same problem occurs.   Received bytes (PC-to-MCU) are good.

Serial data is sent using LPUART_WriteBlocking(), which I note has the following ominous warning:

 /* This API can only ensure that the data is written into the data buffer but can't
ensure all data in the data buffer are sent into the transmit shift buffer. */ 

ラベル(1)
0 件の賞賛
1 解決策
631件の閲覧回数
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi Denis,

I don't know how did you connect MCU and PC. Sounds like the GND is not well connected.
You can also observing the LPUART2_TX data using oscilloscope.

Best Regards,

Robin

 

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

元の投稿で解決策を見る

0 件の賞賛
2 返答(返信)
632件の閲覧回数
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi Denis,

I don't know how did you connect MCU and PC. Sounds like the GND is not well connected.
You can also observing the LPUART2_TX data using oscilloscope.

Best Regards,

Robin

 

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 件の賞賛
631件の閲覧回数
deniscollis
Contributor V

Hi robinshen‌,

The MCU is connected to PC via Serial/TTL-to-USB cable (FTDI).  I think that you may be right that the fault is GND (or power) related, and the JTAG connection has the effect of stabilizing it. 

In any case, I'm sure this has nothing to do with the fsl_uart driver.

0 件の賞賛