merged SD_CARD branch
This commit is contained in:
52
flash_scripts/flash_bas.bdm
Executable file
52
flash_scripts/flash_bas.bdm
Executable file
@@ -0,0 +1,52 @@
|
||||
#!/usr/local/bin/bdmctrl -D2
|
||||
#
|
||||
# firebee board initialization for bdmctrl
|
||||
#
|
||||
open $1
|
||||
reset
|
||||
sleep 10
|
||||
|
||||
wait
|
||||
|
||||
# Init CS0 (BootFLASH @ E000_0000 - E07F_FFFF 8Mbytes)
|
||||
write 0xFF000500 0xE0000000 4
|
||||
write 0xFF000508 0x00001180 4
|
||||
write 0xFF000504 0x007F0001 4
|
||||
|
||||
|
||||
# notify flashlib that we have flash at address 0xE0000000, length 0x7FFFFF, plugin is flash29
|
||||
flash 0xE0000000
|
||||
|
||||
# flash-plugin (target-based flashing) does not work yet
|
||||
#flash-plugin 0x10000000 0x4000 flash29.plugin
|
||||
|
||||
# Erase flash from 0xE0000000 to 0xE00FFFFF (reserved space for BaS)
|
||||
#
|
||||
# Caution: sector offset numbers need to be the ones from the x16 address range
|
||||
# column and they vary in size - needs to be exactly as in the data sheet (p. 9)
|
||||
#
|
||||
# contrary to documentation, it seems we need to erase-wait after each sector
|
||||
|
||||
erase 0xE0000000 0x00000
|
||||
erase-wait 0xE0000000
|
||||
erase 0xE0000000 0x01000
|
||||
erase-wait 0xE0000000
|
||||
erase 0xE0000000 0x02000
|
||||
erase-wait 0xE0000000
|
||||
erase 0xE0000000 0x03000
|
||||
erase-wait 0xE0000000
|
||||
erase 0xE0000000 0x04000
|
||||
erase-wait 0xE0000000
|
||||
erase 0xE0000000 0x05000
|
||||
erase-wait 0xE0000000
|
||||
erase 0xE0000000 0x06000
|
||||
erase-wait 0xE0000000
|
||||
erase 0xE0000000 0x07000
|
||||
erase-wait 0xE0000000
|
||||
erase 0xE0000000 0x08000
|
||||
erase-wait 0xE0000000
|
||||
erase 0xE0000000 0x09000
|
||||
erase-wait 0xE0000000
|
||||
blank-chk 0xE0000000 0x00000
|
||||
load -v bas.elf
|
||||
wait
|
||||
Reference in New Issue
Block a user