Audio hum when idle

Hi,

First time post. I’ve tried a number of configurations to get rid of this hum. I can’t do it and need help.

Issue:
When my laptop boots up and there is no audio being played, there is a hum at 160Hz.

Points of interest:

  • This only happens when external amplified speakers are plugged into the standard audio 3.5mm jack
  • As far as I can tell, the hum kicks in once the audio hardware goes idle.
  • If a notification sound happens, the hum stops for 7 seconds and then continues.
  • If I’m using an audio application of any sort, the hum is gone.
  • If I open the EOS sound settings, the hum is gone.

Initial Help:
Can someone tell me how to monitor what is going into idle? I believe the system is running pipewire-pulse.

Here is the list of packages from pacman:
extra/paprefs 1.2-1
Configuration dialog for PulseAudio
extra/pavucontrol 1:5.0+r61+gee77d86-2 [installed]
PulseAudio Volume Control
extra/pipewire-alsa 1:0.3.64-1 [installed]
Low-latency audio/video router and processor - ALSA configuration
extra/pipewire-pulse 1:0.3.64-1 [installed]
Low-latency audio/video router and processor - PulseAudio replacement
extra/plasma-pa 5.26.5-1 (plasma)
Plasma applet for audio volume management using PulseAudio
extra/pulseaudio 16.1-3
A featureful, general-purpose sound server

Any help is appreciated.

You have a ground loop or noise on your laptops audio circuit, its just hidden during other times.

You can disable suspending the audio device by editing wireplumber alsa configuration.

cp -r /usr/share/wireplumber ~/.config/

go into the .config/wireplumber/main.lua.d directory that is now in your home folder and edit the 50-alsa-config.lua file

near the bottom remove the -- from ["node.pause-on-idle"] and have it equal false

you can also set session.suspend-timout-seconds to 0

save and restart, suspending will be disabled for the audio devices

Hi Echoa and thanks for your reply.

I have tried an audio isolation transformer before and it didn’t fix it.
I copied the lua files as suggested. The alsa config file already had the pause-on-idle set to false. I changed the session.suspend-timeout-seconds to 0 because it was on 5.

After a reboot it continues to hum :frowning:

Is there a way to read the currently applied values?

Thanks again.

If you followed the directions suspend is disabled, idk about checking the values but shouldn’t need to as that’s how I set it for my USB DAC.

Something else is causing the hum, have you tried any other powered speakers? If the noise is in your speakers power supply or amp that could cause it.

How high do you have the speakers volume?

Edit: there’s likely a way with pw-cli I just have never needed to know how :sweat_smile:

https://docs.pipewire.org/page_man_pw_cli_1.html

Or wireplumber

https://pipewire.pages.freedesktop.org/wireplumber/daemon-logging.html

Interesting Echoa.
I didn’t know about pw-cli.
The “module-unload” feature has not been implemented yet :frowning: I tried to unload the suspend module.
It does give information about the device:

	id: 78
	permissions: rwxm
	type: PipeWire:Interface:Device/3
*	properties:
*		api.acp.auto-port = "false"
*		api.acp.auto-profile = "false"
*		api.alsa.card = "2"
*		api.alsa.card.longname = "DellInc.-G77700--06YKK0"
*		api.alsa.card.name = "sof-hda-dsp"
*		api.alsa.path = "hw:2"
*		api.alsa.use-acp = "true"
*		api.dbus.ReserveDevice1 = "Audio2"
*		device.api = "alsa"
*		device.bus = "pci"
*		device.bus-path = "pci-0000:00:1f.3-platform-skl_hda_dsp_generic"
*		device.description = "Comet Lake PCH cAVS"
*		device.enum.api = "udev"
*		device.icon-name = "audio-card-analog-pci"
*		device.name = "alsa_card.pci-0000_00_1f.3-platform-skl_hda_dsp_generic"
*		device.nick = "sof-hda-dsp"
*		device.plugged.usec = "7867814"
*		device.product.id = "0x06c8"
*		device.product.name = "Comet Lake PCH cAVS"
*		device.subsystem = "sound"
*		device.sysfs.path = "/devices/pci0000:00/0000:00:1f.3/skl_hda_dsp_generic/sound/card2"
*		device.vendor.id = "0x8086"
*		device.vendor.name = "Intel Corporation"
*		media.class = "Audio/Device"
*		factory.id = "14"
*		client.id = "85"
*		object.id = "78"
*		object.serial = "563"
*		object.path = "alsa:pcm:2"
*		alsa.card = "2"
*		alsa.card_name = "sof-hda-dsp"
*		alsa.long_card_name = "DellInc.-G77700--06YKK0"
*		alsa.driver_name = "snd_soc_skl_hda_dsp"
*		device.string = "2"

