AnsweredAssumed Answered

Configuring non-JTAG pins on PORTA breaks JTAG with K24

Question asked by Ryan Lush on Feb 5, 2018
Latest reply on Feb 6, 2018 by Ryan Lush

This bit of code seems to kill my JTAG. None of these signals are associated with JTAG so I don't understand what the problem is. I have commented them out one after another and any one of the GPIO_PinInit functions kills the communication. The only one that kinda makes sense is PA4 being the EzPort CS/NMI but the rest of them make no sense at all. Any idea what I'm doing wrong here?

 

#define ANT_BOOT_PORT           PORTA
#define ANT_BOOT_PIN            4
#define ANT_BOOT_CFG            kGPIO_DigitalOutput
#define ANT_BOOT_MUX            kPORT_MuxAsGpio
        
#define ANT_RST_PORT            PORTA
#define ANT_RST_PIN             6
#define ANT_RST_CFG             kGPIO_DigitalOutput
#define ANT_RST_MUX             kPORT_MuxAsGpio
        
#define OLED_RS_PORT            PORTA
#define OLED_RS_PIN             24
#define OLED_RS_CFG             kGPIO_DigitalOutput
#define OLED_RS_MUX             kPORT_MuxAsGpio
        
#define OLED_RST_PORT           PORTA
#define OLED_RST_PIN            25
#define OLED_RST_CFG            kGPIO_DigitalOutput
#define OLED_RST_MUX            kPORT_MuxAsGpio
        
#define OLED_PWR_PORT           PORTA
#define OLED_PWR_PIN            26
#define OLED_PWR_CFG            kGPIO_DigitalOutput
#define OLED_PWR_MUX            kPORT_MuxAsGpio

 

    ///////////////////////////////
    ////////// PORTA //////////////
    ///////////////////////////////
    CLOCK_EnableClock(kCLOCK_PortA);

 

    // GPIO    
    PORT_SetPinMux(ANT_BOOT_PORT,  ANT_BOOT_PIN, ANT_BOOT_MUX);         
    PORT_SetPinMux(ANT_RST_PORT,   ANT_RST_PIN,  ANT_RST_MUX);         
    PORT_SetPinMux(OLED_RS_PORT,   OLED_RS_PIN,  OLED_RS_MUX);         
    PORT_SetPinMux(OLED_RST_PORT,  OLED_RST_PIN, OLED_RST_MUX);         
    PORT_SetPinMux(OLED_PWR_PORT,  OLED_PWR_PIN, OLED_PWR_MUX);         

 

    GPIO_PinInit(ANT_BOOT_PORT,  ANT_BOOT_PIN, &(gpio_pin_config_t){ANT_BOOT_CFG, 0} );      // PA4
    GPIO_PinInit(ANT_RST_PORT,   ANT_RST_PIN,  &(gpio_pin_config_t){ANT_RST_CFG,  0} );            // PA6
    GPIO_PinInit(OLED_RS_PORT,   OLED_RS_PIN,  &(gpio_pin_config_t){OLED_RS_CFG,  0} );           // PA24
    GPIO_PinInit(OLED_RST_PORT,  OLED_RST_PIN, &(gpio_pin_config_t){OLED_RST_CFG, 0} );        // PA25
    GPIO_PinInit(OLED_PWR_PORT,  OLED_PWR_PIN, &(gpio_pin_config_t){OLED_PWR_CFG, 0} );    // PA26

Outcomes