File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
source/hic_hal/nxp/lpc4322 Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -465,7 +465,7 @@ static void SetClock (void) {
465465
466466 /* CPU base clock is in the mid frequency range before final clock set */
467467 LPC_CGU -> BASE_M4_CLK = (0x01 << 11 ) | /* Autoblock En */
468- (0x09 << 24 ) ; /* Clock source: PLL1 */
468+ (CLK_SRC_PLL1 << 24 ) ; /* Clock source: PLL1 */
469469
470470 /* Wait 20us */
471471 WaitUs (20 , (CLK_XTAL * (PLL1_MSEL + 1 )) / ((PLL1_NSEL + 1 ) * 2 ));
@@ -576,7 +576,7 @@ uint32_t MeasureFreq (uint32_t clk_sel) {
576576 }
577577 }
578578 fcnt = (LPC_CGU -> FREQ_MON >> 9 ) & 0x3FFF ;
579- fout = fcnt * (12000000U /511U ); /* FCNT * (IRC_CLK / RCNT) */
579+ fout = fcnt * (CLK_IRC /511U ); /* FCNT * (IRC_CLK / RCNT) */
580580
581581 return (fout );
582582}
You can’t perform that action at this time.
0 commit comments