Yahoo Groups archive

Lpc2000

Index last updated: 2026-04-28 23:31 UTC

Message

Re: running FIQ code from ram?

2004-03-16 by embeddedjanitor

--- In lpc2000@yahoogroups.com, Peter Kuhar <peter.kuhar@g...> wrote:
> Hello,
> 
> I would like to copy FIQ code from flash to ram a startup and then 
run
> FIQ code from RAM(better response). How can i do that in C.
> 
> /Pero

On an LPC210x with MAM enabled, it isn't that obvious that you will 
get a huge performance kick from running an FIQ from RAM. This might 
be a case where assembler is the way to go to tweak the code )if it is 
small.

Anyway, back to your question....The way you do this is very compiler 
dependent. You will need to link/locate the code to use RAM adresses. 
Typically, the copy-to-ram is done by the assembler start-up code that 
executes before main. The concept involved is very similar to the 
initilaisation of your data segment (ie. the segment's imnitialisation 
data gets coipied from flash into RAM). Depending on your compiler, 
this might be as easy as setting a pragma or such or might need some 
manual effort.

-- Charles

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.