From 0626f6f75d748acd4a689589cabf5d2151864714 Mon Sep 17 00:00:00 2001 From: Karl Palsson Date: Sat, 22 Jun 2019 01:08:22 +0000 Subject: [PATCH] doc: efm32: adc: enable peripheral_apis style --- include/libopencm3/efm32/common/adc_common.h | 12 ++++++------ include/libopencm3/efm32/ezr32wg/adc.h | 14 ++++++++++---- include/libopencm3/efm32/lg/adc.h | 13 ++++++++++--- include/libopencm3/efm32/wg/adc.h | 14 ++++++++++---- lib/efm32/common/adc_common.c | 7 +++++++ 5 files changed, 43 insertions(+), 17 deletions(-) diff --git a/include/libopencm3/efm32/common/adc_common.h b/include/libopencm3/efm32/common/adc_common.h index cc41c197..0ce80a41 100644 --- a/include/libopencm3/efm32/common/adc_common.h +++ b/include/libopencm3/efm32/common/adc_common.h @@ -1,3 +1,5 @@ +/** @addtogroup adc_defines + */ /* * This file is part of the libopencm3 project. * @@ -17,8 +19,9 @@ * along with this library. If not, see . */ -#ifndef LIBOPENCM3_EFM32_ADC_H -#define LIBOPENCM3_EFM32_ADC_H +/**@{*/ + +#pragma once #include #include @@ -340,8 +343,6 @@ #define ADC0_BIASPROG ADC_BIASPROG(ADC0) /** @defgroup adc_ch ADC Channel Number -@ingroup adc_defines - @{*/ #define ADC_CH0 0 #define ADC_CH1 1 @@ -453,5 +454,4 @@ void adc_set_calibration_single_offset(uint32_t adc, uint8_t single_offset); END_DECLS -#endif - +/**@}*/ \ No newline at end of file diff --git a/include/libopencm3/efm32/ezr32wg/adc.h b/include/libopencm3/efm32/ezr32wg/adc.h index f06b9492..16269311 100644 --- a/include/libopencm3/efm32/ezr32wg/adc.h +++ b/include/libopencm3/efm32/ezr32wg/adc.h @@ -1,3 +1,12 @@ +/** @defgroup adc_defines ADC Defines + * + * @brief Defined Constants and Types for the EZR32WG Analog to Digital + * Converter + * + * @ingroup EZR32WG_defines + * + * LGPL License Terms @ref lgpl_license + */ /* * This file is part of the libopencm3 project. * @@ -17,9 +26,6 @@ * along with this library. If not, see . */ -#ifndef LIBOPENCM3_EFM32_EZR32WG_ADC_H -#define LIBOPENCM3_EFM32_EZR32WG_ADC_H +#pragma once #include - -#endif diff --git a/include/libopencm3/efm32/lg/adc.h b/include/libopencm3/efm32/lg/adc.h index 5432ce64..3e8d4f5e 100644 --- a/include/libopencm3/efm32/lg/adc.h +++ b/include/libopencm3/efm32/lg/adc.h @@ -1,3 +1,12 @@ +/** @defgroup adc_defines ADC Defines + * + * @brief Defined Constants and Types for the EFM32LG Analog to Digital + * Converter + * + * @ingroup EFM32LG_defines + * + * LGPL License Terms @ref lgpl_license + */ /* * This file is part of the libopencm3 project. * @@ -17,9 +26,7 @@ * along with this library. If not, see . */ -#ifndef LIBOPENCM3_EFM32_LG_ADC_H -#define LIBOPENCM3_EFM32_LG_ADC_H +#pragma once #include -#endif diff --git a/include/libopencm3/efm32/wg/adc.h b/include/libopencm3/efm32/wg/adc.h index 3d6e07f3..bdfadc37 100644 --- a/include/libopencm3/efm32/wg/adc.h +++ b/include/libopencm3/efm32/wg/adc.h @@ -1,3 +1,12 @@ +/** @defgroup adc_defines ADC Defines + * + * @brief Defined Constants and Types for the EFM32WG Analog to Digital + * Converter + * + * @ingroup EFM32WG_defines + * + * LGPL License Terms @ref lgpl_license + */ /* * This file is part of the libopencm3 project. * @@ -17,9 +26,6 @@ * along with this library. If not, see . */ -#ifndef LIBOPENCM3_EFM32_WG_ADC_H -#define LIBOPENCM3_EFM32_WG_ADC_H +#pragma once #include - -#endif diff --git a/lib/efm32/common/adc_common.c b/lib/efm32/common/adc_common.c index f1d14aeb..4c7a1481 100644 --- a/lib/efm32/common/adc_common.c +++ b/lib/efm32/common/adc_common.c @@ -1,3 +1,6 @@ +/** @addtogroup adc_file ADC peripheral API + * @ingroup peripheral_apis + */ /* * This file is part of the libopencm3 project. * @@ -19,6 +22,8 @@ #include +/**@{*/ + /** * Set ADC over sampling * @param[in] adc ADC (use ADCx) @@ -669,3 +674,5 @@ void adc_set_calibration_single_offset(uint32_t adc, uint8_t single_offset) { ADC_CAL(adc) = (ADC_CAL(adc) & ADC_CAL_SINGLEOFF_MASK) | single_offset; } + +/**@}*/ \ No newline at end of file