hi all,
just started getting my head around the MSP430 and failed at the first hurdle...
I've got a very basic program which does little at the moment, targetted to a MSP430G2131 on the Launchpad. In short, the program isn't running. When stepping through on the debugger, it gets as far as initialising a global variable then blows up with:
Can't find a source file at "/db/ztree/library/trees/gep/gep-d17x/src/ti/targets/msp430/rts430/boot_3.3.c"
The linker has been configured to give a 64byte stack and 64byte heap space (although various other configurations have been attempted), the main code is:
/*
* ======== Standard MSP430 includes ========
*/
#include <msp430.h>
/*
* ======== Grace related includes ========
*/
#include <ti/mcu/msp430/csl/CSL.h>
/* GLOBALS */
unsigned char gPulseIdx;
unsigned long gPulse;
typedef enum
{
eIDLING,
eCAPTURED
} STATE;
STATE gState;
/*
* ======== main ========
*/
int main(int argc, char *argv[])
{
int i;
unsigned short u;
CSL_init(); // Activate Grace-generated configuration
__bis_SR_register(LPM0_bits + GIE); //enable interrupt
//local inits
gPulseIdx = 0; //>>DEBUGGER BLOWS UP HERE<<
//process loop
for(;;)
{
switch (gState)
{
case eIDLING:
break;
case eCAPTURED:
u = gPulse;
}
}
return (0);
}
I'm almost certain its a memory allocation problem. The programs been repeatedly disappearing at this point, but only after clearing down the memory allocation have I now actually got an error!
Q> any ideas why it might be blowing up
Q> any ideas how to get the RAM allocation size from the linker?
Q> does the grace configuration add overhead to RAM size - i.e. should GRACE be avoided for such small memory devices?
Any comments/suggestions appreciated!
(CCS v5.1.1.00031)
Mat