• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » Microcontrollers » MSP430™ Microcontrollers » MSP430 Ultra-Low Power 16-bit Microcontroller Forum » Undefined behaviour(getting reset) of msp430f5324
Share
MSP430™ Microcontrollers
  • Forum
  • Announcements
  • E2E Wiki
Options
  • Subscribe via RSS
MSP430 Resources
  • MSP430 Product Folder
  • MSP-EXP430G2 - MSP430 LaunchPad Value Line Development kit
  • MSP430 Getting Started Guide
  • MSP430 Microcontroller Projects
  • More Resources >
  • Forums

    Undefined behaviour(getting reset) of msp430f5324

    This question is not answered
    Ars
    Posted by Ars
    on Apr 27 2012 23:26 PM
    Prodigy190 points


     Hello,

        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).

    • I have checked the RESET Pin. It remains HIGH.

    ·        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

    0042.File_2Without Problem.txt

    what could be wrong ? what would be the debugging & precaution points.Your valuable comments will be helpful.

    Thanks & regards,

    Ars

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
    All Replies
    • TonyKao
      Posted by TonyKao
      on Apr 27 2012 23:42 PM
      Genius3770 points

      Hi Ars,

      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".

      Tony

      Report Abuse
      • Reply
      You have posted to a forum that requires a moderator to approve posts before they are publicly available.
    • Ars
      Posted by Ars
      on Apr 28 2012 06:09 AM
      Prodigy190 points

      Hello,

           I have selected the option data model to “large” .But  didn’t find anything called “code model’ selection. But problem remains same. 

      Report Abuse
      • Reply
      You have posted to a forum that requires a moderator to approve posts before they are publicly available.
    • Jeff Tenney
      Posted by Jeff Tenney
      on Apr 28 2012 10:53 AM
      Guru10795 points

      Hello Ars,

      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.

      Jeff

      Report Abuse
      • Reply
      You have posted to a forum that requires a moderator to approve posts before they are publicly available.
    • Ars
      Posted by Ars
      on Apr 30 2012 03:51 AM
      Prodigy190 points

      Hello jeff,

       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.

      thanks

      Report Abuse
      • Reply
      You have posted to a forum that requires a moderator to approve posts before they are publicly available.
    • TonyKao
      Posted by TonyKao
      on Apr 30 2012 13:00 PM
      Genius3770 points

      Hi Ars,

      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.

      Tony

      Report Abuse
      • Reply
      You have posted to a forum that requires a moderator to approve posts before they are publicly available.
    • Jeff Tenney
      Posted by Jeff Tenney
      on May 01 2012 00:58 AM
      Guru10795 points

      Hi again Ars,

      A few more ideas for you:

      • The 30-day evaluation version may not actually be fully functional.
      • Do you use function pointers in your code?  If so, how do you declare them?  More generally speaking, are you reviewing all the IAR "remarks" and "warnings" from your build process?
      • After a reset you can read the SYSRSTIV register to determine the highest-priority cause of the most-recent reset.  After you read it, be sure to write to it to clear all other causes of the most-recent reset(s).  That way when the next reset comes, you'll see what really caused it.  Seeing the detailed cause of the reset could be a valuable clue.

      Jeff

      Report Abuse
      • Reply
      You have posted to a forum that requires a moderator to approve posts before they are publicly available.
    TI E2E™ Community
    • Support Forums
    • Blogs
    • Videos
    • Groups
    • Site Support & Feedback
    • Settings
    TI E2E™ Community Groups
    • TI University Program
    • Make the Switch
    • Microcontroller Projects
    • Motor Drive & Control
    Other Communities
    • Deyisupport
    • Designsomething.org
    • beagleboard.org
    • TI on Element 14
    • TI on TechXchangeSM
    Other Technical & Support Resources
    • WEBENCH® Design Center
    • Product Information Centers
    • Technical Documents
    • TI Design Network
    • TI Technical Articles
    • TI Training

    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.

    Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

    Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
    TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

    TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
    embedded processors, along with software, tools and the industry’s largest sales/support staff.

    © Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
    Trademarks | Privacy Policy | Terms of Use