亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? stm32f10x_pwr.c

?? STM32+Grlib
?? C
字號:
/**
  ******************************************************************************
  * @file    stm32f10x_pwr.c
  * @author  MCD Application Team
  * @version V3.5.0
  * @date    11-March-2011
  * @brief   This file provides all the PWR firmware functions.
  ******************************************************************************
  * @attention
  *
  * 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.
  *
  * <h2><center>&copy; COPYRIGHT 2011 STMicroelectronics</center></h2>
  ******************************************************************************
  */

/* Includes ------------------------------------------------------------------*/
#include "stm32f10x_pwr.h"
#include "stm32f10x_rcc.h"

/** @addtogroup STM32F10x_StdPeriph_Driver
  * @{
  */

/** @defgroup PWR 
  * @brief PWR driver modules
  * @{
  */ 

/** @defgroup PWR_Private_TypesDefinitions
  * @{
  */

/**
  * @}
  */

/** @defgroup PWR_Private_Defines
  * @{
  */

/* --------- PWR registers bit address in the alias region ---------- */
#define PWR_OFFSET               (PWR_BASE - PERIPH_BASE)

/* --- CR Register ---*/

/* Alias word address of DBP bit */
#define CR_OFFSET                (PWR_OFFSET + 0x00)
#define DBP_BitNumber            0x08
#define CR_DBP_BB                (PERIPH_BB_BASE + (CR_OFFSET * 32) + (DBP_BitNumber * 4))

/* Alias word address of PVDE bit */
#define PVDE_BitNumber           0x04
#define CR_PVDE_BB               (PERIPH_BB_BASE + (CR_OFFSET * 32) + (PVDE_BitNumber * 4))

/* --- CSR Register ---*/

/* Alias word address of EWUP bit */
#define CSR_OFFSET               (PWR_OFFSET + 0x04)
#define EWUP_BitNumber           0x08
#define CSR_EWUP_BB              (PERIPH_BB_BASE + (CSR_OFFSET * 32) + (EWUP_BitNumber * 4))

/* ------------------ PWR registers bit mask ------------------------ */

/* CR register bit mask */
#define CR_DS_MASK               ((uint32_t)0xFFFFFFFC)
#define CR_PLS_MASK              ((uint32_t)0xFFFFFF1F)


/**
  * @}
  */

/** @defgroup PWR_Private_Macros
  * @{
  */

/**
  * @}
  */

/** @defgroup PWR_Private_Variables
  * @{
  */

/**
  * @}
  */

/** @defgroup PWR_Private_FunctionPrototypes
  * @{
  */

/**
  * @}
  */

/** @defgroup PWR_Private_Functions
  * @{
  */

/**
  * @brief  Deinitializes the PWR peripheral registers to their default reset values.
  * @param  None
  * @retval None
  */
void PWR_DeInit(void)
{
  RCC_APB1PeriphResetCmd(RCC_APB1Periph_PWR, ENABLE);
  RCC_APB1PeriphResetCmd(RCC_APB1Periph_PWR, DISABLE);
}

/**
  * @brief  Enables or disables access to the RTC and backup registers.
  * @param  NewState: new state of the access to the RTC and backup registers.
  *   This parameter can be: ENABLE or DISABLE.
  * @retval None
  */
void PWR_BackupAccessCmd(FunctionalState NewState)
{
  /* Check the parameters */
  assert_param(IS_FUNCTIONAL_STATE(NewState));
  *(__IO uint32_t *) CR_DBP_BB = (uint32_t)NewState;
}

/**
  * @brief  Enables or disables the Power Voltage Detector(PVD).
  * @param  NewState: new state of the PVD.
  *   This parameter can be: ENABLE or DISABLE.
  * @retval None
  */
void PWR_PVDCmd(FunctionalState NewState)
{
  /* Check the parameters */
  assert_param(IS_FUNCTIONAL_STATE(NewState));
  *(__IO uint32_t *) CR_PVDE_BB = (uint32_t)NewState;
}

