Electronic Components Datasheet Search
  English  ▼
ALLDATASHEET.NET

X  

AN1576 Datasheet(PDF) 2 Page - STMicroelectronics

Part # AN1576
Description  The In-Application Programming
PDF  15 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  STMICROELECTRONICS [STMicroelectronics]
Direct Link  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN1576 Datasheet(HTML) 2 Page - STMicroelectronics

  AN1576 Datasheet HTML 1Page - STMicroelectronics AN1576 Datasheet HTML 2Page - STMicroelectronics AN1576 Datasheet HTML 3Page - STMicroelectronics AN1576 Datasheet HTML 4Page - STMicroelectronics AN1576 Datasheet HTML 5Page - STMicroelectronics AN1576 Datasheet HTML 6Page - STMicroelectronics AN1576 Datasheet HTML 7Page - STMicroelectronics AN1576 Datasheet HTML 8Page - STMicroelectronics AN1576 Datasheet HTML 9Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 2 / 15 page
background image
2/15
XFLASH DRIVER
1 XFLASH DRIVER
The XFlash driver is a software which can be compiled using either C-Metrowerks or C-
COSMIC and supports all memory models.
The driver is composed of 2 files: XFlash.c and XFlash.h to be included in the project. It pro-
vides RASS_Disable, and XFlashWriteBlock functions. No
Sector Erase function is provided,
since it can be emulated by writing 0xFF in a memory block.
The driver code is approximately 256 bytes in size, this may vary slightly depending on the
compilation.
1.1 DRIVER FUNCTIONS
1.1.1 RASS_Disable
void RASS_Disable(unsigned char key1,unsigned char key2)
This function disables the RASS protection to allow write access to XFLASH sectors 1 & 2, if
the two user variables key1 and key2 have the correct values: 0x56 and 0xAE.
To increase the reliability of the system, the software sequence which writes the hardware
keys should not be stored in the program memory. Both hardware keys must always be
loaded externally (via I/O ports, SCI, etc...). This security feature prevents any wrongful ac-
cess after a program counter corruption.
1.1.2 XFlashWriteBlock
unsigned char XFlashWriteBlock
( unsigned char *Buffer, unsigned int Flash, unsigned char ByteNb )
This function performs write operations with the following parameters:
–
Buffer points to the start address of the new data to be programmed
–
Flash points to the XFLASH start address area where the new data is to be programmed
–
ByteNb is the number of bytes to be programmed
The ByteNb can take a value of up to 256 even though the XFLASH itself is programmed in
rows of 32 bytes max: The XFLASH driver handles the iterative loops automatically in cases
where ByteNb is greater than 32.
The function returns a status: 0 means a failed operation, while a 1 means a successful oper-
ation.
2



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15


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