Commit Graph

116 Commits

Author SHA1 Message Date
4c0cea5f33
Merge pull request #25 from Eraden/readable-errors-and-voltage
Better error messages, better error handling, improve temp config, move forward with voltage
2021-11-24 12:16:38 +01:00
Adrian Woźniak
75737de396
Better error messages, better error handling, improve temp config, move forward with voltage
Reorganize code, add basic voltage manipulation, fix errors

Reorganize code, add basic voltage manipulation, fix errors
2021-11-21 12:42:36 +01:00
2220c3084f
Merge pull request #23 from Eraden/add_temp_input
Default temp input
2021-08-22 21:44:03 +02:00
772b461565
Fix clippy warnings 2021-08-22 21:05:01 +02:00
a68eeda117
Default temp input 2021-08-20 19:18:07 +02:00
806e8da4ee
Reveerse comand namespace 2021-08-05 10:27:00 +02:00
BoostCookie
de85a17e66
Merge pull request #21 from Eraden/fix-logs
Set default log level and initialize logger before load config
2021-08-04 22:02:49 +02:00
Stefan Gehr
09007b78ac as_str() instead of to_str() for loglevel 2021-08-04 22:01:59 +02:00
BoostCookie
28c8b89d71
Merge branch 'main' into fix-logs 2021-08-04 21:59:31 +02:00
5f5b3bc69b
Merge pull request #17 from Eraden/prepare-for-voltage
[WIP] Prepare code for adding voltage
2021-08-04 21:36:59 +02:00
c110d98959
Set default log level and initialize logger before load config 2021-08-04 16:00:28 +02:00
bc2a9fe87d
Set default log level and initialize logger before load config 2021-08-04 14:13:30 +02:00
d9e72d5727
Prepare code for adding voltage
Add clippy and fmt checks