/**
  * @brief  Configures the voltage threshold detected by the Power Voltage Detector(PVD).
  * @param  PWR_PVDLevel: specifies the PVD detection level
  *   This parameter can be one of the following values:
  *     @arg PWR_PVDLevel_2V2: PVD detection level set to 2.2V
  *     @arg PWR_PVDLevel_2V3: PVD detection level set to 2.3V
  *     @arg PWR_PVDLevel_2V4: PVD detection level set to 2.4V
  *     @arg PWR_PVDLevel_2V5: PVD detection level set to 2.5V
  *     @arg PWR_PVDLevel_2V6: PVD detection level set to 2.6V
  *     @arg PWR_PVDLevel_2V7: PVD detection level set to 2.7V
  *     @arg PWR_PVDLevel_2V8: PVD detection level set to 2.8V
  *     @arg PWR_PVDLevel_2V9: PVD detection level set to 2.9V
  * @retval None
  */
void PWR_PVDLevelConfig(uint32_t PWR_PVDLevel)
{
  uint32_t tmpreg = 0;
  /* Check the parameters */
  assert_param(IS_PWR_PVD_LEVEL(PWR_PVDLevel));
  tmpreg = PWR->CR;
  /* Clear PLS[7:5] bits */
  tmpreg &= CR_PLS_MASK;
  /* Set PLS[7:5] bits according to PWR_PVDLevel value */
  tmpreg |= PWR_PVDLevel;
  /* Store the new value */
  PWR->CR = tmpreg;
}

/**
  * @brief  Enables or disables the WakeUp Pin functionality.
  * @param  NewState: new state of the WakeUp Pin functionality.
  *   This parameter can be: ENABLE or DISABLE.
  * @retval None
  */
void PWR_WakeUpPinCmd(FunctionalState NewState)
{
  /* Check the parameters */
  assert_param(IS_FUNCTIONAL_STATE(NewState));
  *(__IO uint32_t *) CSR_EWUP_BB = (uint32_t)NewState;
}

/**
  * @brief  Enters STOP mode.
  * @param  PWR_Regulator: specifies the regulator state in STOP mode.
  *   This parameter can be one of the following values:
  *     @arg PWR_Regulator_ON: STOP mode with regulator ON
  *     @arg PWR_Regulator_LowPower: STOP mode with regulator in low power mode
  * @param  PWR_STOPEntry: specifies if STOP mode in entered with WFI or WFE instruction.
  *   This parameter can be one of the following values:
  *     @arg PWR_STOPEntry_WFI: enter STOP mode with WFI instruction
  *     @arg PWR_STOPEntry_WFE: enter STOP mode with WFE instruction
  * @retval None
  */
void PWR_EnterSTOPMode(uint32_t PWR_Regulator, uint8_t PWR_STOPEntry)
{
  uint32_t tmpreg = 0;
  /* Check the parameters */
  assert_param(IS_PWR_REGULATOR(PWR_Regulator));
  assert_param(IS_PWR_STOP_ENTRY(PWR_STOPEntry));
  
  /* Select the regulator state in STOP mode ---------------------------------*/
  tmpreg = PWR->CR;
  /* Clear PDDS and LPDS bits */
  tmpreg &= CR_DS_MASK;
  /* Set LPDS bit according to PWR_Regulator value */
  tmpreg |= PWR_Regulator;
  /* Store the new value */
  PWR->CR = tmpreg;
  /* Set SLEEPDEEP bit of Cortex System Control Register */
  SCB->SCR |= SCB_SCR_SLEEPDEEP;
  
  /* Select STOP mode entry --------------------------------------------------*/
  if(PWR_STOPEntry == PWR_STOPEntry_WFI)
  {   
    /* Request Wait For Interrupt */
    __WFI();
  }
  else
  {
    /* Request Wait For Event */
    __WFE();
  }
  
  /* Reset SLEEPDEEP bit of Cortex System Control Register */
  SCB->SCR &= (uint32_t)~((uint32_t)SCB_SCR_SLEEPDEEP);  
}

/**
  * @brief  Enters STANDBY mode.
  * @param  None
  * @retval None
  */
void PWR_EnterSTANDBYMode(void)
{
  /* Clear Wake-up flag */
  PWR->CR |= PWR_CR_CWUF;
  /* Select STANDBY mode */
  PWR->CR |= PWR_CR_PDDS;
  /* Set SLEEPDEEP bit of Cortex System Control Register */
  SCB->SCR |= SCB_SCR_SLEEPDEEP;
/* This option is used to ensure that store operations are completed */
#if defined ( __CC_ARM   )
  __force_stores();
#endif
  /* Request Wait For Interrupt */
  __WFI();
}

