adc_arch_private.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2022 Gunar Schorcht
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 ADC_ARCH_PRIVATE_H
21 #define ADC_ARCH_PRIVATE_H
22 
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26 
27 #include "hal/adc_types.h"
28 #include "periph/gpio.h"
29 
30 #ifndef DOXYGEN /* hide implementation details from doxygen */
31 
32 #define RTCIO_GPIO(n) n /* n-th RTCIO GPIO */
33 #define RTCIO_NA UINT8_MAX /* RTCIO pin not available */
34 
38 typedef struct {
39  uint8_t rtc_gpio;
40  gpio_t gpio;
41  adc_unit_t adc_ctrl;
42  adc_channel_t adc_channel;
43  char* pad_name;
44 } _adc_hw_desc_t;
45 
52 extern const _adc_hw_desc_t _adc_hw[];
53 
57 extern const gpio_t _gpio_rtcio_map[];
58 
59 #endif /* !DOXYGEN */
60 
61 #ifdef __cplusplus
62 }
63 #endif
64 
65 #endif /* ADC_ARCH_PRIVATE_H */
Low-level GPIO peripheral driver interface definitions.