Compare commits
3 Commits
52802ae6c5
...
1c52859fb4
| Author | SHA1 | Date | |
|---|---|---|---|
| 1c52859fb4 | |||
| f9f50d7167 | |||
| e21a61232d |
@@ -19,6 +19,8 @@ log = getLogger(__name__)
|
||||
|
||||
ConfigVariable = namedtuple("ConfigVariable", ["name", "value", "line_index"])
|
||||
|
||||
CONFIG_TXT_LOCATIONS = ("/boot/firmware/config.txt", "/boot/config.txt")
|
||||
|
||||
|
||||
class ComputeModuleTypes(IntEnum):
|
||||
UNKNOWN = 0
|
||||
@@ -76,7 +78,7 @@ class RevPiConfig:
|
||||
except ValueError:
|
||||
pass
|
||||
|
||||
# Detect WiFi
|
||||
# Detect WiFi on CM module
|
||||
could_have_wifi = self._cm_type in (ComputeModuleTypes.CM4, ComputeModuleTypes.CM5)
|
||||
if could_have_wifi:
|
||||
lst_grep = grep("DRIVER=brcmfmac", "/sys/class/ieee80211/phy0/device/uevent")
|
||||
@@ -106,7 +108,7 @@ class ConfigTxt:
|
||||
|
||||
def __init__(self):
|
||||
self._config_txt_path = ""
|
||||
for path in ("/boot/firmware/config.txt", "/boot/config.txt"):
|
||||
for path in CONFIG_TXT_LOCATIONS:
|
||||
if exists(path):
|
||||
self._config_txt_path = path
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user