Hi, Diego
Thanks for your response , actually I still have some other issue want to check.
1. as you response
#define BOOT_PIN_NUMBER 6
This one should be 4 right right ? because the MCU_state pin is PTA4. So it should be number 4 or there is other definition for it ?
Also I have one issues I 'd like to change the boot UART port from UART0( original bootloader define) to UART 4.
2 tings need your help:
1. Because of I am not using EVK for test and my test board is using external clock. Should I modified the BOARD_BootClockRUN_PEE(void) to external clock definition?
2. To change the UART port from 0 to 4
I direct replace the UART0 to UART 4 as follow.
But it still doesn't work could you specific tell me does there have any place I also need to change.
void UART4_InitPins(void)
{
/* Port B Clock Gate Control: Clock enabled */
CLOCK_EnableClock(kCLOCK_PortC);
const port_pin_config_t UART4_RX = {/* Internal pull-up/down resistor is disabled */
kPORT_PullDisable,
/* Fast slew rate is configured */
kPORT_FastSlewRate,
/* Passive filter is disabled */
kPORT_PassiveFilterDisable,
/* Open drain is disabled */
kPORT_OpenDrainDisable,
/* Low drive strength is configured */
kPORT_LowDriveStrength,
/* Pin is configured as UART0_RX */
kPORT_MuxAlt3,
/* Pin Control Register fields [15:0] are not locked */
kPORT_UnlockRegister};
/* PORTD2 (pin C4) is configured as UART2_RX */
PORT_SetPinConfig(PORTC, 14U, &UART4_RX);
const port_pin_config_t UART4_TX = {/* Internal pull-up/down resistor is disabled */
kPORT_PullDisable,
/* Fast slew rate is configured */
kPORT_FastSlewRate,
/* Passive filter is disabled */
kPORT_PassiveFilterDisable,
/* Open drain is disabled */
kPORT_OpenDrainDisable,
/* Low drive strength is configured */
kPORT_LowDriveStrength,
/* Pin is configured as UART0_TX */
kPORT_MuxAlt3,
/* Pin Control Register fields [15:0] are not locked */
kPORT_UnlockRegister};
/* PORTD3 (pin B4) is configured as UART2_TX */
PORT_SetPinConfig(PORTC, 15U, &UART4_TX);
SIM->SOPT5 = ((SIM->SOPT5 &
/* Mask bits to zero which are setting */
(~(SIM_SOPT5_UART0TXSRC_MASK)))
/* UART 0 transmit data source select: UART0_TX pin. */
| SIM_SOPT5_UART0TXSRC(SOPT5_UART0TXSRC_UART_TX));