Skip to content

Commit

Permalink
Updates for BBB kernel/wifi
Browse files Browse the repository at this point in the history
  • Loading branch information
dkulp committed Apr 19, 2024
1 parent 861bf5d commit e172a8a
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 10 deletions.
10 changes: 5 additions & 5 deletions SD/FPP_Install.sh
Expand Up @@ -48,7 +48,7 @@
#
#############################################################################
FPPBRANCH=${FPPBRANCH:-"master"}
FPPIMAGEVER="2024-03"
FPPIMAGEVER="2024-04"
FPPCFGVER="86"
FPPPLATFORM="UNKNOWN"
FPPDIR=/opt/fpp
Expand Down Expand Up @@ -495,7 +495,7 @@ case "${OSVER}" in
gettext apt-utils x265 libtheora-dev libvorbis-dev libx265-dev iputils-ping mp3gain \
libmosquitto-dev mosquitto-clients mosquitto libzstd-dev lzma zstd gpiod libgpiod-dev libjsoncpp-dev libcurl4-openssl-dev \
fonts-freefont-ttf flex bison pkg-config libasound2-dev mesa-common-dev qrencode libusb-1.0-0-dev \
flex bison pkg-config libasound2-dev python3-distutils libssl-dev libtool bsdextrautils iw rsyslog smartmontools tzdata"
flex bison pkg-config libasound2-dev python3-distutils libssl-dev libtool bsdextrautils iw rsyslog tzdata"

if [ "$FPPPLATFORM" == "Raspberry Pi" -o "$FPPPLATFORM" == "BeagleBone Black" ]; then
PACKAGE_LIST="$PACKAGE_LIST firmware-realtek firmware-atheros firmware-ralink firmware-brcm80211 firmware-iwlwifi firmware-libertas firmware-zd1211 firmware-ti-connectivity zram-tools"
Expand All @@ -506,7 +506,7 @@ case "${OSVER}" in
PACKAGE_LIST="$PACKAGE_LIST ccache"
fi
if [ "$FPPPLATFORM" != "BeagleBone Black" ]; then
PACKAGE_LIST="$PACKAGE_LIST libva-dev"
PACKAGE_LIST="$PACKAGE_LIST libva-dev smartmontools"
fi
if $isimage; then
PACKAGE_LIST="$PACKAGE_LIST networkd-dispatcher systemd-resolved"
Expand Down Expand Up @@ -710,6 +710,7 @@ case "${FPPPLATFORM}" in

systemctl disable keyboard-setup
systemctl disable unattended-upgrades
systemctl disable resize_filesystem
;;

'Raspberry Pi')
Expand Down Expand Up @@ -1341,10 +1342,9 @@ if [ "x${FPPPLATFORM}" = "xBeagleBone Black" ]; then
sed -i -e "s/#force_color_prompt=yes/force_color_prompt=yes/" /home/fpp/.bashrc

#adjust a bunch of settings in /boot/uEnv.txt
sed -i -e "s+^#enable_uboot_cape_universal=\(.*\)+enable_uboot_cape_universal=1+g" /boot/uEnv.txt
sed -i -e "s+^#disable_uboot_overlay_video=\(.*\)+disable_uboot_overlay_video=1+g" /boot/uEnv.txt
sed -i -e "s+#uboot_overlay_addr0=\(.*\)+uboot_overlay_addr0=/lib/firmware/bbb-fpp-reserve-memory.dtbo+g" /boot/uEnv.txt
sed -i -e "s+#uboot_overlay_addr4=\(.*\)+uboot_overlay_addr4=/lib/firmware/AM335X-I2C2-400-00A0.dtbo+g" /boot/uEnv.txt
sed -i -e "s+#uboot_overlay_addr5=\(.*\)+uboot_overlay_addr5=/lib/firmware/AM335X-I2C1-400-00A0.dtbo+g" /boot/uEnv.txt
sed -i -e "s+ quiet+ quiet rootwait+g" /boot/uEnv.txt
sed -i -e "s+ net.ifnames=.+ +g" /boot/uEnv.txt
sed -i -e "s+^uboot_overlay_pru=+#uboot_overlay_pru=+g" /boot/uEnv.txt
Expand Down
55 changes: 50 additions & 5 deletions SD/README.BBB
Expand Up @@ -62,13 +62,21 @@ systemctl enable systemd-resolved

