Reference.EEPROMWrite History

Hide minor edits - Show changes to markup

June 02, 2010, at 01:11 PM by Equipo Traduccion -
Changed lines 1-23 from:

EEPROM.write(address, value)

Description

Write a byte to the EEPROM.

Parameters

address: the location to write to, from 0 to 511 (int)

value: the value to write, from 0 to 255 (byte)

Returns

none

The Atmega 168 datasheet says that EEPROM memory has a specified life of 100000 write/erase cycles, so there is a limit to how many times you can write information to that memory space. Keep this in mind for long-lived projects or fast-moving data.

The datasheet also specifies that a write cycle takes 3.3 ms to complete. Other EEPROM write and read requests will fail if executed in this time period. This delay appears to be built into the EEPROM library as a casual test shows each cycle taking 3.33 ms to execute.

Hence, you do not specifically need to add a delay to an EEPROM write, just be aware of the built-in time delay.

Example

to:

EEPROM.write(dirección, valor)

Descripción

Escribe un byte en la EEPROM.

Parámetros

dirección: la localización en donde escribir, desde 0 a 511 (int)

valor: el valor a escribir, de 0 a 255 (byte)

Devuelve

nada

La datasheet (hoja de características) del Atmega 168 dice que su memoria EEPROM tiene una vida especificada de 100000 ciclos de escritura/borrado, así que hay un limite de veces en las que puedes escribir información en ese espacio de memoria. Tenlo en cuenta en proyectos de larga vida o con movimientos de datos rápidos.

La datasheet tambien especifica que un ciclo de escritura tarda en completarse 3.3 ms. Otras peticiones de escritura o lectura a la EEPROM fallararn si son ejecutadas en este periodo de tiempo. Este retardo parece estar integrado en la librería EEPROM ya que hay test que indican que cada ciclo tarda 3.33 ms en ejecutarse.

Por lo tanto no necesitas añadir un retardo a una escritura en la EEPROM, pero ten en cuenta el retardo de tiempo ya integrado.

Ejemplo

Changed lines 39-40 from:

See also

to:

Mira también

August 27, 2007, at 03:22 AM by Paul Badger -
Changed lines 19-20 from:

The datasheet also specifies that a write cycle takes 3.3 ms to complete. Other EEPROM write and read requests will fail if executed in this time period.

to:

The datasheet also specifies that a write cycle takes 3.3 ms to complete. Other EEPROM write and read requests will fail if executed in this time period. This delay appears to be built into the EEPROM library as a casual test shows each cycle taking 3.33 ms to execute.

Hence, you do not specifically need to add a delay to an EEPROM write, just be aware of the built-in time delay.

August 27, 2007, at 03:05 AM by Paul Badger -
Added lines 17-20:

The Atmega 168 datasheet says that EEPROM memory has a specified life of 100000 write/erase cycles, so there is a limit to how many times you can write information to that memory space. Keep this in mind for long-lived projects or fast-moving data.

The datasheet also specifies that a write cycle takes 3.3 ms to complete. Other EEPROM write and read requests will fail if executed in this time period.

March 04, 2007, at 06:20 PM by David A. Mellis -
Added lines 1-34:

EEPROM.write(address, value)

Description

Write a byte to the EEPROM.

Parameters

address: the location to write to, from 0 to 511 (int)

value: the value to write, from 0 to 255 (byte)

Returns

none

Example

#include <EEPROM.h>

void setup()
{
  for (int i = 0; i < 512; i++)
    EEPROM.write(i, i);
}

void loop()
{
}

See also

Share