Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Altera_Forum
Honored Contributor I
727 Views

ISR in TCM using __attribute__ hangs

I'm porting NiosII Software Altera Training labs to a new board and I'm having problems getting the interrupt handler routine to run into a tightly coupled memory. 

 

It seems to be a hardware problem, as I've tried to run the stock lab4_solns.c into my own NEEK sof and it doesn't work. It only works if the software is run in the supplied sof image. 

 

The problem I see is that the software hangs or start over every time I push a button and the ISR should be called. I can run arbitrary functions from the TCM using the __attribute__ directive and I can run the ISR from the regular memory, but using the attribute in the ISR function definition will cause this problem -- only if used with my own sof hardware image. 

 

I've read a couple of Altera documents on TCM and ISR and I haven't found any hardware requirement I'm not meeting. I'm using the internal interrupt controller and both reset and exception address are set to external memory, as I'm supposed to use the attribute to allocate it into the TCM. I'm also using the new ISR API to in order to keep the lab software source files as unchanged as possible. I'm using dual port instruction TCM and connecting the processor instruction tcm master and data master to each port. 

 

Any direction on how to get it to work is highly appreciated!
0 Kudos
0 Replies
Reply