I haven’t looked at the daemon-logging yet. Will do.

Some basic things to try that may help:

Try using a powerstrip to plug in the speakers and not the power outlet directly.

Make sure the speakers are not close to other electronics - if the speakers are not shielded this may cause hum. But probably not at 160hz? :thinking:

Also note: You have an amplifier on the computer and one in the speakers. :thinking:
Such a setup you may need to keep the volume low in Linux.

device.plugged.usec = “7867814”

Seems to fit with about 7 seconds, but I don’t know if you can change it or if it will help. Maybe some wiser people on the forum could shed some light on this.

Welcome to the Endeavour OS forums :enos_flag:

1 Like

This is what I’m thinking it is, the question is whether its the speakers amp or the PCs introducing the noise

It would be 60hz in the United States and maybe Canada but I’m not positive for other countries but I doubt 160hz. When you have fixed frequency noise its usually hardware related in some way, the question is which hardware? Mine for instance is my speakers amp if I don’t limit their volume.

Hi Melways and thanks for the welcome and reply.

I’ve used this setup in a few locations around the house and it is the same.
They are Edifier PC Speakers and are therefore designed for how I am using them.
Interesting spotting of the device.plugged.usec value. I’ll check this out thanks.

I don’t have time right now but will come back to this. This has been an issue for years so…

It’s absolutely 160Hz. I used a spectrum analyzer on my phone and also just checked by listening to 60Hz and 160Hz on YouTube.

It’s a strange frequency that’s for sure.

What I haven’t put in this post yet is that there is another computer in the house that seems to do the same thing! Also, if the computer has Windows on it, it doesn’t do it.

Don’t worry, I’ll never go back to stupid-looking Windows ever again.

If 2 computers do it this could be something in the environment.

The problem with Linux and audio drivers is very few if not no manufacturers make audio drivers for Linux. Some audio devices have quirks or the ability to eliminate certain small issues when using windows drivers but Linux doesn’t have that luxury.

So to get to the bottom of this

Are the computers the same model?
Do they use the same audio codec?
Do they use the same equipment (speakers,etc)
Are they on the same circuit or different ones?

Any information you can provide about commonality between the 2 systems that do it can help narrow down the suspects.

i would also check alsamixer could be muting unused channels can help or it has some setting like automute disabled…

1 Like

Good suggestion, i forgot about alsa as i cant use it for my DAC XP
Though still there shouldnt be noise on a muted output

Hi guys,
Thanks again for your input. As I said above, I’ve been having this problem for years and only now being bothered to try and fix it.
I don’t have much time for this though.
The “wireplumber” change I made due to Echoa’s suggestion seems to have helped a bit, but not fixed it.
I’ll come back to this when I can. For now, I am running “chill” music all the time and planning on buying a USB Audio Interface.

I’ve still not had time to work on this however, I just noticed something interesting.
EndeavourOS just crashed on me (MS Teams and Confluence, what a mix) and I held the power button down till the laptop switched off.
NO HUM.

Normally, if I shut down my laptop, the hum starts (or continues) once it has shut down. Maybe during the shut down it stops and starts, but it always starts after shut down.

This time, because I held the power button down and there was no hum (I had music on to stop the hum), the services didn’t shut down, and more to the point, the silicone didn’t get switched into whatever state it is that causes the hum (low power etc). The laptop was completely off, with no hum.

I started the laptop again, and during the service initialisation phase, the hum kicked in again.

Why am I the only one on the planet with this issue and on two devices in my house no less? It could be the house, but I doubt it.

I might add, the background music is quite relaxing, hence my lack of motivation to fix this.

Refrigerator, heating, a/c, a close-by neighbor’s electrical device running, possibilities are endless…

youre not, tons of people do especially with laptops. Laptops generally have poorly implemented audio circuits as do MANY motherboards with noise from PSU, PCIE, CPU, etc.

The problem is that nobody can tell you exactly what the cause is without having the device in hand in that location, plugged into the things youre plugged into. Audio is very sensitive to noise from many sources. I have a family member that has a logitech headset that generates tons of noise on the mic when plugged into their laptop but it doesnt do it elsewhere and other devices dont do it when plugged in its specific to THAT headset when plugged into THAT laptop. :man_shrugging:

2 Likes

Thanks again to all of you.
I decided to make my life easier and ditch this problem by purchasing a USB3 Thunderbolt Docking station.

I got a Kensington SD5600T and it is working like a dream:

Video, Mouse, Keyboard, Ethernet, Webcam, and Audio, all working with no issues through one cable. I did have to authorize the Dock in the Gnome settings.

Thanks again.

Note 1: The media centre still has issues.
Note 2: To anyone else having this issue, I’m sorry but there is no easy solution here.

closing
if you want to proceed open a new thread please :wink: