?login_element?

Subversion Repositories NedoOS

Rev

Rev 8 | Blame | Compare with Previous | Last modification | View Log | Download

  1. /**
  2.   ******************************************************************************
  3.   * @file    opora_dac_defs.h
  4.   * @author  Phyton Application Team
  5.   * @version V1.0.0
  6.   * @date
  7.   * @brief   This file contains all the Special Function Registers definitions
  8.   *          for the DAC peripheral unit used in the Milandr OPORA
  9.   *          microcontrollers.
  10.   ******************************************************************************
  11.   * @copy
  12.   *
  13.   * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
  14.   * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE
  15.   * TIME. AS A RESULT, PHYTON SHALL NOT BE HELD LIABLE FOR ANY DIRECT, INDIRECT
  16.   * OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING
  17.   * FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE
  18.   * CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
  19.   *
  20.   * <h2><center>&copy; COPYRIGHT 2010 Phyton</center></h2>
  21.   ******************************************************************************
  22.   * FILE opora_dac_defs.h
  23.   */
  24.  
  25. /* Define to prevent recursive inclusion -------------------------------------*/
  26. #ifndef __OPORA_DAC_DEFS_H
  27. #define __OPORA_DAC_DEFS_H
  28.  
  29. /** @addtogroup __CMSIS CMSIS
  30.   * @{
  31.   */
  32.  
  33. /** @addtogroup __OPORA_Peripheral_Units OPORA Peripheral Units
  34.   * @{
  35.   */
  36.  
  37. /** @defgroup Periph_DAC DAC
  38.   * @{
  39.   */
  40.  
  41. /** @defgroup Periph_DAC_Data_Structures Data Structures
  42.   * @{
  43.   */
  44.  
  45. /** @defgroup Periph_DAC_TypeDef DAC_TypeDef
  46.   * @{
  47.   */
  48.  
  49. typedef struct {
  50.   __IO uint32_t CFG;
  51.   __IO uint32_t DAC1_DATA;
  52.   __IO uint32_t DAC2_DATA;
  53. } DAC_TypeDef;
  54.  
  55. /** @} */ /* End of group Periph_DAC_TypeDef */
  56.  
  57. /** @} */ /* End of group Periph_DAC_Data_Structures */
  58.  
  59. /** @defgroup Periph_DAC_Defines Defines
  60.   * @{
  61.   */
  62.  
  63. /** @defgroup Periph_DAC_DAC_CFG_Bits DAC_CFG
  64.   * @{
  65.   */
  66.  
  67. #define DAC_CFG_Cfg_M_REF0_OFFS                 0
  68. #define DAC_CFG_Cfg_M_REF0                      ((uint32_t)0x00000001)
  69.  
  70. #define DAC_CFG_Cfg_M_REF1_OFFS                 1
  71. #define DAC_CFG_Cfg_M_REF1                      ((uint32_t)0x00000002)
  72.  
  73. #define DAC_CFG_Cfg_ON_DAC0_OFFS                2
  74. #define DAC_CFG_Cfg_ON_DAC0                     ((uint32_t)0x00000004)
  75.  
  76. #define DAC_CFG_Cfg_ON_DAC1_OFFS                3
  77. #define DAC_CFG_Cfg_ON_DAC1                     ((uint32_t)0x00000008)
  78.  
  79. #define DAC_CFG_Cfg_SYNC_A_OFFS                 4
  80. #define DAC_CFG_Cfg_SYNC_A                      ((uint32_t)0x00000010)
  81.  
  82.  
  83. /** @} */ /* End of group Periph_DAC_DAC_CFG_Bits */
  84.  
  85. /** @} */ /* End of group Periph_DAC_Defines */
  86.  
  87. /** @defgroup Periph_DAC_Defines Defines
  88.   * @{
  89.   */
  90.  
  91. /** @defgroup Periph_DAC_DAC1_DATA_Bits DAC1_DATA
  92.   * @{
  93.   */
  94.  
  95. #define DAC1_DATA_DAC0DATA_OFFS                 0
  96. #define DAC1_DATA_DAC0DATA_MASK                 ((uint32_t)0x00000FFF)
  97.  
  98. #define DAC1_DATA_DAC1DATA_OFFS                 16
  99. #define DAC1_DATA_DAC1DATA_MASK                 ((uint32_t)0x0FFF0000)
  100.  
  101.  
  102. /** @} */ /* End of group Periph_DAC_DAC1_DATA_Bits */
  103.  
  104. /** @} */ /* End of group Periph_DAC_Defines */
  105.  
  106. /** @defgroup Periph_DAC_Defines Defines
  107.   * @{
  108.   */
  109.  
  110. /** @defgroup Periph_DAC_DAC2_DATA_Bits DAC2_DATA
  111.   * @{
  112.   */
  113.  
  114. #define DAC2_DATA_DAC1DATA_OFFS                 0
  115. #define DAC2_DATA_DAC1DATA_MASK                 ((uint32_t)0x00000FFF)
  116.  
  117. #define DAC2_DATA_DAC0DATA_OFFS                 16
  118. #define DAC2_DATA_DAC0DATA_MASK                 ((uint32_t)0x0FFF0000)
  119.  
  120.  
  121. /** @} */ /* End of group Periph_DAC_DAC2_DATA_Bits */
  122.  
  123. /** @} */ /* End of group Periph_DAC_Defines */
  124.  
  125. /** @} */ /* End of group Periph_DAC */
  126.  
  127. /** @} */ /* End of group __OPORA_Peripheral_Units */
  128.  
  129. /** @} */ /* End of group __CMSIS */
  130.  
  131. #endif /* __OPORA_DAC_DEFS_H */
  132.  
  133. /******************* (C) COPYRIGHT 2010 Phyton *********************************
  134. *
  135. * END OF FILE opora_dac_defs.h */
  136.