Quote:
Originally Posted by fatmcgav
HI Emmanuel_uk,
cheers for the tip.
Whats the easiest way of gettin it set to load before the login-page, as i ultimatly want the system to run headless...
Could i do it just after ndiswrapper?
Cheers
Fatmcgav
|
I saw a post somewhere that recommended udev. The nice thing about udev is that I can change USB ports and it works automagically. Here's what I came up with:
/etc/udev/rules.d/wireless.rules:
SUBSYSTEM=="usb", SYSFS{product}=="Linksys Wireless-G USB Network Adapter with SpeedBooster", RUN+="/usr/local/bin/enableWireless.sh $kernel"
/usr/local/bin/enableWireless.sh:
#!/bin/sh
# Ensure that there is at least one argument.
if [ $# -lt 1 ] ; then
echo "Too few arguments passed to $0"
exit -1
fi
# Putting a '1' into this file overrides the kernel's erroneous denial
# of this device.
FILE="/sys/bus/usb/devices/$1/bConfigurationValue"
# Only put a '1' into the file if it is empty.
if [ "`cat $FILE`" == "" ] ; then
echo -n 1 > $FILE
fi
Enjoy