I have started using msp430f5324 device for one of my project and i am facing strange behaviour of reset when code crosses certain limits.Even i have put ISR routines to catch the cause.Plz find attached .map files generated .
STACK size : 512 bytes and
compiler : IAR 5.40.3 30 days Evaluation version
Optimization : None
memory model : small
The behaviour corresponds to map file ( File_1 with reset problem) :
· The device gets reset ( power on and off automatically).
· Suspecting software reset(NMI).
· I tried to catch it with SYSNMI and UNMI ISRs. But not able to catch.
· Even I experimented with STACK size : 1024 bytes.
The behaviour corresponds to map file ( File_2 without reset problem) :
· I have commented few functions which are straight forward and those functions don’t deal with device Hardware registers too.
· The device is found to be working normally.
· Even keeping those function working, if I comment some other functions then too the device works.
7142.File_1_With Reset Problem.txt
what could be wrong ? what would be the debugging & precaution points.Your valuable comments will be helpful.
Thanks & regards,
I noticed that your code size is ~44kb, which means you need to use the 20-bit CPUX extensions to access the additional flash. Try setting the "data model" and "code model" to "large".
I have selected the option data model to “large” .But didn’t find anything called “code model’ selection. But problem remains same.
Two separate questions for you.
Do you have any assembly language in your project?
Can you have the compiler generate a listing with assembly mnemonics included for one of your source code files. Like this:
Project Options -> C/C++ Compiler -> List -> Output List File (Yes) -> Assembler mnemonics (Yes)
Review the listing file (*.lst) generated by the compiler and see if function calls are made with "CALLA" or "CALL" and see if functions end with "RETA" or "RET". If you have the project configured correctly, you will see CALLA / RETA.
thanks for suggestions.I have done this.And functions are being called thru' "CALLA" and end with "RETA"
And i don't have any assembly file include in my project.
After you have changed the data model and recompiled, does it still say this in the linker map?
__data_model = small
Also, try enabling "20-bit context save on interrupt" in Compiler->Code.
Hi again Ars,
A few more ideas for you:
All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.
TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs andembedded processors, along with software, tools and the industry’s largest sales/support staff.