Display volume of alsa card on i3status

发布时间 2023-10-14 14:35:14作者: 蟹蟹你哦

Display volume of alsa on i3status

  • System: gentoo
  • Desktop: i3wm

here is my i3status config of volumes:

order += "volume master"
order += "volume speaker"

volume master {
        format = "♪ %volume"
        format_muted = "♪ muted (%volume)"
        device = "default"
        mixer = "Master"
        mixer_idx = 0
}

volume speaker {
        format = "♪ %volume"
        format_muted = "♪ muted (%volume)"
        device = "default"
        mixer = "Speaker"
        mixer_idx = 0
}

As you can see, I just change 'master' to my other card scontrol from command:

$ amixer scontrols

important: You should change your .asoundrc too, like this:

defaults.pcm.!card 2
defaults.pcm.!device 0
defaults.ctl.!card 2
defaults.pcm.dmix.rate 96000