Hi Jun,
thanks for testing.
I double checked your code again and found you removed the following two lines on the line 247 which I had recommended:
LL_AHB1_GRP1_DisableClockLowPower(RCC_AHB1LPENR_OTGHSULPILPEN);
LL_AHB1_GRP1_EnableClockLowPower(RCC_AHB1LPENR_OTGHSLPEN);
Why do you enable the clocks in low power mode?
Line 260 in my tree
LL_AHB1_GRP1_DisableClock(LL_AHB1_GRP1_PERIPH_OTGHSULPI); disables
ULPI clock.
OTG_HS clock is enabled by lines 184-187.
STM32Cube HAL defines:
#define LL_AHB1_GRP1_PERIPH_OTGHS RCC_AHB1ENR_OTGHSEN
#define LL_AHB1_GRP1_PERIPH_OTGHSULPI RCC_AHB1ENR_OTGHSULPIEN
and functions LL_AHB1_GRP1_EnableClock, LL_AHB1_GRP1_DisableClock,
LL_AHB1_GRP1_DisableClockLowPower,
LL_AHB1_GRP1_EnableClockLowPower mentions
LL_AHB1_GRP1_PERIPH_OTGHSULPI and LL_AHB1_GRP1_PERIPH_OTGHSULPI
as valid parameters.
Could you check again I found a typo in ifdefs which didn't disable ULPI clock?
Yannis