Loading...
Searching...
No Matches
periph_cpu.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2021 Freie Universität Berlin
3 *
4 * This file is subject to the terms and conditions of the GNU Lesser
5 * General Public License v2.1. See the file LICENSE in the top level
6 * directory for more details.
7 */
8
20#ifndef PERIPH_WL_PERIPH_CPU_H
21#define PERIPH_WL_PERIPH_CPU_H
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
27#ifndef DOXYGEN
28
32#define ADC_T_ADCVREG_STUP_US (20)
33
37#define ADC_DEVS (1U)
38
43#define HAVE_ADC_RES_T
44typedef enum {
45 ADC_RES_6BIT = (ADC_CFGR1_RES),
46 ADC_RES_8BIT = (ADC_CFGR1_RES_1),
47 ADC_RES_10BIT = (ADC_CFGR1_RES_0),
48 ADC_RES_12BIT = (0x0),
49 ADC_RES_14BIT = (0x1),
50 ADC_RES_16BIT = (0x2)
51} adc_res_t;
58#define STM32_BOOTLOADER_ADDR (0x1FFF0000)
59
64#define VBAT_ADC_RES ADC_RES_12BIT
65#define VBAT_ADC_MAX 4095
68#endif /* ndef DOXYGEN */
69
80#define CPU_STM32WL_SUBGHZSPI_DEBUG_MOSIOUT GPIO_PIN(PORT_A, 7)
81#define CPU_STM32WL_SUBGHZSPI_DEBUG_MOSIOUT_AF GPIO_AF13
82
83#define CPU_STM32WL_SUBGHZSPI_DEBUG_MISOOUT GPIO_PIN(PORT_A, 6)
84#define CPU_STM32WL_SUBGHZSPI_DEBUG_MISOOUT_AF GPIO_AF13
85
86#define CPU_STM32WL_SUBGHZSPI_DEBUG_SCKOUT GPIO_PIN(PORT_A, 5)
87#define CPU_STM32WL_SUBGHZSPI_DEBUG_SCKOUT_AF GPIO_AF13
88
89#define CPU_STM32WL_SUBGHZSPI_DEBUG_NSSOUT GPIO_PIN(PORT_A, 4)
90#define CPU_STM32WL_SUBGHZSPI_DEBUG_NSSOUT_AF GPIO_AF13
102#define CPU_STM32WL_SUBGHZ_RF_BUSY GPIO_PIN(PORT_A, 12)
106#define CPU_STM32WL_SUBGHZ_RF_BUSY_AF GPIO_AF6
107
111#define CPU_STM32WL_SUBGHZ_DEBUG_RF_NRESET GPIO_PIN(PORT_A, 11)
115#define CPU_STM32WL_SUBGHZ_DEBUG_RF_NRESET_AF GPIO_AF13
116
120#define CPU_STM32WL_SUBGHZ_DEBUG_RF_SMPSRDY GPIO_PIN(PORT_B, 2)
124#define CPU_STM32WL_SUBGHZ_DEBUG_RF_SMPSRDY_AF GPIO_AF13
125
129#define CPU_STM32WL_SUBGHZ_DEBUG_RF_LDORDY GPIO_PIN(PORT_B, 4)
133#define CPU_STM32WL_SUBGHZ_DEBUG_RF_LDORDY_AF GPIO_AF13
134
138#define CPU_STM32WL_SUBGHZ_DEBUG_RF_HSE32RDY GPIO_PIN(PORT_A, 10)
142#define CPU_STM32WL_SUBGHZ_DEBUG_RF_HSE32RDY_AF GPIO_AF13
154#ifdef DOXYGEN
155#define CONFIG_STM32_WLX5XX_SUBGHZ_DEBUG
156#endif
159#ifdef __cplusplus
160}
161#endif
162
163#endif /* PERIPH_WL_PERIPH_CPU_H */
adc_res_t
Possible ADC resolution settings.
Definition adc.h:93
@ ADC_RES_16BIT
ADC resolution: 16 bit.
Definition adc.h:99
@ ADC_RES_8BIT
ADC resolution: 8 bit.
Definition adc.h:95
@ ADC_RES_14BIT
ADC resolution: 14 bit.
Definition adc.h:98
@ ADC_RES_6BIT
ADC resolution: 6 bit.
Definition adc.h:94
@ ADC_RES_10BIT
ADC resolution: 10 bit.
Definition adc.h:96
@ ADC_RES_12BIT
ADC resolution: 12 bit.
Definition adc.h:97