Print system clock and bus clocks over UART2. More...
#include "navhal.h"
Macros | |
| #define | CORTEX_M4 |
Functions | |
| int | main (void) |
Variables | |
| hal_pll_config_t | pll_cfg |
| PLL configuration: 8 MHz HSE -> 168 MHz system clock. | |
| hal_clock_config_t | cfg |
| System clock source configuration. | |
Print system clock and bus clocks over UART2.
This example demonstrates:
© 2025 NAVROBOTEC PVT. LTD. All rights reserved.
| #define CORTEX_M4 |
| int main | ( | void | ) |
< Initialize system clock with PLL
< Initialize SysTick with 40 µs tick
< Initialize UART2 at 9600 baud
< Print SYSCLK label
< Print system clock
< Print APB1CLK label
< Print APB1 clock
< Print APB2CLK label
< Print APB2 clock
< Print AHBCLK label
< Print AHB clock
< Newline
< Wait 1 second
System clock source configuration.
| hal_pll_config_t pll_cfg |
PLL configuration: 8 MHz HSE -> 168 MHz system clock.