Toggle navigation
Documentation
The friendly Operating System for the Internet of Things
periph_conf.h
Go to the documentation of this file.
1
/*
2
* SPDX-FileCopyrightText: 2014 Ludwig Knüpfer <ludwig.knuepfer@fu-berlin.de>
3
* SPDX-License-Identifier: LGPL-2.1-only
4
*/
5
6
#pragma once
7
19
#include "
macros/units.h
"
20
21
#ifdef __cplusplus
22
extern
"C"
{
23
#endif
24
30
#if !defined(CLOCK_CORECLOCK) || defined(DOXYGEN)
31
# define CLOCK_CORECLOCK GHZ(1)
32
#endif
33
37
#define NATIVE_TIMER_MIN_RES 200
38
42
#define RANDOM_NUMOF (1U)
43
44
/* MARK: - Timer peripheral configuration */
49
#define TIMER_NUMOF (1U)
50
#define TIMER_CHANNEL_NUMOF (1U)
56
#if !defined(UART_NUMOF) || defined(DOXYGEN)
57
# define UART_NUMOF (1U)
58
#endif
59
63
#if !defined(PWM_NUMOF) || defined(DOXYGEN)
64
# define PWM_NUMOF (8U)
65
#endif
66
70
#if !defined(QDEC_NUMOF) || defined(DOXYGEN)
71
# define QDEC_NUMOF (8U)
72
#endif
73
74
/* MARK: - I2C configuration (mock implementation) */
79
#if !defined(I2C_NUMOF) || defined(DOXYGEN)
85
# define I2C_NUMOF 1
86
#endif
93
#if !defined(SPI_NUMOF) || defined(DOXYGEN)
103
# define SPI_NUMOF (1U)
104
#endif
105
106
#if !defined(SPI_MAXCS) || defined(DOXYGEN)
113
# define SPI_MAXCS (4U)
114
#endif
115
124
#define SPI_HWCS(x) (UINT_MAX - SPI_MAXCS + x)
127
#ifdef __cplusplus
128
}
129
#endif
130
units.h
Unit helper macros.
Generated on Mon Nov 10 2025 19:30:11 by
1.9.1