Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
Announcements
All support for Intel NUC 7 - 13 systems has transitioned to ASUS. Read latest update.
12578 Discussions

Global Variables and debugging

Altera_Forum
Honored Contributor II
902 Views

I am using a system with a NIOS II/f and a level III debugger.  

 

I am writing a simple (C) program and I am running the code and data from 32K bytes on on chip ram for testing purposes.  

 

The program contains a two dimensional array.  

 

init[4][256]  

 

The array is updated with predictable values on an interrupt.  

 

When I look at the global variable init[2][0...99] in the variables pane the data is incorrect.  

 

However I then get the address of init[2][0] and look at memory and the data appears correct in here. Therefore the memory pane differs from the global variable data. 

 

The data at init[0][0....255] and init[1][0...255] appears ok (although this data is never overwritten, only the data in init[2][0....255] and init[3][0....255] appears incorrect and this is the data that is updated on the interrupt).  

 

And advice or suggestions as to why this is happening?
0 Kudos
0 Replies
Reply