mirror of
https://github.com/riptidewave93/UNVR-NAS.git
synced 2025-03-09 15:40:13 +00:00
fix: additional fixups for UNVR/UNVRPro
* Fixup fan control so it works on UNVR * Add LED integration work for UNVR * Rename our mtd-ro kernel module dir * Fixup shortnames in ubnteeprom
This commit is contained in:
parent
5962f1ea30
commit
58ce1fb99f
10 changed files with 35 additions and 32 deletions
|
@ -3,7 +3,7 @@ import os
|
|||
import re
|
||||
import time
|
||||
|
||||
from ubnthelpers import get_ubnt_shortname
|
||||
from functools import lru_cache
|
||||
|
||||
SMARTCTL_PATH = "/usr/sbin/smartctl"
|
||||
|
||||
|
@ -36,6 +36,12 @@ THERMAL_SYS_PATHS = {
|
|||
},
|
||||
}
|
||||
|
||||
|
||||
@lru_cache(None)
|
||||
def get_ubnt_shortname() -> str:
|
||||
return os.popen("ubnteeprom -systeminfo -key shortname").read().rstrip("\n")
|
||||
|
||||
|
||||
def __get_board_temps():
|
||||
# Are we supported?
|
||||
if get_ubnt_shortname() not in THERMAL_SYS_PATHS:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue