Nios® II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
Announcements
Intel Support hours are Monday-Fridays, 8am-5pm PST, except Holidays. Thanks to our community members who provide support during our down time or before we get to your questions. We appreciate you!

Need Forum Guidance? Click here
Search our FPGA Knowledge Articles here.
12453 Discussions

Functions are not getting called even if they are called in Nios II S/W Design/Code

Altera_Forum
Honored Contributor II
943 Views

Hi all, 

 

I am new to NIOS but I am trying to learn it. I have written a code, which is having multiple functions, some of the functions are calling other functions. Now here the problem starts, as I am calling other functions from inside of another function, many times the called functions are not getting called or executed. This I have completely verified by observation in the Signal Tap(I am Using PIOs). 

 

For Example: There is a Write Function, One Read Function and a Delay Function. Whenever I am calling Delay Function inside a Write/Read Function, it is not getting called. I don't know the reasons of it but I am attributing it to Stack Overflow or Usage of 100MHz clock in NIOS. 

 

Please help me in finding the reasons for it and a possible solution. 

 

Regards, 

Dindayal
0 Kudos
3 Replies
Altera_Forum
Honored Contributor II
135 Views

could you please post some code?! 

 

Does your NIOS II is configured with data-cache?
Altera_Forum
Honored Contributor II
135 Views

Yes NIOS is configured with 2k of Data Cache and 4k of Instruction Cache. I am attaching the code. 

 

The problem which I am facing is that whenever I am calling the delay_1us() function, it is not getting called and this is leading to incorrect writing/reading from Single Wire Interface. I don't know the reason of this, it might be because of Stack issues.
Altera_Forum
Honored Contributor II
135 Views

How do you notice the function not been called? you print something or breakpoint in that function?

Reply