Prepare code for adding voltage
2021-08-02 22:55:51 +02:00
90e1dcdad6
Update binary version 2021-08-02 11:02:27 +02:00
e33de2cd96
Merge pull request #15 from Eraden/refactor-and-fixes
Refactor and fixes
2021-08-02 10:44:31 +02:00
Adrian Woźniak
a527f7396e
Replace len() < 1 with is_empty() 2021-08-02 10:21:11 +02:00
Stefan Gehr
0539f0b515 Workaround for service starting before hwmon paths
Let the service fail when there are no hwmon paths yet.
2021-08-02 00:08:04 +02:00
Stefan Gehr
e5cac912c1 Correct ExecStart-Path for systemd-service
Also added correct dependency local-fs.target
But often the hwmon paths are still not resolved when the service starts ¯\_(ツ)_/¯
2021-08-02 00:05:21 +02:00
Stefan Gehr
35532b1eb7 Simplifications and fixes for edge cases
monitor.rs: Removed hardcoded pwm-range of 0 to 255 and instead
correctly interpolate between pwm_min() and pwm_max()
main.rs: Simpler comparison to check whether temperature changed since
last time
hw_mon.rs: Removed unnecessary conversions between u32 and u64
2021-08-02 00:02:03 +02:00
Adrian Woźniak
c5f968fcf9
Move hw_mod to own file. 2021-07-31 22:42:58 +02:00
Adrian Woźniak
365c58ff37
Move errors to own file. Move monitor to own file. 2021-07-31 22:40:57 +02:00
Adrian Woźniak
8c5fa618c3
Refactor after review 2021-07-31 22:33:32 +02:00
6eeeb3a487
Update src/main.rs
Co-authored-by: Richard Kuhnt <r15ch13+git@gmail.com>
2021-07-31 20:34:41 +02:00
73369978ca
Update src/main.rs
Co-authored-by: Richard Kuhnt <r15ch13+git@gmail.com>
2021-07-31 20:33:45 +02:00
Adrian Woźniak
cfa9867e3d
Refactor, fix broken resolve conflicts, add verbose monitor, skip update speed if temp didn't changed. 2021-07-30 21:34:31 +02:00
1484daee9a
Merge pull request #13 from Eraden/compress-binary
Compress binary
2021-07-30 13:02:32 +02:00
Adrian Woźniak
768c0e6dce
Add sudo 2021-07-30 12:50:59 +02:00
Adrian Woźniak
01aa49f761
Compress binary 2021-07-30 12:50:59 +02:00
Adrian Woźniak
41571459d6
Move start service to graphical 2021-07-30 12:48:22 +02:00
Adrian Woźniak
f69465843f
Move start service to graphical 2021-07-30 10:22:38 +02:00
2c7dd81a30
Merge pull request #12 from Eraden/service-fix
Move start service after graphics
2021-07-29 10:45:45 +02:00
ac1daf69ea
Merge pull request #9 from BoostCookie/main
Fanspeeds as floats, 0 is lowest speed, bugfixes
2021-07-29 10:40:00 +02:00
20214db390
Update main.rs 2021-07-29 10:32:21 +02:00
e9985d50b5
Update main.rs 2021-07-29 10:28:13 +02:00
c54bdc0af0
Update main.rs 2021-07-29 10:21:26 +02:00
fe2ed25ff7
Merge branch 'main' into main 2021-07-29 10:10:19 +02:00
21300d4d48 Move start service after graphics. NOTE: graphic is always after multi-user 2021-07-28 22:49:06 +02:00
136a61f65a
Merge pull request #7 from r15ch13/vega-fix
Compare target pwm value to pwm1_min and pwm1_max instead of fan rpm
2021-07-28 21:22:38 +02:00
Richard Kuhnt
cbe1203fb0 Use .unwrap_or_default() in pwm_min/fan_min 2021-07-28 21:07:00 +02:00
Stefan Gehr
6b17d3815f Use pwm_min, pwm_max for converting speed to pwm
Don't hardcode 0 and 255 anymore. Instead use pwm_min and pwm_max as
boundaries when converting from a speed (0 to 100) to a pwm value.
0 gets mapped to pwm_min, 100 gets mapped to pwm_max everything inbetween
gets linearly interpoltated.
2021-07-20 09:53:22 +02:00
Stefan Gehr
90e212a158 Fanspeeds as floats, 0 is lowest speed, bugfixes
1. The fanspeeds can now be specified as floats for better granularity
2. Removed 4 as the lowest possible speed. Lowest possible value is now 0.0
3. min and max values are now correctly read for pwm1 and not the rpm
   values of fan1 anymore
4. Percentage speed now gets correctly converted to the pwm values
   (usually between 0 and 255)
5. Before the update of the pwm-value was skipped when the current speed
   was below minimum or above maximum. This got removed. Why was that
   there in the first place?
6. Simpler algorithm for speed_for_temp
7. in monitor the min value is now actually below MIN and the max value
   below MAX. Before it was swapped
8. Fixed grammar error "can's" instead of "can't"
2021-07-19 22:25:34 +02:00
Richard Kuhnt
56b5ff2f89 Convert speed value from config to PWM 2021-07-19 19:20:47 +02:00
Richard Kuhnt
73a0a4d7fc Compare target pwm value to pwm1_min and pwm1_max instead of fan rpm
- Add PWM values to monitor
2021-07-19 17:12:55 +02:00
Adrian Woźniak
0794605006
Primary license 2021-07-05 08:08:55 +02:00
Adrian Woźniak
6996d67ee5
Primary license 2021-07-05 08:07:06 +02:00
f121e165a5 Fix apache2 license file 2021-07-04 08:42:45 +02:00
8737403888
Merge pull request #5 from AuroransSolis/main
Add OpenRC service file
2021-07-04 08:06:00 +02:00
Aurorans Solis
ddf02e3b9c OpenRC service file. 2021-07-03 15:49:35 -07:00
Adrian Woźniak
408b5864cd
Test parse card0, move checking vendor 2021-07-04 00:09:20 +02:00
2b3a41cb9b
Update rust.yml 2021-07-04 00:09:20 +02:00