Freescale Semiconductor, Inc.
ARCHIVED BY FREESCALE SEMICONDUCTOR, INC. 2005
Freescale Semiconductor, Inc.
Programming
For example, when using SDS’s DOWN.EXE to generate the
Guide for using this command.
ARCHIVED BY FREESCALE SEMICONDUCTOR, INC. 2005
C.5 EXECUTING PROGRAM COMMAND SEQUENCE
Listed below is the source code of the flash Program which contains the necessary steps to write the flash memory MBM29LV160T. It executes the flash program command sequence and copies the ROM image from RAM area to the Flash memory area on ADS board. Figure
|
| XREF | STKTOP |
|
OFFSET1 |
| equ $AAA |
| |
OFFSET2 |
| equ $554 |
| |
TIME |
| equ $FFF |
| |
***************************************************************** | ||||
ECHO | MACRO | CHAR |
|
|
| bsr | TXD_RDY |
| |
| nop |
|
|
|
| nop |
|
|
|
| nop |
|
|
|
| move.b | #CHAR,$FFFFF907 | ||
| ENDM |
|
|
|
***************************************************************** | ||||
ENABLE | MACRO |
|
|
|
| move.w | #$00AA,(A5) | ; Unlock Flash | |
| move.w | #$0055,(A6) |
| |
| move.w | #$00A0,(A5) |
| |
| ENDM |
|
|
|
***************************************************************** | ||||
| SECTION | parameter |
| |
pSOURCE |
| DC.L | $00010000 | |
pTARGET |
| DC.L | $01000000 | |
pSIZE |
| DC.L | $00010000 | |
pFLASH |
| DC.L | $01000000 | |
pERROR |
| DC.L | $0 |
|
pFINISH |
| DC.L | $0 |
|
pERROR_ADDRESS | DC.L | $0 |
| |
|
| DC.L | STKTOP |
|
***************************************************************** | ||||
| SECTION | code |
|
|
START |
|
|
|
|
MOVEA.L #STKTOP,a7 | ||||
| MOVE.L | #0,pERROR |
| |
| MOVE.L | #0,pFINISH |
| |
| move.l | #0,pERROR_ADDRESS |
For More Information On This Product,
Go to: www.freescale.com