As usual, the problem isn't a new problem, and this isn't a new solution. But I will describe it to help someone doing the same.
With this project I've made a wifi infra-red remote control for my Daikin air conditioner.
In these schema you can see all parts involved.
Some more details:
- normal air conditioner is controlled by an infra-red remote controller (top left in the pic: "classic remote");
- an ESP8266 project, closed up in a small box (top right in pic: "new ESP8266 wifi remote"), can talk with your air conditioner with infra-red communication;
- in the ESP8266 project I've added a temperature and humidity sensor to monitor in-home conditions;
- trough the router the ESP8266 box can connect to internet and talk to an app in my smartphone;
- both the classic remote control and the new ESP8266 controller talk one-way to air conditioner, it receives commands and makes a beep, but it doesn't talk back to the remote control;
- knowing the IP address of the router, I can talk to your ESP8266 through internet;
- to talk from the Internet to a device in your home wifi network, I've needed to assign a port to my ESP8266 in my router configuration;
Construction of the ESP8266 based WIFI controller
Here is the schema for the wifi controller. I've used a Wemos D1 mini because it's small and cheap, it's based on the popular ESP8266 chip and works perfectly with Arduino IDE.
So in this text the terms ESP8266 and Wemos are interchangeable.
As usual, first I've built it on a breadboard and when everything works, I began to solder.
Pin D4 is used to read temperature and humidity from DHT11 sensor.
Pin D0 is used to send signals to the infra-red led. It's connected to the base of the NPN BC547 transistor which is used as a current amplifier. The infra-red led will talk to air conditioner with impulses so we can use it to drive more current that the WeMos pin can source. A couple of resistors are used to reduce the current to the base of the transistor (1 Kohm) and to limit the current in the led (100 ohm) *.
* = a couple of lines about the values of this two resistors should be written (need help).
(The DHT11 sensor in my project is different from the one in the schema, the one I've used is a module which already contains a 10k pullup resistor, so the resistor of 1kohm between 3.3V and signal pin of DHT11 could be removed) **
** = I should better understand this point (need help)
The network rules and Internet calls
In the Setup( ) section of the code in the Wemos a wifi client that connects to the local home network is started, and the router will give a local IP address to the Wemos. In Setup( ) also a web server is started, which can answer to http calls in your local network.
Here is a drawing to understand how IPs work. Every router creates a private network.
All the local addresses have the same structure and changes only for the last number: 192.168.1.x (depending on your router you could have a different structure, such as 10.0.0.x, etc.).
The code in the Wemos defines that the Wemos can answer to these 3 commands:
server.on("/onoff", switchAcOnOff);
server.on("/sensor", sensorData);
server.on("/temp", temperatureSet);
So, if the IP of the...
Read more »
Converting a normal air conditioner into a Wi-Fi-controlled one is possible with the use of additional smart home technology. By doing this, you can control your air conditioner remotely using your smartphone or other smart devices, allowing you to adjust the temperature, set schedules, and monitor energy usage from anywhere with an internet connection.
Here's a general outline of how you can make a regular air conditioner Wi-Fi-enabled:
Smart Plug: One of the easiest and most cost-effective ways is to use a Wi-Fi-enabled smart plug. Plug your air conditioner into the smart plug, and then connect the smart plug to your home Wi-Fi network. Many smart plugs can be controlled via smartphone apps or integrated with voice-controlled smart assistants like Amazon Alexa or Google Assistant.
Smart IR Controller: If you have an air conditioner with an infrared (IR) remote control, you can use a Wi-Fi-enabled smart IR controller. These devices learn the IR signals from your existing remote and then allow you to control the air conditioner through a smartphone app.
Smart Thermostat: Some air conditioners are compatible with smart thermostats. If your AC unit has a standard thermostat interface (usually for central HVAC systems), you can replace the standard thermostat with a smart thermostat that has Wi-Fi capabilities.
Air Conditioner with Built-in Wi-Fi: Many modern air conditioners come with built-in Wi-Fi connectivity, making them "smart" right out of the box. These units can be connected to your home network directly, and you can control them through dedicated smartphone apps.
Keep in mind that the specific steps and requirements may vary depending on the type and model of your air conditioner and the smart home technology you choose to use. Always follow the manufacturer's instructions and safety guidelines when installing and setting up any smart home devices.
Before attempting any modifications or installations, make sure to check the compatibility of your air conditioner with the smart devices you intend to use. If you're uncertain about any step, it's a good idea to seek professional assistance or advice.