标签:puts mod 细节 输出 mode 设置 conf 模式 its
//初始化TIM8 Channel1 PWM?模式
TIM_OCInitStructure.TIM_OCMode = TIM_OCMode_PWM2; //
TIM_OCInitStructure.TIM_OutputState = TIM_OutputState_Enable; //
//TIM_OCInitStructure.TIM_OCPolarity = TIM_OCPolarity_High; //
TIM_OCInitStructure.TIM_OCPolarity = TIM_OCPolarity_Low; //
TIM_OC3Init(TIM8, &TIM_OCInitStructure); //
TIM_OC3PreloadConfig(TIM8, TIM_OCPreload_Enable); //
TIM_Cmd(TIM8, ENABLE); //
TIM_CtrlPWMOutputs(TIM8, ENABLE); // 设置TIM8的PWM输出为使能 TIM1和TIM8定时器需要加上这句
标签:puts mod 细节 输出 mode 设置 conf 模式 its
原文地址:http://www.cnblogs.com/yekongdexingxing/p/6610041.html