diff --git a/backend/Cargo.lock b/backend/Cargo.lock index dac5d74..9416cdc 100644 --- a/backend/Cargo.lock +++ b/backend/Cargo.lock @@ -826,7 +826,7 @@ dependencies = [ [[package]] name = "powertools-rs" -version = "1.1.0-beta4" +version = "1.1.0-beta5" dependencies = [ "async-trait", "limits_core", diff --git a/backend/Cargo.toml b/backend/Cargo.toml index edd666a..4d4db5e 100644 --- a/backend/Cargo.toml +++ b/backend/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "powertools-rs" -version = "1.1.0-beta4" +version = "1.1.0-beta5" edition = "2021" authors = ["NGnius (Graham) "] description = "Backend (superuser) functionality for PowerTools" diff --git a/backend/src/settings/steam_deck/util.rs b/backend/src/settings/steam_deck/util.rs index 1d89d1c..def76e9 100644 --- a/backend/src/settings/steam_deck/util.rs +++ b/backend/src/settings/steam_deck/util.rs @@ -1,4 +1,5 @@ //! Rough Rust port of some BatCtrl functionality +//! Original: /usr/share/jupiter_controller_fw_updater/RA_bootloader_updater/linux_host_tools/BatCtrl //! I do not have access to the source code, so this is my own interpretation of what it does. //! //! But also Quanta is based in a place with some questionable copyright practices, so... @@ -95,11 +96,20 @@ pub fn set(setting: Setting, mode: u8) -> Result { #[derive(Copy, Clone)] #[repr(u8)] pub enum Setting { + CycleCount = 0x32, + ControlBoard = 0x6C, Charge = 0xA6, ChargeMode = 0x76, LEDStatus = 199, } +#[derive(Copy, Clone, Debug)] +#[repr(u8)] +pub enum ControlBoard { + Enable = 0xAA, + Disable = 0xAB, +} + #[derive(Copy, Clone, Debug)] #[repr(u8)] pub enum ChargeMode { diff --git a/package.json b/package.json index 847547a..1fad640 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "PowerTools", - "version": "1.1.0-beta4", + "version": "1.1.0-beta5", "description": "Power tweaks for power users", "scripts": { "build": "shx rm -rf dist && rollup -c", diff --git a/src/index.tsx b/src/index.tsx index 04cd538..8dd8cd1 100755 --- a/src/index.tsx +++ b/src/index.tsx @@ -263,7 +263,7 @@ const Content: VFC<{ serverAPI: ServerAPI }> = ({}) => { ); }} > - Defaults + {tr("Defaults")} diff --git a/translations/es-ES.mo b/translations/es-ES.mo index 40ddd41..ea096f8 100644 Binary files a/translations/es-ES.mo and b/translations/es-ES.mo differ diff --git a/translations/es-ES.po b/translations/es-ES.po index aef82f0..9477cf9 100644 --- a/translations/es-ES.po +++ b/translations/es-ES.po @@ -39,6 +39,11 @@ msgstr "Guardar perfil y cargarlo la próxima vez" msgid "Profile" msgstr "Perfil" +#: index.tsx:266 +# (Button to reset everything to system defaults) +msgid "Defaults" +msgstr "Valores predeterminados" + # -- components/battery.tsx -- #: components/battery.tsx:42 diff --git a/translations/fr-CA.mo b/translations/fr-CA.mo index caf046a..3303e11 100644 Binary files a/translations/fr-CA.mo and b/translations/fr-CA.mo differ diff --git a/translations/fr-CA.po b/translations/fr-CA.po index 9c38d83..cbc62df 100644 --- a/translations/fr-CA.po +++ b/translations/fr-CA.po @@ -39,6 +39,11 @@ msgstr "Sauvegarder le profile et le charger la prochaine fois" msgid "Profile" msgstr "Profile" +# (Button to reset everything to system defaults) +#: index.tsx:266 +msgid "Defaults" +msgstr "Valeurs par défaut" + # -- components/battery.tsx -- # (Battery section title) #: components/battery.tsx:42 diff --git a/translations/pt.pot b/translations/pt.pot index 44e2e02..be9b1ee 100644 --- a/translations/pt.pot +++ b/translations/pt.pot @@ -37,6 +37,11 @@ msgstr "" msgid "Profile" msgstr "" +#: index.tsx:266 +# (Button to reset everything to system defaults) +msgid "Defaults" +msgstr "" + # -- components/battery.tsx -- #: components/battery.tsx:42