| Electronic Components Datasheet Search |
|
AN1576 Datasheet(PDF) 7 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
AN1576 Datasheet(HTML) 7 Page - STMicroelectronics |
|
7 / 15 page ![]() 7/15 XFLASH DRIVER 1.3.3 Firmware template #include "io72264.h"/* ST72264 memory and register mapping */ #include "Xflash.h" /* XFlash driver software */ void Loop(void); /*************************Main loop ****************************************/ void main(void) { /************************ Initialization **********************************/ ST7_Init(); //General initialization while(1) Loop(); } /*****************UserWhileWriteBlock*************************************/ void UserWhileWriteBlock(void) { WDGCR=0x08; //Refresh WATCHDOG Timer } /***************Programming routine within External ISR*********************/ @interrupt void On_DEMO(void) { unsigned char tmp; unsigned char RamBuffer [64]@0xA6; /* New code and RASS keys buffer */ SPI_Init(); //initialize SPI communication SPI_Rx(RamBuffer,2,100,(char)0); //Receive RASS keys from EEPROM RASS_Disable(RamBuffer[0],RamBuffer[1]); //Unlock Flash for (tmp=0;tmp<2;tmp++) { SPI_Rx(RamBuffer,64,64*tmp,(char)0); XFlashWriteBlock(RamBuffer,(unsigned int)&Loop+64*tmp,64); } SPI_Disable(); WDGCR=0xC0; //Resets the MCU which also relocks the XFLASH; } /************************Sector 1 software*********************************/ #pragma section (Loop) void Loop(void) { } |
|
|
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 |
| 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 |