mirror of
https://github.com/libretro/Lakka-LibreELEC.git
synced 2024-11-24 07:56:21 +00:00
17 lines
344 B
Bash
Executable File
17 lines
344 B
Bash
Executable File
#!/bin/sh
|
|
|
|
# SPDX-License-Identifier: GPL-2.0
|
|
# Copyright (C) 2018-present Team LibreELEC (https://libreelec.tv)
|
|
|
|
case $(dtsoc) in
|
|
amlogic,g12*|amlogic,sm1)
|
|
TEMP=$(cat /sys/devices/virtual/thermal/thermal_zone1/temp)
|
|
;;
|
|
*)
|
|
TEMP=$(cat /sys/class/hwmon/hwmon0/temp1_input)
|
|
;;
|
|
esac
|
|
|
|
TEMP="$(( $TEMP / 1000 ))"
|
|
echo "${TEMP} C"
|