70 lines
1.3 KiB
C
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#ifndef _TIMER_H
#define _TIMER_H
#include "sys.h"
//////////////////////////////////////////////////////////////////////////////////
/*****************************************************************************************************/
//定时器驱动代码
//STM32H7工程模板-HAL库函数版本
//DevEBox 大越创新
//淘宝店铺mcudev.taobao.com
//淘宝店铺shop389957290.taobao.com
/*****************************************************************************************************/
//////////////////////////////////////////////////////////////////////////////////
extern TIM_HandleTypeDef TIM3_Handler; //定时器3PWM句柄
extern TIM_OC_InitTypeDef TIM3_CH4Handler; //定时器3通道4句柄
void TIM3_Init(u16 arr,u16 psc); //定时器初始化
void TIM3_PWM_Init(u16 arr,u16 psc);
void TIM_SetTIM3Compare4(u32 compare);
u32 TIM_GetTIM3Capture4(void);
void TIM5_CH1_Cap_Init(u32 arr,u16 psc);
#endif
/*****************************************************************************************************/
//定时器驱动代码
//STM32H7工程模板-HAL库函数版本
//DevEBox 大越创新
//淘宝店铺mcudev.taobao.com
//淘宝店铺shop389957290.taobao.com
/*****************************************************************************************************/