- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I has try run my program with all types memory in SRAM.
System configuration: Dev. board Cyclone, NIOS II, full featured FPAG design. Program don't running if all types of program memory located in SRAM. But if read/write data memory relocate to SDRAM program will work correctly. May be someone already collided with such problem and knows its decision? P.S: excusme for my poor english.Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
So are you transfering you're program code and giving enough room for stack/heap operations?
You also have the reset location to whatever the address is in this SRAM? Do you know if you're program starts at all? (i.e. try making it do some simple I/O at startup like turn a led on or something). If you can provide more information about your setup that might be handy. (resources used and the steps taken for the system to boot).- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
--- Quote Start --- originally posted by badomen@Aug 19 2004, 07:00 AM so are you transfering you're program code and giving enough room for stack/heap operations?
you also have the reset location to whatever the address is in this sram?
do you know if you're program starts at all? (i.e. try making it do some simple i/o at startup like turn a led on or something).
if you can provide more information about your setup that might be handy. (resources used and the steps taken for the system to boot). --- Quote End --- Thanks. I think that this heap. Running programm behaves is distinguished from time to time. In main's code inserted some calls of prinft function. After start program execute different amount of the lines code, whereupon get hangs. If only read/write memory in SRAM and other in SDRAM all is ok. I am surprised such requirements to memories for stack and heap. 1Mbyte for stack/heap this plenty of.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ya if it is a simple program that should be enough. When you compile in the IDE if you're quick enough, they give you a breakdown of how much memory you're program takes, and the amount left over for the heap/stack. If you program kicks the bucket at different places then to me that sounds like memory colliding but I don't know why if you have that much.
In you're code you're not doing any memory allocation yourself are you? I didn't follow what you said about "If only read/write memory in SRAM and other in SDRAM all is ok" are you saying that it works in those memories in read/write mode, but when using the onboard memory it doesn't? If that's the case you may want to check if you're memory is indeed running out (if you don't perform the optimizations that you're readme file give you a hello world program can turn into something like 67kB .... yikes!) Altera has a document talking about reducing the memory requirements but I can't remember what it's called. A few things to try are using -O3 optimization, small C lib, no clean exit, adding the pre-processor "ALT_NO_INSTUCTION_EMULATION", etc.... (in the properties of the software project). If you have done those then you're code might be around ten times bigger then you expect unfortunately. G-luck
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page