MSP430 device does not start up
Technical Note 37778
Arkitekturer:
MSP430
Komponent:
general
Uppdaterad:
2015-11-06 13:53
Introduction
This Technical Note discusses cases where an MSP430 device does not start, or does not reach the main function.
Some different symptoms
The hardware never starts up.
The MSP430 device resets without reaching the "main()" function.
The watchdog timer times out during initialization.
The cause
If the application has much (over 4k) of global initialized data, then the initialization within cstartup will not be finished before the watchdog times out (and the device is reset).
Affected derivatives
The MSP430 derivatives MSP430F1610, F1611 and F1612 have large RAM, but this Technical Note applies to any device with large RAM.
The solution
The Watchdog timer must be turned off before the initialization phase. This should preferably be done in __low_level_init.
Steps (for MSP430F1610, F1611 or F1612)
- Copy of the file "low_level_init.c" (from ...\430\src\lib\) to your project directory.
- Add the copied "low_level_init.c" file to your project.
- Edit your copy of the "low_level_init.c" file
- In the file you need to add, either...
-
#include <msp430x16x.h>
- ...or add...
-
#include <io430x16x.h>
- You should add, in the __low_level_init() function.
-
WDTCTL = WDTPW + WDTHOLD;
- Finally you should consider (if needed) where in your application the Watchdog should be activated. In such a case add the appropriate C source at that place.
All product names are trademarks or registered trademarks of their respective owners.