Modify the program counter in coldfire v2.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Modify the program counter in coldfire v2.

1,737 Views
b_q_j
Contributor I
I am trying (without success) to change the program counter from where it is executing in flash (a loader program), to the location of an .s19 file in SRAM, to begin executing.  If anyone has an explanation or an example, it would be most helpful.  btw I am using a M5213EVB. 

Thanks,
Brandon

Labels (1)
0 Kudos
Reply
2 Replies

543 Views
admin
Specialist II
Hmm, not sure what the problem could be. In assembly language, you would use the JMP instruction. In a C program, you would use a function call at a specific address:
((void (*)(void))0x12345678)();
Regards,
- mike
0 Kudos
Reply

543 Views
b_q_j
Contributor I
I had never seen that before!  Perfect, thank you!

-Brandon
0 Kudos
Reply