Use the update rate parameter provided and not the default.

This commit is contained in:
Simon Wilks
2012-09-24 23:36:21 +02:00
parent 4adca98991
commit 37163011fc
2 changed files with 9 additions and 1 deletions
Executable
+8
View File
@@ -0,0 +1,8 @@
#/bin/sh
git fetch upstream
# Fetches any new changes from the original repo
git merge upstream/master
# Merges any changes fetched into your working files
+1 -1
View File
@@ -179,7 +179,7 @@ static void
pwm_timer_set_rate(unsigned timer, unsigned rate)
{
/* configure the timer to update at the desired rate */
rARR(timer) = 1000000 / pwm_update_rate;
rARR(timer) = 1000000 / rate;
/* generate an update event; reloads the counter and all registers */
rEGR(timer) = GTIM_EGR_UG;