UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Adventurer
Adventurer
1,807 Views
Registered: ‎03-30-2017

UART driver under FreeRTOS on Zynq Ultrascale+

Xilinx provides UART driver example, working in BM configuration (xuartps_intr_example.c).

This example utilize interrupts.

However, there no examples on how to utilize UART driver under FreeRTOS!

I've tried wrapping the xuartps_intr_example in a task and creating another task (Beeper), that just prints a perioding message. (see attached file)

It doesn't work as expected, it outputs the following:

 

"main:: rtÿSuccessfully ran UART Interrupt Example Test"

 

I am expecting to see messages from the task Beeper, but task Beeper is in the blocked state, in fact all other tasks are in blocked state?!

I am suspecting that the UART interrupt setup affects the FreeRTOS somehow. Unfortunately, there are no clear instructions how to utilize Xilinx drivers under FreeRTOS and no design examples, that utilize interrupts under FreeRTOS.

 

I'd appreciate any help,

Igor

0 Kudos
1 Reply
1,237 Views
Registered: ‎02-09-2010

Re: UART driver under FreeRTOS on Zynq Ultrascale+

You might download code from https://www.freertos.org/a00104.html

(see Full_Demo/serial.c).

and look at this: https://www.freertos.org/RTOS-Xilinx-Zynq.html


 

I just found many unanswered questions about UART and interrupts. I recommend also reading https://forums.xilinx.com/t5/Embedded-Processor-System-Design/xuart-ps-intr-example-c-code-not-working/td-p/789134

 

Hope it can help.

0 Kudos