Debian ABC --- 1st time ---1

1. how to check your wireless card type, linkage

 

cor@MiWiFi-R3-srv:~$ lspci -nn | grep Network
04:00.0 Network controller [0280]: Broadcom Limited BCM43142 802.11b/g/n [14e4:4365] (rev 01)

 1.1 let's figure out how to install the right driver to enable wifi

:~$ discover --vendor-id --model-id pci | uniq
bash: discover: command not found

1.2 try

http://www.lwfinger.com/b43-firmware/

try below shell under  "root"

#!/bin/sh
#
# install_bcm43xx_firmware
#
# This script tries to download and install the firmware needed to run
# WLAN cards using Broadcom's bcm43xx chips.

# firmware for b43
URL1=http://www.lwfinger.com/b43-firmware
FILE1=broadcom-wl-5.100.138.tar.bz2
FIRMWARE1=broadcom-wl-5.100.138/linux/wl_apsta.o

# firmware for b43legacy
URL2=http://downloads.openwrt.org/sources
FILE2=wl_apsta-3.130.20.0.o

test -z "$( type -p curl)" && { echo "'curl' is not installed, aborting. Please install 'curl' and try again."; exit 1; }
test -z "$( type -p b43-fwcutter)" && { echo "'b43-fwcutter' is not installed, aborting. Please install 'b43-fwcutter' and try again."; exit 1; }
test -d /lib/firmware || mkdir -p /lib/firmware

TMPDIR=$(mktemp -d /var/tmp/bcm.XXXXXX) || exit 1

pushd $TMPDIR >/dev/null

echo "Downloading b43 firmware"
curl -# -f -o $FILE1 $URL1/$FILE1
if [ $? -eq 0 ];then
    echo "Extracting b43 firmware"
    tar xjf $FILE1
    b43-fwcutter -w /lib/firmware $FIRMWARE1
else
    echo "Could not download b43 firmware. Please look at /usr/share/doc/packages/b43-fwcutter/README."
fi

echo
echo "Downloading b43legacy firmware"
curl -# -f -o $FILE2 $URL2/$FILE2
if [ $? -eq 0 ];then
    echo "Extracting b43legacy firmware"
    b43-fwcutter -w /lib/firmware $FILE2
else
    echo "Could not download b43legacy firmware. Please look at /usr/share/doc/packages/b43-fwcutter/README."
fi

echo
if [ -d /lib/firmware/b43 ] ; then
    echo "b43 firmware successfully installed."
    sync && sync
    /sbin/modprobe -r b43
    /sbin/modprobe b43
else
    echo "b43 firmware installation failed."
fi
if [ -d /lib/firmware/b43legacy ] ; then
    echo "b43legacy firmware successfully installed."
    sync && sync
    /sbin/modprobe -r b43legacy
    /sbin/modprobe b43legacy
else
    echo "b43legacy firmware installation failed."
fi

popd >/dev/null
rm -rf $TMPDIR

exit 0

1.2.1 curl is not preinstalled

root@MiWiFi-R3-srv:/home/cor# apt-get install curl  b43-fwcutter

1.2.2   Please install 'b43-fwcutter'

root@MiWiFi-R3-srv:/home/cor# . ./installwifi.sh 
'b43-fwcutter' is not installed, aborting. Please install 'b43-fwcutter' and try again.

root@MiWiFi-R3-srv:/home/cor# apt-get install b43-fwcutter
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package b43-fwcutter

apt-get install broadcom-sta-dkms
# --> this really takes a long time to be finished
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  binutils cpp-4.9 dkms fakeroot gcc gcc-4.9 gcc-4.9-base libasan1 libcilkrts5 libcloog-isl4 libfakeroot libgcc-4.9-dev libisl10 libitm1 liblsan0
  libtsan0 libubsan0 make
Suggested packages:
  binutils-doc gcc-4.9-locales gcc-multilib manpages-dev autoconf automake libtool flex bison gdb gcc-doc gcc-4.9-multilib gcc-4.9-doc libgcc1-dbg
  libgomp1-dbg libitm1-dbg libatomic1-dbg libasan1-dbg liblsan0-dbg libtsan0-dbg libubsan0-dbg libcilkrts5-dbg libquadmath0-dbg make-doc
Recommended packages:
  linux-headers-686-pae | linux-headers-amd64 | linux-headers-generic | linux-headers linux-image libc6-dev | libc-dev libc6-dev
The following NEW packages will be installed:
  binutils broadcom-sta-dkms cpp-4.9 dkms fakeroot gcc gcc-4.9 gcc-4.9-base libasan1 libcilkrts5 libcloog-isl4 libfakeroot libgcc-4.9-dev libisl10
  libitm1 liblsan0 libtsan0 libubsan0 make
0 upgraded, 19 newly installed, 0 to remove and 98 not upgraded.
Need to get 19.9 MB of archives.
After this operation, 87.4 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
--> Y

# wait

 

posted @ 2020-03-12 22:51  碧水东流至此回  阅读(106)  评论(3)    收藏  举报