Hi @Chavira
Thanks for your response.
My original problem was that I wanted to switch the debug console UART on Cortex-M4 core 0 to another UART, because the default pin (M40_UART) used in the SDK hello_world example is already in use by another core on my board. That’s why I needed to understand what the instance field in hal_uart_config_t really meant. In DbgConsole_Init() I need to pass that value.
After checking some files related to that function. in MIMX8QM6_cm4_core0.h I found the definitions of the uart base address.
/** Array initializer of LPUART peripheral base addresses */
#define LPUART_BASE_ADDRS { CM4_0__LPUART_BASE, CM4_1__LPUART_BASE, DMA__LPUART0_BASE, DMA__LPUART1_BASE, DMA__LPUART2_BASE, DMA__LPUART3_BASE, DMA__LPUART4_BASE, SCU__LPUART_BASE }
/** Array initializer of LPUART peripheral base pointers */
#define LPUART_BASE_PTRS { CM4_0__LPUART, CM4_1__LPUART, DMA__LPUART0, DMA__LPUART1, DMA__LPUART2, DMA__LPUART3, DMA__LPUART4, SCU__LPUART }
So the instance field is just the index into this array of base addresses (?). It works anyway. Thanks
Best Regards,
io