Framework-System / EC tool (no restart)

I was recently made aware of a tool that Framework has developed for Linux and Windows. It is called Framework-system:
GitHub - FrameworkComputer/framework-system: Rust libraries and tools to interact with the Framework Computer systems

This piece of software allows one to check the EC for values and to make some changes to it. Things like display brightness, fingerprint led, and the battery charging limit can be viewed and changed, without needing a restart.

I’ve got it working on Linux (Ubuntu) without issue, but am having problems getting it working on Windows through a command prompt.

Has anyone had any luck with that? This is the error I’m getting:

cargo run --no-default-features --features “windows” – --test
Finished dev [unoptimized + debuginfo] target(s) in 0.19s
Running target\debug\framework_tool.exe --test
Self-Test
SMBIOS Platform: IntelGen13
SMBIOS is_framework: true
Dump EC memory region
thread ‘main’ panicked at ‘called Result::unwrap() on an Err value: Error { code: 0x80070002, message: The system cannot find the file specified. }’, framework_lib\src\chromium_ec\windows.rs:40:14
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
error: process didn’t exit successfully: target\debug\framework_tool.exe --test (exit code: 101)

WSL is not a solution either, it seems, because the virtualized Linux VM does not get direct access to hardware in that state.

2 Likes

Can’t power shell work like the terminal? Can’t it run rust stuff similarly? I have no idea of rust, but if it’s like python, you should be able to use power shell somewhat similarly

Thanks this happens under both normal cmd and administrator cmd, as well as normal powershell and administrator powershell.

Looks like it’s trying to open a device (\Device\CrosEC), but it doesn’t exist (as per the error). Is it missing a device driver?

Apparently it is, per : GitHub - FrameworkComputer/framework-system: Rust libraries and tools to interact with the Framework Computer systems

1 Like

Rust is a compiled language. It better compares to C++

This was it.

One big take away for this is that you have to disable secure boot. Be wary of this as it will force bitlocker to prompt for a key. If you switch away from a MS account and are using a local account make sure you have this, or the means to log into your MS account to recover it. Serious pain in the butt.

It is basially C/C++ with guard rails.