You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

通过SSH使用cmus时,将OSMC设备音频从HDMI切换至插孔的方法

Switching cmus Audio Output to Headphone Jack on OSMC (Debian Jessie)

Hey there! Let's get your cmus audio switched from HDMI to the headphone jack without needing to install missing ALSA tools like alsamixer or amixer. Here are a few reliable methods tailored to your OSMC setup:

cmus has built-in audio output controls, so we can tweak this right within the player:

  1. Open cmus and press : to enter command mode.
  2. First, check your current audio output module with:
    :show ao
    
    You’ll likely see ao=alsa since OSMC uses ALSA under the hood.
  3. List all supported audio modules to confirm your options:
    :ao list
    
    Common options here are alsa and pulse—stick with alsa for most OSMC setups.
  4. Identify the correct ALSA device for your headphone jack:
    Exit cmus (press q) and run this command (no installation needed—it reads kernel audio info):
    cat /proc/asound/cards
    
    For a typical Raspberry Pi-based OSMC setup, you’ll see output like:
    0 [ALSA           ]: bcm2835 - bcm2835 ALSA
                         bcm2835 ALSA
    
    Usually, HDMI maps to hw:0,0 and the headphone jack to hw:0,1.
  5. Back in cmus, set the ALSA device to your headphone jack:
    :ao set alsa device=hw:0,1
    
    If that doesn’t work, try plughw:0,1 (adds software mixing for better compatibility) or sysdefault:CARD=ALSA.
  6. Play a track to test the output. If it works, save the config with :save so cmus uses this setting every time you launch it.

Method 2: Use OSMC’s Built-in Audio Tool

OSMC comes with a dedicated audio config utility that lets you set the system-wide default output:

  1. Exit cmus and run:
    sudo /usr/bin/osmc-audio-config
    
  2. Follow the on-screen prompts to select Analog (this corresponds to the headphone jack) as your default audio output.
  3. Restart your device or restart cmus—your music will now play through the headphones.

Method 3: Edit cmus Config File for Permanent Settings

If you want cmus to always use the headphone jack by default, edit its config file:

  1. Exit cmus and open the config file with your favorite editor (nano is pre-installed on OSMC):
    nano ~/.cmus/rc
    
  2. Add this line at the end (replace hw:0,1 with the device that worked for you):
    ao_set alsa device=hw:0,1
    
  3. Save and exit (press Ctrl+O, hit Enter, then Ctrl+X). Next time you start cmus, it’ll automatically use the headphone jack.

Any of these methods should get your audio switched over. Start with Method 1 since it targets cmus specifically without changing your system’s global audio settings.

内容的提问来源于stack exchange,提问作者Johannes Lemonde

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.19 09:15:20