Tiny Core Linux
Tiny Core Base => TCB Q&A Forum => Topic started by: Fakir on December 18, 2016, 02:40:38 PM
-
Hi folks,
after having managed to get live TC up und running on a macbook (http://forum.tinycorelinux.net/index.php/topic,20605.0.html (http://forum.tinycorelinux.net/index.php/topic,20605.0.html)), the only thing which isn't working yet is the sound:
I don't manage to get OSS working (app manager says that installing the actual version fails after downloading, that both for oss.tcz and ossxmix.tcz; when I want to use my old version from mid 2013 the app manager tells me to install oss-modules-4.2.9-tinycore.tcz but I doubt that these exist).
OSS always worked fine without any problem.
Alsa modules and mixer can be installed but don't play any sound.
Are there any other (good :) ) alternatives to OSS?
Do you have any idea what I could do to solve this?
Julian
-
Hi,
You could try alsa-config.tcz .
-
there's only one alternative to oss: alsa. a bad one if you ask me.
-
What sound hardware do you have (aplay -l)?
When you load the alsa extension, do you see any error messages?
Do you get any error messages with the alsamixer command? Is the master volume un-muted?
-
Hi: OSS is discontinued. I do not use it any more. I suggest: Get rid of it. Stay with Alsa only. I learned from this forum, that Alsa and OSS installed at the same time presents a conflict.
Plse try the following:
1. check sound level and mute on/off using: $ alsamixer
2. Then: $ speaker-test
(when you hear a noise, alsa is working)
-
Some issues can get solved really easily. :) Obviously I just had to install alsa.conf (before the other alsa components) and then it worked.
Thank you!
-
Hi: OSS is discontinued. I do not use it any more. I suggest: Get rid of it.
Please provide a source for this claim.
-
@hiro,
could you elaborate why ALSA is a bad alternative to OSS?
Do you think it would make sense to provide OSS support?
-
The git log shows OSS hasn't much activity:
https://sourceforge.net/p/opensound/git/ci/ac48ed061efb79b231e8b998b05264f8b33c4376/log/?path=
Last commit 2015 Feb.
-
well, ok, the last real feature change was in 2013-10-28 06:45:04 if i read the commit log correctly. after that he only tried to maintain compatibility so it builds on various OS.
but does that mean it doesn't build on recent linux any more?
-
I don't know, I haven't tried.
-
@hiro,
could you elaborate why ALSA is a bad alternative to OSS?
Do you think it would make sense to provide OSS support?
Yes indeed, I think OSS works much better out of the box with no special configuration. Configuration, if needed, is a lot more consistent. Quality of the code is higher. Alsa hurts in the ears unless you manage to compile the better resampler or disable resampling altogether. Oss uses the good old standard audio interface and is still compatible with older programs that got written before the incompatible alsa got introduced.
Also, alsa is why pulseaudio exists (pulseaudio is even more sad than alsa, but it only exists because alsa is so useless out of the box).
-
Since I still had a build script for the last OSS modules built for tc-5.x I thought I'd give this an attempt. Unfortunately the git v4.2 has changed significantly resulting in a failed build. I'll try figure this out since there's requests for it..
Sent from my iPhone using Tapatalk
-
Ok patched for Kernel 4.x the modules built successfully. these were the x86 modules which I'll try to test with the previous ossxmix etc etc from tc-4.x. and submit to repo. The thing is did the OP want x86_64 modules & app's for corpure64 for a macbook?
-
which patches exactly are you talking about? link/revision?
-
which patches exactly are you talking about? link/revision?
http://ossnext.trueinstruments.com/forum/viewtopic.php?f=3&t=5800#p21140 (http://ossnext.trueinstruments.com/forum/viewtopic.php?f=3&t=5800#p21140)
I was referring to this OSS forum post, however I lost track of which version of sources I applied the patch too and am now unable to duplicate the successful built, for x86_64 version Still a work in progress.
I also found that stripping the compiled sources prevent modules from loading, YMMV
The OSS offices are just up the street from me, I'm thinking about taking a walk and knocking on their door..
-
@ Fakir
I installed TC on a macbook air. Audio does not work for me. I installed all of the ALSA componets form the application menu, from top to bottom. Can you tell me witch files you have installed and in what order?
aplay -l:
Card 1: PCH [HDA Intel PCH], device 0: Analog CS4208 [CS4208 Analog]
alsamixer:
can not open mixer: No such file or directory
Thank you
-
@ coreplayer2: not necessarily. I just used OSS before because it worked. Alsa now does the same for me. :)
@ Frank69: I did not install TC, I always use it live from of a non-writeable usb stick. First, I load and install the alsa-conf, then the alsa-modules, then its mixer.
-
I'd be interested in getting OSS (and sgmixer) working on 32 bi x-86 (and also 64 bit), too. One of the reasons I'm a bit behind the curve with TC (I'm still primarily using 4.7.7) is that I've never got alsa to work on 7.x.
-
I have tried different orders and extensions but without success. I always use a fresh installaite so old files can not affect it. However, I keep getting the same error message: No such file or directory.
Does anyone have an idea?
-
Make sure that none of the alsa extensions are listed "onboot"
Re-boot, then: $ tce-load -i graphics-KERNEL
$ tce-load -i alsa-config
$ tce-load -i alsa
Copy and paste any error messages here.
-
Hello Juanito. Thanks for your help. These are the steps I have made
$ tce-load -i -w graphics-KERNEL
Black screen. I rebooted the system
$ tce-load -i -w graphics-KERNEL
graphics-4.2.9-tinycore is already installed!
$ tce-load -i -w alsa-config
No errors
$ tce-load -i -w alsa
No errors
$ amixer
Simple mixer control 'IEC958',0
Capabilities: pswitch pswitch-joined
Playback channels: Mono
Mono: Playback [on]
Simple mixer control 'IEC958',1
Capabilities: pswitch pswitch-joined
Playback channels: Mono
Mono: Playback [on]
Simple mixer control 'IEC958',2
Capabilities: pswitch pswitch-joined
Playback channels: Mono
Mono: Playback [on]
$ speaker-test
Playback device is default
Stream parameters are 48000Hz, S16_LE, 1 channels
Using 16 octaves of pink noise
ALSA lib pcm_dmix.c:1029:(snd_pcm_dmix_open) unable to open slave
Playback open error: -2,No such file or directory
-
What do "aplay -l" and "lsmod" give?
-
It's a long list
$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 1: PCH [HDA Intel PCH], device 0: CS4208 Analog [CS4208 Analog]
Subdevices: 1/1
Subdevice #0: subdevice #0
$ lsmod
Module Size Used by Tainted: G
snd_hda_codec_cirrus 12288 1
snd_hda_codec_generic 36864 1 snd_hda_codec_cirrus
snd_hda_intel 20480 0
snd_hda_codec 53248 3 snd_hda_codec_cirrus,snd_hda_codec_generic,snd_hda_intel
snd_hwdep 12288 1 snd_hda_codec
snd_hda_core 24576 3 snd_hda_codec_generic,snd_hda_intel,snd_hda_codec
snd_pcm 49152 3 snd_hda_intel,snd_hda_codec,snd_hda_core
snd_timer 20480 1 snd_pcm
snd 36864 7 snd_hda_codec_cirrus,snd_hda_codec_generic,snd_hda_intel,snd_hda_codec,snd_hwdep,snd_pcm,snd_timer
soundcore 12288 1 snd
joydev 16384 0
cpufreq_conservative 12288 0
cpufreq_stats 12288 0
cpufreq_powersave 12288 0
cpufreq_userspace 12288 0
squashfs 24576 103
lz4_decompress 12288 1 squashfs
loop 16384 206
hid_apple 12288 0
r8152 28672 0
cdc_ether 12288 0
usbnet 20480 1 cdc_ether
mii 12288 2 r8152,usbnet
sbs 12288 0
video 20480 0
sbshc 12288 1 sbs
xhci_pci 12288 0
xhci_hcd 73728 1 xhci_pci
ac 12288 0
battery 16384 0
lpc_ich 16384 0
pcspkr 12288 0
thunderbolt 32768 0
mei_me 12288 0
mei 36864 1 mei_me
apple_bl 12288 0
backlight 12288 2 video,apple_bl
-
I'm curious to know why your PCH [HDA Intel PCH] is listed as card 1, when the default playback device is usually card 0
post the output of this please
cat /proc/asound/cards
-
It would be good to check that you don't have ~/.asoundrc in your backup.
Does this work: $ speaker-test -Ddefault:1 -c2 -t wav -l1
-
@ coreplayer2
I can't find the hidden file ~ / .asoundrc in the directory / home / tc
$ cat /proc/asound/cards
1 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0xb0a14000 irq 52
@ Juanito
Unfortunately, I see no errors but still heard nothing
$ speaker-test -Ddefault:1 -c2 -t wav -l1
speaker-test 1.1.0
Playback device is default:1
Stream parameters are 48000Hz, S16_LE, 2 channels
WAV file(s)
Rate set to 48000Hz (requested 48000Hz)
Buffer size range from 2048 to 8192
Period size range from 1024 to 1024
Using max buffer size 8192
Periods = 4
was set period_size = 1024
was set buffer_size = 8192
0 - Front Left
1 - Front Right
Time per period = 2.850497
-
Ooops my bad, aplay -l does infact lis the sound card as device 0.
aplay -l
**** List of PLAYBACK Hardware Devices ****
card 1: PCH [HDA Intel PCH], device 0: CS4208 Analog [CS4208 Analog]
But I'd still like to see the result of
cat /proc/asound/cards
A handy alsa tip I use..
create a file named 'alsa' in ~/.X.d directory with commands to setup alsa mixer simple control, eg;
/home/tc/.X.d/alsa
amixer set "Master" 80 unmute
Which sets volume to 80% and unmute's the Master Volume Control.
@ juanito Maybe we could ask alsa startup file to create this? Would save folks a huge headache
just a thought
I use this technique to unmute the SPDIF controls at boot, which enables 'SPDIF out' via Optical cable, eg;
amixer -c 0 cset name='IEC958 Default PCM Playback Switch' on
amixer -c 1 cset name='IEC958 Playback Switch' on
-
Unfortunately, I see no errors but still heard nothing
try opening " alsamixer" and unmute the 'Matster control and increase the volume'
or enter this in the terminal
amixer set "Master" 80 unmute
Also take note of the sound card in use, F6 to select the device if not enabled by default
-
@ Juanito
Unfortunately, I see no errors but still heard nothing
$ speaker-test -Ddefault:1 -c2 -t wav -l1
speaker-test 1.1.0
Playback device is default:1
...
As coreplayer2 mentions, that probably means that the master volume is muted
@ juanito Maybe we could ask alsa startup file to create this? Would save folks a huge headache
just a thought
For me at least, if alsa-config is loaded after graphics-KERNEL (only needed if you have an hdmi device) and before alsa, then the master volume is un-muted. After that the user can adjust the various settings to their liking and use "sudo alsactl store" after alsa has been set up and add /usr/local/etc/alsa/asound.state to their backup.
@coreplayer2 - maybe you could check if alsa-config un-mutes your hardware?
-
@ juanito Maybe we could ask alsa startup file to create this? Would save folks a huge headache
just a thought
...After that the user can adjust the various settings to their liking and use "sudo alsactl store" after alsa has been set up and add /usr/local/etc/alsa/asound.state to their backup.
I hear you, but with my hardware as an example, the "sudo alsactl store" has no effect on the IEC958 / SPDIF controls, therefore I have these commands set to run in ~/X.d/alsa
I was suggesting a simple unmute wouldn't hurt if run from the Startup file, might save much confusion..
amixer set "Master" unmute
though I prefer
echo "amixer set \"Master\" unmute" >> ~/.X.d/alsa
@coreplayer2 - maybe you could check if alsa-config un-mutes your hardware?
I have both in onboot
alsa-config.tcz
Alsa.tcz and graphics tcz (loaded via Nvidia) there is no unmuting of any alsa controls, though I should try manually loading these extensions in order.
By default alsa reports this:
~$ cat /proc/asound/cards
0 [AK5370 ]: USB-Audio - AK5370
AKM AK5370 at usb-0000:00:14.0-14, full speed
1 [NVidia ]: HDA-Intel - HDA NVidia
HDA NVidia at 0xf7080000 irq 17
2 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0xf7330000 irq 31
device 0 is a USB microphone which obviously can't output audio and NVidia device is an unplugged HDMI out, so I configure devices manually
# /etc/modprobe.conf: Modprobe config file.
#
options snd-hda-intel index=0
options snd-hda-NVidia index=1
options snd-usb-audio index=2
to get this on each boot
~$ cat /proc/asound/cards
0 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0xf7330000 irq 31
1 [NVidia ]: HDA-Intel - HDA NVidia
HDA NVidia at 0xf7080000 irq 17
2 [AK5370 ]: USB-Audio - AK5370
AKM AK5370 at usb-0000:00:14.0-14, full speed
then this in ~/.X.d/alsa
amixer -c 0 cset name='IEC958 Default PCM Playback Switch' on
amixer -c 1 cset name='IEC958 Playback Switch' on
amixer set "Master" 80 unmute
Obviously using the SPDIF pass-through, I don't need to set "Master" 80 unmute (is just there for a reminder).
-
though I should try manually loading these extensions in order.
It would be good if you could try this :)
-
@Frank69 - Also try unmuting and turning up PCM, on my system i don't get sound with this muted.
-
though I should try manually loading these extensions in order.
It would be good if you could try this :)
Ok tried this :) and the results were good but not perfect.
$ tce-load -i graphics-KERNEL (Loaded via Nvidia drivers)
$ tce-load -i alsa-config (loaded next manually)
$ tce-load -i alsa (loaded last manually)
results in correct detection of devices
tc@box:~$ cat /proc/asound/cards
0 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0xf7330000 irq 32
1 [NVidia ]: HDA-Intel - HDA NVidia
HDA NVidia at 0xf7080000 irq 17
2 [AK5370 ]: USB-Audio - AK5370
AKM AK5370 at usb-0000:00:14.0-14, full speed
tc@box:~$
Master volume unmuted and set at approx. 50%
SPDIF #2 (listed as default) unmuted
SPDIF #1 muted and of course is the connection in use. After a manual unmute and we have 6channel audio out to receiver.
So a partial success
:|
-
If I load graphics-KERNEL and then alsa (i.e. I don't load alsa-config), I get this:
$ amixer set "Master" 80 unmute
amixer: Unable to find simple control 'Master',0
I guess this is because the analogue sound is not the default and hdmi is not connected.
As mentioned earlier, if I load alsa-config before alsa, then the master volume is un-muted automatically.
Maybe we could wait for tc-8.x alsa and see what happens with that?
-
@ coreplayer 2:41
if i only use alsa-config.tcz and alsa.tcz
In /mnt/sdb1/tce/onboot.lst
alsa-config.tcz
alsa.tcz
tc@box:~$ cat /proc/asound/cards
1 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0xb0a14000 irq 52
tc@box:~$ amixer
amixer: Mixer attach default error: No such file or directory
tc@box:~$ alsamixer
cannot open mixer: No such file or directory
tc@box:~$
@ nitran 01:48
I again installed graphics-KERNEL.tcz, alsa-config.tcz and alsa.tcz
In /mnt/sdb1/tce/onboot.lst
graphics-4.2.9-tinycore.tcz
alsa-config.tcz
alsa.tcz
tc@box:~$ cat /proc/asound/cards
0 [HDMI ]: HDA-Intel - HDA Intel HDMI
HDA Intel HDMI at 0xb0a10000 irq 54
1 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0xb0a14000 irq 53
tc@box:~$ amixer
Simple mixer control 'IEC958',0
Capabilities: pswitch pswitch-joined
Playback channels: Mono
Mono: Playback [on]
Simple mixer control 'IEC958',1
Capabilities: pswitch pswitch-joined
Playback channels: Mono
Mono: Playback [on]
Simple mixer control 'IEC958',2
Capabilities: pswitch pswitch-joined
Playback channels: Mono
Mono: Playback [on]
tc@box:~$ alsamixer
Alsa mixer works
I tried the Master setting to unmute
tc@box:~$ amixer set "Master" 80 unmute
amixer: Unable to find simple control 'Master',0
If I use alsamixer (F6) I can raise the master volume
I can not set the PDIF settings
Finally, I tried the audio output
tc@box:~$ speaker-test
speaker-test 1.1.0
Playback device is default
Stream parameters are 48000Hz, S16_LE, 1 channels
Using 16 octaves of pink noise
ALSA lib pcm_dmix.c:1029:(snd_pcm_dmix_open) unable to open slave
Playback open error: -2,No such file or directory
speaker-test -Ddefault:1 -c2 -t wav -l1
No audio
A mac uses Thunderbolt 3. That I have connected to my TV (HDMI).
I get a picture but no sound through hdmi
If it is not possible to play audio I will wait alsa on TC-8.x
I want to thank you for your help
-
Your situation is pretty much the same as my laptop.
One further thing you could try is to mute the headphone output - I needed to do this to get sound from the speakers with tc-6.x, but I don't need to do this with tc-7.x.
I'm pretty sure that you would manage to get sound with pulseaudio, but that's one more level of complexity/bloat...
-
Indeed similar and pulse audio works great too. However, using pulse audio requires a config file to specify hardware to use by default at each boot. I really like slick PAVControl but it needs pulse audio. There is one anomaly with pulse audio, whenever I use pulseaudio there exists a one or two second delay in opening Firefox browser menu's. Additionally as found in my case Alsa doesn't appear to support automatic configuration of two SPDIF hardware ports. So, I've reverted to using Alsa with two config files to guarantee the correct hardware is used and unmuted at every system boot no matter which extension is loaded first
-
Ooops, Sorry juanito I didn't see the post you were referring too
-
@ Frank69
Juanito is right about pulse audio. I'd install pavcontrol and pulse audio (follow pulse audio info file instructions closely).
Using pavcontrol it's an easy graphical process to redirect audio streams to any output. Once you know which configuration works on your setup you'll be able to configure Alsa to work for you
-
Thanks coreplayer2. I'm going to try this.
-
SOLVED I can play audio.
There are a some bugs and the settings are not saved, but pulse audo works.
For any readers with the same problem:
- I have installed pavcontrol.tcz from the application browser
- Pulsaudio is automatically installed
- Goto pulsaudio.tcz in te application browser
- On the right site are the instructions how to configure pulsaudio
Thanks to Juanito and coreplayer2
-
Glad you have sound working now.
There is a method to configure pavcontrol and pulse audio to use the correct device on reboots. However unless you simply like the volume control provided in pavcontrol to adjust the audio stream I would use the information regarding which device and output is used to setup alsa.
meanwhile, to make pulse audio persistent across reboots please post the full output of
pacmd list-cards
Note if the output is large, then use code tags to make it easier to read
-
The requested printout is only visible after I watched a YouTube video. For that you get an error (No PulseAudio daemon running, or not running as session daemon).
tc@box:~$ pacmd list-cards
Welcome to PulseAudio! Use "help" for usage information.
>>> 1 card(s) available.
index: 0
name: <alsa_card.pci-0000_00_1b.0>
driver: <module-alsa-card.c>
owner module: 5
properties:
alsa.card = "1"
alsa.card_name = "HDA Intel PCH"
alsa.long_card_name = "HDA Intel PCH at 0xb0a14000 irq 52"
alsa.driver_name = "snd_hda_intel"
device.bus_path = "pci-0000:00:1b.0"
sysfs.path = "/devices/pci0000:00/0000:00:1b.0/sound/card1"
device.bus = "pci"
device.vendor.id = "8086"
device.form_factor = "internal"
device.string = "1"
device.description = "Built-in Audio"
module-udev-detect.discovered = "1"
device.icon_name = "audio-card-pci"
profiles:
input:analog-stereo: Analog Stereo Input (priority 60, available: unknown)
output:analog-stereo: Analog Stereo Output (priority 6000, available: unknown)
output:analog-stereo+input:analog-stereo: Analog Stereo Duplex (priority 6060, available: unknown)
off: Off (priority 0, available: unknown)
active profile: <output:analog-stereo+input:analog-stereo>
sinks:
alsa_output.pci-0000_00_1b.0.analog-stereo/#0: Built-in Audio Analog Stereo
sources:
alsa_output.pci-0000_00_1b.0.analog-stereo.monitor/#0: Monitor of Built-in Audio Analog Stereo
alsa_input.pci-0000_00_1b.0.analog-stereo/#1: Built-in Audio Analog Stereo
ports:
analog-input: Analog Input (priority 10000, latency offset 0 usec, available: unknown)
properties:
analog-input-microphone: Microphone (priority 8700, latency offset 0 usec, available: unknown)
properties:
device.icon_name = "audio-input-microphone"
analog-output-speaker: Speakers (priority 10000, latency offset 0 usec, available: unknown)
properties:
device.icon_name = "audio-speakers"
analog-output-headphones: Headphones (priority 9000, latency offset 0 usec, available: no)
properties:
device.icon_name = "audio-headphones"
-
I've succeeded to save the pavcontrol settings.
First you need to unmute the audio and set the volume in pavcontrol.
Save the setting
sudo alsactl store
Ensure that this file is backed up on exit TC
nano /opt/.filetool.lst
Put at the bottom
usr/local/etc/alsa/asound.state
Make sure the settings are put back on boot
sudo nano /opt/bootlocal.sh
Put at the bottom
alsactl restore
-
Good job.
If you resolved changing settings and configuration with alsactrl as described in the alsa info file, then maybe your system didn't need pulseaudio after all?
Sorry have taken a while to get back to you on default.pa config file, I've been really busy with OSS this week. When complete, I'll reinstall pulseaudio so can give correct information.
If interested pulseaudio uses pacmd commandline scripting to control and set any pulseaudio parameter.
We don't have a great description of a setup in the wiki but adding a line at the end of this file
"usr/local/etc/pulse/default.pa" to configure pulseaudio on startup works great in newer systems with complicated configurations like HDMI and SPDIF
I added
set-card-profile 2 output:iec958-stereoto my default.pa file then added it to the system backup to set configuration on reboot.
The important info from "active profile: <output:analog-stereo+input:analog-stereo>" is:
active profile: <output:analog-stereo+input:analog-stereo>
However I'm not convinced your pulseaudio deamon is running correctly, but if alsactl store has resolved the issue then this is a moot point..
Meanwhile, still working on OSS
:p
-
Sorry, but I do not quite understand your post. The file
"Usr / local / etc / pulse / default.pa" in not present on TC. What does it do?
You are right. There are multiple errors with the pulse audio daemon. But it works.
-
Hi, there shouldn't be any errors. but looks to me like the dbus is not setup. follow the instructions in the pulseaudio info file
:)
-
dbus is running. I used these instructions to configure dbus
howto:
ALSA needs to be working for whatever sound device you have.
Create dbus entry for booting into X
$ Echo 'dbus-launch --sh syntax --exit-with-session "> ~ / .X.d / dbus
$ /usr/local/etc/init.d/dbus Status [Check dbus is running]
If not running, starting with dbus
$ Sudo /usr/local/etc/init.d/dbus start
If dbus was not, Initially running, add a command to start it next reboot
$ Sudo echo '/usr/local/etc/init.d/dbus start ">> /opt/bootlocal.sh
exit to console
startx
$ Pulseaudio -vv [to test]
When it is running correctly
echo "start-pulseaudio-x11"> ~ / .X.d / pulseaudio
-
ok, If configured correctly, all the menu items and tabs should be immediately available on opening of pavucontrol app, there should be no errors
:)
-
There are no problems with the app. Only if you test pulseaudio
($ PulseAudio -vv) then get some error messages.