Loading...
Searching...
No Matches
cpu.h
1/*
2 * SPDX-FileCopyrightText: 2013 Freie Universität Berlin (FUB)
3 * SPDX-License-Identifier: LGPL-2.1-only
4 */
5
6#pragma once
7
12
13#include <stdio.h>
14#include <stdbool.h>
15
16#include "lpc23xx.h"
17#include "arm_cpu.h"
18
19#ifdef __cplusplus
20extern "C" {
21#endif
22
23extern uintptr_t __stack_start;
24
28void cpu_init_pll(void);
29
33void cpu_init_mam(void);
34
38void lpc23xx_pclk_scale(uint32_t source, uint32_t target, uint32_t *pclksel, uint32_t *prescale);
39
43void cpu_init_clks(void);
44
48bool install_irq(int IntNumber, void (*HandlerAddr)(void), int Priority);
49
50#ifdef MODULE_PERIPH
51void gpio_init_ports(void);
52#endif
53
57static inline bool cpu_woke_from_backup(void) {
58 return RSIR == 0;
59}
60
64bool cpu_backup_ram_is_initialized(void);
65
69#define CPU_HAS_BACKUP_RAM (1)
70
71#ifdef __cplusplus
72}
73#endif
74
bool cpu_woke_from_backup(void)
Returns true if the CPU woke up from deep sleep.
uintptr_t __stack_start
end of user stack memory space