You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

48 lines
1.1 KiB

  1. # MB96F506
  2. # Fujitsu Cortex-M3 with 512kB Flash and 64kB RAM
  3. if { [info exists CHIPNAME] } {
  4. set _CHIPNAME $CHIPNAME
  5. } else {
  6. set _CHIPNAME mb9bf500
  7. }
  8. if { [info exists ENDIAN] } {
  9. set _ENDIAN $ENDIAN
  10. } else {
  11. set _ENDIAN little
  12. }
  13. if { [info exists CPUTAPID] } {
  14. set _CPUTAPID $CPUTAPID
  15. } else {
  16. set _CPUTAPID 0x4ba00477
  17. }
  18. # delays on reset lines
  19. adapter_nsrst_delay 100
  20. jtag_ntrst_delay 100
  21. # Fujitsu cortex-M3 reset configuration
  22. reset_config trst_only
  23. jtag newtap $_CHIPNAME cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id $_CPUTAPID
  24. set _TARGETNAME $_CHIPNAME.cpu
  25. target create $_TARGETNAME cortex_m -endian $_ENDIAN -chain-position $_TARGETNAME
  26. # MB9BF506 has 64kB of SRAM on its main system bus
  27. $_TARGETNAME configure -work-area-phys 0x1FFF8000 -work-area-size 0x10000 -work-area-backup 0
  28. # MB9BF506 has 512kB internal FLASH
  29. set _FLASHNAME $_CHIPNAME.flash
  30. flash bank $_FLASHNAME fm3 0 0 0 0 $_TARGETNAME
  31. # 4MHz / 6 = 666kHz, so use 500
  32. adapter_khz 500
  33. # if srst is not fitted use SYSRESETREQ to
  34. # perform a soft reset
  35. cortex_m reset_config sysresetreq