I completed a project wherein I used shift registers and MOSFETs to control a display composed of 12V incandescent bulbs and, thanks to the help I got from this forum, it's working great.
I have only one problem. When I dim the bulbs (using the Output Enable pin on the shift registers), it causes my 12v power supply to buzz annoyingly. It's loudest when most of the bulbs are on and when they're dimmed to about 50%.
Any suggestions on how exactly to eliminate it? I've attached the schematic. (Only two bulb channels are shown, for clarity.)
What is the power rating of the power supply? Sorry, too late for reading the 26 earlier posts.
What is the bulb data? Know that cold bulbs pull quite some current when powered up. It's similar to a capacitive load.
Code......?????
As you found, dimming can cause buzzing from the switching of the mosfets.
This was eveident right from day 1 of someone trying dimming or speed control of any kind.
There are probably answers out there but I am not familiar with them being a simple fix.
Perhaps think along the lines of higher frequency switching beyond human hearing levels.
It's a 15A power supply. The 12V bulbs pull about .3A each. I made sure the power supply was more than sufficient for all the bulbs, plus the board, with overhead.
Modern switching power supplies do make noise (coil whine) at different loads.
And the cheaper or open-frame types could make more noise.
Nothing much you can do about that, apart from putting it into an enclosure.
In the absence of info on the PSU we are working in the dark. (Sorry).
Assuming its a SMPS PSU I could well imagine that the PWM square wave has harmonics that would not please the SMPS. I'd try a BIG capacitor to smooth the current demand.
Using an Adafruit ItsyBitsy 32u4 (5v). Having trouble finding the frequency of the PWM pins for that board. Hesitant to mess with the timer, because the whole function of the circuit is time-based.
Personally I encourage people to mess with things, in my opinion it's one of the joys of the hobby. What have you got to lose if it screws things up? You can always put it back and you'll have learned something.
Go on, mess until the cows jump over the moon. Or something.