/**
  * @brief  Checks whether the specified PWR flag is set or not.
  * @param  PWR_FLAG: specifies the flag to check.
  *   This parameter can be one of the following values:
  *     @arg PWR_FLAG_WU: Wake Up flag
  *     @arg PWR_FLAG_SB: StandBy flag
  *     @arg PWR_FLAG_PVDO: PVD Output
  * @retval The new state of PWR_FLAG (SET or RESET).
  */
FlagStatus PWR_GetFlagStatus(uint32_t PWR_FLAG)
{
  FlagStatus bitstatus = RESET;
  /* Check the parameters */
  assert_param(IS_PWR_GET_FLAG(PWR_FLAG));
  
  if ((PWR->CSR & PWR_FLAG) != (uint32_t)RESET)
  {
    bitstatus = SET;
  }
  else
  {
    bitstatus = RESET;
  }
  /* Return the flag status */
  return bitstatus;
}

/**
  * @brief  Clears the PWR's pending flags.
  * @param  PWR_FLAG: specifies the flag to clear.
  *   This parameter can be one of the following values:
  *     @arg PWR_FLAG_WU: Wake Up flag
  *     @arg PWR_FLAG_SB: StandBy flag
  * @retval None
  */
void PWR_ClearFlag(uint32_t PWR_FLAG)
{
  /* Check the parameters */
  assert_param(IS_PWR_CLEAR_FLAG(PWR_FLAG));
         
  PWR->CR |=  PWR_FLAG << 2;
}

/**
  * @}
  */

/**
  * @}
  */

/**
  * @}
  */

