Electronic Components Datasheet Search
  British  ▼
ALLDATASHEET.CO.UK

X  

AN2540 Datasheet(PDF) 10 Page - STMicroelectronics

Part # AN2540
Description  EEPROM emulation in STR91xFxx devices
PDF  25 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  STMICROELECTRONICS [STMicroelectronics]
Direct Link  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN2540 Datasheet(HTML) 10 Page - STMicroelectronics

Back Button AN2540 Datasheet HTML 6Page - STMicroelectronics AN2540 Datasheet HTML 7Page - STMicroelectronics AN2540 Datasheet HTML 8Page - STMicroelectronics AN2540 Datasheet HTML 9Page - STMicroelectronics AN2540 Datasheet HTML 10Page - STMicroelectronics AN2540 Datasheet HTML 11Page - STMicroelectronics AN2540 Datasheet HTML 12Page - STMicroelectronics AN2540 Datasheet HTML 13Page - STMicroelectronics AN2540 Datasheet HTML 14Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 10 / 25 page
background image
Implementing the EEPROM emulation
AN2540 - Application note
10/25
Figure 2.
Sector swap scheme: Sector1 erased
In this application, sector0 is divided up as follows:
■ 0x0000 0002 - 0x0000 04FF memory space is allocated to variable A
■ 0x0000 0500 - 0x0000 0510 memory space is allocated to variable B
■ 0x0000 0511 - 0x0000 1FFF memory space is allocated to variable C
In sector0, variables are stored until there the memory space left is not large enough to be
allocated to another variable (case of variable A in the following example).
Example: Let us assuming that variable A is to be updated at time t0 + (n+1) × tA to A(t0 +
(n+1) × tA). Addresses from 0x0000 0002 to 0x0000 04FF are all full, the next value is then
stored in the base address of the space allocated to variable A in sector1.
The latest stored values of all other variables (B and C) are transferred from their current
location in sector0 to the base address of their allocated space in sector1. After the transfer
of all variables is complete, sector0 is erased.
Variables are then stored and updated in sector1 in the same way as described for sector0.
When there is not enough memory space left for one of these variables in sector1, the
variables are transferred back to sector0 (now empty) as described above and so on. This
process is illustrated in Figure 3.
A(t) values
B(t) values
C(t) values
0x0000 0000
0x0000 1FFF
A(t0)
B(t0)
C(t0)
Sector0
Sector1 Header
A(t) values
B(t) values
C(t) values
0x0000 2000
0x0000 3FFF
Sector1 Erased
Update
Update
Update
Sector swap
(Erase one when using the other)
A(t0 + tA)
A(t0 + n × tA)
B(t0 + m × tB)
C(t0 + p × tC)
Sector0 Header
A(t0)
B(t0)
C(t0)
A(t0 + tA)
A(t0 + n × tA)
B(t0 + m × tB)
C(t0 + p × tC)
ai14086



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com