#TinyALSA doesn't work in chroot

1 messages · Page 1 of 1 (latest)

earnest shuttle
#

I don't use tinyalsa. Does it respect whatever alsamixer shows? Like whatever is the first card, it would use it by default.

#

Maybe try playing a sample that's sure to have audio first?

earnest shuttle
#

That's a bit unclear. Did you play a sample with an audio in chroot? Does this same sample play in host? You should test playing a sample in chroot that also plays with an audiable output when you play it in host.

earnest shuttle
#

You can use strace in chroot. Run strace -ff tinycap 10 test.wav -D 1 -t 10 and see if there are opening permission errors when opening any device file in /dev.

earnest shuttle
#

Looks fine to me. I see no errors.

#

Can you run alsamixer in chroot?

#

Check if settings are different there? I can only think of mic being muted.

earnest shuttle
#

I can recommend to you a way to "inject" alsamixer to your chroot from the host. But do this in a copy of your chroot directory instead.

#

Make sure /dev and all stuff are unmounted first from your chroot.

#

Then do cp -a your-chroot-directory your-chroot-directory-copy

#

Then do ( cd path/to/new-chroot && bash /path/to/rcopy.bash -t . $(which alsamixer) ).

#

Then chroot to your new chroot. Mount dev and stuff as needed.

#

See if alsamixer works.

#

It's a workaroundish method to creating a chroot. Sometimes you'll have to copy all files of a package manually. And sometimes you also have to copy a specific library manually.

earnest shuttle
#

No I'm only giving you ideas how you can debug it.

#

I never used tinyalsa myself.

#

It's not easy to figure out the problem if you don't have a working reference. If you don't have alsa it makes things more difficult.

#

Only thing left you can do is hack the source code itself.

#

Add some debug lines in crucial parts or maybe add a way to verify the device isn't muted.

earnest shuttle
#

Can't set to 1?

#

Also maybe you need to specify the ID intead of the name?

#

tinymix -D 1 set 1 34 for example to enable master playback.

#

So reverse?

#

tinymix -D 1 set 34 1?