mirror of https://github.com/ARMmbed/mbed-os.git
STM-can-api: Fixed variable name for H7
- can_frequency uses f instead of hz for can frequency - Also added comment to system_clockpull/13565/head
parent
2a13fa199d
commit
73493b909a
|
@ -105,6 +105,9 @@ uint8_t SetSysClock_PLL_HSE(uint8_t bypass)
|
|||
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
|
||||
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSE;
|
||||
RCC_OscInitStruct.PLL.PLLM = RCC_PLLM_DIV6;
|
||||
//! 170MHz as a core frequency for FDCAN is not suitable for many frequencies,
|
||||
//! as it provides low accuracy. When no FDCAN is used, the full capacity of 170 MHz
|
||||
//! should be standard.
|
||||
#if DEVICE_CAN
|
||||
RCC_OscInitStruct.PLL.PLLN = 80;
|
||||
#else
|
||||
|
|
|
@ -287,7 +287,7 @@ int can_frequency(can_t *obj, int f)
|
|||
#else
|
||||
// STM32H7 doesn't support yet HAL_RCCEx_GetPeriphCLKFreq for FDCAN
|
||||
// Internal ST ticket 92465
|
||||
int ntq = 10000000 / hz;
|
||||
int ntq = 10000000 / f;
|
||||
#endif
|
||||
|
||||
int nominalPrescaler = 1;
|
||||
|
|
Loading…
Reference in New Issue