Bootloader HCS12

Started by tipet20002000 April 5, 2003
Hello,

Does anybody know how can I run application from RAM with metrowerks?

I've done a bootloader in C for MC9S12A128 and a program with Builder
C++ to download code from PC to HCS12 via RS485.

I can download code into block 1, but to download code into block 0 I
need executing code from RAM, and I don't know how to do it.

I'm using metrowerks 2.0 and BDM multilink.

Thank you very much.



Hi,

I'm not 100% sure I do understand your setup.

If you just want to build a little app in an SRECORD or binary format which gets loaded
to your core at runtime and executed in RAM, then just change in the prm file the
addresses of the READ_ONLY placements to be allocated in RAM.

If you want to copy part of your app to RAM at runtime, see take a look at the technical note TN10 (...\CodeWarrior\Technical
Notes\TN.pdf). The compiler backend description of position independent code might help as well, this is in
"...\CodeWarrior\CodeWarrior Manuals\pdf\Manual Compiler HC12.pdf", chapter "Motorola HC12 Back End\Position Independent Code
(PIC)".

Bye

Daniel

> -----Original Message-----
> From: tipet20002000 [mailto:]
> Sent: Saturday, April 05, 2003 9:37
> To:
> Subject: [68HC12] Bootloader HCS12 > Hello,
>
> Does anybody know how can I run application from RAM with metrowerks?
>
> I've done a bootloader in C for MC9S12A128 and a program with Builder
> C++ to download code from PC to HCS12 via RS485.
>
> I can download code into block 1, but to download code into block 0 I
> need executing code from RAM, and I don't know how to do it.
>
> I'm using metrowerks 2.0 and BDM multilink.
>
> Thank you very much. >
> -------------------- >
> ">http://docs.yahoo.com/info/terms/





Hi,

Thank you for your answer.
Finally I can complete my bootloader, I've copy the
code from ROM to RAM in execution time and it runs OK.

My problem was to remove startup code generated for
debugging which didn't let me to use INITRM.

Best regards.

___________________________________________________
Yahoo! Messenger - Nueva versi GRATIS
Super Webcam, voz, caritas animadas, y m...
http://messenger.yahoo.es