/**
******************************************************************************
* @file stm32f3xx_hal_hrtim.c
* @author MCD Application Team
* @brief TIM HAL module driver.
* This file provides firmware functions to manage the following
* functionalities of the High Resolution Timer (HRTIM) peripheral:
* + HRTIM Initialization
* + DLL Calibration Start
* + Timer Time Base Unit Configuration
* + Simple Time Base Start/Stop
* + Simple Time Base Start/Stop Interrupt
* + Simple Time Base Start/Stop DMA Request
* + Simple Output Compare/PWM Channel Configuration
* + Simple Output Compare/PWM Channel Start/Stop Interrupt
* + Simple Output Compare/PWM Channel Start/Stop DMA Request
* + Simple Input Capture Channel Configuration
* + Simple Input Capture Channel Start/Stop Interrupt
* + Simple Input Capture Channel Start/Stop DMA Request
* + Simple One Pulse Channel Configuration
* + Simple One Pulse Channel Start/Stop Interrupt
* + HRTIM External Synchronization Configuration
* + HRTIM Burst Mode Controller Configuration
* + HRTIM Burst Mode Controller Enabling
* + HRTIM External Events Conditioning Configuration
* + HRTIM Faults Conditioning Configuration
* + HRTIM Faults Enabling
* + HRTIM ADC trigger Configuration
* + Waveform Timer Configuration
* + Waveform Event Filtering Configuration
* + Waveform Dead Time Insertion Configuration
* + Waveform Chopper Mode Configuration
* + Waveform Compare Unit Configuration
* + Waveform Capture Unit Configuration
* + Waveform Output Configuration
* + Waveform Counter Start/Stop
* + Waveform Counter Start/Stop Interrupt
* + Waveform Counter Start/Stop DMA Request
* + Waveform Output Enabling
* + Waveform Output Level Set/Get
* + Waveform Output State Get
* + Waveform Burst DMA Operation Configuration
* + Waveform Burst DMA Operation Start
* + Waveform Timer Counter Software Reset
* + Waveform Capture Software Trigger
* + Waveform Burst Mode Controller Software Trigger
* + Waveform Timer Pre-loadable Registers Update Enabling
* + Waveform Timer Pre-loadable Registers Software Update
* + Waveform Timer Delayed Protection Status Get
* + Waveform Timer Burst Status Get
* + Waveform Timer Push-Pull Status Get
* + Peripheral State Get
@verbatim
==============================================================================
##### Simple mode v.s. waveform mode #####
==============================================================================
[..] The HRTIM HAL API is split into 2 categories:
(#)Simple functions: these functions allow for using a HRTIM timer as a
general purpose timer with high resolution capabilities.
HRTIM simple modes are managed through the set of functions named
HAL_HRTIM_Simple<Function>. These functions are similar in name and usage
to the one defined for the TIM peripheral. When a HRTIM timer operates in
simple mode, only a very limited set of HRTIM features are used.
Following simple modes are proposed:
(++)Output compare mode,
(++)PWM output mode,
(++)Input capture mode,
(++)One pulse mode.
(#)Waveform functions: These functions allow taking advantage of the HRTIM
flexibility to produce numerous types of control signal. When a HRTIM timer
operates in waveform mode, all the HRTIM features are accessible without
any restriction. HRTIM waveform modes are managed through the set of
functions named HAL_HRTIM_Waveform<Function>
##### How to use this driver #####
==============================================================================
[..]
(#)Initialize the HRTIM low level resources by implementing the
HAL_HRTIM_MspInit() function:
(##)Enable the HRTIM clock source using __HRTIMx_CLK_ENABLE()
(##)Connect HRTIM pins to MCU I/Os
(+++) Enable the clock for the HRTIM GPIOs using the following
function: __HAL_RCC_GPIOx_CLK_ENABLE()
(+++) Configure these GPIO pins in Alternate Function mode using
HAL_GPIO_Init()
(##)When using DMA to control data transfer (e.g HAL_HRTIM_SimpleBaseStart_DMA())
(+++)Enable the DMAx interface clock using __DMAx_CLK_ENABLE()
(+++)Initialize the DMA handle
(+++)Associate the initialized DMA handle to the appropriate DMA
handle of the HRTIM handle using __HAL_LINKDMA()
(+++)Initialize the DMA channel using HAL_DMA_Init()
(+++)Configure the priority and enable the NVIC for the transfer
complete interrupt on the DMA channel using HAL_NVIC_SetPriority()
and HAL_NVIC_EnableIRQ()
(##)In case of using interrupt mode (e.g HAL_HRTIM_SimpleBaseStart_IT())
(+++)Configure the priority and enable the NVIC for the concerned
HRTIM interrupt using HAL_NVIC_SetPriority() and HAL_NVIC_EnableIRQ()
(#)Initialize the HRTIM HAL using HAL_HRTIM_Init(). The HRTIM configuration
structure (field of the HRTIM handle) specifies which global interrupt of
whole HRTIM must be enabled (Burst mode period, System fault, Faults).
It also contains the HRTIM external synchronization configuration. HRTIM
can act as a master (generating a synchronization signal) or as a slave
(waiting for a trigger to be synchronized).
(#)Start the high resolution unit using HAL_HRTIM_DLLCalibrationStart(). DLL
calibration is executed periodically and compensate for potential voltage
and temperature drifts. DLL calibration period is specified by the
CalibrationRate argument.
(#)HRTIM timers cannot be used until the high resolution unit is ready. This
can be checked using HAL_HRTIM_PollForDLLCalibration(): this function returns
HAL_OK if DLL calibration is completed or HAL_TIMEOUT if the DLL calibration
is still going on when timeout given as argument expires. DLL calibration
can also be started in interrupt mode using HAL_HRTIM_DLLCalibrationStart_IT().
In that case an interrupt is generated when the DLL calibration is completed.
Note that as DLL calibration is executed on a periodic basis an interrupt
will be generated at the end of every DLL calibration operation
(worst case: one interrupt every 14 micro seconds !).
(#) Configure HRTIM resources shared by all HRTIM timers
(##)Burst Mode Controller:
(+++)HAL_HRTIM_BurstModeConfig(): configures the HRTIM burst mode
controller: operating mode (continuous or one-shot mode), clock
(source, prescaler) , trigger(s), period, idle duration.
(##)External Events Conditionning:
(+++)HAL_HRTIM_EventConfig(): configures the conditioning of an
external event channel: source, polarity, edge-sensitivity.
External event can be used as triggers (timer reset, input
capture, burst mode, ADC triggers, delayed protection)
They can also be used to set or reset timer outputs. Up to
10 event channels are available.
(+++)HAL_HRTIM_EventPrescaler
没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
收起资源包目录
stm32f334的高精度定时器HRTIM产生三路互补pwm波 (169个子文件)
f334_one.axf 195KB
f334_one_sct.Bak 494B
stm32f3xx_hal_hrtim.c 298KB
stm32f3xx_hal_tim.c 174KB
stm32f3xx_hal_i2c.c 161KB
stm32f3xx_hal_tim_ex.c 96KB
stm32f3xx_hal_uart.c 95KB
stm32f3xx_hal_rcc_ex.c 63KB
stm32f3xx_hal_rcc.c 45KB
stm32f3xx_hal_flash_ex.c 33KB
stm32f3xx_hal_dma.c 29KB
stm32f3xx_hal_flash.c 22KB
stm32f3xx_hal_cortex.c 22KB
stm32f3xx_hal_gpio.c 20KB
stm32f3xx_hal_pwr.c 18KB
stm32f3xx_hal_uart_ex.c 17KB
stm32f3xx_hal.c 17KB
stm32f3xx_hal_i2c_ex.c 12KB
system_stm32f3xx.c 12KB
stm32f3xx_hal_pwr_ex.c 10KB
hrtim.c 9KB
main.c 6KB
stm32f3xx_it.c 5KB
usart.c 3KB
tim.c 3KB
stm32f3xx_hal_msp.c 2KB
gpio.c 2KB
stm32f3xx_hal_hrtim.crf 795KB
stm32f3xx_hal_tim.crf 771KB
stm32f3xx_hal_i2c.crf 769KB
stm32f3xx_hal_uart.crf 746KB
stm32f3xx_hal_tim_ex.crf 744KB
stm32f3xx_hal_rcc.crf 742KB
stm32f3xx_hal_flash_ex.crf 733KB
stm32f3xx_hal_dma.crf 732KB
stm32f3xx_hal_rcc_ex.crf 732KB
stm32f3xx_hal_flash.crf 731KB
stm32f3xx_hal_gpio.crf 730KB
hrtim.crf 730KB
main.crf 728KB
stm32f3xx_hal_uart_ex.crf 728KB
stm32f3xx_hal_i2c_ex.crf 728KB
stm32f3xx_hal.crf 728KB
stm32f3xx_hal_pwr.crf 728KB
usart.crf 728KB
stm32f3xx_hal_pwr_ex.crf 728KB
gpio.crf 728KB
tim.crf 728KB
stm32f3xx_hal_cortex.crf 728KB
system_stm32f3xx.crf 728KB
stm32f3xx_it.crf 727KB
stm32f3xx_hal_msp.crf 727KB
main.d 2KB
stm32f3xx_hal_flash_ex.d 2KB
stm32f3xx_hal_uart_ex.d 2KB
stm32f3xx_hal_tim_ex.d 2KB
stm32f3xx_hal_rcc_ex.d 2KB
stm32f3xx_hal_pwr_ex.d 2KB
stm32f3xx_hal_cortex.d 2KB
stm32f3xx_hal_i2c_ex.d 2KB
stm32f3xx_hal_hrtim.d 2KB
stm32f3xx_hal_flash.d 2KB
stm32f3xx_hal_uart.d 2KB
stm32f3xx_hal_gpio.d 2KB
stm32f3xx_hal_dma.d 2KB
stm32f3xx_hal_rcc.d 2KB
stm32f3xx_hal_pwr.d 2KB
stm32f3xx_hal_tim.d 2KB
stm32f3xx_hal_i2c.d 2KB
stm32f3xx_it.d 2KB
stm32f3xx_hal.d 2KB
stm32f3xx_hal_msp.d 2KB
usart.d 2KB
hrtim.d 2KB
gpio.d 2KB
tim.d 2KB
system_stm32f3xx.d 2KB
startup_stm32f334x8.d 55B
f334_one_STM32F334C8Tx.dbgconf 2KB
f334_one_f334_one.dep 81KB
stm32f334x8.h 1.24MB
arm_math.h 246KB
stm32f3xx_hal_hrtim.h 229KB
stm32f3xx_hal_rcc_ex.h 198KB
stm32_hal_legacy.h 186KB
core_cm7.h 136KB
core_cm4.h 112KB
core_cm3.h 101KB
core_sc300.h 100KB
stm32f3xx_hal_rcc.h 88KB
stm32f3xx_hal_gpio_ex.h 77KB
stm32f3xx_hal_tim.h 75KB
stm32f3xx_hal_uart.h 73KB
stm32f3xx_hal_tim_ex.h 65KB
stm32f3xx_hal.h 55KB
cmsis_armcc_V6.h 54KB
core_sc000.h 44KB
core_cm0plus.h 44KB
cmsis_gcc.h 40KB
core_cm0.h 36KB
共 169 条
- 1
- 2
资源评论
apple-wxy
- 粉丝: 88
- 资源: 7
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 实验一、线性表的基本操作.doc
- Day43 Java反射(二)
- kenwood-健伍TK-868G车载电台维修手册(含PCB图、原理图)2024更新
- kenwood-健伍tm-471a车载电台维修手册(含PCB图、原理图)2024
- Android System WebView-109.0.5414.118 arm,arm64.apk
- 无人机遂行编队飞行中的纯方位无源定位_周宏兵.pdf
- 2000-2017年各省经济政策不确定性指数数据.xlsx
- 基于matlab实现的云模型发生器 包括基本云发生器,x条件云发生器,y条件云发生器 现已用于数据挖掘等基本领域.rar
- 基于matlab实现的图像匹配和深度图计算程序.rar
- 基于matlab实现的霍夫曼Huffman编码译码GUI界面设计 源程序代码.rar
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功