|
1 | | -# Example: Hardware Rev 3.1 with Temperature-based Fan Control |
| 1 | +# Example: Hardware Rev 3.1 with PID Temperature Control |
2 | 2 | # |
3 | | -# This example shows how to use the hardware package together with |
4 | | -# temperature control modules for automatic fan speed adjustment. |
| 3 | +# This example shows how to use the PID temperature control module for |
| 4 | +# precise, automatic fan speed regulation using a PID controller. |
| 5 | +# The PID target temperature and gains are tunable live from Home Assistant. |
| 6 | +# |
| 7 | +# For a simpler curve-based approach, see with-temperature-curve-rev-3.1.yaml |
5 | 8 |
|
6 | 9 | packages: |
7 | | - # Include the hardware-specific configuration |
8 | | - hardware: !include ../hardware-rev-3.1.yaml |
9 | | - |
10 | | - # Include the RPM status LEDs module |
11 | | - rpm_status_leds: !include ../modules/rpm_status_leds.yaml |
12 | | - |
13 | | - # Include temperature control module (choose one): |
14 | | - # Linear control: Simple linear mapping from temperature to fan speed |
15 | | - # temperature_control: !include ../modules/temperature_linear.yaml |
16 | | - |
17 | | - # PID control: Advanced control with PID algorithm for precise temperature regulation |
18 | | - # temperature_control: !include ../modules/temperature_pid.yaml |
| 10 | + hardware: |
| 11 | + url: https://github.com/zeroflow/wifi-fancontroller |
| 12 | + files: [hardware-rev-3.1.yaml] |
| 13 | + ref: main |
| 14 | + rpm_status_leds: |
| 15 | + url: https://github.com/zeroflow/wifi-fancontroller |
| 16 | + files: [modules/rpm_status_leds.yaml] |
| 17 | + ref: main |
| 18 | + temperature_pid: |
| 19 | + url: https://github.com/zeroflow/wifi-fancontroller |
| 20 | + files: [modules/temperature_pid.yaml] |
| 21 | + ref: main |
19 | 22 |
|
20 | 23 | esphome: |
21 | 24 | name: my-fancontroller |
@@ -52,16 +55,10 @@ web_server: |
52 | 55 | # Enable captive portal for WiFi setup |
53 | 56 | captive_portal: |
54 | 57 |
|
55 | | -# You can customize the temperature control behavior by overriding |
56 | | -# substitutions from the temperature modules: |
| 58 | +# Optional: override PID gains at compile time. |
| 59 | +# All of these are also tunable live from Home Assistant without reflashing. |
57 | 60 | # |
58 | 61 | # substitutions: |
59 | | -# # For temperature_linear.yaml: |
60 | | -# target_temp: "25.0" # Target temperature in °C |
61 | | -# temp_hysteresis: "2.0" # Temperature hysteresis in °C |
62 | | -# |
63 | | -# # For temperature_pid.yaml: |
64 | | -# target_temp: "25.0" # Target temperature in °C |
65 | | -# kp: "1.0" # Proportional gain |
66 | | -# ki: "0.1" # Integral gain |
67 | | -# kd: "0.05" # Derivative gain |
| 62 | +# kp: "3.0" # Proportional gain (UI scale ×100: % fan per °C) |
| 63 | +# ki: "0.005" # Integral gain (UI scale ×100) |
| 64 | +# kd: "0.0" # Derivative gain (UI scale ×100) |
0 commit comments