fix: 修改spi时钟频率和时钟源,修改跳频控制时钟源,修改跳频逻辑

This commit is contained in:
2025-05-23 10:57:27 +08:00
parent d3f2a27299
commit b8dda6c20b
15 changed files with 134 additions and 65 deletions
@@ -923,6 +923,7 @@ int32_t Hardware_Init(void)
static int hop_cnt = 0;
static int next_pll_index = 2;
static double curr_freq;
static double hop_freq = MIN_FREQ + FREQ_SEP;
static double next_freq = MIN_FREQ;
@@ -943,7 +944,11 @@ int32_t Hardware_Init(void)
}
else
{
next_freq = (curr_freq + FREQ_SEP > MAX_FREQ) ? MIN_FREQ : curr_freq + FREQ_SEP;
hop_freq += FREQ_SEP;
if( hop_freq > MAX_FREQ){
hop_freq = MIN_FREQ + FREQ_SEP;
}
next_freq = hop_freq;
}
if (next_pll_index == 2)