High-Pitched noise coming from PSU when FastLED.show() is writing I have this really weird

High-Pitched noise coming from PSU when FastLED.show() is writing

I have this really weird problem where my PSU makes noise when FastLED is writing to the leds. It’s very likely an electrical problem but I’m posting here since it seems to be related to the data transmission. I made a video to show the problem.

I already tried a spare PSU, same behavior. The video shows a barebone connection but I had the same problem with a Capacitor and resistors installed. The twisted grounds on the data lines are floating. When I connected them to the APA102 Gnd it made the noise worse. Also, the noise has a different pitch depending on the DATA_RATE_MHZ.

I also tried running a long ground wire from the PSU to the Teensy. No change. The other wires’ lengths are already as short as they can be, as this circuit is going into a game table.

Teensy 3.2
FastLED version 3.001.005 (kcouck fork)
Arduino IDE v1.8.3

Code : https://pastebin.com/YKevShbX

Looks like your within Amps? how many LED’s ? the noise is more noticeable on the the full white? If these are 5050 RGB’s then you could be pulling close to the 50-60mA. If you have 400 LED’s then your pushing close to 24 Amps. Granted the power supply is rated 30 amps you typically going to get about 20% of that at a constant. Thats if you using a reputable Power Supply. If its a generic one purchased on a deal site then all bets are off the table what it really can support. So the percentage rule of 20% of a 30 Amp PS is really 24 AMPs. In your case if you using close to the 400 pixels and you go all white (full pixel power) your at your Power supply max. When a power supply is maxed you will get some interesting noise.

Solution is to get a power supply with more amperage support and using the 20-30% rule to make sure your within reach. I would go with a 50 amp to be safe. Others here may have better feedback…

My wild ass guess… Something in the PSU is picking up the clock frequency from the strips and/or wiring. Make sure the PSU casing is correctly grounded (it should be a non current carrying wire to earth) and move the PSU away as much as possible from the strips… that should help reduce if not eliminate that audible noise.

Goofy video but hits on point to what I think you are hearing from your PSU under heavy load. https://www.youtube.com/watch?v=T7HsXHqtxrI

@Chris_Rees It’s 344 leds and I get the noise even running them white at 40% power… shouldn’t even draw 10A. Also, they don’t make the noise when I don’t write to them. So they can be showing full white and not make any noise if I disconnect the data lines.

JP Roy may be on par with this one then. Perhaps some funky resonating issues with ground issue? Do you have another brand of Power supply you could try?

@JP_Roy How do I make sure my PSU is grounded? It’s connected to AC via 3 wires into a 3-pronged wall outlet… other than that I’m not sure what to do. I will also try to move the PSU away. Thank you for looking into it!

@Chris_Rees Now I know it’s called Coil Whine at least. Gets me closer to a good diagnostic :slight_smile:

I am actually thinking more of the strips and clock/data wiring (but mostly the strips…) acting as EM transmitting antennas and something in the PSU acting as a receiver.

I like that video from Chris Rees, it explains well how the picked up frequencies can be transformed into audio frequencies.

Somehow gluing down the noisy PSU component (if you can locate it…) could turn out to be be a good solution !

Hey @Franck_Marcotte , for PSU grounding/earthing… if the AC wire GND connection is electrically connected to the PSU casing, then it should be OK unless that wire somehow conducts current (IE: GND loops… ) then any AC high frequency component on that current may indeed be the source of that audible noise in your PSU.

You also might try a ferrite core with one loop of the PSU power line feeding the strip. Something about the same size as the PSU’s bucking core…

One last thought observation on the teensy. If your using the octows2811 shield make sure you are using the power header and don’t use the USB to power the teensy and octo. One project we had was throwing some interesting interference until we powered it strictly from the octo power header. Be mindful that you may need to cut the USB power trace or disconnect the octo power so the two don’t interfere when you update code via usb.

I got my hands on a brand new Meanwell 60A PSU. It makes the same noise but much quieter. So at least I know it’s not a problem coming directly from my JC Power PSUs.

Last thing I will try is the ferrite cores, I will order some.

@Franck_Marcotte are you using the octows2811?

@Chris_Rees No just directly a Teensy 3.2

Are you doing any level shifting?

@Chris_Rees Yes with a 74HCT245 and 100 ohms resistors. It makes the noise with or without.

@Franck_Marcotte the noise is perfectly normal. A switch mode power supply uses a high frequency AC supply to reduce the size of the transformer required. Often you can hear the whine (age and abuse dependant).

If you plug your phone into the charger and hold your ear close, you will hear the tiny transformer in there.

I can tell which animation/pattern is showing on my LEDs by the sound of the PSU. My PSU goes quieter when its under more load.