-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add PWM frequency to system settings #389
Add PWM frequency to system settings #389
Conversation
This needs a cooresponding GroundControl PR (as yet unsubmitted). - add a system setting $39 fPWM - set the default value to 3 = 490Hz - change the prescaler for timers2-4 on change of fPWM - report the change if verboseDebug > 0
You also need to increment the SettingsVersion number in settings.h as well. This ensures that settings on the arduino are wiped and reloaded with the default and then loaded from GC. Otherwise, the new variable or potentially other variables can have some very odd values or even overflows. |
Interesting, you can change PWM frequency within a cut file using $39= commands in the cut file. |
it seems like the lag can happen with any speed change during a cut, but putting in a manual z-axis change (or a several-second long auto one) seems to give the affected routine (PID?) time to clear or catch up. Not that a speed change would be useful, but it does cast interesting shadows of some internal process. |
To see it change, turn on 'verboseDebug' in Config.h... |
This is so mind blowing. Wow. I want to keep playing around with it more, but even just changing the settings and hearing the tone change is incredible. It's funny that the noise has been with us for so long and now we can change it. What a fundamentally cool thing! It feels like this PR really touches the heart of the machine. Awesome work @blurfl!! You are really on fire here. |
PR MaslowCNC#389 replaced this function with one of the same name which accepts a setting parameter.
…tion remove function that was replaced in PR #389
This builds upon PR #385 and #386 to allow changing the PWM prescaler frequency from GroundControl.
This needs a cooresponding GroundControl PR (GroundControl #619).