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.
 
 
 
 
 
 

26 lines
923 B

  1. # ARM Debug Interface V5 (ADI_V5) utility
  2. # ... Mostly for SWJ-DP (not SW-DP or JTAG-DP, since
  3. # SW-DP and JTAG-DP targets don't need to switch based
  4. # on which transport is active.
  5. #
  6. # declare a JTAG or SWD Debug Access Point (DAP)
  7. # based on the transport in use with this session.
  8. # You can't access JTAG ops when SWD is active, etc.
  9. # params are currently what "jtag newtap" uses
  10. # because OpenOCD internals are still strongly biased
  11. # to JTAG .... but for SWD, "irlen" etc are ignored,
  12. # and the internals work differently
  13. # for now, ignore non-JTAG and non-SWD transports
  14. # (e.g. initial flash programming via SPI or UART)
  15. # split out "chip" and "tag" so we can someday handle
  16. # them more uniformly irlen too...)
  17. proc swj_newdap {chip tag args} {
  18. set tran [transport select]
  19. if [string equal $tran "jtag"] { eval jtag newtap $chip $tag $args}
  20. if [string equal $tran "swd"] { eval swd newdap $chip $tag $args }
  21. }