LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Containers
User Name
Password
Linux - Containers This forum is for the discussion of all topics relating to Linux containers. Docker, LXC, LXD, runC, containerd, CoreOS, Kubernetes, Mesos, rkt, and all other Linux container platforms are welcome.

Notices


Reply
  Search this Thread
Old 08-10-2020, 06:22 AM   #1
mackowiakp
Member
 
Registered: Jun 2014
Location: Poland/Gdynia
Distribution: Mageia 9, SH4, Debian
Posts: 367

Rep: Reputation: 8
Stream sound via Bluetooth to sounbar


I have Debian 10 Buster, installed in LXC container on QNAP NAS. QNAP operates using QTS 4.4.3. It is bizarre version of Ubuntu 14.4.
My goal is to play sound from container based Debian via Bluetooth on soundbar. The problem is that Debian does not recognize Bluetooth dongle. And the second problem is that I dont know how redirect audio output to Bluetooth. On "ordinary" Linux (Mageia 7) works fine the command (radio station playback):

Code:
mplayer http://stream.rcs.revma.com/ypqt40u0x1zuv
Below output from LSUSB from Debian. The Bluetooth module is detected but not recognize:

Code:
root@Debian:~# lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 1005:b155 Apacer Technology, Inc. 
Bus 001 Device 002: ID 0665:5161 Cypress Semiconductor USB to Serial
Bus 001 Device 004: ID 4851:1103  
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
And output from the first command run on Debian:

Code:
root@Debian:~# mplayer http://stream.rcs.revma.com/ypqt40u0x1zuv
MPlayer 1.3.0 (Debian), built with gcc-8 (C) 2000-2016 MPlayer Team
do_connect: could not connect to socket
connect: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.

Playing http://stream.rcs.revma.com/ypqt40u0x1zuv.
Resolving stream.rcs.revma.com for AF_INET6...
Connecting to server stream.rcs.revma.com[2001:41d0:203:8b9f::]: 80...

Failed to connect to server with AF_INET6
Resolving stream.rcs.revma.com for AF_INET...
Connecting to server stream.rcs.revma.com[51.210.113.159]: 80...
Resolving n06a-eu.rcs.revma.com for AF_INET6...
Connecting to server n06a-eu.rcs.revma.com[2001:41d0:203:81be::]: 80...

Failed to connect to server with AF_INET6
Resolving n06a-eu.rcs.revma.com for AF_INET...
Connecting to server n06a-eu.rcs.revma.com[51.178.178.190]: 80...

Name   : Radio Nowy Swiat
Cache size set to 320 KBytes
Cache fill:  0.00% (0 bytes)   
ICY Info: StreamTitle='Radio Nowy Świat - Pion i poziom!';


Audio only file format detected.
==========================================================================
Opening audio decoder: [mpg123] MPEG 1.0/2.0/2.5 layers I, II, III
AUDIO: 44100 Hz, 2 ch, s16le, 128.0 kbit/9.07% (ratio: 16000->176400)
Selected audio codec: [mpg123] afm: mpg123 (MPEG 1.0/2.0/2.5 layers I, II, III)
==========================================================================
AO: [pulse] Init failed: Connection refused
Failed to initialize audio driver 'pulse'
[AO_ALSA] alsa-lib: confmisc.c:767:(parse_card) cannot find card '0'
[AO_ALSA] alsa-lib: conf.c:4568:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory
[AO_ALSA] alsa-lib: confmisc.c:392:(snd_func_concat) error evaluating strings
[AO_ALSA] alsa-lib: conf.c:4568:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory
[AO_ALSA] alsa-lib: confmisc.c:1246:(snd_func_refer) error evaluating name
[AO_ALSA] alsa-lib: conf.c:4568:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
[AO_ALSA] alsa-lib: conf.c:5047:(snd_config_expand) Evaluate error: No such file or directory
[AO_ALSA] alsa-lib: pcm.c:2565:(snd_pcm_open_noupdate) Unknown PCM default
[AO_ALSA] Playback open error: No such file or directory
Failed to initialize audio driver 'alsa'
[AO SDL] Samplerate: 44100Hz Channels: Stereo Format s16le
[AO SDL] using aalib audio driver.
[AO SDL] Unable to open audio: No available audio device
Failed to initialize audio driver 'sdl:aalib'
Could not open/initialize audio device -> no sound.
Audio: no sound
Video: no video


Exiting... (End of file)
Output of list available devices:

Code:
root@Debian:~# mplayer -ao help
MPlayer 1.3.0 (Debian), built with gcc-8 (C) 2000-2016 MPlayer Team
Available audio output drivers:
        oss     OSS/ioctl audio output
        alsa    ALSA-0.9.x-1.x audio output
        pulse   PulseAudio audio output
        jack    JACK audio output
        nas     NAS audio output
        sdl     SDLlib audio output
        openal  OpenAL audio output
        mpegpes DVB audio output
        v4l2    V4L2 MPEG Audio Decoder output
        null    Null audio output
        pcm     RAW PCM/WAVE file writer audio output
