Skip to main content
ANTTI LEINONEN
Visitor II
February 17, 2017
Question

How to change from JTAG-DP to SW-DP (ARM Cortex-M4)

Posted on February 17, 2017 at 07:53

Hello, Entering SW-DP mode can be done by following instructions in RM0351 chapter 44.3.1. External TCK/TMS sequence is required.

Is there any other way to change from JTAG-DP to SW-DP? With ARM Cortex-M3 this can be done as described in RM0008 chapter 9.4.2 AF remap and debug I/O configuration register (AFIO_MAPR)

    This topic has been closed for replies.

    2 replies

    Mikas Longbardi
    Associate III
    August 15, 2017
    Posted on August 15, 2017 at 02:05

    Its annoying for sure and as you mention seams to be a ''tool vendor issue'' since F4/M4 dont have any AFIO_MAPR.

    john doe
    Senior III
    August 15, 2017
    Posted on August 15, 2017 at 04:57

    They dont have a MAPR but they do have an AFR. GPIOx->AFR[0], for instance.

    GPIOA->AFR[0]:  0x20007701    00100000000000000111011100000001

      PIN  0: TIM2_CH1

      PIN  1:  -

      PIN  2: USART2_TX

      PIN  3: USART2_RX

      PIN  4:  -

      PIN  5:  -

      PIN  6:  -

      PIN  7: TIM3_CH2

    GPIOA->AFR[1]:  0x00000000    00000000000000000000000000000000