lpc176x: Introduce get_pclock_frequency()

Add get_pclock_frequency() - a standard way of obtaining the
peripheral clock frequency.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor
2021-03-24 19:45:43 -04:00
parent 964e3cc456
commit 6cab7bcfcb
6 changed files with 23 additions and 12 deletions

View File

@@ -19,6 +19,7 @@
#define PCLK_USB 31
int is_enabled_pclock(uint32_t pclk);
void enable_pclock(uint32_t pclk);
uint32_t get_pclock_frequency(uint32_t pclk);
void gpio_peripheral(uint32_t gpio, int func, int pullup);
#endif // internal.h