K64F Ethernet + UART3

03 Apr 2018

Hello, unfortunately it is not possible to use Ethernet together with Serial (UART3) under mbed. I found the reason under hardware_init_MK64F12.c file where pins PTC16 and PTC17 are used for network. When I disabled the PortC clock and pins change, everything works fine. If it is valid change can you make these corrections in future releases? Thank you and have a nice day. With best regards David

void k64f_init_eth_hardware(void)
{
    port_pin_config_t configENET = {0};

#ifndef FEATURE_UVISOR
    /* Disable MPU only when uVisor is not around. */
    MPU->CESR &= ~MPU_CESR_VLD_MASK;
#endif/*FEATURE_UVISOR*/

//    CLOCK_EnableClock(kCLOCK_PortC);
    CLOCK_EnableClock(kCLOCK_PortB);
    /* Affects PORTC_PCR16 register */
//    PORT_SetPinMux(PORTC, 16u, kPORT_MuxAlt4);
    /* Affects PORTC_PCR17 register */
//    PORT_SetPinMux(PORTC, 17u, kPORT_MuxAlt4);
    /* Affects PORTC_PCR18 register */
//    PORT_SetPinMux(PORTC, 18u, kPORT_MuxAlt4);
    /* Affects PORTC_PCR19 register */
//    PORT_SetPinMux(PORTC, 19u, kPORT_MuxAlt4);
    /* Affects PORTB_PCR1 register */
    PORT_SetPinMux(PORTB, 1u, kPORT_MuxAlt4);
26 Mar 2019

Hello,

I would like to say "me too". I can't find in the schematic that these pins are connected to any of the ethernet chips. If I comment out PTC16 and PTC17 (like David did), then everything seems to work fine.