资源简介
STM8S105C6例程
代码片段和文件信息
/**
******************************************************************************
* @file stm8s_adc1.c
* @brief This file contains all the functions/macros for the ADC1 peripheral.
* @author STMicroelectronics - MCD Application Team
* @version V1.1.1
* @date 06/05/2009
******************************************************************************
*
* THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
* WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE
* TIME. AS A RESULT STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY
* DIRECT INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING
* FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE
* CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
*
* © COPYRIGHT 2009 STMicroelectronics
* @image html logo.bmp
******************************************************************************
*/
/* Includes ------------------------------------------------------------------*/
#include “stm8s_adc1.h“
/* Private typedef -----------------------------------------------------------*/
/* Private define ------------------------------------------------------------*/
/* Private macro -------------------------------------------------------------*/
/* Private variables ---------------------------------------------------------*/
/* Private function prototypes -----------------------------------------------*/
/* Private functions ---------------------------------------------------------*/
/* Public functions ----------------------------------------------------------*/
/**
* @addtogroup ADC1_Public_Functions
* @{
*/
/**
* @brief Deinitializes the ADC1 peripheral registers to their default reset
* values.
* @par Parameters:
* None
* @retval None
*/
void ADC1_DeInit(void)
{
ADC1->CSR = ADC1_CSR_RESET_VALUE;
ADC1->CR1 = ADC1_CR1_RESET_VALUE;
ADC1->CR2 = ADC1_CR2_RESET_VALUE;
ADC1->CR3 = ADC1_CR3_RESET_VALUE;
ADC1->TDRH = ADC1_TDRH_RESET_VALUE;
ADC1->TDRL = ADC1_TDRL_RESET_VALUE;
ADC1->HTRH = ADC1_HTRH_RESET_VALUE;
ADC1->HTRL = ADC1_HTRL_RESET_VALUE;
ADC1->LTRH = ADC1_LTRH_RESET_VALUE;
ADC1->LTRL = ADC1_LTRL_RESET_VALUE;
ADC1->AWCRH = ADC1_AWCRH_RESET_VALUE;
ADC1->AWCRL = ADC1_AWCRL_RESET_VALUE;
}
/**
* @brief Initializes the ADC1 peripheral according to the specified parameters
* @param[in] ADC1_ConversionMode: specifies the conversion mode
* can be one of the values of @ref ADC1_ConvMode_TypeDef.
* @param[in] ADC1_Channel: specifies the channel to convert
* can be one of the values of @ref ADC1_Channel_TypeDef.
* @param[in] ADC1_PrescalerSelection: specifies the ADC1 prescaler
* can be one of the values of @ref ADC1_PresSel_TypeDef.
* @param[in] ADC1_ExtTrigger: specifies the external trigger
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2020-06-03 11:32 Debug\
目录 0 2020-06-03 11:32 Debug\Exe\
文件 865608 2020-06-03 11:32 Debug\Exe\FWLib.a
目录 0 2020-06-03 11:32 Debug\List\
目录 0 2020-06-03 11:32 Debug\Obj\
文件 641187 2020-06-03 11:32 Debug\Obj\FWLib.pbd
文件 641187 2020-06-03 11:32 Debug\Obj\FWLib.pbd.browse
文件 24182 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_API.o
文件 172782 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_API.pbi
文件 10675 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_API.pbi.cout
文件 29078 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_IODriver.o
文件 173888 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_IODriver.pbi
文件 10680 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_IODriver.pbi.cout
文件 3153 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_MultiChannelKey.o
文件 167382 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_MultiChannelKey.pbi
文件 10687 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_MultiChannelKey.pbi.cout
文件 33906 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_Services.o
文件 172664 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_Services.pbi
文件 10680 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_Services.pbi.cout
文件 29425 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_SingleChannelKey.o
文件 174052 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_SingleChannelKey.pbi
文件 10688 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_SingleChannelKey.pbi.cout
文件 18904 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_TimerDriver.o
文件 164163 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_TimerDriver.pbi
文件 10683 2020-06-03 11:32 Debug\Obj\STM8_TSL_RC_TimerDriver.pbi.cout
文件 46951 2020-06-03 11:32 Debug\Obj\stm8s_adc1.o
文件 165974 2020-06-03 11:32 Debug\Obj\stm8s_adc1.pbi
文件 10668 2020-06-03 11:32 Debug\Obj\stm8s_adc1.pbi.cout
文件 17330 2020-06-03 11:32 Debug\Obj\stm8s_awu.o
文件 140113 2020-06-03 11:32 Debug\Obj\stm8s_awu.pbi
文件 10667 2020-06-03 11:32 Debug\Obj\stm8s_awu.pbi.cout
............此处省略140个文件信息
评论
共有 条评论