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.

MSP430G2553: How to initialize the PC register after loading an assembly program?

Part Number: MSP430G2553

Hi,

I am writing the "LED blink" assembly program on the msp430g2553 micro processor based only on the MSP430 Assembly Language documentation provided by TI. I am trying to learn basically from scratch. So far, I have written a correctly structured .asm file in which I assemble with the cl430 program, then link using the same program with appropriate options. I am able to produce an executable that I flash onto the board using the mspdebug tool. The problem is that the PC remains set to 0xFFFF after it is loaded. Based on the documentation, I was under the impression that the debugger would set the PC according to the entry point specified by the linker. This apparently is not the case.

The PC gets set correctly if I use a C program instead, which I compile+assemble+link using the msp gcc toolchain (taken from online examples), and even then I am not fully sure how that happens. I realize that I could go about my life just using C instead of assembly, but I am trying to learn how this stuff works.

So, my question is, how do I go about getting the PC to set itself to the entry point of my assembly program?

**Attention** This is a public forum