traveo2_c2d_4m.cfg 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. #
  2. # Copyright (C) <2019-2024>
  3. # <Cypress Semiconductor Corporation (an Infineon company)>
  4. #
  5. # Configuration script for Cypress TRAVEO™II C-2D-4M family of microcontrollers.
  6. # TRAVEO™II C-2D-4M is a dual-core device with CM0+ and CM7 cores. All cores share
  7. # the same Flash/RAM/MMIO address space.
  8. #
  9. source [find target/infineon/common/common_ifx.cfg]
  10. namespace import ifx::*
  11. # The following four lines can be used to override Flash Geometry of the target device
  12. # In this case configuration scripts will not perform any auto-detection and will use
  13. # predefined values.
  14. # If all these variables are set to zero, configuration scripts will attempt to detect
  15. # the type of target device by reading SiliconID from SFlash and matching it with MPN
  16. # database, see cympn.cfg file.
  17. set MAIN_LARGE_SECTOR_NUM 126
  18. set MAIN_SMALL_SECTOR_NUM 16
  19. set WORK_LARGE_SECTOR_NUM 48
  20. set WORK_SMALL_SECTOR_NUM 256
  21. # Reset configuration - use hardware XRES pin
  22. # If this line is commented-out OpenOCD will use SYSRESETREQ to reset the CM0+ core and
  23. # all peripherals. This will also reset CM4/CM7 cores.
  24. # reset_config srst_only srst_pulls_trst
  25. # Defines the name of the Target and allows to override it from the command line
  26. set_or_global CHIPNAME traveo2_c2d_4m
  27. set TARGET_VARIANT TVIIC2D4M
  28. echo "** Supported Flash Loaders: ***********************"
  29. echo "** SMIF0_LOADER: TV2_C2D_4M_SemperFlash_0.elf"
  30. echo "** SMIF1_LOADER: TV2_C2D_4M_SemperFlash_1.elf"
  31. echo "***************************************************"
  32. set TRAVEO_VARIANT_C2D_4M 1
  33. set_or_global ENABLE_SEMPERFLASH_0 0
  34. set_or_global SEMPERFLASH_LOADER_0 TV2_C2D_4M_SemperFlash_0.elf
  35. set_or_global ENABLE_SEMPERFLASH_1 0
  36. set_or_global SEMPERFLASH_LOADER_1 TV2_C2D_4M_SemperFlash_1.elf
  37. set_or_global HYPERRAM_LOADER_1 TV2_C2D_4M_HyperRAM.elf
  38. # Include common functionality script
  39. source [find target/infineon/cat1c/base_cytxxx.cfg]
  40. proc enable_hyperram_1 { {xip_base 0x84000000} } {
  41. global HYPERRAM_LOADER_1
  42. catch {
  43. load_image ../flm/cypress/traveo2/${HYPERRAM_LOADER_1} 0x28000800
  44. reg pc 0x28000800
  45. reg sp 0x28010000
  46. reg r0 $xip_base
  47. reg r1 0
  48. reg r2 3
  49. resume 0x28000800
  50. wait_halt
  51. mrw $xip_base
  52. echo "** HyperRAM mapped to address [format 0x%08X $xip_base]"
  53. }
  54. }