IMXRT1024 Suitable UART Method

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

IMXRT1024 Suitable UART Method

Jump to solution
2,131 Views
Lukas_Frank
Senior Contributor I

Hi all,

 

I am between usage UART_WriteByte and UART_TransferSendNonBlocking. Which one is correct? I want just minimum delay. I know that UART_TransferSendNonBlocking is non-polling method and I will use it with interrupts.

But I see that there is a normal interrupt example in SDK with UART_WriteByte. Can I ensure same performance when I use UART_WriteByte with interrupt method ? Will they be same if I do like that ?

Will it be a polling approach, When I use only UART_WriteByte ?

Will it be a non-polling approach, When I use UART_WriteByte with interrupts?

 

Thanks and Regards.

 

0 Kudos
Reply
1 Solution
2,043 Views
jeremyzhou
NXP Employee
NXP Employee

Hi,
Thanks for your reply.
The depth of Transmit and Receive buffers are 4-datawords, just like the below figure shows.

jeremyzhou_0-1630896679857.png

 


Hope this is clear.
Have a great day,
TIC

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

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

View solution in original post

10 Replies
2,100 Views
jeremyzhou
NXP Employee
NXP Employee

Hi,
Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
1-) How can I get the received byte count that comes to my FIFO.
-- Please check the RXCOUNT bits.

jeremyzhou_0-1630293250115.png


2-) What is the best way to use polling, interrupt or eDMA?
-- In my opinion, you can choose the interrupt or eDMA way.
Have a great day,
TIC

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

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

2,087 Views
Lukas_Frank
Senior Contributor I

Hi again Dear @jeremyzhou ,

 

I've tried that watching that registers in debug mode. But, issue comes like that; I am setting FIFO size with related registers 256 word (despite it is stated as read-only, I am a little bit confused in here. In this question LPUART_FIFO , @danielchen stated it can be configurable) and I am expecting RXCOUNT represents 256 word but it is always being 4 word and decreasing like 3-2-1-0 at the end of transmission.

 

Why we are not able to watch TX/RXCOUNT as actual FIFO size?

 

Thanks and Regards.

0 Kudos
Reply
2,075 Views
jeremyzhou
NXP Employee
NXP Employee

Hi,
1) Why we are not able to watch TX/RXCOUNT as actual FIFO size?
-- The FIFO buffer depth is fixed, in another, is not configurable.

Have a great day,
TIC

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

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

2,066 Views
Lukas_Frank
Senior Contributor I

Hi Dear @jeremyzhou ,

 

Then, what is the actual size of FIFO Buffer Depth ?

 

Thanks and Regards.

0 Kudos
Reply
2,054 Views
Lukas_Frank
Senior Contributor I

Hi Dear @jeremyzhou ,

 

Could you please reply me? This question was for approval. Will I not be able to set and use my FIFO size as 256 word? Will it be just 4 word as defaultly stated in MIMXRT1024_features.h below?

 

/* @brief Capacity (number of entries) of the transmit/receive FIFO (or zero if no FIFO is available). */
#define FSL_FEATURE_LPUART_FIFO_SIZEn(x) (4)

 

Thanks and Regards.

 
Tags (1)
0 Kudos
Reply
2,044 Views
jeremyzhou
NXP Employee
NXP Employee

Hi,
Thanks for your reply.
The depth of Transmit and Receive buffers are 4-datawords, just like the below figure shows.

jeremyzhou_0-1630896679857.png

 


Hope this is clear.
Have a great day,
TIC

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

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

2,034 Views
Lukas_Frank
Senior Contributor I

Hi Dear @jeremyzhou,

 

Will I not be able to set these depth as 256-word? Is there no possibility?

Lukas_Frank_0-1631000964183.png

Thanks and Regards.

0 Kudos
Reply
2,008 Views
jeremyzhou
NXP Employee
NXP Employee

Hi,
Thanks for your reply.
1) Will I not be able to set these depth as 256-word? Is there no possibility?
-- No, you can't.
Hope this is clear.
Have a great day,
TIC

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

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

2,121 Views
jeremyzhou
NXP Employee
NXP Employee

Hi,
Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
To be prudent, I was wondering if you can describe what kind of data the UART will transmit, then I'll share the advice with you to do it.
Have a great day,
TIC

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

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

2,110 Views
Lukas_Frank
Senior Contributor I

Hi Dear @jeremyzhou,

 

I will transmit and receive datagram packages between length 70 to 250 words.

I wonder about two topics as follows:

 

1-) How can I get received byte count that comes to my FIFO.

2-) What is the best way to use polling, interrupt or eDMA? 

 

Thanks and Regards.

0 Kudos
Reply