전자부품 데이터시트 검색엔진
  Korean  ▼
ALLDATASHEET.CO.KR

X  

AN2540 데이터시트(PDF) 18 Page - STMicroelectronics

부품명 AN2540
상세설명  EEPROM emulation in STR91xFxx devices
PDF  25 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
제조업체  STMICROELECTRONICS [STMicroelectronics]
홈페이지  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN2540 데이터시트(HTML) 18 Page - STMicroelectronics

Back Button AN2540 Datasheet HTML 14Page - STMicroelectronics AN2540 Datasheet HTML 15Page - STMicroelectronics AN2540 Datasheet HTML 16Page - STMicroelectronics AN2540 Datasheet HTML 17Page - STMicroelectronics AN2540 Datasheet HTML 18Page - STMicroelectronics AN2540 Datasheet HTML 19Page - STMicroelectronics AN2540 Datasheet HTML 20Page - STMicroelectronics AN2540 Datasheet HTML 21Page - STMicroelectronics AN2540 Datasheet HTML 22Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 18 / 25 page
background image
Embedded application aspects
AN2540 - Application note
18/25
4
Embedded application aspects
This section gives some advice on how to overcome software limitations in embedded
applications and to fulfill the needs of different applications.
4.1
Data granularity management
The emulated EEPROM can be used in embedded applications where non-volatile storage
of data updated with a byte, half-word or word granularity is required. It generally depends
on the user requirements and Flash architecture, such as stored data length, write access,
etc.
The STR91xFxx on-chip Flash memory allows 16-bit, half-word programming. Data can
however be programmed by bytes or words by using some software techniques.
4.1.1
Programming on a word-by-word basis
To write 32 bits of data "FMI_Data" to the desired Flash memory address "FMI_Address" in
Bank1 for example, the process is the following:
■ Write the LSB part of the data (the first two bytes) to the desired Flash memory address.
■ Write the MSB part of the data (the last two bytes) to the Flash memory address
incremented twice.
4.1.2
Programming on a byte-by-byte basis
Writing by bytes offers the user the possibility to cover the entire memory space and,
therefore, to store more data. The performance may however be reduced.
A simple example can be useful to understand how to implement such a feature.
Let us assume for example that we want to write one byte of data "0xDD" into Bank1 at the
FMI_Address. This can be achieved as follows:
If FMI_Address is even, then 0xFFDD is written. If FMI_Address is odd, 0xDDFF is written.
The generic scheme is shown in Figure 8.
u16 LSB=FMI_Data;
u16
MSB= FMI_Data >>16;
FMI_WriteHalfWord ( FMI_Address,
LSB);
FMI_WaitForLastOperation(FMI_BANK_1);
FMI_WriteHalfWord ( FMI_Address+2,
MSB);FMI_WaitForLastOperation(FMI_BANK_1);



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


데이터시트 다운로드

Go To PDF Page


링크 URL



ALLDATASHEET 가 귀하에 도움이 되셨나요?  [ DONATE ] 

Alldatasheet는?   |   광고문의   |   운영자에게 연락하기   |   개인정보취급방침   |   링크 투 데이터시트    |   링크교환   |   제조사별 검색
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