Progmem of arrays Arduino

So I'm working on a project that I need a lot of memory for, I'm hoping in a few months time I can buy and add some extra memory to my arduino but at the moment I need about 10k bytes of memory to save an array. I was hoping to place this in flash as all I need to do is save integer values and only read it once later on down the track (preferably obtain the array data onto my computer).

So I figured I would use PROGMEM from PROGMEM - Arduino Reference and so I attempted the following code:

#include <avr/pgmspace.h>

const int rowSize = 2;
int count = 0;
int completeX = 10;
PROGMEM prog_int16_t  accAxisX[][rowSize] = {};

void setup()
{

}
void loop()
{
  delay(500);
  accAxisX [count][2]  = completeX;
  count++;
  completeX += 10;
}

But I keep getting:
sketch_apr06b.ino: In function 'void loop()':
sketch_apr06b:14: error: assignment of read-only location 'accAxisX[count][2]'

Does this mean once I create the array outside the loop function I can't change it again afterwards? And if I was hoping to do it this way I would have to fill up a large array and sent it separately?

I've been reading around and some people say its not possible to write into flash, and others say it is but you need to change your boot-loader (definitely don't have the knowledge to be able to do) and others say its part of the micro-controller so you can? But I'm starting to get confused among all the information. If it helps I'm running an atmega32u4 http://www.dfrobot.com/image/data/DFR0201/atmega32u4%20datasheet.pdf

You only need progmem once, prog_int16_t re-implements it, just use int16_t

int16_t  accAxisX[][rowSize] PROGMEM = {{ 1, 2 },{ 1, 2 }};

Your data can only be set in the initializer list ( bit above in {} brackets ). Not at runtime.

If your data can be computed at compile time, you can fill the array then. Otherwise you will need to use a standard array.

Keep in mind that PROGMEM is read-only. You can not change the data in the array at run time.

PROGMEM prog_int16_t  accAxisX[][rowSize] = {};

The compiler counts the initializers (and comes up with 0 in this case) to determine the size of the array when you don't provide all sizes. A 0 by 2 array is useless. You might as well delete this whole line.

Thanks heaps guys for your messages, and for the hints of my problems with my code. So basically what you're saying is that once I compile and upload, there's no possible way I can write into flash, or is this only the case with PROGMEM? So even if I don't change the array, that also means I can't add any arrays to flash during run time either then?

there's no possible way I can write into flash, or is this only the case with PROGMEM?

PROGMEM is flash.
Unless you rewrite the boot loader, you can't write it at run time.

AWOL:

there's no possible way I can write into flash, or is this only the case with PROGMEM?

PROGMEM is flash.
Unless you rewrite the boot loader, you can't write it at run time.

That makes me sort of sad, guess I have no choice but to get some more memory, thanks heaps though guys, I appreciate your input and happy I got all that cleared up :).