lpuart issue

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 
1,096件の閲覧回数
gnichimohamed
Contributor III

Hello

I am starting to use lpuart on freedom KL03Z board. I started with lpuart_non_blocking_example which works fine. However as soon as i start a new project with processor expert the lpuart doesn't work. I am suspecting that the issue lies within the initialisation code of PeX. I attached the project here.

Second question, I want to read incoming chars, one by one so i want to make something like this

While(rxbuffer is not empty)         LPUART_DRV_ReceiveData(BOARD_DEBUG_UART_INSTANCE, &rxChar, 1);

 

I can't find a way to test if the rxbuffer is empty or it has something in it. I have to test that because in my application i don't know how much bytes am going to receive either 2 or 3. I am looking for a similar function like the arduino Serial.available().

 

Thank you for helping

Original Attachment has been moved to: uart.rar

ラベル(1)
0 件の賞賛
返信
1 解決策
756件の閲覧回数
Carlos_Mendoza
NXP Employee
NXP Employee

Hi Gnichi,

I had some problems opening your project, bu please find attached a non blocking lpuart example using Processor Expert for the KL03Z.

Hope it helps!

Best Regards,

Carlos Mendoza

Technical Support Engineer

-----------------------------------------------------------------------------------------------------------------------

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

-----------------------------------------------------------------------------------------------------------------------

元の投稿で解決策を見る

0 件の賞賛
返信
3 返答(返信)
756件の閲覧回数
gnichimohamed
Contributor III

Is there at least a processor expert example using lpuart like the non blocking example?

0 件の賞賛
返信
757件の閲覧回数
Carlos_Mendoza
NXP Employee
NXP Employee

Hi Gnichi,

I had some problems opening your project, bu please find attached a non blocking lpuart example using Processor Expert for the KL03Z.

Hope it helps!

Best Regards,

Carlos Mendoza

Technical Support Engineer

-----------------------------------------------------------------------------------------------------------------------

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

-----------------------------------------------------------------------------------------------------------------------

0 件の賞賛
返信
756件の閲覧回数
jacobjennings
Contributor III

The receiving case of this example is blocking.

0 件の賞賛
返信