From c290205fb9286a3609d63cc11ad7d680e6f3984f Mon Sep 17 00:00:00 2001 From: /rootzoll Date: Fri, 15 Dec 2023 01:42:31 +0100 Subject: [PATCH] #4259 activating nvme hat on sd card build (#4322) * #4259 activating nvme in config.txt * adding to CHANGES * compact config.txt --- CHANGES.md | 1 + build_sdcard.sh | 28 ++++++++-------------------- 2 files changed, 9 insertions(+), 20 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 4a16453ff..d885f24ae 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,5 +1,6 @@ ## What's new in Version 1.11.0 of RaspiBlitz? +- New: Enabling NVMe PCIe Hats - Update: RaspiOS base image from 2023-12-05 (Bookworm) - Update: Bitcoin Core v26.0 [details](https://bitcoincore.org/en/releases/26.0/) - Update: LND v0.17.3-beta [details](https://github.com/lightningnetwork/lnd/releases/tag/v0.17.3-beta) diff --git a/build_sdcard.sh b/build_sdcard.sh index cc1c0af99..6f24c588c 100644 --- a/build_sdcard.sh +++ b/build_sdcard.sh @@ -437,15 +437,18 @@ if [ "${baseimage}" = "raspios_arm64" ]; then # see https://github.com/rootzoll/raspiblitz/issues/428#issuecomment-472822840 configFile="/boot/config.txt" - max_usb_current="max_usb_current=1" - max_usb_currentDone=$(grep -c "$max_usb_current" $configFile) + raspiblitzEdits=$(grep -c "Raspiblitz" $configFile) - if [ ${max_usb_currentDone} -eq 0 ]; then + if [ ${raspiblitzEdits} -eq 0 ]; then + echo "# Raspiblitz Edits adding to $configFile" echo | tee -a $configFile echo "# Raspiblitz" | tee -a $configFile - echo "$max_usb_current" | tee -a $configFile + echo "max_usb_current=1" | tee -a $configFile + echo "dtparam=nvme" | tee -a $configFile + echo 'dtoverlay=pi3-disable-bt' | tee -a $configFile + echo 'dtoverlay=disable-bt' | tee -a $configFile else - echo "$max_usb_current already in $configFile" + echo "# Raspiblitz Edits already in $configFile" fi # run fsck on sd root partition on every startup to prevent "maintenance login" screen @@ -754,21 +757,6 @@ if [ "${baseimage}" = "raspios_arm64" ] || [ "${baseimage}" = "debian" ]; then ifconfig wlan0 down fi - echo -e "\n*** DISABLE BLUETOOTH ***" - configFile="/boot/config.txt" - disableBT="dtoverlay=disable-bt" - disableBTDone=$(grep -c "$disableBT" $configFile) - - if [ "${disableBTDone}" -eq 0 ]; then - # disable bluetooth module - echo "" | tee -a $configFile - echo "# Raspiblitz" | tee -a $configFile - echo 'dtoverlay=pi3-disable-bt' | tee -a $configFile - echo 'dtoverlay=disable-bt' | tee -a $configFile - else - echo "disable BT already in $configFile" - fi - # remove bluetooth services systemctl disable bluetooth.service systemctl disable hciuart.service