牛卧堂MCU技术交流

标题: [Mini51] PWM Fan Control [打印本页]

作者: admin    时间: 2022-6-16 10:49
标题: [Mini51] PWM Fan Control
This example code uses PWM Channel 0 (P2.2) to control 4-wire PWM fan speed and uses Timer 0 external capture pin (P3.2) to detect fan speed in RPM. Inputting PWM waveform to the PWM fan control pin can control fan speed. By changing PWM duty ratio, PWM fan can operate in suitable speed. The PWM fan sense pin outputs tachometer signal, which changes voltage level when rotating from one pole to another. By calculating the time which fan takes when rotating one round, user can get the fan speed in RPM.

To use this example code, user should connect PWM channel 0 (P2.2) to PWM fan control pin and connect Timer 0 external capture pin (P3.2) to fan sense pin.

You can download the sample code at https://www.nuvoton.com/resource-downlo ... 1216133919





欢迎光临 牛卧堂MCU技术交流 (http://www.nuvoton-mcu.com/) Powered by Discuz! X3.2