Dear all,
I want to use lpuart polling example on SDK, the demo_example is LPUART1, but I want to use LPUART2.
Then I add pin_mux and set the clock, then debug console print as below:
ASSERT ERROR " (reg & PCC_CLKCFG_PR_MASK) != 0UL ": file "/home/wendy/workspace/imx8ulp-m33/devices/MIMX8UD7/drivers/fsl_clock.c" Line "300" function name "CLOCK_SetIpSrc"
This is my add:
Solved! Go to Solution.
Thanks for your update. please follow below thread for this question. Re: imx8ulp m33 core gpio - NXP Community
I add clock in ATF: plat/imx/imx8ulp/imx8ulp_bl31_setup.c:
mmio_write_32(0x28102000+ 0x2c, 0x80000000);
But it doesn't work
Hi @wendy-liu :
LPUART2 is in DPS domain, is designed for DSP core, not for CM33. CM33 can not control it.
please check the reference manual.
Regards
Daniel
LPUART0 and LPUART1 are in CM33 real time domain.
I know, but how to enable LPUART2 on DSP domain?
Hi @wendy-liu :
The error message is from function CLOCK_SetIpSrc, can you debug and check the value of reg?
Regards
Daniel
The reg of PCC_LPUART2 is always 0.
Please try below lines.
const cgc_rtd_sys_clk_config_t g_sysClkConfigFroSource = {
.divCore = 0, /* Core clock divider. */
.divBus = 1, /* Bus clock divider. */
.divSlow = 3, /* Slow clock divider. */
.src = kCGC_RtdSysClkSrcFro, /* System clock source. */
.locked = 0, /* Register not locked. */
};
CLOCK_SetFusionSysClkConfig(&g_sysClkConfigFroSource);
BOARD_InitPins();
BOARD_BootClockRUN();
BOARD_InitDebugConsole();
Fusion_Init();
BOARD_SetTrdcGlobalConfig();
rate = CLOCK_GetFreq(kCLOCK_FusionDspBusClk);
PRINTF("The rate is 0x%x. \r\n", rate);
CLOCK_SetIpSrc(kCLOCK_Lpuart2, kCLOCK_Pcc2BusIpSrcFusionDspBus);
Any support, information, and technology (“Materials”) provided by NXP are provided AS IS, without any warranty express or implied, and NXP disclaims all direct and indirect liability and damages in connection with the Material to the maximum extent permitted by the applicable law. NXP accepts no liability for any assistance with applications or product design. Materials may only be used in connection with NXP products. Any feedback provided to NXP regarding the Materials may be used by NXP without restriction.
I have already enabled LPUART2, but I'm having some issues with API “LPUART_WriteBlocking” I'm currently using.
Thanks for your update. please follow below thread for this question. Re: imx8ulp m33 core gpio - NXP Community
yes, I read reg of LPUART1 and LPUART2 CLOCK, result is 0xd2000000 and 0.
Now, I 'm working with TRDC for eDMA access.
I add some configutation in
did you initialize the DSP core (Fusion_Init) before you call CLOCK_SetIpSrc?