UART RX is stuck

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

UART RX is stuck

1,024 Views
arielablumer
Contributor III

Hi,

I'm using MQX 4.2.0.2 w/ K66.

I use UART to communicate with a peripheral and it happens that the task waiting for UART data is stuck for minutes. I monitor the peripheral lines and I'm certain that data is transmitted.

I verified UART interrupt is enabled so I would expect the scheduler to preempt the task on first data transmission.

Any idea what may be the reason for this behavior?

Thanks,

Ariela

0 Kudos
5 Replies

720 Views
arielablumer
Contributor III

One more thing - I actually have 2 devices which communicate w/ the k66 via UART.

It it happens that UART reception from both devices stops when problem occurs.

0 Kudos

720 Views
danielchen
NXP TechSupport
NXP TechSupport

Hi Ariela:

could you try to increase your task's priority to see whether it helps?

You mentioned you have two devices communicate w/ the K66 via UART, could you attach your schematics about UART? could you attach your code snippet about your uart configurations.

Regards

Daniel

0 Kudos

720 Views
arielablumer
Contributor III

Hi Daniel,

Task priority is already higher than other application tasks, It’s not a matter of priorities as the system is not busy and most of the time the idle task is running.

I also doubt if it’s a matter of HW as everything works just fine most of the time. I guess it’s something that prevents scheduling/inetrrupts.

Thanks,

Ariela

0 Kudos

720 Views
arielablumer
Contributor III

Hi Daniel,

I'm not sure I follow.

I already know the interrupt has happened and data is transmitted correctly from the device.

My application works against a WiFi device, I doubt I can simulate the problem w/o the full application.

One hint I do have - the problem occurs w/ higher probability once I enable the DHCP server.

Note that there was some correspondence about a similar issue about a year ago. There wasn't any conclusion.

Thanks,

Ariela

0 Kudos

720 Views
danielchen
NXP TechSupport
NXP TechSupport

Hi Ariela:

I think you can check the following

1 trace your code, which line is stopped.

2, whether ISR is called, place a break point in it.

3, check the waveform of rx by your oscillograph

If you need further assistance, please create a simple project for us to reproduce your issue in our side

Regards

Daniel

0 Kudos