Closed MulattoKid closed 4 months ago
See ZD 17479
One thing I forgot to mention was that in uart_init
in hal/imx_rt.c
I had to specifically configure the pins used for debug output like so:
CLOCK_EnableClock(kCLOCK_Iomuxc);
IOMUXC_SetPinMux(IOMUXC_GPIO_AD_B0_12_LPUART1_TX, 0U);
IOMUXC_SetPinMux(IOMUXC_GPIO_AD_B0_13_LPUART1_RX, 0U);
IOMUXC_SetPinConfig(IOMUXC_GPIO_AD_B0_12_LPUART1_TX, 0x10B0U);
IOMUXC_SetPinConfig(IOMUXC_GPIO_AD_B0_13_LPUART1_RX, 0x10B0U);
When not doing this, I didn't get any debug output from the bootloader. I did compile with
DEBUG_UART?=1
PRINTF_ENABLED?=1
in my .config
. Not sure if I'm missing something?
Hi @MulattoKid ,
Thank you so much for this PR. Your contributor agreement has been accepted and placed on file.
We've assigned this PR to @bigbrett for review.
Thanks, David Garske, wolfSSL
One thing I forgot to mention was that in
uart_init
inhal/imx_rt.c
I had to specifically configure the pins used for debug output like so:CLOCK_EnableClock(kCLOCK_Iomuxc); IOMUXC_SetPinMux(IOMUXC_GPIO_AD_B0_12_LPUART1_TX, 0U); IOMUXC_SetPinMux(IOMUXC_GPIO_AD_B0_13_LPUART1_RX, 0U); IOMUXC_SetPinConfig(IOMUXC_GPIO_AD_B0_12_LPUART1_TX, 0x10B0U); IOMUXC_SetPinConfig(IOMUXC_GPIO_AD_B0_13_LPUART1_RX, 0x10B0U);
When not doing this, I didn't get any debug output from the bootloader. I did compile with
DEBUG_UART?=1 PRINTF_ENABLED?=1
in my
.config
. Not sure if I'm missing something?
@MulattoKid Not sure off the top of my head, I will look into this more. It doesn't appear that the hal layer does this pin mux initialization, which could be why printouts don't show up. Regardless, I don't want this to block your PR.
Thanks for the quick responses :)
This PR adds support for
MIMXRT1042XJM5B
. I've tested this locally on the EVK and a custom PCB, and it works on both.My approach was:
make
and fix compilation warnings for bothwolfBoot
and the test applicationI added local support for patching the test app's ELF file to add the signature to it. Doing so I could flash both
wolfBoot
and the test app throughVSCode
, and was able to get to both binariesmain
entrypoints.I've not tested that this doesn't break any of the other RT targets.
@danielinux This is the support we discussed during our call. Hopefully this can help getting 1042 support included in
wolfBoot
.Kind regards, Daniel