Flash usage

I’m brewing up a small project which will require processing a dataset that is larger than the FE310’s 16KB RAM. It’s fixed data and I don’t need to access it too quickly so the flash memory seems a reasonable place to stash it. How do I get started doing that, monkeying with the .data section in the linker script?

My Dr Who just used:

const unsigned char song[] = {
  #include "drwho.h"

With the included file obviously containing numbers separated with commas (and spaces, newlines etc).

It it’s const then it just automatically lives in the .text section along with the program code. If it’s not const then it’s in .data and gets copied to RAM on program start, which you obviously don’t want.


Ack! Thanks.