flash using to store data

Go To Last Post
6 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

i want to use te flash in a atmega 32 to store data (12000 kByte).

now i read a few days back, that flash only contents the program. 

 

so i want to use flash for the program but also, to store the data who is coming from that program.

is this possible ?

 

thanks in advance for your help.

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quite possible. You need to locate some parts of your program in the high flash area known as the "bootloader section" and that will be able to use SPM (self program memory) to write to the flash.

 

Note the Flash will wear out if you write it more than 10,000 times over the entire life of the AVR

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

clawson wrote:
Quite possible.
trixo wrote:
atmega 32 to store data (12000 kByte).

12MB on a Mega32?

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Missed the 'k'. As Lee says you could store 12,000 bytes, you couldn't store 12,000 K bytes!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

no of course, it was a mistake from me indecision

just 12000 bytes.

 

clawson wrote:

Quite possible. You need to locate some parts of your program in the high flash area known as the "bootloader section" and that will be able to use SPM (self program memory) to write to the flash.

 

some parts of the program ? and SPM ?

i gonna find out how this is working,....thanx

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Look up "bootloader" as it uses the same mechanism. If using avr-gcc read about in the manual.