/******************* (C) COPYRIGHT 2011 STMicroelectronics *****END OF FILE****/

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
蜜臀av国产精品久久久久| 亚洲免费观看视频| av在线不卡电影| 国产 日韩 欧美大片| 国产激情视频一区二区三区欧美| 午夜国产不卡在线观看视频| 亚洲国产综合视频在线观看| 亚洲成人自拍偷拍| 日韩av电影免费观看高清完整版 | 4438成人网| 久久久亚洲午夜电影| 18成人在线观看| 日韩精品一二三区| 国产电影一区二区三区| 99精品视频一区| 精品sm在线观看| 欧美精品一区二区在线观看| 中文字幕欧美激情| 亚洲国产视频一区二区| 国产麻豆一精品一av一免费| 在线这里只有精品| 欧美极品xxx| 日本三级亚洲精品| 在线观看三级视频欧美| 久久久99精品免费观看不卡| 1024国产精品| 成人国产在线观看| 亚洲一区中文在线| www.成人在线| 中文字幕av在线一区二区三区| 亚洲午夜久久久久| 欧亚一区二区三区| 亚洲另类在线一区| 欧美亚一区二区| 一区二区三区在线视频观看| 琪琪一区二区三区| 欧美精品久久99| 亚洲成在线观看| 欧美日韩精品欧美日韩精品一 | 欧美美女bb生活片| 五月天视频一区| 日韩欧美一区二区在线视频| 五月婷婷激情综合| 日韩一区二区高清| 韩国成人在线视频| 亚洲欧洲日韩在线| 色婷婷国产精品久久包臀| 亚洲成人免费视频| 日韩欧美一区二区不卡| 国产精品影视在线| 亚洲美女视频一区| 成人激情小说网站| 国产精品污网站| 欧美高清你懂得| 国产福利一区在线| 亚洲香肠在线观看| 久久精品一二三| 91麻豆国产香蕉久久精品| 亚洲国产成人91porn| 2021中文字幕一区亚洲| eeuss国产一区二区三区| 一区二区三区四区av| 日韩精品一区二区三区视频 | 日韩精品影音先锋| 99精品国产一区二区三区不卡| 亚洲国产精品一区二区久久恐怖片| 日韩视频免费观看高清完整版 | 日韩伦理电影网| 91蝌蚪porny| 精品在线免费观看| 亚洲大型综合色站| 亚洲色图欧美在线| 久久精品视频一区二区| 欧美日韩一级二级三级| 97精品久久久午夜一区二区三区 | 欧美激情一区二区三区| 欧美一区二区视频网站| 色综合天天综合网天天狠天天| 激情综合网激情| 精品系列免费在线观看| 日韩av二区在线播放| 秋霞国产午夜精品免费视频| 亚洲综合视频在线| 亚洲午夜免费电影| 亚洲精品成人精品456| 26uuu国产日韩综合| 欧美成人video| 精品日韩在线一区| 久久久综合精品| 国产日韩精品久久久| 国产欧美精品一区二区三区四区| 91精品久久久久久久久99蜜臂| 欧美久久久久久久久久| 欧美日韩大陆一区二区| 91精品国产乱| 欧美videossexotv100| 337p粉嫩大胆色噜噜噜噜亚洲 | 天堂成人国产精品一区| 免费人成在线不卡| 国产一区二区毛片| 91丝袜美女网| 欧美美女一区二区在线观看| 欧美精品视频www在线观看| 在线观看亚洲a| 欧美乱妇一区二区三区不卡视频| 色狠狠av一区二区三区| 色一情一伦一子一伦一区| 欧美色图天堂网| 日韩欧美一级片| 国产精品久久久久久久久久久免费看 | 在线免费观看不卡av| 欧美一区二区人人喊爽| 日本一区二区三区电影| 五月婷婷欧美视频| 91在线观看下载| 国产视频一区在线观看| 一区二区激情小说| 成人h动漫精品一区二| 日韩欧美一级特黄在线播放| 亚洲综合图片区| 成人性视频网站| 欧美一区二区三区影视| 中文字幕亚洲成人| 狠狠久久亚洲欧美| 欧美精品日韩综合在线| 亚洲免费观看高清在线观看| 盗摄精品av一区二区三区| 精品少妇一区二区三区在线播放 | 日韩精品最新网址| 日韩影视精彩在线| 精品视频1区2区| 亚洲国产你懂的| 欧美欧美欧美欧美首页| 亚洲午夜一区二区三区| 欧美性做爰猛烈叫床潮| 亚洲国产日韩一级| 欧美一级片免费看| 视频一区在线视频| 久久综合丝袜日本网| 国产凹凸在线观看一区二区| 日本一区二区视频在线观看| 亚洲国产精品综合小说图片区| 欧美在线免费观看亚洲| 日韩专区一卡二卡| 国产网站一区二区三区| 99精品在线观看视频| 午夜亚洲福利老司机| 久久久国产午夜精品| 色综合网站在线| 免费成人在线影院| 亚洲欧美日韩在线不卡| 制服丝袜一区二区三区| 成人av免费网站| 蜜桃久久久久久| 亚洲美女视频一区| 精品电影一区二区| 欧美日韩国产高清一区二区| 国产精品1024久久| 日日摸夜夜添夜夜添精品视频 | 日韩精品欧美精品| 中文字幕第一页久久| 精品少妇一区二区三区视频免付费| 成人av动漫在线| 国产精品一区二区久久精品爱涩| 亚洲线精品一区二区三区八戒| 欧美国产精品中文字幕| 欧美一区二区三区人| 色悠久久久久综合欧美99| 国产精品性做久久久久久| 秋霞国产午夜精品免费视频 | 色国产精品一区在线观看| 国内精品伊人久久久久av一坑| 一区二区三区资源| 国产精品久久影院| 国产精品午夜在线| 国产精品视频免费看| 中文字幕一区二区三区在线播放 | 99久久免费视频.com| 成人福利在线看| 97se亚洲国产综合在线| 成人免费视频国产在线观看| 不卡区在线中文字幕| 色婷婷久久久综合中文字幕| 色婷婷av一区二区三区gif| 欧美无乱码久久久免费午夜一区| 韩国视频一区二区| 9人人澡人人爽人人精品| 97se亚洲国产综合自在线| 欧美在线不卡视频| 欧美成人伊人久久综合网| 日本一区二区电影| 亚洲综合999| 国产综合成人久久大片91| 99久久精品国产毛片| 日韩欧美卡一卡二| 亚洲欧美另类综合偷拍| 久久99国产精品尤物| 色综合久久久久综合体桃花网| 欧美一区二区三区男人的天堂| 国产情人综合久久777777|