Project Introduction
Based on Renesas RA MCU, design a controller for computer 4Pin PWM fan. ~~~~
Preliminary preparation
The speed control of computer fans is generally PWM and DC. PWM control requires 4 wires, which are 12V, GND, speed detection, and PWM signal.
I used an oscilloscope to measure the motherboard’s PWM signal to be 5V-23.44kHz, and the speed detection signal to be
Power supply part: The 12V to 5V part is FP6115DR. You can use the IC that you removed from the material board directly; the 5V to 3.3V part is 1117-3.3.
Main control part: R7FA2E1A72DFL
LED part: 74HC595 controls 8 LEDs. It is also a disassembled part and occupies 3 IOs.
PWM part: Use NTMFS4C10N MOS tube for level conversion, remove it from the old surface, which is a bit overkill.
Software part: developed using Keil, refer to the official PWM routine.
The chip clock is 48M, to make the PWM frequency 24kHz, the counter value should be set to 2000, on line 28.
The range of ndt is 0~100, 32 lines is a negative clock period, and the calculated value is 2000~0.
Behaviors 55~58 control the PWM duty cycle, changing from 0 to 100 and then to 0 in a cycle.
Demo video: https://www.bilibili.com/video/BV1vY411c7cz/
There is a problem
1. USB 5V pin network error (fixed)
2. PWM fan socket line sequence error (corrected)
All reference designs on this site are sourced from major semiconductor manufacturers or collected online for learning and research. The copyright belongs to the semiconductor manufacturer or the original author. If you believe that the reference design of this site infringes upon your relevant rights and interests, please send us a rights notice. As a neutral platform service provider, we will take measures to delete the relevant content in accordance with relevant laws after receiving the relevant notice from the rights holder. Please send relevant notifications to email: bbs_service@eeworld.com.cn.
It is your responsibility to test the circuit yourself and determine its suitability for you. EEWorld will not be liable for direct, indirect, special, incidental, consequential or punitive damages arising from any cause or anything connected to any reference design used.
Supported by EEWorld Datasheet