how to init clock with mk02

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

how to init clock with mk02

ソリューションへジャンプ
1,306件の閲覧回数
jackxu
Contributor III

pastedImage_1.png

pastedImage_2.png

pastedImage_3.png

pastedImage_7.png

Hi there,

what i can set about the "fllStableDelay"

CLOCK_BootToFeeMode(g_defaultClockConfigRun.mcgConfig.oscsel, g_defaultClockConfigRun.mcgConfig.frdiv,
g_defaultClockConfigRun.mcgConfig.dmx32, g_defaultClockConfigRun.mcgConfig.drs,fllStableDelay);

Thanks in advance!

-Jack

1 解決策
1,111件の閲覧回数
isaacavila
NXP Employee
NXP Employee

Hello Jack,

This pointer to function passes a delay function that will be executed after FLL is configured, this is done to make sure that FLL is stable after/during clock transition. If you do not want to execute any delay function, you can pass NULL pointer.

On the other hand, if you want to execute one delay function, you can use the CLOCK_FllStableDelay function as reference. This function waits for 1 ms aproximately.

static void CLOCK_FllStableDelay(void)
{
    /*
       Should wait at least 1ms. Because in these modes, the core clock is 100MHz
       at most, so this function could obtain the 1ms delay.
     */
    volatile uint32_t i = 30000U;
    while (i--)
    {
        __NOP();
    }
}

I hope this can help you!

Best Regards,

Isaac

元の投稿で解決策を見る

1 返信
1,112件の閲覧回数
isaacavila
NXP Employee
NXP Employee

Hello Jack,

This pointer to function passes a delay function that will be executed after FLL is configured, this is done to make sure that FLL is stable after/during clock transition. If you do not want to execute any delay function, you can pass NULL pointer.

On the other hand, if you want to execute one delay function, you can use the CLOCK_FllStableDelay function as reference. This function waits for 1 ms aproximately.

static void CLOCK_FllStableDelay(void)
{
    /*
       Should wait at least 1ms. Because in these modes, the core clock is 100MHz
       at most, so this function could obtain the 1ms delay.
     */
    volatile uint32_t i = 30000U;
    while (i--)
    {
        __NOP();
    }
}

I hope this can help you!

Best Regards,

Isaac