EmbeddedRelated.com
Forums

Using IAP in a CrossWorks Tasking Library (CTL) application

Started by eli1s March 1, 2005

Hello everybody!
This is my first message on thi board.
Is there anybody on this board doing In Application Programming by
application, running on Rowley CTL kernel?



Re: Using IAP in a CrossWorks Tasking Library (CTL) application

An Engineer's Guide to the LPC2100 Series

Hi Eli,

We ship the source code of the flash loader in the CrossWorks for ARM
distribution which could be a place to start. Other things to beware of
is that the code must be executing in RAM (place the functions in the
.fast section) and you'll have to disable global interrupts to avoid a
task switch in the middle of the flash programming.

Regards
Michael

>Hello everybody!
>This is my first message on thi board.
>Is there anybody on this board doing In Application Programming by
>application, running on Rowley CTL kernel? >
>
>Yahoo! Groups Links >





Hi Michael,
Probably I will have to write some separate code loader application,
to be run in RAM.

My software download scenario is as follows:
1. The CTL application runs normally and then it receives
START_PROGRAM_DOWNLOAD command (through some proprietary serial
protocol).
2. I presume that the command processor task will have to disable
IRQ and FIQ interrupts (I use both of them), copy a ram runnable
image of software loader application from flash to RAM, and start it.
3. Probably the loader application can be a CTL application too. It
will respond only to software download part of the serial
communication protocol. The reason, I want to run a CTL application
for the download is that I want to use the same serial drivers and
the same RS-422 Tx driver enable/disable timing mechanism, I use in
the main application. Every time a RECEIVE_PROGRAM_RECORD command is
received, it may call an IAP function to program the flash.
4. After the software download completes, an END_PROGRAM_DOWNLOAD
command is received. On reception, the loader application will
disable all interrupts, and reboot the LPC2106.

I will be glad to have your remarks. In addition, if there is
anybody on the board that already did IAP inside a CTL application
and wants to share the experience, it may be of benefit to all the
board members. Many thanks,
Eli.
--- In , Michael Johnson <mpj@r...> wrote:
> Hi Eli,
>
> We ship the source code of the flash loader in the CrossWorks for
ARM
> distribution which could be a place to start. Other things to
beware of
> is that the code must be executing in RAM (place the functions in
the
> .fast section) and you'll have to disable global interrupts to
avoid a
> task switch in the middle of the flash programming.
>
> Regards
> Michael
>
> >Hello everybody!
> >This is my first message on thi board.
> >Is there anybody on this board doing In Application Programming
by
> >application, running on Rowley CTL kernel?
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >Yahoo! Groups Links
> >
> >
> >
> >
> >
> >
> >
> >
> >