mirror of
https://gitlab.steamos.cloud/holo/steamos-manager.git
synced 2025-07-06 06:30:27 -04:00
Merge branch 'work/matts/unify-device-series' into 'master'
Add platform configurations for Legion Go, ROG Ally, and ROG Ally X See merge request holo/steamos-manager!2
This commit is contained in:
commit
b926dbd50b
4 changed files with 70 additions and 1 deletions
12
data/platforms/rog-ally-series.toml
Normal file
12
data/platforms/rog-ally-series.toml
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
[performance_profile]
|
||||||
|
platform_profile_name = "asus-wmi"
|
||||||
|
# until custom mode is added
|
||||||
|
suggested_default = "performance"
|
||||||
|
|
||||||
|
[tdp_limit]
|
||||||
|
method = "firmware_attribute"
|
||||||
|
|
||||||
|
[tdp_limit.firmware_attribute]
|
||||||
|
attribute = "asus-armoury"
|
||||||
|
# until custom mode is added
|
||||||
|
performance_profile = "performance"
|
|
@ -200,6 +200,48 @@ pub mod test {
|
||||||
assert!(steam_deck_variant().await.is_err());
|
assert!(steam_deck_variant().await.is_err());
|
||||||
assert!(device_variant().await.is_err());
|
assert!(device_variant().await.is_err());
|
||||||
|
|
||||||
|
write(crate::path(SYS_VENDOR_PATH), "ASUSTeK COMPUTER INC.\n")
|
||||||
|
.await
|
||||||
|
.expect("write");
|
||||||
|
write(crate::path(BOARD_NAME_PATH), "INVALID\n")
|
||||||
|
.await
|
||||||
|
.expect("write");
|
||||||
|
write(crate::path(PRODUCT_NAME_PATH), "INVALID\n")
|
||||||
|
.await
|
||||||
|
.expect("write");
|
||||||
|
assert_eq!(
|
||||||
|
steam_deck_variant().await.unwrap(),
|
||||||
|
SteamDeckVariant::Unknown
|
||||||
|
);
|
||||||
|
assert_eq!(
|
||||||
|
device_variant().await.unwrap(),
|
||||||
|
(DeviceType::Unknown, String::from("unknown"))
|
||||||
|
);
|
||||||
|
|
||||||
|
write(crate::path(BOARD_NAME_PATH), "RC71L\n")
|
||||||
|
.await
|
||||||
|
.expect("write");
|
||||||
|
assert_eq!(
|
||||||
|
steam_deck_variant().await.unwrap(),
|
||||||
|
SteamDeckVariant::Unknown
|
||||||
|
);
|
||||||
|
assert_eq!(
|
||||||
|
device_variant().await.unwrap(),
|
||||||
|
(DeviceType::RogAlly, String::from("RC71L"))
|
||||||
|
);
|
||||||
|
|
||||||
|
write(crate::path(BOARD_NAME_PATH), "RC72LA\n")
|
||||||
|
.await
|
||||||
|
.expect("write");
|
||||||
|
assert_eq!(
|
||||||
|
steam_deck_variant().await.unwrap(),
|
||||||
|
SteamDeckVariant::Unknown
|
||||||
|
);
|
||||||
|
assert_eq!(
|
||||||
|
device_variant().await.unwrap(),
|
||||||
|
(DeviceType::RogAllyX, String::from("RC72LA"))
|
||||||
|
);
|
||||||
|
|
||||||
write(crate::path(SYS_VENDOR_PATH), "LENOVO\n")
|
write(crate::path(SYS_VENDOR_PATH), "LENOVO\n")
|
||||||
.await
|
.await
|
||||||
.expect("write");
|
.expect("write");
|
||||||
|
@ -218,6 +260,18 @@ pub mod test {
|
||||||
(DeviceType::Unknown, String::from("unknown"))
|
(DeviceType::Unknown, String::from("unknown"))
|
||||||
);
|
);
|
||||||
|
|
||||||
|
write(crate::path(PRODUCT_NAME_PATH), "83E1\n")
|
||||||
|
.await
|
||||||
|
.expect("write");
|
||||||
|
assert_eq!(
|
||||||
|
steam_deck_variant().await.unwrap(),
|
||||||
|
SteamDeckVariant::Unknown
|
||||||
|
);
|
||||||
|
assert_eq!(
|
||||||
|
device_variant().await.unwrap(),
|
||||||
|
(DeviceType::LegionGo, String::from("83E1"))
|
||||||
|
);
|
||||||
|
|
||||||
write(crate::path(PRODUCT_NAME_PATH), "83L3\n")
|
write(crate::path(PRODUCT_NAME_PATH), "83L3\n")
|
||||||
.await
|
.await
|
||||||
.expect("write");
|
.expect("write");
|
||||||
|
|
|
@ -165,7 +165,10 @@ impl PlatformConfig {
|
||||||
async fn load() -> Result<Option<PlatformConfig>> {
|
async fn load() -> Result<Option<PlatformConfig>> {
|
||||||
let platform = match device_type().await? {
|
let platform = match device_type().await? {
|
||||||
DeviceType::SteamDeck => "jupiter",
|
DeviceType::SteamDeck => "jupiter",
|
||||||
DeviceType::LegionGoS => "legion-go-s",
|
DeviceType::LegionGo => "legion-go-series",
|
||||||
|
DeviceType::LegionGoS => "legion-go-series",
|
||||||
|
DeviceType::RogAlly => "rog-ally-series",
|
||||||
|
DeviceType::RogAllyX => "rog-ally-series",
|
||||||
_ => return Ok(None),
|
_ => return Ok(None),
|
||||||
};
|
};
|
||||||
let config = read_to_string(format!(
|
let config = read_to_string(format!(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue