The motor controller in an electric vehicle generates significant heat during operation. This project presents an adaptive cooling system based on a fuzzy logic controller that dynamically regulates the pump and cooling fan speeds according to real-time temperature measurements — maintaining an optimal operating temperature while reducing energy consumption compared to conventional cooling systems.
Motor controllers in electric vehicles generate significant heat during operation. If not properly managed, excessive temperatures can reduce efficiency, accelerate component aging, and affect overall system reliability.
Most conventional cooling systems operate at a fixed speed or use simple ON–OFF control, resulting in unnecessary energy consumption under varying thermal conditions. In this project, the conventional cooling system consumes an average of 12.25 W during normal operation.
To address this issue, this project presents a fuzzy logic–based cooling system that dynamically adjusts the pump and cooling fan speeds according to real-time temperature measurements. The proposed system maintains the controller within its optimal operating temperature while reducing energy consumption and improving cooling performance.
The system consists of two main components: a plant model that simulates the motor controller's heat generation using a PTC heater, and a controller model based on an ESP32 with a fuzzy logic algorithm and PWM driver to regulate the water pump and cooling fan.
DS18B20 sensors measure the water block & radiator temperatures, while an INA219 sensor monitors the system's current consumption.
The measured temperature is classified into four linguistic variables: Safe, Normal, Hot, and Critical
The fuzzy controller applies four IF–THEN rules to determine the appropriate control output based on the current temperature condition
The centroid method converts the fuzzy output into PWM signals to regulate the pump and cooling fan speeds
| Input Temperature | Range |
|---|---|
| Safe | 0–40 °C |
| Normal | 30–70 °C |
| Panas | 60–90 °C |
| Kritis | 85–100 °C |
| PWM Output | Range |
|---|---|
| Low | 0–75 |
| Mid | 50–150 |
| High | 120–220 |
| Full | 205–255 |
The prototype was experimentally evaluated through sensor validation, thermal model verification, and performance testing under both normal and disturbance conditions. The proposed fuzzy logic controller was compared with conventional cooling methods, including fixed-speed operation and ON–OFF control.
The prototype's thermal response closely matched the first-order thermal model developed in MATLAB. During the 30-minute heating test, both responses exhibited similar dynamic characteristics, resulting in a Mean Absolute Error (MAE) 0,936°C dan a Root Mean Square Error 1,227°C, confirming the accuracy of the proposed thermal model.
The three cooling strategies were evaluated under normal operating conditions to compare temperature stability, overshoot, and energy consumption. While the ON–OFF controller achieved the lowest power consumption, it introduced significant temperature oscillations. The proposed fuzzy logic controller maintained the target temperature of 44–45°C with only 0.81°C overshoot, providing a better balance between cooling performance and energy efficiency.
The cooling strategies were further evaluated under sudden thermal disturbances. The ON–OFF controller exhibited a large temperature overshoot of 29.12°C due to its binary switching behavior. In contrast, the fuzzy logic controller adapted smoothly to the changing thermal conditions, limiting the overshoot to 10.94°C and gradually restoring the controller temperature to the desired operating range.
The Overall Cooling Performance Index (OCPI) combines cooling effectiveness, temperature overshoot, and energy efficiency into a single performance metric. Under normal operating conditions, the proposed fuzzy logic controller achieved the highest OCPI score, demonstrating the best balance between thermal stability and energy efficiency.
| Performance Metric | Conventional systems | ON‑OFF | Fuzzy Logic |
|---|---|---|---|
| Normal Condition — Average Power | 12,25 W | 6,46 W | 9,15 W |
| Normal Condition — Overshoot | 0,03 °C | 12,00 °C | 0,81 °C |
| Normal Condition — OCPI | 0,84 | 0,64 | 0,90 |
| Disturbance Condition — Average Power | 12,35 W | 7,56 W | 9,22 W |
| Disturbance Condition — Overshoot | 7,88 °C | 29,12 °C | 10,94 °C |
| Disturbance Condition — OCPI | 0,87 | 0,56 | 0,83 |
The proposed fuzzy logic–based cooling system maintained the motor controller within the target operating temperature of 44–45°C while reducing average cooling system power consumption by approximately 25% compared with the conventional cooling method.
Compared with the ON–OFF controller, the fuzzy controller achieved a better balance between thermal stability and energy efficiency, obtaining the highest OCPI value (0.90) and demonstrating reliable performance under both normal and disturbed operating conditions.