EasyManua.ls Logo

Micron Xccela Flash - Program; Read

Micron Xccela Flash
20 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
CCM005-1718347970-10451
micron_xccela_zedboard_user_guide.pdf Rev 2.1 4/19 11
Micron
®
Xccela
Flash User Guide for ZedBoard
4.3.1 Program
Step 1: erase
spi_programmer erase <device> <offset> <len>
device: mtd0
offset: depends on where you want to start erasing
len: erasing size
For example: Erase flash from address 0x0 to 0x20000>
zynq> spi_programmer erase /dev/mtd0 0 0x20000
Erased 131072 bytes from address 0x00000000 in flash
Step 2: program data from source file (source file is stored in SD card)
spi_programmer write <device> <offset> <len> <source-filename>
device: mtd0
offset: depends on where you want to start programming
len: length to program
source-filename: your input file
For example: Program uImage from SD card to flash, from 0x0 to 0x20000
zynq> spi_programmer write /dev/mtd0 0 0x20000 /sdcard/uImage
Copied 131072 bytes from /sdcard/uImage to address 0x00000000 in flash
4.3.2 Read
spi_programmer read <device> <offset> <len> <dest-filename>
device: mtd0
offset: the start reading address in spi nor
len: length
dest-filename: the file name of saving data
For example: Dump flash data (from address 0 to 0x20000) to SD card:
zynq> spi_programmer read /dev/mtd0 0 0x20000 /sdcard/read.bin
Copied 131072 bytes from address 0x00000000 in flash to /sdcard/read.bin
Note: Run the
sync
command after every read operation to make sure the
data pattern is completely dumped from the SRAM to the SD card:
zynq> sync