How to find out which EC-Tool-version my FW is on

Hello there, I want to change some battery settings using software TLP-Utility. For changing the charge-thersholds they differentiate between EC-Firmware V2 and V3 (Battery Care Vendor Specifics — TLP 1.8.0 documentation). Now I looked around a little bit about the Firmware but I´m not quite confident enough building it myself and flashing it. So I wonder how to find out which version is installed right now?

OS: Fedora
Kernel: x86_64 Linux 6.14.9-300.fc42.x86_64
CPU: AMD Ryzen 5 7640U

You can use the Framework Tool to interact with the EC.

Just follow the docs, compile the tool using Rust. You only need the tool:

# Building only the tool
cargo build -p framework_tool
ls -l target/debug/framework_tool

Afterwards you can run sudo ./target/debug/framework_tool --versions to get all the relevant versions. For my AMD Ryzen AI 300 I get:

> sudo framework_tool --versions
Place your finger on the fingerprint reader
Mainboard Hardware
  Type:           Laptop 13 (AMD Ryzen AI 300 Series)
  Revision:       MassProduction
UEFI BIOS
  Version:        03.03
  Release Date:   03/10/2025
EC Firmware
  Build version:  lilac-3.0.3-413f018 2025-03-06 05:45:28 marigold2@ip-172-26-3-226
  Current image:  RO
PD Controllers
  Right (01):       0.0.0B (MainFw)
  Left  (23):       0.0.0B (MainFw)
Laptop Webcam Module (2nd Gen)
  Firmware Version: 1.1.1
Touchpad
  Firmware Version: v0704

This tool can also be used to adjust the charging threshold:

> sudo framework_tool --charge-limit 80
Minimum 0%, Maximum 80%

@dumdidu
That is actually a bit of a difficult question to answer.
The EC has many different API calls.
E.g. to read the smart battery, to get the temperature sensors etc.
Each API call has a “version” parameter.
The EC then can handle multiple different versions by looking at the “version” parameter in the API call.

My suggestion, is just to try the tool set at V3, and if it does not work, try V2.
I have not used TLP, but it looks to me that it is expecting the following to be present:
tlp-stat -b

/sys/class/power_supply/BAT1/charge_control_end_threshold

If you don’t have that file, it might not work.

You can also use a tool called “ectool” to set the battery thresholds.

Although I have experience writing EC firmware, none of what you need should require new EC firmware.

1 Like

Thnx for the tips, I will probably try that

Hmm I´ll have a look at that tool