mirror of
https://github.com/archr-linux/Arch-R.git
synced 2026-03-31 14:41:55 -07:00
24 lines
592 B
Bash
Executable File
24 lines
592 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# SPDX-License-Identifier: GPL-2.0
|
|
# Copyright (C) 2020-present Team LibreELEC (https://libreelec.tv)
|
|
|
|
# find heartbeat triggers and set them to none
|
|
case $(dtsoc) in
|
|
amlogic*)
|
|
for triggerfile in $(find /sys/devices/platform/leds -name trigger); do
|
|
trigger=$(awk -F'[][]' '{print $2}' "$triggerfile")
|
|
if [ "$trigger" = "heartbeat" ]; then
|
|
echo "none" > "$triggerfile"
|
|
fi
|
|
done
|
|
;;
|
|
esac
|
|
|
|
# add device-specific led handling here
|
|
case $(dtname) in
|
|
khadas,vim3*)
|
|
echo "255" > /sys/devices/platform/leds/leds/vim3\:red/brightness
|
|
;;
|
|
esac
|