For sure something is not installed, because I install Debian Container from GitHub as core-only image. So for example XFace env and vncserver was necessery to install manually (as many others).
So what else I have to install/configure?

[EDIT]

I chnged one no-name USB dongle to another one, no-name too. And now USB dongle is recognized but stilldont know how to redirect audio stream to bluetooth.

Below new outputs:

Code:
root@Debian:~# lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 1005:b155 Apacer Technology, Inc. 
Bus 001 Device 002: ID 0665:5161 Cypress Semiconductor USB to Serial
Bus 001 Device 006: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
root@Debian:~# mplayer -ao help  
MPlayer 1.3.0 (Debian), built with gcc-8 (C) 2000-2016 MPlayer Team
Available audio output drivers:
        oss     OSS/ioctl audio output
        alsa    ALSA-0.9.x-1.x audio output
        pulse   PulseAudio audio output
        jack    JACK audio output
        nas     NAS audio output
        sdl     SDLlib audio output
        openal  OpenAL audio output
        mpegpes DVB audio output
        v4l2    V4L2 MPEG Audio Decoder output
        null    Null audio output
        pcm     RAW PCM/WAVE file writer audio output

root@Debian:~# mplayer http://stream.rcs.revma.com/ypqt40u0x1zuv
MPlayer 1.3.0 (Debian), built with gcc-8 (C) 2000-2016 MPlayer Team
do_connect: could not connect to socket
connect: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.

Playing http://stream.rcs.revma.com/ypqt40u0x1zuv.
Resolving stream.rcs.revma.com for AF_INET6...
Connecting to server stream.rcs.revma.com[2001:41d0:203:8b9d::]: 80...

Failed to connect to server with AF_INET6
Resolving stream.rcs.revma.com for AF_INET...
Connecting to server stream.rcs.revma.com[51.210.32.71]: 80...
Resolving n02a-eu.rcs.revma.com for AF_INET6...
Connecting to server n02a-eu.rcs.revma.com[2001:41d0:203:742e::]: 80...

Failed to connect to server with AF_INET6
Resolving n02a-eu.rcs.revma.com for AF_INET...
Connecting to server n02a-eu.rcs.revma.com[51.91.64.46]: 80...

Name   : Radio Nowy Swiat
Cache size set to 320 KBytes
Cache fill:  0.00% (0 bytes)   
ICY Info: StreamTitle='Chumbawamba - Homophobia';


Audio only file format detected.
==========================================================================
Opening audio decoder: [mpg123] MPEG 1.0/2.0/2.5 layers I, II, III
AUDIO: 44100 Hz, 2 ch, s16le, 128.0 kbit/9.07% (ratio: 16000->176400)
Selected audio codec: [mpg123] afm: mpg123 (MPEG 1.0/2.0/2.5 layers I, II, III)
==========================================================================
AO: [pulse] Init failed: Connection refused
Failed to initialize audio driver 'pulse'
[AO_ALSA] alsa-lib: confmisc.c:767:(parse_card) cannot find card '0'
[AO_ALSA] alsa-lib: conf.c:4568:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory
[AO_ALSA] alsa-lib: confmisc.c:392:(snd_func_concat) error evaluating strings
[AO_ALSA] alsa-lib: conf.c:4568:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory
[AO_ALSA] alsa-lib: confmisc.c:1246:(snd_func_refer) error evaluating name
[AO_ALSA] alsa-lib: conf.c:4568:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
[AO_ALSA] alsa-lib: conf.c:5047:(snd_config_expand) Evaluate error: No such file or directory
[AO_ALSA] alsa-lib: pcm.c:2565:(snd_pcm_open_noupdate) Unknown PCM default
[AO_ALSA] Playback open error: No such file or directory
Failed to initialize audio driver 'alsa'
[AO SDL] Samplerate: 44100Hz Channels: Stereo Format s16le
[AO SDL] using aalib audio driver.
[AO SDL] Unable to open audio: No available audio device
Failed to initialize audio driver 'sdl:aalib'
Could not open/initialize audio device -> no sound.
Audio: no sound
Video: no video


Exiting... (End of file)

Last edited by mackowiakp; 08-10-2020 at 07:12 AM. Reason: Syntax error
 
  


Reply

Tags
bluetooth, debian 10, lxc, mplayer



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] bluetooth dongle + bluetooth speaker but no sound on the bluetooth speaker vonbiber Slackware 4 05-11-2017 09:53 AM
Icecast stream a stream R03L Linux - Software 1 07-17-2009 06:37 PM
program to stream the stream (or maybe streaming proxy?) jimmykarily Linux - Software 1 05-13-2009 04:35 AM
How to record a stream and start a new outputXXX.avi/mp3 for each new stream title ? frenchn00b Linux - General 4 08-04-2008 05:40 AM
Howto transcode & relay a MPEG stream to a WMV stream?? crazyivan Linux - Software 0 06-15-2007 03:18 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Containers

All times are GMT -5. The time now is 08:59 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration