Archive Page 9
Here’s how to simply forward sound from one computer to another in Ubuntu.
First, install paprefs:
1 | sudo apt-get install paprefs |
Start it by executing paprefs in a terminal. If every checkbox is grayed out, you have to make a symlink to the PulseAudio modules directory as paprefs searches for the modules in the wrong place:
1 2 3 | sudo ln -s /usr/lib/pulse-0.99 /usr/lib/pulse-0.99.3 # or for a newer PulseAudio version: ln -s /usr/lib/pulse-1.0 /usr/lib/pulse-1.0.0 |
Here’s a simple shell script I wrote for controlling PulseAudio volume from shell under Linux. It takes two parameters: up and down and sets volume for all sinks.
1 2 3 4 5 6 7 8 9 10 11 12 | #!/bin/bash OLDIFS=$IFS IFS=$'\n' for L in `pacmd dump | grep set-sink-volume`; do if [ $1 = "up" ]; then pacmd set-sink-volume `echo $L | awk '{print $2}'` `echo $L | awk '{print $3+5000}'` fi if [ $1 = "down" ]; then pacmd set-sink-volume `echo $L | awk '{print $2}'` `echo $L | awk '{print $3-5000}'` fi done IFS=$OLDIFS |
Do you have problems running OpenGL apps under Wine with an Nvidia card and a 64bit Linux? Wine says X11DRV_WineGL_InitOpenglInfo couldn’t initialize OpenGL?
Here’s the fix.
– apt-get install ia32-libs, if it’s already installed and you still have problems, move on to the next step
– move everything from /usr/lib/i386-linux-gnu to /usr/lib32 EXCEPT /usr/lib/i386-linux-gnu/glib2.0.
– extract the official 64bit Nvidia driver: ./NVIDIA-Linux-x86-290.10.run -x
– copy libGL.so.290.10 (or newer) and the tls directory from Nvidia driver’s directory called 32 to /usr/lib32
– create symlinks libGL.so.1 and libGL.so in /usr/lib32, they should both point to libGL.so.290.10
– run sudo ldconfig
That’s it. Now wine should run OpenGL apps without problems.
You’ll need the package alsa-firmware. Download the latest source from www.alsa-project.org, then run these commands:
1 2 3 4 5 6 7 8 | tar -xvjf alsa-firmware-1.0.24.1.tar.bz2 cd alsa-firmware-1.0.24.1/ ./configure make sudo make install sudo modprobe -r snd_emu10k1_synth sudo modprobe -r snd_emu10k1 sudo modprobe snd_emu10k1 |
After that, you should be able to see the card as “SB Audigy” in the Ubuntu sound settings. Use 7.1 surround output to have sound on all outputs. I recommend a great util called Emutrix for manipulating inputs and outputs of the card:
1 2 3 4 5 | sudo apt-get install qt4-qmake libqt4-dev libasound2-dev svn checkout http://emutrix.googlecode.com/svn/trunk/ emutrix-read-only cd emutrix-read-only make ./emutrix |
Have a look at alsamixer too.
If you want to use jackaudio, install qjackctl with apt-get install qjackctl.
I’ll collect the Ubuntu utilities I find useful in this (continuously updated) post.
fslint: finds duplicate files in folders
Lookit: captures screenshot and uploads it to FTP/SSH/various image sharing sites. I only configured Capture are to
RSS-Aware: a simple and powerful RSS reader which stays in the panel and displays notifications if there are new items in the subscribed RSS feeds (the URLs are stored in a simple text file). Download it here.
xkill: kill windows with a key combination. Instructions are here.
nautilus-scripts: this is not an utility, just an option to extend Nautilus’ popup menu. Place your scripts in ~/.gnome2/nautilus-scripts/ and they will appear in the right click menu:
The Play with VLC on TV script I’m using here (opens the selected files with VLC on Screen3, audio out on digital S/PDIF output):
1 2 3 | #!/bin/bash DISPLAY=`echo $DISPLAY | sed s/[.]0$// | sed s/\.3$//`.3 vlc --audio-language en --sub-language=hu --spdif --aout alsa --alsa-audio-device hw:0,1 --fullscreen "$@" |
wine-launcher-creator: creates desktop launchers for wine apps. Download it here. Don’t forget to install python-qt4 with sudo apt-get install python-qt4.
gnome-keybindings import/export: a very useful script can be found here.
screenlets: widgets for your desktop. Run apt-get install screenlets, then start it’s config with screenlets.
autossh: seamlessly reconnects your SSH session when it gets disconnected. I’m using it for running tunnels in the background:
1 2 3 4 5 6 7 | #!/bin/bash #AUTOSSH_LOGFILE=/home/nonoo/autosshlog AUTOSSH_LOGLEVEL=0 AUTOSSH_GATETIME=0 AUTOSSH_POLL=60 export AUTOSSH_LOGLEVEL AUTOSSH_GATETIME AUTOSSH_POLL autossh -M 0 -f -N -q -g -L localport:serverhost:remoteport serverhost &>/dev/null |
smartd: monitors your HDDs/SSDs SMART status. Run sudo apt-get install smartmontools, then edit /etc/default/smartmontools and uncomment start_smartd=yes to make it start on system boot. It sends an email when something’s wrong.
I got a black screen under Ubuntu when the screensaver got activated, or I switched to console mode with ctrl+alt+1 and back to X with ctrl+alt+7. The cause of the problem is gnome-screensaver, so I uninstalled it, and installed xscreensaver instead.
I created a symlink at /usr/bin/gnome-screensaver-command which points at /usr/bin/xscreensaver-command. This is needed because if I use xscreensaver’s built-in lock method, it won’t notice my keypresses, only mouse movements and the screensaver could turn on if I using just my keyboard for a few minutes.
Install the following packages also: sudo apt-get install xscreensaver-data-extra xscreensaver-gl-extra
I configured xscreensaver with xscreensaver-demo:
I’ve set Turn off after to Never in System Settings -> Screen, and Lock screen after: 10 minutes. This will start the screensaver after 10 minutes.
I also had to add xscreensaver to Startup applications with the command: xscreensaver -nosplash
Here’s how to start Skype minimized under Linux. Install gdevilspie (it needs python-glade2 also, be sure to install it first), then run it. Add a new rule:
1 2 3 4 5 6 7 8 9 | ( if ( begin ( matches ( window_name ) "^Skype" ) ) ( begin ( close ) ( println "match" ) ) ) |
Start devilspie and click on the checkbox to start devilspie automatically on startup. Devilspie will be added to the Gnome startup application list, edit the entry and change the command from devilspie to devilspie -a.
I’ve installed Ubuntu on my shiny new RevoDrive 3 with my custom kernel powered installer CD. I couldn’t make it boot, so I installed a 200mb /boot partition to my other HDD and made that the first boot drive in the BIOS. Maybe I could do this solution but I didn’t want to spend more time on this and booting the kernel from the HDD works well. I made two RAID0 partitions on the Revo, one for the swap and one for the data.
» …continue reading ‘RevoDrive 3 & GTX560Ti on Ubuntu’
The current Ubuntu installer disc comes with the Linux kernel 3.0.0, but I’m planning to buy an OCZ RevoDrive 3 which has drivers in the 3.2 kernel. So I upgraded the kernel on the installer disc. Here’s how it’s done.
» …continue reading ‘Modifying Ubuntu installer CD’
About me
I'm Nonoo. This is my blog about music, sounds, filmmaking, amateur radio, computers, programming, electronics and other things I'm obsessed with.
... »