PROGMEM size limitations?

I’m using a lot of PROGMEM to store arrays for my current project. I have the following being stored:

Array 1: 4800 bytes
Array 2: 300 bytes
Array 3: 300 bytes
Array 4: 300 bytes
Array 5: 300 bytes
Array 6: 300 bytes
Array 7: 300 bytes
Array 8: 300 bytes
Array 9: 300 bytes
Array 10: 300 bytes
Array 11: 300 bytes

What is the size of PROGMEM? Arrays 1 and 2 are the only arrays currently working correctly.

PROGMEM means the array is stored in FLASH, of which you have 32K (minus the bootloader size which is 512 bytes, I think?)

So you are using 4800+10*300 --> 7800 bytes of FLASH.

-- Check out our new shield: http://www.ruggedcircuits.com/html/gadget_shield.html

I depends on the flash RAM available on the Arduino board you use.

Remember that anything you store in your arrays will be static, it can not be dynamically updated while your program is running.

Remember that anything you store in your arrays will be static, it can not be dynamically updated while your program is running.

This not really true. All Controllers that sport a bootloader allow to reprogram the FLASH in place. This also is a good method to destroy your bootloader :-)

http://www.arduino.cc/en/Reference/PROGMEM

The Bootloader for the 168 and 328 takes 2 kBytes.

@deSiva: Please explain how a user program in the lower 30k persuades the Arduino bootloader to overlay program memory.

That is not what I intended to say.

What I wanted to say is this: (1) Older processors did not allow the programming of individual FLASH cells. This could be done by ISP only. This is the main reason why so called EEPROM was installed in the first place. (2) After it was possible to implement more advanced NOR FLASH, program memory could be overwritten, allowing the "bootloader technology" (3) There is a fuse setting that prevents this; there is also a fuse setting that prevents the modification of just the bootloader section; both not activated in a standard Arduino chip. (4) By careless use of MEMPROG it is possible to not only overwrite your own code by data, but also the bootloader -> BINGO!

Alligator, how are you declaring/defining these "arrays"?

Mikal