# Zynq Not getting Interrupt

**URL:** <https://forums.freertos.org/t/zynq-not-getting-interrupt/6206>\
**Category:** Kernel\
**Created:** [October 5, 2016, 5:34pm UTC](https://forums.freertos.org/t/zynq-not-getting-interrupt/6206 "2016-10-05T17:34:32Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [October 5, 2016, 5:34pm UTC](https://forums.freertos.org/t/zynq-not-getting-interrupt/6206/1 "2016-10-05T17:34:32Z")

</div>

**[raymadigan](https://sourceforge.net/u/raymadigan/)** wrote on [Wednesday, October 05, 2016](https://sourceforge.net/p/freertos/discussion/382005/thread/3de639c3/#aa53):

I am using a Zynq processor on a MicroZed board and I am working to incorporate FreeRTOS into the project. I am using DMA to send data from the PS to the PL. The problem I am experiencing is that I don’t get the interrupt from the PL when the transfer is complete hence I cannot acknowledge it and the interrupt stays high forever.

I followed the following procedure:  
I have a minimal bare metal application that sends the packet from the PS to the PL using SimpleTransfer DMA. The application sets up the dma and interrupts to receive the interrupt and I can watch the acknowledgement in an ILA I have setup on the device. I have arranged all of the interrupt and dma setup in a single function so I can just copy it to the FreeRTOS implementation, comment out a few lines and be good.

I got the FreeRTOS blinky demo to work. I removed everything except the blinky code to get the example as simple as possible. I left in the two tasks to turn on and off the led.

I copied this application to a new project and added a semiphore and a new task that fires once when the semiphore fires that sends the dma packet to the PL. I used the interrupt and dma setup procedure that I used in the minimal bare metal app. I can see the interrupt go high in the ILA in the PS and it never goes low. I am not able to acknowledge the interrupt because I get the interrupt in my FreeRTOS implementation.

I have an application that I built 6 months ago that uses the same concept, it is more complicated in that it services DMA from the PL to the PS in scatter gather. It actually had a FreeRTOS task as the interrupt service. This problem I don’t need to service the interrupt except to acknowledge that the packet was sent. I look at this old application and cannot seem to see anything different. I am still looking.

---

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [October 5, 2016, 6:46pm UTC](https://forums.freertos.org/t/zynq-not-getting-interrupt/6206/2 "2016-10-05T18:46:34Z")

</div>

**[raymadigan](https://sourceforge.net/u/raymadigan/)** wrote on [Wednesday, October 05, 2016](https://sourceforge.net/p/freertos/discussion/382005/thread/3de639c3/#67fb):

I found the problem. I use a different name for the XScuGic interrupt controller. It is used in the FreeRTOS\_tick\_config file.

---

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [October 10, 2016, 10:14pm UTC](https://forums.freertos.org/t/zynq-not-getting-interrupt/6206/3 "2016-10-10T22:14:19Z")

</div>

**[raymadigan](https://sourceforge.net/u/raymadigan/)** wrote on [Monday, October 10, 2016](https://sourceforge.net/p/freertos/discussion/382005/thread/3de639c3/#772a):

I answered this wrong. I am using FreeRTOS v9.0.0 and FreeRTOS\_Labs 160919. I used the base demo for the zynq and TCP\_and\_Fat. In the file FreeRTOS\_tick\_config.c the function vConfigureTickInterrupt has a static instance of the XScuGic interrupt controller as a local variable. This function assumes that noone else will be using the interrupt controller, it reinitializes the interrupt controller. The interrupt controller state is lost and any previous defined interrupts will not be services.

This function should have an  
extern XScuGic xInterruptController.

and the interrupt controller defined in main. This is how the FreeRTOS demo for the zynq is setup. Otherwise this change will have to be made for every release by anyone who uses the TCP connectivity.

---

<div class="post-metadata">

**Author:** ![rtel](https://d3iykfbgfh8zhg.cloudfront.net/user_avatar/forums.freertos.org/rtel/32/31_2.png) [@rtel](https://forums.freertos.org/u/rtel)\
**Post date:** [October 11, 2016, 3:49am UTC](https://forums.freertos.org/t/zynq-not-getting-interrupt/6206/4 "2016-10-11T03:49:06Z")

</div>

**[rtel](https://sourceforge.net/u/rtel/)** wrote on [Tuesday, October 11, 2016](https://sourceforge.net/p/freertos/discussion/382005/thread/3de639c3/#772a/c82b):

Thanks for the info - I think (as you suggest) this was changed for the  
Zynq demo in the main FreeRTOS download, but evidently not in the labs  
download.
