This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CCS 5.3 cstartup

Other Parts Discussed in Thread: CC430F6137

Hello,

On a CC430F6137 the ZI_FUNCTION() generates a reset vector after writing a 0x00 to 0x1f2c.  As such, the cstartup never gets to main().

What might be causing this reset?

thanks,

-neil

  • 0x1f2c is normal ram. Writing to it has no special effect except altering the ram cell content.

    If you get a reset at this point, it is likely the watchdog that gets a timeout because the initialization of your variables took too much time. However, this looks a bit early (but may have to do with you looking at the code - I assume you use the debugger).

    Nevertheless, you may add a custom init (see compiler/linker documentation) and disable the watchdog before initializing the variables. Or you may use the legacy COFF output format, which doesn't initialize uninitialized variables to 0 and therefore doesn't take that much time before it starts main.

  • I hadn't considered the watchdog, but it make sense...  As my RAM usage increased, so does the initialization time.

    It failed both when debugging (single-step/breakpoints) and free running (how I initially encountered it), I'm assuming the debugger pauses the watchdog when the processor is halted?

    thanks,

    -neil

  • Neil Fortney1 said:
    I'm assuming the debugger pauses the watchdog when the processor is halted?

    Depends on project settings and if the EEM of the MSP supports this feature at all.

    Also, during debugger access, the processor doesn't get every clock cycle while the watchdog will, so if you're single-stepping, the watchdog may bark sooner.

**Attention** This is a public forum