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.
 
 
 
 
 
 

62 lines
1.4 KiB

  1. #
  2. # Texas Instruments CC32xx - ARM Cortex-M4
  3. #
  4. # http://www.ti.com/product/CC3200
  5. # http://www.ti.com/product/CC3220
  6. #
  7. source [find target/swj-dp.tcl]
  8. source [find target/icepick.cfg]
  9. if { [info exists CHIPNAME] } {
  10. set _CHIPNAME $CHIPNAME
  11. } else {
  12. set _CHIPNAME cc32xx
  13. }
  14. #
  15. # Main DAP
  16. #
  17. if { [info exists DAP_TAPID] } {
  18. set _DAP_TAPID $DAP_TAPID
  19. } else {
  20. if {[using_jtag]} {
  21. set _DAP_TAPID 0x4BA00477
  22. } else {
  23. set _DAP_TAPID 0x2BA01477
  24. }
  25. }
  26. if {[using_jtag]} {
  27. jtag newtap $_CHIPNAME cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id $_DAP_TAPID -disable
  28. jtag configure $_CHIPNAME.cpu -event tap-enable "icepick_c_tapenable $_CHIPNAME.jrc 0"
  29. } else {
  30. swj_newdap $_CHIPNAME cpu -expected-id $_DAP_TAPID
  31. }
  32. #
  33. # ICEpick-C (JTAG route controller)
  34. #
  35. if { [info exists JRC_TAPID] } {
  36. set _JRC_TAPID $JRC_TAPID
  37. } else {
  38. set _JRC_TAPID 0x0B97C02F
  39. }
  40. if {[using_jtag]} {
  41. jtag newtap $_CHIPNAME jrc -irlen 6 -ircapture 0x1 -irmask 0x3f -expected-id $_JRC_TAPID -ignore-version
  42. jtag configure $_CHIPNAME.jrc -event setup "jtag tapenable $_CHIPNAME.cpu"
  43. }
  44. set _TARGETNAME $_CHIPNAME.cpu
  45. dap create $_CHIPNAME.dap -chain-position $_CHIPNAME.cpu
  46. target create $_TARGETNAME cortex_m -dap $_CHIPNAME.dap
  47. if { [info exists WORKAREASIZE] } {
  48. set _WORKAREASIZE $WORKAREASIZE
  49. } else {
  50. set _WORKAREASIZE 0x2000
  51. }
  52. $_TARGETNAME configure -work-area-phys 0x20000000 -work-area-size $_WORKAREASIZE -work-area-backup 0