Memory type/write cycles/loss at power up

Dave E

Senior Member
Hello all,

I am a bit confused about the different types of memory in the PICAXE chips and number of write cycles, when data is lost and that sort of thing.

Could someone that knows a bit more the me take a look below and see if I have this right?

Pardon the way I had to make the table.

NAME............MEMORY.....# WRITE.....COMMANDS.....DATA LOST AT
...................TYPE...........CYCLES.........USED..........POWER DOWN


program------eeprom------100k-------------------------no
data mem.----eeprom------100k-------read/write--------no
general vars----ram--------infinite---b0, b1, w0 etc-----yes
storage--------ram---------infinite---peek/poke---------yes
scratch pad----ram---------infinite---peek/poke---------yes

Thanks for the input,
Dave E
 

Dave E

Senior Member
Good point.

According to manual 1:
The 28X1 has "storage variable" memory at locations 80 - 126 and 192 - 239 while the scratchpad memory is at locations 0 - 127.

Is the scratchpad locations 80-126 the actual same memory as storage variable memory 80-126?

If so, can peek/poke and get/put be used interchangeably?

Dave E
 

Texy

Senior Member
Hello all,

I am a bit confused about the different types of memory in the PICAXE chips and number of write cycles, when data is lost and that sort of thing.

Could someone that knows a bit more the me take a look below and see if I have this right?

Pardon the way I had to make the table.

NAME............MEMORY.....# WRITE.....COMMANDS.....DATA LOST AT
...................TYPE...........CYCLES.........USED..........POWER DOWN

program------eeprom------100k-------------------------no
data mem.----eeprom------100k-------read/write--------no
general vars----ram--------infinite---b0, b1, w0 etc-----yes
storage--------ram---------infinite---peek/poke---------yes
scratch pad----ram---------infinite---peek/poke---------yes

Thanks for the input,
Dave E
The program memory is flashram, not eeprom and has 100k write cycles, the eeprom memory has 1,000k write cycles. This is according to Microchips 16F88 datasheet (Picaxe 18X).

Texy
 

demonicpicaxeguy

Senior Member
the eeprom memory has 1,000k write cycles. This is according to Microchips 16F88 datasheet (Picaxe 18X).

Texy
hmmm. i recall an experiment where i proved that to be a rather un charitable rating, i can't recall at how many cycles the eeprom finally failed but it was somwhere near the 5 million mark
i've also got the feeling the program memmory may be as underrated as well

i'm planning on another test at some time soon only in tempreture and voltage controlled conditions and also involving a few more devices than a used pic i had lying around,(maybe an sd card,pic16f88,24lc256,avr??)
i'll start a thread on it later
 

Dippy

Moderator
Yes, I recall that too. It was millions more wasn't it.

However, another Note Of Caution.
Microchip have access to a few more PIC chips than DPG.
They can do a statistical analysis of failure rate with some meaningful numbers.
They may have found that 0.1% failed after 1M, 10% failed after 2M and 50% failed after 3M etc.
Testing using 1 or 2 chips is interesting, and proved that with those chips made from a particular batch on a particular day could do 5 million writes.
It also proves that Microchip are (no doubt) erring on the side of caution so that 99.9% of people don't moan that they failed prematurely. Sensible I would have thought?
An interesting experiment yes, but unless you test dozens of devices from different manuf batches then it can only remain an interesting experiment - but with little statistical significance.

Stick to the Microchip figures as they will give greater confidence. Do you really think they wouldn't claim 2 million if they felt confident?
So, for up to date specs read the appropriate device DATA SHEET from Microchip.

There is a page on the Microchip website describing the durability testing somewhere.

Finally:
What is the probability of being able to say the word 'statistics' to an audience after 5 pints of Carlserg?
In my case, very low :)
 

Dave E

Senior Member
Thanks for all of the input. I do have one other question or three.

The 28X1 and 40X1 chips:
The manual lists that they have 95 bytes of usable RAM at addresses 80-126 and 192-239.
The manual also states that they have scratchpad RAM of 128 bytes at address 0-127.

Questions:
1) Is this a total of 223 bytes using peek/poke for the 95 bytes and using get/put for the 128 bytes?
2) Or does the scratchpad include the first mentioned 95 bytes?
2a) If question 2 is true, when should I use peek/poke or get/put?

I could run a simple test to check it but am a bit leary about peeking and poking and getting and putting in places I shouldn't be.

If anyone could shed some light here, it would be appreciated.

Thanks again.
Dave E
 

westaust55

Moderator
Good point.

According to manual 1:
The 28X1 has "storage variable" memory at locations 80 - 126 and 192 - 239 while the scratchpad memory is at locations 0 - 127.

Is the scratchpad locations 80-126 the actual same memory as storage variable memory 80-126?

If so, can peek/poke and get/put be used interchangeably?

Dave E
Have a look at the PICAXE variable map that I prepared some time ago;
http://www.picaxeforum.co.uk/showthread.php?t=9525&highlight=variable

(pity some data such as this cannot be made "sticky" so easier for all to find/see as required.)

Variables b0, b1, are in the SFR (RAM type) memory area
The scratchpad is a completely differene RAM area.

No, get/put and peek/poke are for different memory areas
 
Last edited:

ylp88

Senior Member
On the note of EEPROM endurance:

http://www.microchip.com/stellent/idcplg?IdcService=SS_GET_PAGE&nodeId=1406&dDocName=en010003

It applies to serial EEPROMs (i.e. those you connect by i2c or SPI such as the 24LC256 and 25LC256), but similar principals apply to the onboard EEPROM for PIC chips.

In summary, several factors can affect EEPROM R/W longevity, but the easiest to control are operating voltage (running your PIC/PICAXE at 3.3V will extend the life over one running at 5V) and temperature (operation in an ambient environment of 40'C doesn't do any favours for EEPROM life). But as already pointed out, these things are statistical and it is possible to have cells die prematurely in "ideal" conditions while those in horrible conditions push on.

ylp88
 

westaust55

Moderator
The program memory is flashram, not eeprom and has 100k write cycles, the eeprom memory has 1,000k write cycles. This is according to Microchips 16F88 datasheet (Picaxe 18X).

Texy
The same applies to the 28X1 and 40X1 devices. Extracted from the Microchip datasheet:
High Endurance Flash/EEPROM Cell:
- 100,000 write Flash endurance
- 1,000,000 write EEPROM endurance
 
Top