Exception Vector Name  Address Error - MCF52235EVB

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Exception Vector Name  Address Error - MCF52235EVB

2,200 次查看
cmag
Contributor I
Howdy again.  I haven't posted in a few hours so I thought I'd bring up my latest problem. :smileyvery-happy:
 
I'm getting the ol Exception Vector Name : Address Error, but only when I'm trying to debug from flash.  I know the first question is "do I have it loaded in flash" : yes I do.  It even runs for a little bit but then dies after a couple of seconds.  I'm afraid I may be encroaching on the RAM limits, but I'm not really sure how to know.   In code warrior at the bottom of the list of all of the compiled and linked files,  the total of my code appears to be 18K.  I don't know if that's a valid way of telling anything at all though.
 
My linker file has ROM set at address 0 and has allotted 256K, and my RAM has been allotted at 32K.  I didn't really think my program was that big, but I don't know.  Could anyone help?   I know this was pretty vague, but I don't really know what info would help.  I've included my mem map if that should help.
 
Thanks as always,
cmag
标签 (1)
0 项奖励
回复
4 回复数

704 次查看
RichTestardi
Senior Contributor II
Is it possible you're running off the end of your stack?  You might try making it bigger, or you might look at it after you crash and see if the end of it (just above 0x20000CA0) is untouched.
 
When you say "it runs for a little bit", does it crash before or after interrupts are enabled?  That's the other place you can get lots of variability, not to mention stack usage...
 
From your xmap file, it appears you have about 3k of static data, 2k of stack, and the rest of your 32k allocated to your heap (are you using your heap?)...  Does that sound right?  Your code size looks like 22k?
 
You seem to imply you don't crash when running from RAM?  I assume you have the same stack size in your RAM and FLASH lcf files?
 
 
0 项奖励
回复

703 次查看
cmag
Contributor I
Thanks for the reply Rich.
 
I could be running off the end of my heap, to be honest I'm not smart enough with this stuff to know.  In fact, I don't know if I'm using heap.  I took a class in this several years ago and you've probably forgotten more than I ever knew.
 
For some reason today it seems to be working though I haven't done anything.  I know that it's just temporary and I expect it to crash again at any moment.
 
If you don't mind, could you possibly take a quick look at my linker files and see if there is anything that is obviously wrong or that you would advise for or against, a best practices if you will?  It works in RAM perfectly 100% of the time without question, but that obviously doesn't buy me a lot.  I know just enough to know that there's a lot I don't know and getting lost in the documentation isn't as helpful as someone that speaks English.
 
Thanks for helping the newbies, this forum has been immensely helpful.
 
cmag
0 项奖励
回复

703 次查看
cmag
Contributor I
Huh, well it's possible my error could be coming from somewhere else?  It turns out that my error occurs in a function in one of my header files.  From main(), I'm passing a pointer to an array (defined above main()) into a function in one of my header files.  That function is doing a memset to clear out the array.
 
BTW, I looked at the memory in the place that you specified and it appears to have stuff in it.  You said this was just above the heap.  What does that mean as far as the program is concerned.  I attached an image of what I saw.
 
Thanks,
cmag
 
0 项奖励
回复

703 次查看
cmag
Contributor I
Hey Rich, I just tried using a different "canned" linker file for Flash that had a bigger stack and by God, worked like a charm.  You are the man, thanks for pointing me in the right direction.  You, Mark and that Crasy Cat are a wonderful asset to this board.  Thanks again. 
 
cmag


Message Edited by cmag on 2008-04-17 12:42 AM
0 项奖励
回复