Skip to content

Commit

Permalink
v6.35
Browse files Browse the repository at this point in the history
+ DietPi-Config | When selecting a not auto-detected sound card, a reboot is required to apply device tree changes
  • Loading branch information
MichaIng authored Jan 22, 2021
1 parent 317c35d commit 45ac1d9
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions dietpi/dietpi-config
Original file line number Diff line number Diff line change
Expand Up @@ -2829,8 +2829,8 @@ NB: All Ethernet connections will be dropped!' && Network_ApplyChanges
# Disabled
elif (( $ETH_DISABLED )); then

if G_WHIP_YESNO 'Ethernet must be enabled before settings can be changed.\n
Would you like to enable Ethernet now?\n - (NOTICE) Connections may drop!'; then
if G_WHIP_YESNO 'Ethernet must be enabled before settings can be changed.
\nWould you like to enable Ethernet now?\n - (NOTICE) Connections may drop!'; then

ETH_DISABLED=0
Network_ApplyChanges
Expand All @@ -2851,8 +2851,8 @@ Would you like to enable Ethernet now?\n - (NOTICE) Connections may drop!'; then
# Disabled | Offer chance to enable (also enables WiFi modules)
if (( $WIFI_DISABLED )); then

if G_WHIP_YESNO 'WiFi must be enabled before settings can be changed.\n
Would you like to enable WiFi now?\n - NB: Connections may drop!'; then
if G_WHIP_YESNO 'WiFi must be enabled before settings can be changed.
\nWould you like to enable WiFi now?\n - NB: Connections may drop!'; then

WIFI_DISABLED=0
Network_ApplyChanges
Expand All @@ -2862,8 +2862,8 @@ Would you like to enable WiFi now?\n - NB: Connections may drop!'; then
# No hardware found
elif (( ! $WIFI_HARDWARE )); then

if G_WHIP_YESNO 'No supported WiFi hardware was found.\n
Would you like to disable WiFi?\n - NB: Connections may drop!'; then
if G_WHIP_YESNO 'No supported WiFi hardware was found.
\nWould you like to disable WiFi?\n - NB: Connections may drop!'; then

WIFI_DISABLED=1
Network_ApplyChanges
Expand Down Expand Up @@ -3875,8 +3875,8 @@ Additional benchmarks:

if [[ $psu_noise_reduction == 'Off' ]]; then

G_WHIP_YESNO 'PSU noise reduction:\n\nThis mode attempts to reduce power consumption on your SBC. In turn, this may reduce PSU inflicted noise, that may degrade audio output quality.\n
The following will now be applied:\n - CPU governor = Powersave\n - Display output = Disabled\n\nDo you want to continue?' || return
G_WHIP_YESNO 'PSU noise reduction:\n\nThis mode attempts to reduce power consumption on your SBC. In turn, this may reduce PSU inflicted noise, that may degrade audio output quality.
\nThe following will now be applied:\n - CPU governor = powersave\n - Display output = disabled\n\nDo you want to continue?' || return

G_CONFIG_INJECT 'CONFIG_CPU_GOVERNOR=' 'CONFIG_CPU_GOVERNOR=powersave' /boot/dietpi.txt
/boot/dietpi/func/dietpi-set_cpu
Expand Down Expand Up @@ -4008,6 +4008,9 @@ The following will now be applied:\n - CPU governor = Powersave\n - Display outp
G_WHIP_MENU "Please select a soundcard\n - Current : $soundcard_current" || return
/boot/dietpi/func/dietpi-set_hardware soundcard "$G_WHIP_RETURNED_VALUE"

# RPi: Reboot required to apply device tree changes, which applies to all but auto-detected selections
(( $G_HW_MODEL > 9 )) || [[ $G_WHIP_RETURNED_VALUE == 'hw:'[0-9]','[0-9] || $G_WHIP_RETURNED_VALUE == 'usb-dac' ]] || REBOOT_REQUIRED=1

elif [[ $G_WHIP_RETURNED_VALUE == 'Auto-conversion' ]]; then

# Remove equalizer and plug suffix
Expand Down Expand Up @@ -4682,8 +4685,8 @@ _EOF_

else

G_WHIP_MSG "[FAILED] Unknown menu ID $TARGETMENUID, reverting to DietPi-Config main menu\n
This error should never show up. Please try to reproduce it. If it reappears, you found a coding bug.
G_WHIP_MSG "[FAILED] Unknown menu ID $TARGETMENUID, reverting to DietPi-Config main menu
\nThis error should never show up. Please try to reproduce it. If it reappears, you found a coding bug.
Please report it to: https://github.com/MichaIng/DietPi/issues"
TARGETMENUID=0

Expand Down

0 comments on commit 45ac1d9

Please sign in to comment.