Archives
Tags
Author Archives: Pavel Hofman
Compiling Alsa Modules from Takashi Iwai’s GIT Repository
Download your current kernel headers: sudo aptitude install linux-headers-$(uname -r) If the command fails with “not found” error, install headers package appropriate for your running kernel. Or install whole kernel source by sudo apt-get source linux-image-$(uname -r) Download development software stack: sudo aptitude install kernel-package Clone git sound tree: git clone https://kernel.googlesource.com/pub/scm/linux/kernel/git/tiwai/sound.git If needed, switch to another branch: cd sound git checkout -b ak411x-fix remotes/origin/topic/ak411x-fix cd .. Clone git alsa-driver-build tree: git clone https://kernel.googlesource.com/pub/scm/linux/kernel/git/tiwai/alsa-driver-build.git Setup alsa kernel, configure, compile: cd alsa-driver-build.git/alsa utils/setup-alsa-kernel ../../sound ./gitcompile If your kernel headers are located in a different directory than /usr/src/linux-headers-$(uname -r), specify the path … Continue reading
Posted in Linux Audio
Comments Off on Compiling Alsa Modules from Takashi Iwai’s GIT Repository
Pulseaudio with LD_PRELOADing libsoxr-lsr
Pulseaudio with default-sample-rate=192000 and resample-method=src-sinc-best-quality takes about 90% CPU on my i5, aplay via default (pulse plugin) complains about xruns, pulseaudio gets killed eventually (I do not know what kills it, CPU ulimit is unlimited, probably some laptop service watching CPU hogs). Simply starting pulseaudio with LD_PRELOAD LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libsoxr-lsr.so.0 pulseaudio drops pulseaudio CPU load down to 6-9% while resampling running (checked in the card’s hw_params). That was simple 🙂 Integrating with client-spawn pulseaudio Tested on Mint15: 1. Create executable script /usr/local/bin/pulseaudio.sh. Make sure to use correct path to your libsoxr-lsr library: #! /bin/bash export LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libsoxr-lsr.so.0 exec /usr/bin/pulseaudio $@ Do not forget … Continue reading
Posted in Linux Audio
1 Comment
Using libsoxr-lsr in Alsa Rate Plugin with LD_PRELOAD
Since my previous post the great libsoxr library incl. the libsoxr-lsr variant has become part of debian testing/ubuntu repositories. It means we can easily use it instead of libsamplerate now. Just install the package: pavel@samsung ~ $ aptitude search libsoxr p libsoxr-dev – High quality 1D sample-rate conversion lib p libsoxr-dev:i386 – High quality 1D sample-rate conversion lib p libsoxr-lsr0 – High quality 1D sample-rate conversion lib p libsoxr-lsr0:i386 – High quality 1D sample-rate conversion lib p libsoxr0 – High quality 1D sample-rate conversion lib p libsoxr0:i386 – High quality 1D sample-rate conversion lib sudo aptitude install libsoxr-lsr0 Check contents … Continue reading
Posted in Linux Audio
Comments Off on Using libsoxr-lsr in Alsa Rate Plugin with LD_PRELOAD
DTS SPDIF input decoder
DTS only, DD does not work (mplayer does not detect the format) arecord -q -t raw -c2 -r 48000 -f S16_LE -D plughw:0,1 | mplayer – -channels 6 -ao alsa:device=plughw=0
Posted in IT Infrastructure
Comments Off on DTS SPDIF input decoder
Support for libsoxr in alsa rate plugin
Preliminary results of libsoxr integration Plugin rate API modified to allow float. This avoids the information loss of int24->int16 conversion currently occuring in alsa-lib (int24->float32 is bit perfect). Libsamplerate (and libsoxr) use float internally. The sweep file generated by: sox -V -r 44100 -c 2 -s -b 24 -n sweep.wav synth 10 sine 1:22000 vol -6dB Spectrum of the sweep sox sweep.wav -n spectrogram -w Kaiser -z 180 -o spectrum-sweep.png Devices defined in .asoundrc: pcm.raw { type hw card 0 device 0 format S32_LE } pcm.flexibleraw { type plug slave.pcm raw } pcm.dumpratefile { type file #slave.pcm flexibleraw slave.pcm null … Continue reading
Posted in Linux Audio
1 Comment
Tool for A/B Testing
Here is a simple script for A/B testing. Just modify the CONFIG section to your needs, or feel free to rewrite completely 🙂 Continue reading
Posted in Linux Audio
Comments Off on Tool for A/B Testing
Offline Copies for Central BackupPC server
Making offline copies of a large backuppc server is a backuppc mailing list evergreen. Here is a brief decription of what we have been using for a few years now. Continue reading
Simple Centralized WakeOnLAN Service
Company-wide systems serving individual computers need a centralized WakeOnLAN service to turn them on in a simple and scriptable way. Here is a simple PHP script its authors generously shared on internet. I did only minor modifications. The tool has proven useful for nightly backups, data updates of our workstations, as well as remote access to already shut-down computers. Continue reading
Posted in IT Infrastructure
Comments Off on Simple Centralized WakeOnLAN Service
BackupPC with Locking and WOL
The wonderful BackupPC project has been serving us well for many years. Since backups occur preferably at night and energy costs rise, the machines should be shutdown as soon as the backup finishes. However, apart of backups, other nightly services run on the backed-up machines, requiring centralized locking/synchronization. Throughout the years we have enhanced our BackupPC installation with WOL capability, simple centralized locks, config templates, and other features. Continue reading
Posted in IT Infrastructure
Comments Off on BackupPC with Locking and WOL