Skip to content

Arduino program that control individual timers OC1RA and ICR1. Allows for PWM control 0-100% and 8MHz.

Notifications You must be signed in to change notification settings

NotAKangaroo2/25KHz-Arduino-Fan-PWM-Control

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 

Repository files navigation

25KHz-Arduino-Fan-PWM-Control

Arduino program that control individual timers OC1RA and ICR1. Allows for PWM control 0-100% and 8MHz. Using a frequency in HZ, from 125HZ to 8MHz (Stability at higher frequencies is not great, so don't use this for signals over ~5-6 MHz). A variable is declared in the code and can be modified using setPwmDuty(); to change the duty cycle for the specified frequency. Please visit my Arduino page for more information:

Usage:

  • 2 variables at the top of the file change freq and duty.
  • Modify PWM_FREQ_HZ to change the frequency (In HZ) from 125 to 8000000
  • Modify setPwmDuty(); within the loop to modify the duty cycle. Important! Do not modify TCNT1_TOP. It is used in the setPwmDuty function to set OC1RA value

Circuit:

  • It is very simple, The Arduino needs to control the PWM pin of the fan with a seperate power supply for the fan with grounds connected together

Links:

Feel free to open an issue if there are questions!

About

Arduino program that control individual timers OC1RA and ICR1. Allows for PWM control 0-100% and 8MHz.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 100.0%