Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error setting thresholds on Matebook 16 #64

Open
Akamarai opened this issue Nov 28, 2022 · 4 comments
Open

Error setting thresholds on Matebook 16 #64

Akamarai opened this issue Nov 28, 2022 · 4 comments
Labels
not our bug This is a bug in another piece of software

Comments

@Akamarai
Copy link

Hi,
I'm under Arch Linux actually and either compiling or using AUR one i have the same issue:
The upper limit is met, but not the lower one. Example it charges up to 70% however if at 50% I plug in it still charges until 70%.

Here is the log:

INFO: 2022/11/28 10:23:16 main.go:63: matebook-applet version custom-build
TRACE: 2022/11/28 10:23:16 driver.go:135: Fn-lock is OFF
TRACE: 2022/11/28 10:23:16 driver.go:197: Checking if the fnlock endpoint is writable...
TRACE: 2022/11/28 10:23:16 driver.go:135: Fn-lock is OFF
TRACE: 2022/11/28 10:23:16 driver.go:161: successful write to driver interface
INFO: 2022/11/28 10:23:16 main.go:106: Found writable fnlock endpoint, will use it
TRACE: 2022/11/28 10:23:16 driver.go:241: got values from interface: [40 70]
TRACE: 2022/11/28 10:23:16 driver.go:262: interpreted values: min 40%, max 70%
TRACE: 2022/11/28 10:23:16 driver.go:192: Checking if the threshold endpoint is writable...
TRACE: 2022/11/28 10:23:16 driver.go:241: got values from interface: [40 70]
TRACE: 2022/11/28 10:23:16 driver.go:262: interpreted values: min 40%, max 70%
TRACE: 2022/11/28 10:23:16 driver.go:326: successful write to driver interface
INFO: 2022/11/28 10:23:16 main.go:121: Found writable battery thresholds endpoint, will use it
TRACE: 2022/11/28 10:23:16 main.go:73: looking for endpoint to save thresholds to...
TRACE: 2022/11/28 10:23:16 driver.go:241: got values from interface: [40 70]
TRACE: 2022/11/28 10:23:16 driver.go:262: interpreted values: min 40%, max 70%
INFO: 2022/11/28 10:23:16 main.go:77: Persistence thresholds values endpoint found.
TRACE: 2022/11/28 10:23:16 applet.go:38: Setting up menu...
INFO: 2022/11/28 10:23:16 applet.go:146: Couldn't get custom icon, falling back to default
TRACE: 2022/11/28 10:23:16 driver.go:241: got values from interface: [40 70]
TRACE: 2022/11/28 10:23:16 driver.go:262: interpreted values: min 40%, max 70%
TRACE: 2022/11/28 10:23:16 driver.go:192: Checking if the threshold endpoint is writable...
TRACE: 2022/11/28 10:23:16 driver.go:241: got values from interface: [40 70]
TRACE: 2022/11/28 10:23:16 driver.go:262: interpreted values: min 40%, max 70%
TRACE: 2022/11/28 10:23:16 driver.go:326: successful write to driver interface
TRACE: 2022/11/28 10:23:16 driver.go:135: Fn-lock is OFF
TRACE: 2022/11/28 10:23:16 applet.go:72: Menu is now ready
TRACE: 2022/11/28 10:23:16 applet.go:106: Setting up GUI thread...

Here some additional info:

cat /sys/devices/platform/huawei-wmi/charge_control_thresholds
→ 40 70
@nekr0z
Copy link
Owner

nekr0z commented Nov 28, 2022

Judging by the log and the platform value, the lower threshold is set correctly. Did you try to reproduce this under Windows, does the lower threshold indeed work on your model? In that case, it could be a driver problem, and needs to be reported to the driver's developers.

@Akamarai
Copy link
Author

Judging by the log and the platform value, the lower threshold is set correctly. Did you try to reproduce this under Windows, does the lower threshold indeed work on your model? In that case, it could be a driver problem, and needs to be reported to the driver's developers.

I also tried on windows and the same problem happens, but previously I am 100% sure that it worked on both Linux and windows the charging range. Now also on windows there is only the upper limit and not the lower limit. Could be a driver update ?

@nekr0z
Copy link
Owner

nekr0z commented Nov 30, 2022

Could be a driver update ?

Not really. Since the Linux driver is written totally from scratch and not by the same people as the Windows one, it's not the driver. There are only two things that are the same between Linux and Windows in this regard: the laptop itself and the BIOS.

So, the culprit is either the laptop itself (that got broken in some way) or a BIOS update (that no longer respects the lower threshold).

@nekr0z nekr0z added the not our bug This is a bug in another piece of software label Nov 30, 2022
@Akamarai
Copy link
Author

the laptop itself

I'll try to make clean install of both system in the next days and i'll update you.

BIOS update

No bios update

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
not our bug This is a bug in another piece of software
Projects
None yet
Development

No branches or pull requests

2 participants