#check
cd /root
export NEW_KERNEL_VERSION=6.7.4-fpp12_1
export BASE_NEW_KERNEL_VERSION=6.6.25-fpp14
export NEW_KERNEL_VERSION=6.6.25-fpp14_1
wget https://github.com/FalconChristmas/fpp-linux-kernel/raw/master/debs/linux-image-${NEW_KERNEL_VERSION}_armhf.deb
# wget https://github.com/FalconChristmas/fpp-linux-kernel/raw/master/debs/linux-headers-${NEW_KERNEL_VERSION}_armhf.deb
dpkg -i *.deb
rm -f *.deb
apt-get remove -y --purge --autoremove linux-image-$(uname -r) linux-headers-$(uname -r) bbb.io-kernel-tasks

wget https://github.com/FalconChristmas/fpp-linux-kernel/raw/master/debs/wireless-${BASE_NEW_KERNEL_VERSION}.tgz
tar -xzf wireless-${BASE_NEW_KERNEL_VERSION}.tgz
cp -a wireless/* /lib/modules/${BASE_NEW_KERNEL_VERSION}/kernel/drivers/net/wireless
depmod -a ${BASE_NEW_KERNEL_VERSION}
rm -rf wireless
rm -f wireless-${BASE_NEW_KERNEL_VERSION}.tgz

# delete old kernels and modules in /boot and /lib/modules
# and in /boot/dtbs and any initrd's
rm -rf /lib/modules/$(uname -r)
Expand Down Expand Up @@ -109,6 +117,43 @@ echo "blacklist bluetooth" > /etc/modprobe.d/blacklist-bluetooth.conf
echo "blacklist hci_uart" >> /etc/modprobe.d/blacklist-bluetooth.conf
echo "blacklist bnep" >> /etc/modprobe.d/blacklist-bluetooth.conf


echo "options 8188eu.ko rtw_power_mgnt=0 rtw_enusbss=0" > /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 8192eu.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 8723au.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 8723bu.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 8812au.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 8814au.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 8821au.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 8821cu.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 8852au.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 8852bu.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options 88x2bu.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options rtl8188fu.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf
echo "options rtl8192cu.ko rtw_power_mgnt=0 rtw_enusbss=0" >> /etc/modprobe.d/wifi-disable-power-management.conf

rm -f /etc/modprobe.d/blacklist-native-wifi.conf
touch /etc/modprobe.d/blacklist-native-wifi.conf
#echo "blacklist rtl8192cu" >> /etc/modprobe.d/blacklist-native-wifi.conf
#echo "blacklist rtl8192c_common" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtl8xxxu" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist r8188eu" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtl8188fu" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtl818x" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtl8712" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtl8188eu" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtl8723bs" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtl8187" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist r8188eu" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist r8723bs" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist r8712u" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtw88_8822bu" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtw88_8822b" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtw88_usb" >> /etc/modprobe.d/blacklist-native-wifi.conf
echo "blacklist rtw88_core" >> /etc/modprobe.d/blacklist-native-wifi.conf



# need to reboot so that the new kernel is picked up and used
reboot
#re-login in and make sure "df -k" reports 2.5G+ of space for /
Expand Down Expand Up @@ -136,9 +181,9 @@ rmdir /tmp/rootfs

# Put the SD card back in a Linux system and run the following (substitute
# the proper device name for your SD card in place of '/dev/sdc'):
VERSION=8.0-pre-alpha2
OSVERSION=2024-02
DEVICE=/dev/sde
VERSION=8.0-pre-alpha4
OSVERSION=2024-04
DEVICE=/dev/sdc
dd if=${DEVICE} of=FPP-v${VERSION}-BBB.img bs=1M count=3572


Expand All @@ -150,6 +195,6 @@ apt-get install squashfs-tools
mount ${DEVICE}1 /mnt
mksquashfs /mnt BBB-${VERSION}_${OSVERSION}.fppos -b 512K -comp xz
cd /mnt/root
tar -czf ~/ccache-BBB-2023.x-v${VERSION}.tar.gz .ccache
tar -czf ~/ccache-BBB-2024.x-v${VERSION}.tar.gz .ccache
cd ~
umount /mnt

0 comments on commit e172a8a

Please sign in to comment.