06-05-2013 05:00 AM
Hello everyone,
I am a new user to the Arduino Uno. I have a project where I need to control some devices using a PWM signal at 125Hz. Does anyone know how I can change the Arduino Uno base frequency from 490Hz to 125Hz?
Thanks,
David
06-13-2013 06:52 AM
Hi David,
I had a similiar problem with my arduino mega2560.
I used the following pages to solve my problem (Read everything carefully):
http://forum.arduino.cc/index.php?topic=72092.0
http://arduino.cc/en/Tutorial/SecretsOfArduinoPWM
Finally I changed my Timer 0 (!!! changes internally some functions like delay() or millis() !!!) in my >>> void setup() <<< with the following code:
TCCR0B = (TCCR0B & 0xF8) | 0x02;
You have to make it in the LIFA_Base.ino and upload again to your board. But make a copy of your original LIFA_Base.ino.
In my opinion you should try to change Timer 1 to 122.5 Hz.
I hope this helped. Good luck