stm32f1xx_hal_dac_ex.h 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370
  1. /**
  2. ******************************************************************************
  3. * @file stm32f1xx_hal_dac_ex.h
  4. * @author MCD Application Team
  5. * @brief Header file of DAC HAL Extension module.
  6. ******************************************************************************
  7. * @attention
  8. *
  9. * <h2><center>&copy; COPYRIGHT(c) 2016 STMicroelectronics</center></h2>
  10. *
  11. * Redistribution and use in source and binary forms, with or without modification,
  12. * are permitted provided that the following conditions are met:
  13. * 1. Redistributions of source code must retain the above copyright notice,
  14. * this list of conditions and the following disclaimer.
  15. * 2. Redistributions in binary form must reproduce the above copyright notice,
  16. * this list of conditions and the following disclaimer in the documentation
  17. * and/or other materials provided with the distribution.
  18. * 3. Neither the name of STMicroelectronics nor the names of its contributors
  19. * may be used to endorse or promote products derived from this software
  20. * without specific prior written permission.
  21. *
  22. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
  23. * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  24. * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  25. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
  26. * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  27. * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
  28. * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
  29. * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  30. * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  31. * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  32. *
  33. ******************************************************************************
  34. */
  35. /* Define to prevent recursive inclusion -------------------------------------*/
  36. #ifndef __STM32F1xx_HAL_DAC_EX_H
  37. #define __STM32F1xx_HAL_DAC_EX_H
  38. #ifdef __cplusplus
  39. extern "C" {
  40. #endif
  41. #if defined (STM32F100xB) || defined (STM32F100xE) || defined (STM32F101xE) || defined (STM32F101xG) || defined (STM32F103xE) || defined (STM32F103xG) || defined (STM32F105xC) || defined (STM32F107xC)
  42. /* Includes ------------------------------------------------------------------*/
  43. #include "stm32f1xx_hal_def.h"
  44. /** @addtogroup STM32F1xx_HAL_Driver
  45. * @{
  46. */
  47. /** @addtogroup DACEx
  48. * @{
  49. */
  50. /* Exported types ------------------------------------------------------------*/
  51. /* Exported constants --------------------------------------------------------*/
  52. /** @defgroup DACEx_Exported_Constants DACEx Exported Constants
  53. * @{
  54. */
  55. /** @defgroup DACEx_lfsrunmask_triangleamplitude DACEx lfsrunmask triangleamplitude
  56. * @{
  57. */
  58. #define DAC_LFSRUNMASK_BIT0 0x00000000U /*!< Unmask DAC channel LFSR bit0 for noise wave generation */
  59. #define DAC_LFSRUNMASK_BITS1_0 ((uint32_t)DAC_CR_MAMP1_0) /*!< Unmask DAC channel LFSR bit[1:0] for noise wave generation */
  60. #define DAC_LFSRUNMASK_BITS2_0 ((uint32_t)DAC_CR_MAMP1_1) /*!< Unmask DAC channel LFSR bit[2:0] for noise wave generation */
  61. #define DAC_LFSRUNMASK_BITS3_0 ((uint32_t)DAC_CR_MAMP1_1 | DAC_CR_MAMP1_0)/*!< Unmask DAC channel LFSR bit[3:0] for noise wave generation */
  62. #define DAC_LFSRUNMASK_BITS4_0 ((uint32_t)DAC_CR_MAMP1_2) /*!< Unmask DAC channel LFSR bit[4:0] for noise wave generation */
  63. #define DAC_LFSRUNMASK_BITS5_0 ((uint32_t)DAC_CR_MAMP1_2 | DAC_CR_MAMP1_0) /*!< Unmask DAC channel LFSR bit[5:0] for noise wave generation */
  64. #define DAC_LFSRUNMASK_BITS6_0 ((uint32_t)DAC_CR_MAMP1_2 | DAC_CR_MAMP1_1) /*!< Unmask DAC channel LFSR bit[6:0] for noise wave generation */
  65. #define DAC_LFSRUNMASK_BITS7_0 ((uint32_t)DAC_CR_MAMP1_2 | DAC_CR_MAMP1_1 | DAC_CR_MAMP1_0) /*!< Unmask DAC channel LFSR bit[7:0] for noise wave generation */
  66. #define DAC_LFSRUNMASK_BITS8_0 ((uint32_t)DAC_CR_MAMP1_3) /*!< Unmask DAC channel LFSR bit[8:0] for noise wave generation */
  67. #define DAC_LFSRUNMASK_BITS9_0 ((uint32_t)DAC_CR_MAMP1_3 | DAC_CR_MAMP1_0) /*!< Unmask DAC channel LFSR bit[9:0] for noise wave generation */
  68. #define DAC_LFSRUNMASK_BITS10_0 ((uint32_t)DAC_CR_MAMP1_3 | DAC_CR_MAMP1_1) /*!< Unmask DAC channel LFSR bit[10:0] for noise wave generation */
  69. #define DAC_LFSRUNMASK_BITS11_0 ((uint32_t)DAC_CR_MAMP1_3 | DAC_CR_MAMP1_1 | DAC_CR_MAMP1_0) /*!< Unmask DAC channel LFSR bit[11:0] for noise wave generation */
  70. #define DAC_TRIANGLEAMPLITUDE_1 0x00000000U /*!< Select max triangle amplitude of 1 */
  71. #define DAC_TRIANGLEAMPLITUDE_3 ((uint32_t)DAC_CR_MAMP1_0) /*!< Select max triangle amplitude of 3 */
  72. #define DAC_TRIANGLEAMPLITUDE_7 ((uint32_t)DAC_CR_MAMP1_1) /*!< Select max triangle amplitude of 7 */
  73. #define DAC_TRIANGLEAMPLITUDE_15 ((uint32_t)DAC_CR_MAMP1_1 | DAC_CR_MAMP1_0) /*!< Select max triangle amplitude of 15 */
  74. #define DAC_TRIANGLEAMPLITUDE_31 ((uint32_t)DAC_CR_MAMP1_2) /*!< Select max triangle amplitude of 31 */
  75. #define DAC_TRIANGLEAMPLITUDE_63 ((uint32_t)DAC_CR_MAMP1_2 | DAC_CR_MAMP1_0) /*!< Select max triangle amplitude of 63 */
  76. #define DAC_TRIANGLEAMPLITUDE_127 ((uint32_t)DAC_CR_MAMP1_2 | DAC_CR_MAMP1_1) /*!< Select max triangle amplitude of 127 */
  77. #define DAC_TRIANGLEAMPLITUDE_255 ((uint32_t)DAC_CR_MAMP1_2 | DAC_CR_MAMP1_1 | DAC_CR_MAMP1_0) /*!< Select max triangle amplitude of 255 */
  78. #define DAC_TRIANGLEAMPLITUDE_511 ((uint32_t)DAC_CR_MAMP1_3) /*!< Select max triangle amplitude of 511 */
  79. #define DAC_TRIANGLEAMPLITUDE_1023 ((uint32_t)DAC_CR_MAMP1_3 | DAC_CR_MAMP1_0) /*!< Select max triangle amplitude of 1023 */
  80. #define DAC_TRIANGLEAMPLITUDE_2047 ((uint32_t)DAC_CR_MAMP1_3 | DAC_CR_MAMP1_1) /*!< Select max triangle amplitude of 2047 */
  81. #define DAC_TRIANGLEAMPLITUDE_4095 ((uint32_t)DAC_CR_MAMP1_3 | DAC_CR_MAMP1_1 | DAC_CR_MAMP1_0) /*!< Select max triangle amplitude of 4095 */
  82. /**
  83. * @}
  84. */
  85. /** @defgroup DACEx_trigger_selection DAC trigger selection
  86. * @{
  87. */
  88. #define DAC_TRIGGER_NONE 0x00000000U /*!< Conversion is automatic once the DAC1_DHRxxxx register
  89. has been loaded, and not by external trigger */
  90. #define DAC_TRIGGER_T6_TRGO ((uint32_t) DAC_CR_TEN1) /*!< TIM6 TRGO selected as external conversion trigger for DAC channel */
  91. #define DAC_TRIGGER_T7_TRGO ((uint32_t)( DAC_CR_TSEL1_1 | DAC_CR_TEN1)) /*!< TIM7 TRGO selected as external conversion trigger for DAC channel */
  92. #define DAC_TRIGGER_T2_TRGO ((uint32_t)(DAC_CR_TSEL1_2 | DAC_CR_TEN1)) /*!< TIM2 TRGO selected as external conversion trigger for DAC channel */
  93. #define DAC_TRIGGER_T4_TRGO ((uint32_t)(DAC_CR_TSEL1_2 | DAC_CR_TSEL1_0 | DAC_CR_TEN1)) /*!< TIM4 TRGO selected as external conversion trigger for DAC channel */
  94. #define DAC_TRIGGER_EXT_IT9 ((uint32_t)(DAC_CR_TSEL1_2 | DAC_CR_TSEL1_1 | DAC_CR_TEN1)) /*!< EXTI Line9 event selected as external conversion trigger for DAC channel */
  95. #define DAC_TRIGGER_SOFTWARE ((uint32_t)(DAC_CR_TSEL1 | DAC_CR_TEN1)) /*!< Conversion started by software trigger for DAC channel */
  96. #if defined (STM32F101xE) || defined (STM32F101xG) || defined (STM32F103xE) || defined (STM32F103xG)
  97. /* For STM32F10x high-density and XL-density devices: TIM8 */
  98. #define DAC_TRIGGER_T8_TRGO ((uint32_t) DAC_CR_TSEL1_0 | DAC_CR_TEN1) /*!< TIM8 TRGO selected as external conversion trigger for DAC channel */
  99. #endif /* STM32F101xE || STM32F101xG || STM32F103xE || STM32F103xG */
  100. #if defined (STM32F100xB) || defined (STM32F100xE) || defined (STM32F105xC) || defined (STM32F107xC)
  101. /* For STM32F10x connectivity line devices and STM32F100x devices: TIM3 */
  102. #define DAC_TRIGGER_T3_TRGO ((uint32_t) DAC_CR_TSEL1_0 | DAC_CR_TEN1) /*!< TIM3 TRGO selected as external conversion trigger for DAC channel */
  103. #endif /* STM32F100xB || STM32F100xE || STM32F105xC || STM32F107xC */
  104. /* Availability of trigger from TIM5 and TIM15: */
  105. /* - For STM32F10x value line devices STM32F100xB: */
  106. /* trigger from TIM15 is available, TIM5 not available. */
  107. /* - For STM32F10x value line devices STM32F100xE: */
  108. /* trigger from TIM15 and TIM5 are both available, */
  109. /* selection depends on remap (with TIM5 as default configuration). */
  110. /* - Other STM32F1 devices: */
  111. /* trigger from TIM5 is available, TIM15 not available. */
  112. #if defined (STM32F100xB)
  113. #define DAC_TRIGGER_T15_TRGO ((uint32_t)( DAC_CR_TSEL1_1 | DAC_CR_TSEL1_0 | DAC_CR_TEN1)) /*!< TIM15 TRGO selected as external conversion trigger for DAC channel */
  114. #else
  115. #define DAC_TRIGGER_T5_TRGO ((uint32_t)( DAC_CR_TSEL1_1 | DAC_CR_TSEL1_0 | DAC_CR_TEN1)) /*!< TIM5 TRGO selected as external conversion trigger for DAC channel */
  116. #if defined (STM32F100xE)
  117. /*!< DAC trigger availability depending on STM32F1 devices:
  118. For STM32F100x high-density value line devices, the TIM15 TRGO event can be selected
  119. as replacement of TIM5 TRGO if the MISC_REMAP bit in the AFIO_MAPR2 register is set.
  120. Refer to macro "__HAL_AFIO_REMAP_MISC_ENABLE()/__HAL_AFIO_REMAP_MISC_DISABLE()".
  121. Otherwise, TIM5 TRGO is used and TIM15 TRGO is not used (default case).
  122. For more details please refer to the AFIO section. */
  123. #define DAC_TRIGGER_T15_TRGO DAC_TRIGGER_T5_TRGO
  124. #endif /* STM32F100xE */
  125. #endif /* STM32F100xB */
  126. /**
  127. * @}
  128. */
  129. #if defined (STM32F100xB) || defined (STM32F100xE)
  130. /** @defgroup DAC_flags_definition DAC flags definition
  131. * @{
  132. */
  133. #define DAC_FLAG_DMAUDR1 ((uint32_t)DAC_SR_DMAUDR1)
  134. #define DAC_FLAG_DMAUDR2 ((uint32_t)DAC_SR_DMAUDR2)
  135. /**
  136. * @}
  137. */
  138. /** @defgroup DAC_IT_definition DAC IT definition
  139. * @{
  140. */
  141. #define DAC_IT_DMAUDR1 ((uint32_t)DAC_SR_DMAUDR1)
  142. #define DAC_IT_DMAUDR2 ((uint32_t)DAC_SR_DMAUDR2)
  143. /**
  144. * @}
  145. */
  146. #endif /* STM32F100xB || STM32F100xE */
  147. /**
  148. * @}
  149. */
  150. /* Exported macro ------------------------------------------------------------*/
  151. #if defined (STM32F100xB) || defined (STM32F100xE)
  152. /** @defgroup DACEx_Exported_Macros DACEx Exported Macros
  153. * @{
  154. */
  155. /** @brief Enable the DAC interrupt
  156. * @param __HANDLE__: specifies the DAC handle
  157. * @param __INTERRUPT__: specifies the DAC interrupt.
  158. * This parameter can be any combination of the following values:
  159. * @arg DAC_IT_DMAUDR1: DAC channel 1 DMA underrun interrupt
  160. * @arg DAC_IT_DMAUDR2: DAC channel 2 DMA underrun interrupt
  161. * @retval None
  162. */
  163. #define __HAL_DAC_ENABLE_IT(__HANDLE__, __INTERRUPT__) (((__HANDLE__)->Instance->CR) |= (__INTERRUPT__))
  164. /** @brief Disable the DAC interrupt
  165. * @param __HANDLE__: specifies the DAC handle
  166. * @param __INTERRUPT__: specifies the DAC interrupt.
  167. * This parameter can be any combination of the following values:
  168. * @arg DAC_IT_DMAUDR1: DAC channel 1 DMA underrun interrupt
  169. * @arg DAC_IT_DMAUDR2: DAC channel 2 DMA underrun interrupt
  170. * @retval None
  171. */
  172. #define __HAL_DAC_DISABLE_IT(__HANDLE__, __INTERRUPT__) (((__HANDLE__)->Instance->CR) &= ~(__INTERRUPT__))
  173. /** @brief Checks if the specified DAC interrupt source is enabled or disabled.
  174. * @param __HANDLE__: DAC handle
  175. * @param __INTERRUPT__: DAC interrupt source to check
  176. * This parameter can be any combination of the following values:
  177. * @arg DAC_IT_DMAUDR1: DAC channel 1 DMA underrun interrupt
  178. * @arg DAC_IT_DMAUDR2: DAC channel 2 DMA underrun interrupt
  179. * @retval State of interruption (SET or RESET)
  180. */
  181. #define __HAL_DAC_GET_IT_SOURCE(__HANDLE__, __INTERRUPT__) (((__HANDLE__)->Instance->CR & (__INTERRUPT__)) == (__INTERRUPT__))
  182. /** @brief Get the selected DAC's flag status.
  183. * @param __HANDLE__: specifies the DAC handle.
  184. * @param __FLAG__: specifies the DAC flag to get.
  185. * This parameter can be any combination of the following values:
  186. * @arg DAC_FLAG_DMAUDR1: DAC channel 1 DMA underrun flag
  187. * @arg DAC_FLAG_DMAUDR2: DAC channel 2 DMA underrun flag
  188. * @retval None
  189. */
  190. #define __HAL_DAC_GET_FLAG(__HANDLE__, __FLAG__) ((((__HANDLE__)->Instance->SR) & (__FLAG__)) == (__FLAG__))
  191. /** @brief Clear the DAC's flag.
  192. * @param __HANDLE__: specifies the DAC handle.
  193. * @param __FLAG__: specifies the DAC flag to clear.
  194. * This parameter can be any combination of the following values:
  195. * @arg DAC_FLAG_DMAUDR1: DAC channel 1 DMA underrun flag
  196. * @arg DAC_FLAG_DMAUDR2: DAC channel 2 DMA underrun flag
  197. * @retval None
  198. */
  199. #define __HAL_DAC_CLEAR_FLAG(__HANDLE__, __FLAG__) (((__HANDLE__)->Instance->SR) = (__FLAG__))
  200. /**
  201. * @}
  202. */
  203. #endif /* STM32F100xB || STM32F100xE */
  204. /* Private macro -------------------------------------------------------------*/
  205. /** @defgroup DACEx_Private_Macros DACEx Private Macros
  206. * @{
  207. */
  208. #if defined (STM32F101xE) || defined (STM32F101xG) || defined (STM32F103xE) || defined (STM32F103xG)
  209. #define IS_DAC_TRIGGER(TRIGGER) (((TRIGGER) == DAC_TRIGGER_NONE) || \
  210. ((TRIGGER) == DAC_TRIGGER_T6_TRGO) || \
  211. ((TRIGGER) == DAC_TRIGGER_T8_TRGO) || \
  212. ((TRIGGER) == DAC_TRIGGER_T7_TRGO) || \
  213. ((TRIGGER) == DAC_TRIGGER_T5_TRGO) || \
  214. ((TRIGGER) == DAC_TRIGGER_T2_TRGO) || \
  215. ((TRIGGER) == DAC_TRIGGER_T4_TRGO) || \
  216. ((TRIGGER) == DAC_TRIGGER_EXT_IT9) || \
  217. ((TRIGGER) == DAC_TRIGGER_SOFTWARE))
  218. #endif /* STM32F101xE || STM32F101xG || STM32F103xE || STM32F103xG */
  219. #if defined (STM32F100xE) || defined (STM32F105xC) || defined (STM32F107xC)
  220. #define IS_DAC_TRIGGER(TRIGGER) (((TRIGGER) == DAC_TRIGGER_NONE) || \
  221. ((TRIGGER) == DAC_TRIGGER_T6_TRGO) || \
  222. ((TRIGGER) == DAC_TRIGGER_T3_TRGO) || \
  223. ((TRIGGER) == DAC_TRIGGER_T7_TRGO) || \
  224. ((TRIGGER) == DAC_TRIGGER_T5_TRGO) || \
  225. ((TRIGGER) == DAC_TRIGGER_T2_TRGO) || \
  226. ((TRIGGER) == DAC_TRIGGER_T4_TRGO) || \
  227. ((TRIGGER) == DAC_TRIGGER_EXT_IT9) || \
  228. ((TRIGGER) == DAC_TRIGGER_SOFTWARE))
  229. #endif /* STM32F100xE || STM32F105xC || STM32F107xC */
  230. #if defined (STM32F100xB)
  231. #define IS_DAC_TRIGGER(TRIGGER) (((TRIGGER) == DAC_TRIGGER_NONE) || \
  232. ((TRIGGER) == DAC_TRIGGER_T6_TRGO) || \
  233. ((TRIGGER) == DAC_TRIGGER_T3_TRGO) || \
  234. ((TRIGGER) == DAC_TRIGGER_T7_TRGO) || \
  235. ((TRIGGER) == DAC_TRIGGER_T15_TRGO) || \
  236. ((TRIGGER) == DAC_TRIGGER_T2_TRGO) || \
  237. ((TRIGGER) == DAC_TRIGGER_T4_TRGO) || \
  238. ((TRIGGER) == DAC_TRIGGER_EXT_IT9) || \
  239. ((TRIGGER) == DAC_TRIGGER_SOFTWARE))
  240. #endif /* STM32F100xB */
  241. #define IS_DAC_LFSR_UNMASK_TRIANGLE_AMPLITUDE(VALUE) (((VALUE) == DAC_LFSRUNMASK_BIT0) || \
  242. ((VALUE) == DAC_LFSRUNMASK_BITS1_0) || \
  243. ((VALUE) == DAC_LFSRUNMASK_BITS2_0) || \
  244. ((VALUE) == DAC_LFSRUNMASK_BITS3_0) || \
  245. ((VALUE) == DAC_LFSRUNMASK_BITS4_0) || \
  246. ((VALUE) == DAC_LFSRUNMASK_BITS5_0) || \
  247. ((VALUE) == DAC_LFSRUNMASK_BITS6_0) || \
  248. ((VALUE) == DAC_LFSRUNMASK_BITS7_0) || \
  249. ((VALUE) == DAC_LFSRUNMASK_BITS8_0) || \
  250. ((VALUE) == DAC_LFSRUNMASK_BITS9_0) || \
  251. ((VALUE) == DAC_LFSRUNMASK_BITS10_0) || \
  252. ((VALUE) == DAC_LFSRUNMASK_BITS11_0) || \
  253. ((VALUE) == DAC_TRIANGLEAMPLITUDE_1) || \
  254. ((VALUE) == DAC_TRIANGLEAMPLITUDE_3) || \
  255. ((VALUE) == DAC_TRIANGLEAMPLITUDE_7) || \
  256. ((VALUE) == DAC_TRIANGLEAMPLITUDE_15) || \
  257. ((VALUE) == DAC_TRIANGLEAMPLITUDE_31) || \
  258. ((VALUE) == DAC_TRIANGLEAMPLITUDE_63) || \
  259. ((VALUE) == DAC_TRIANGLEAMPLITUDE_127) || \
  260. ((VALUE) == DAC_TRIANGLEAMPLITUDE_255) || \
  261. ((VALUE) == DAC_TRIANGLEAMPLITUDE_511) || \
  262. ((VALUE) == DAC_TRIANGLEAMPLITUDE_1023) || \
  263. ((VALUE) == DAC_TRIANGLEAMPLITUDE_2047) || \
  264. ((VALUE) == DAC_TRIANGLEAMPLITUDE_4095))
  265. /**
  266. * @}
  267. */
  268. /* Exported functions --------------------------------------------------------*/
  269. /** @addtogroup DACEx_Exported_Functions
  270. * @{
  271. */
  272. /** @addtogroup DACEx_Exported_Functions_Group1
  273. * @{
  274. */
  275. /* Extension features functions ***********************************************/
  276. uint32_t HAL_DACEx_DualGetValue(DAC_HandleTypeDef* hdac);
  277. HAL_StatusTypeDef HAL_DACEx_TriangleWaveGenerate(DAC_HandleTypeDef* hdac, uint32_t Channel, uint32_t Amplitude);
  278. HAL_StatusTypeDef HAL_DACEx_NoiseWaveGenerate(DAC_HandleTypeDef* hdac, uint32_t Channel, uint32_t Amplitude);
  279. HAL_StatusTypeDef HAL_DACEx_DualSetValue(DAC_HandleTypeDef* hdac, uint32_t Alignment, uint32_t Data1, uint32_t Data2);
  280. void HAL_DACEx_ConvCpltCallbackCh2(DAC_HandleTypeDef* hdac);
  281. void HAL_DACEx_ConvHalfCpltCallbackCh2(DAC_HandleTypeDef* hdac);
  282. void HAL_DACEx_ErrorCallbackCh2(DAC_HandleTypeDef* hdac);
  283. #if defined (STM32F100xB) || defined (STM32F100xE)
  284. void HAL_DAC_IRQHandler(DAC_HandleTypeDef* hdac);
  285. void HAL_DAC_DMAUnderrunCallbackCh1(DAC_HandleTypeDef *hdac);
  286. void HAL_DACEx_DMAUnderrunCallbackCh2(DAC_HandleTypeDef* hdac);
  287. #endif /* STM32F100xB) || defined (STM32F100xE) */
  288. /**
  289. * @}
  290. */
  291. /**
  292. * @}
  293. */
  294. /** @addtogroup DACEx_Private_Functions
  295. * @{
  296. */
  297. void DAC_DMAConvCpltCh2(DMA_HandleTypeDef *hdma);
  298. void DAC_DMAHalfConvCpltCh2(DMA_HandleTypeDef *hdma);
  299. void DAC_DMAErrorCh2(DMA_HandleTypeDef *hdma);
  300. /**
  301. * @}
  302. */
  303. /**
  304. * @}
  305. */
  306. /**
  307. * @}
  308. */
  309. #endif /* STM32F100xB || STM32F100xE || STM32F101xE || STM32F101xG || STM32F103xE || STM32F103xG || STM32F105xC || STM32F107xC */
  310. #ifdef __cplusplus
  311. }
  312. #endif
  313. #endif /*__STM32F1xx_HAL_DAC_EX_H */
  314. /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/