Skip to content

andrejicd/Vivax_Midea-AC_Web_Controller

Repository files navigation

❄️ Vivax Clime - Advanced ESP8266 Midea/Vivax Controller v10.0

This project transforms a cheap ESP-01S module into a powerful, smart WiFi controller for Vivax, Midea, and compatible air conditioners using the UART protocol.

Unlike factory solutions, this system operates entirely locally (no Cloud), offers instant response times, features a modern mobile-app-like interface, and unlocks advanced diagnostics that original dongles lack.

🚀 What is new in v10.0?

  • ⚡ Power Monitoring (Watts): Displays real-time power consumption (in Watts) directly on the dashboard (requires AC hardware support).
  • 🎨 Full Graphical UI: Sub-menus (Info, AC Diag, Logs) are now fully graphical with dark mode, card designs, and animations. No more raw text outputs.
  • 🔊 Sound Control: Dedicated button to toggle the AC buzzer (beep) on/off.
  • 🕵️‍♂️ Advanced Sniffer: A built-in "Matrix-style" packet sniffer (/logs) to view raw HEX data exchange between the ESP and AC.
  • 🛠️ Deep Diagnostics: The /infoAC page now visualizes internal error codes, raw sensor data, and UART connection status.
  • 🧹 Optimization: Removed the non-functional LED button (hardware limitation on specific Vivax models) to clean up the interface.

🛠 Key Features (Retained from v6.2)

  • Control: Power, Modes (Cool, Heat, Dry, Auto, Fan), Fan Speed (Min, Mid, Max, Auto).
  • Smart Sensors:
    • Indoor Room Temperature.
    • Outdoor Temperature (with error filtering for missing sensors).
  • Advanced Options: Turbo, Eco, Swing (Vertical).
  • Direct+: A special function to simulate "Step" swing movement by pulsing the swing motor for 800ms.
  • Stability:
    • Watchdog: Auto-restart if WiFi connection is lost for more than 10 minutes.
    • Anti-Freeze: Optimized communication stack.
  • Security: Protected access via Username/Password.

🔌 Hardware

Component Note
ESP-01S The "S" version is recommended (stronger signal and LED on the correct pin).
UART Adapter Mandatory adapter for ESP-01 to step down voltage from AC (5V) to ESP (3.3V).
Connector 4-pin header on the AC mainboard (looks like USB, but isn't).

Connection Diagram

Pinout for connecting Vivax AC to the ESP-01 Adapter:

Pin (AC Unit) Function Pin (Adapter) Function (ESP)
1 5V 2 VCC
2 TX 4 RX (GPIO 3)
3 RX 3 TX (GPIO 1)
4 GND 1 GND

⚠️ WARNING: Do not connect the ESP-01 directly to the AC pins without a voltage regulator/adapter. The 5V logic from the AC can destroy the ESP8266 chip.

📂 Installation & Structure

Your project folder should look like this:

Vivax Clime/
├── Vivax Clime.ino         # Main Code (v10.0)
├── Settings.h            # YOUR SETTINGS (WiFi, Passwords)
└── src/                  # Library Folder
    └── mideaAC.h         # Modified Library (v10.0 Power Edition)

1. Configuration (Settings.h)

Rename Settings_example.h to Settings.h and edit:

// 1. WiFi Network
const char* ssid = "YOUR_WIFI_NAME";
const char* password = "YOUR_WIFI_PASSWORD";

// 2. Web Interface Login
const char* www_username = "admin";
const char* www_password = "vivax";

// 3. Static IP Address (Adjust to your router 0.1 or 1.1)
IPAddress local_IP(192, 168, 0, 200); 
IPAddress gateway(192, 168, 0, 1);

// 4. OTA (Over-The-Air) Password
const char* ota_hostname = "Vivax-Klima";
const char* ota_password = "vivax123";

2. Flashing

In Arduino IDE settings:

  • Board: Generic ESP8266 Module
  • Flash Size: 1MB (FS:64KB OTA:~470KB) <-- Crucial for Web Update!
  • Upload Speed: 115200

🚦 LED Indication (Diagnostics)

Blue LED on ESP-01S (GPIO 2):

  • 🔵 Solid On: AC is Powered ON.
  • Off: AC is OFF (Standby).
  • 🔄 Blinking: No WiFi connection / Connecting.

📲 How to use on Mobile

  1. Connect to your WiFi.
  2. Open the IP address (e.g., 192.168.0.200) in your browser.
  3. Login.
  4. Web App Mode: In browser options, select "Add to Home Screen".
  5. You now have a fullscreen app icon on your phone.

Hidden / Advanced Pages:

  • /logs - Sniffer: View live data packets (HEX) to debug communication.
  • /info - System: View Uptime, WiFi Signal (RSSI), Free RAM.
  • /infoAC - Diagnostics: View extended AC sensors, Error codes, and UART status.

🔄 Firmware Update (Two Methods)

1. Via Web (Mobile/Desktop)

The easiest way to update without removing the module:

  1. In Arduino IDE: Sketch -> Export Compiled Binary.
  2. Transfer the .bin file to your phone.
  3. In the Vivax Clime app, click the "Upd" link at the bottom.
  4. Login, select the file, and click Update Firmware.

2. Via Arduino OTA (PC)

  1. In Arduino IDE, select the network port Vivax-Klima under Port.
  2. Click Upload (password is in Settings.h).

❓ FAQ

Q: The Power Usage says "0 W" or doesn't appear? A: The firmware queries the AC for power usage every 10 seconds. If your AC motherboard does not support this specific command (common in entry-level models), it will return 0 or no data.

Q: Where is the LED button? A: It was removed in v9.0. Extensive testing showed that many Vivax models do not support software control of the display via the UART port (hardware limitation).

Q: Outdoor temperature shows "--"? A: Your outdoor unit likely does not have a temperature sensor connected to the main electronics board. The software hides invalid readings automatically.

Q: What does the DIRECT button do? A: Since the library lacks a specific "step" command for this model, this button simulates a short pulse (800ms) of the Swing function to move the vanes incrementally.


Disclaimer: This is a DIY project. The author is not responsible for any damage caused by incorrect wiring or usage.

Releases

No releases published

Packages

 
 
 

Contributors