From 0fc2103cfef72dedb625d75032dd877718e2769e Mon Sep 17 00:00:00 2001 From: Daniil Tsivinsky Date: Mon, 13 Jun 2022 20:16:12 +0300 Subject: [PATCH] update keyboard mic-mute led using huawei-wmi driver --- bin/toggle-mic-mute.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bin/toggle-mic-mute.sh b/bin/toggle-mic-mute.sh index a8dcaf7..f0ddbc4 100755 --- a/bin/toggle-mic-mute.sh +++ b/bin/toggle-mic-mute.sh @@ -10,8 +10,12 @@ if [[ "$state" == "0" ]]; then # mic is muted pactl set-source-mute @DEFAULT_SOURCE@ 0 dunstify -a "$appName" -u low -t 1000 -r "$id" "Actived microphone" "It's not muted now" + + echo "0" >/sys/devices/platform/huawei-wmi/leds/platform::micmute/brightness else # mic is not muted pactl set-source-mute @DEFAULT_SOURCE@ 1 dunstify -a "$appName" -u low -t 1000 -r "$id" "Disabled microphone" "It's muted now" + + echo "1" >/sys/devices/platform/huawei-wmi/leds/platform::micmute/brightness fi