[quote user="Clemens Ladisch"]And what are the contents of the reset vector? Still __crt0_start?[/quote] Yes it still is, good point indeed. But I've figured out how to fix this as well. In your project create a new file called "mycrt0.S" with the following contents: .section ".resetvec-patched", "a" __msp430_resetvec_hook: .word workaroundUSCI28 In the linker script, eg. for my project msp430fr5969 .ld, change the following lines __reset_vector : { KEEP (*(__interrupt_vector_56)) KEEP (*(__interrupt_vector_reset)) KEEP (*(.resetvec)) } > RESETVEC to __reset_vector : { KEEP (*(.resetvec-patched)) } > RESETVEC Look up the location of the reset vector in the linker script, here for example I'm using msp430fr5969 .ld: MEMORY { [...] RESETVEC : ORIGIN = 0xFFFE, LENGTH = 0x0002 } Now recompile and start a debug session. Open a disassembly view and enter the address of the reset vector, in this example 0xfffe, to resolve where reset jumps to (click image for full size): In this example the start of the code is at 0x4420, the encircled number in the picture. Now enter that address into the disassembly view and you should get this (click image for full size): The NOP represents code you'd want to run before everything else. If you want to debug the whole startup deselect the following two settings in the debug settings(click image for full size):
↧