27 March, 2006

Wi-Fi

  • get WG511DCB.arm from prism54.com or somewhere else (not as easy to find as you'd think) [1.0.4.3.arm?]
  • rename it into isl3890
  • copy it into /lib/firmware
  • add "alias eth1 islpci_cb" to you /etc/modprobe
  • bring up the interface after instering the PCMCIA card - "/sbin/ifconfig eth1 up" (/sbin/ifconfig/ eth0 down)
  • it helps to have wlassistant installed (yum does it for you painfully enough)
  • Try to connect to the network of choice. Don't forget to select DHCP in the network config.
  • Cross your fingers and wait
  • Alternatively
http://sourceforge.net/projects/ndiswrapper
Unfortunately this involves patching and recompiling the kernel, which is always fun.

Check your architecture

rpm -q --qf '%{ARCH}\n' kernel

24 March, 2006

Further Emacs Improvements

    • (setq-default line-spacing 2)

23 March, 2006

Mounting NTFS (Fedora)

Get the module rpm from here (see step 2 first)
  1. Become a root
    • su
  2. Check your kernel version (do this before you download the rpm)
    • uname -r
  3. Go to where you saved the rpm and install it
    • rpm -ivh ntfs-blah-blah-blach.rpm
  4. Create a mountpoint for your windows partition
    • mkdir /mnt/win
  5. Check the device identifier (look for ntfs in the output)
    • /sbin/fdisk -l
  6. Add following to your /etc/fstab
    • /dev/hda1 /mnt/windows ntfs ro,defaults,umask=0222 0 0
  7. Enjoy
Read this and more useful FC5 instructions here

ALSA

The Alsa sound mixer helps xmms and multiple instances of mplayer etc co-exist peacefully. It comes standard now with Fedora 4 and 5.
  • In ~/.mplayer/config (vo=x11 is good for tranlucency, xv- for screen captures) add
    • ao=alsa
    • softvol = "yes" # this line may also be added to ./mplayer/gui.conf in case you like gmplayer
  • xmms
    • output plugins menu - Set to Alsa
      • Under "Configure" select software mixing
  • In Dell 8500 in particular the shortcuts for master and headphone volumes are separate . You can set up you r own and bind it to a command such as the following
    • $ amixer set Headphone 5%+
Here's my ~/.asoundrc:
pcm.ossmix {
type dmix
ipc_key 1021 # must be unique!
slave {
pcm "hw:0,0"
period_time 0
period_size 1024 # must be power of 2
buffer_size 8192 # dito. It
#format "S32_LE"
#periods 128 # dito.
rate 48000
}

# bindings are cool. This says, that only the first
# two channels are to be used by dmix, which is enough for
# (most) oss apps and also lets multichannel chios work
# much faster:

bindings {
0 0 # from 0 => to 0
1 1 # from 1 => to 1
}
}

# Redirect to ossmix
pcm.!default {
type plug
slave.pcm "ossmix" # use our new PCM here
}

# Redirect to ossmix
pcm.dsp0 {
type plug
slave.pcm "ossmix" # use our new PCM here
}

# mixer0 like above
ctl.mixer0 {
type hw
card 0
}

21 March, 2006

Ha-le-lu-ja! Ha-le-lu-ja! Hibernation! Hibernation! Hi-be-e-rna-tion!

Hibebrnation finally works in Fedora 5. NVIDIA divers installed the way described below, however, seems to dislike the hibernation, especcially the wakin up part. Anyway, here is a way to enable the NVIDIA drivers under Fedora 5. (Note: Fedora 5 came with kernel version 2.6-15-2669_FC5, but was upgraded using yum to 2.6.16-1.2069_FC5)
su -
cd /etc/yum.repos.d/
wget http://people.redhat.com/davej/kernels/Fedora/FC5/kernels.repo
yum install rpm-build
yum install kernel-devel -y
yum update kernel kernel-devel -y
mkdir /root/nvidia
cd /root/nvidia
wget http://www.leemhuis.info/files/fedorarpms/MISC.lvn/graphics/xorg-x11-drv-nvidia-1.0.8178-0.lvn.5.i386.rpm
wget http://www.leemhuis.info/files/fedorarpms/MISC.lvn/graphics/nvidia-kmod-1.0.8178-0.lvn.3.2.6.15_1.1881_FC5.src.rpm
reboot
select the new kernel, then:
su -
cd /root/nvidia
rpmbuild --rebuild --target `uname -m` nvidia-kmod-*.src.rpm
cp -a /usr/src/redhat/RPMS/`uname -m`/kmod-nvidia* ./
rpm -Uvh kmod-*nvidia-1.0.8178-0.*.rpm xorg-x11-drv-nvidia-1.0.8178-0.lvn.5.i386.rpm
modprobe nvidia
chkconfig nvidia-glx on
service nvidia-glx start
nvidia-xconfig
reboot

19 March, 2006

Cette putain de "3d Modeline" est vraiment chiante, hein!

(set-face-attribute 'mode-line nil :box nil)

12 March, 2006

Loads of interesting rants on programming languages and stuff in general from the Amazon Guy

http://www.cabochon.com/~stevey/blog-rants/index.html

More Emacs - get rid of the usless GUI Stuff.

Add to .emacs


(if (fboundp 'scroll-bar-mode) (scroll-bar-mode -1))


(if (fboundp 'tool-bar-mode) (tool-bar-mode -1))


(if (fboundp 'menu-bar-mode) (menu-bar-mode -1))

03 March, 2006

To swap or not to swap?

In

/proc/sys/vm/swappiness


the paramter can be set to a value from 0 to 100.

See discussion here:
http://kerneltrap.org/node/3000

my .emacs

;; .emacs

;;; uncomment this line to disable loading of "default.el" at startup
;; (setq inhibit-default-init t)
(eval-after-load "perl-mode"
'(define-key perl-mode-map "\C-c\C-c" 'comment-region))

(show-paren-mode 1)
;; define function to match a parenthesis otherwise insert a '~'
(defun goto-match-paren (arg)
"Go to the matching parenthesis if on parenthesis otherwise insert '~'."
(interactive "p")
(cond ((looking-at "\\s\(") (forward-list 1) (backward-char 1))
((looking-at "\\s\)") (forward-char 1) (backward-list 1))
(t (self-insert-command (or arg 1)))))
(global-set-key (kbd "~") 'goto-match-paren)



;; turn on font-lock mode
(when (fboundp 'global-font-lock-mode)
(global-font-lock-mode t))

;; enable visual feedback on selections
;(setq transient-mark-mode t)

;; default to better frame titles
(setq frame-title-format
(concat "%b - emacs@" system-name))

;; default to unified diffs
(setq diff-switches "-u")
(custom-set-variables
;; custom-set-variables was added by Custom -- don't edit or cut/paste it!
;; Your init file should contain only one such instance.
'(auto-compression-mode t nil (jka-compr))
'(case-fold-search t)
'(current-language-environment "UTF-8")
'(default-input-method "rfc1345")
'(global-font-lock-mode t nil (font-lock))
'(pc-selection-mode t nil (pc-select))
'(save-place t nil (saveplace))
'(show-paren-mode t nil (paren))
'(transient-mark-mode t))
;;(custom-set-faces
;; custom-set-faces was added by Custom -- don't edit or cut/paste it!
;; Your init file should contain only one such instance.
;; '(default ((t (:stipple nil :background "ivory3" :foreground "black" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :family "adobe-courier")))))
(custom-set-faces
;; custom-set-faces was added by Custom -- don't edit or cut/paste it!
;; Your init file should contain only one such instance.
'(default ((t (:stipple nil :background "ivory3" :foreground "black" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight bold :height 90 :width normal :family "adobe-courier")))))