How Xiaomi Smart Lamp Works: Device, Connection and Features

Xiaomi smart lamps have become one of the most popular devices for creating a smart home system due to the combination of affordable price, wide functionality and ease of use. These devices don't just light up the room, they integrate into the Mi Home ecosystem, support voice control, schedule automation, even synchronization with other gadgets, but how does a light bulb work? How does it differ from a regular bulb? LED-And what are the hidden possibilities behind the simple appearance of light bulbs?

In this article, we will analyze the device of Xiaomi smart lamps (including models Yeelight, Mi). LED Smart Bulb and Aqara, explain the principles of their operation at the hardware and software level, and show how to configure the lamp for maximum convenience. You'll learn what communication protocols are used, how the lamp interacts with the Xiaomi router and cloud, and why it can sometimes "glut" for no apparent reason.

1. Xiaomi smart lamp device: what's inside?

Xiaomi smart lamp looks like a regular lamp LED-lamp-lamp E27 or E14, But inside it, there's a real minicomputer:

  • πŸ’‘ LED-matrix - usually based on Cree or Osram chips, providing brightness up to 800-1000 lm and color temperature from 1700K (warm lights 6500K (cold. RGB-Models (e.g. Yeelight Color) have added red, green and blue diodes to produce 16 million shades.
  • 🧠 Microcontrollers are usually the ESP8266 or Realtek RTL8710, which processes commands, controls brightness and communicates with the router over Wi-Fi.
  • πŸ“Ά Wi-Fi module – operates on frequency 2.4 GHz (supports) 5 GHz is not!) and uses the protocol IEEE 802.11 b/g/n. Important: The lamp doesn’t connect directly to the phone – it always communicates via the router.
  • πŸ”‹ The power supply unit - transforms ~220V in low voltage for LED In cheap models, it can cause flickering when the network is poor.

A critical feature: all Xiaomi smart bulbs (except some Aqara models) run ONLY through the company’s cloud, which means that even for local management (for example, on a schedule), the lamp sends data to Xiaomi servers in China or Singapore. Without the Internet, some of the features will not be available β€” but more about this in the section on connection.

Interesting fact: Yeelight lamps (a subsidiary of Xiaomi) use the open Yeelight Inter-Device Protocol, which allows them to be controlled over a local network without the cloud, making them more flexible for home automation enthusiasts.

πŸ“Š What Xiaomi Smart Lamp Is It You Use?
Yeelight (RGB monochrome)
Mi LED Smart Bulb
Aqara
Another.
I haven't bought it yet.

2.The principle of operation: how does the lamp receive and execute commands?

The algorithm of the Xiaomi smart lamp can be divided into 4 stages:

  1. Connecting to the network. When you first turn on, the lamp creates its own Wi-Fi hotspot (the name begins with yeelink-light-... or miio:..) You connect your phone to it through the Mi Home app, and then the lamp automatically goes to your home network.
  2. Cloud-based authorization. Lamp sends unique Device ID And you have to go to Xiaomi servers, where it's linked to your account, and this is a mandatory step, because without it, you can't remotely control the lamp.
  3. When you send a command (e.g., turn on the light) through an app or voice assistant, it goes the next way: πŸ“± Control device (telephone/column) β†’ Xiaomi's Cloud β†’ router β†’ lamp. ⚑ With local control (if the lamp and phone are on the same network), the command can go directly through the router, bypassing the cloud.

Implementation

{"id":1,"method":"set_power","params":["on", "smooth", 500]}

It is important to understand that delaying the execution of a command depends on:

  • 🌍 Ping to Xiaomi servers (if using the cloud). for Russia, the average response time is 100-300 ms.
  • πŸ“Ά Wi-Fi quality: If the signal is weak, the lamp may freeze or not respond.
  • πŸ”„ Loads on a router. If you have a lot of devices connected to it, you can lose commands.

πŸ’‘

If the lamp responds to commands with a delay, try in the router settings to fix a static IP-This will reduce the time spent searching for a device on the network.

3. Connecting the lamp to Mi Home: step-by-step instructions

To make the lamp work, you need to add it to the Mi Home app, and here are the detailed instructions with the nuances:

Download the Mi Home app (App) Store/Google Play)

Create a Xiaomi account (or log in through an existing one)

Make sure the router is running at 2.4 GHz

Turn the lamp into the socket (it should flash yellow)

-->

Step 1. Open Mi Home, press. + β†’ Add the device and select Lighting category. In the list, find your model (e.g. Mi). LED Smart Bulb or Yeelight Color).

Step 2. Connect to the lamp access point (no password required) and then the app will automatically transfer the lamp to your home network.

  • πŸ”Œ The lamp flashes yellow (if not, turn it off/on 5 times in a row to reset).
  • πŸ“΅ The phone's off. VPN Proxies (they can block the connection to the cloud).
  • 🌐 The router does not block outbound connections to ports 80 and 443.

Step 3: Once you've successfully connected, the lamp will appear on the device list.

  • 🎨 Customize color and brightness.
  • ⏰ Set a schedule (for example, turn on the alarm clock).
  • 🀝 Add to the group with other lamps for synchronous control.
What to do if the lamp does not connect?
1.Reboot the router - sometimes DHCP-server forgets to give out IP-2. Check if the router is in isolation mode for customers (AP Isolation) – it blocks device interaction on the local network. 3. If you use a dual-band router, force the phone to connect to the 2.4 GHz network (many phones automatically switch to 5 GHz, which leads to a failure). 4. For Yeelight lamps, try the Yeelight alternative app (it sometimes works more stable than Mi Home).

4. Lamp control: methods and nuances

Xiaomi smart lamp supports several control methods, let’s consider each of them with pros and cons:

Management methodHow it worksPlusesCons
Mi Home appendixControl over the cloud or local area network (if the phone and lamp are on the same Wi-Fi network).βœ… Full functionality (colors, scripts, schedules).βœ… Works from anywhere in the world.❌ Requires Internet for Cloud Teams.❌ Sometimes it is β€œlagging” because of Xiaomi servers.
Voice assistantsIntegration with Alice (Yandex), Google Assistant or Siri via HomeKit (only for some models).βœ… Convenient for quick management.βœ… Supports complex commands (e.g., turn on the light at 50% brightnessΒ»).❌ Requires setting up a bundle of accounts.❌ Possible recognition errors.
Physical switchThe lamp remembers the last state and restores it after the power is turned on.βœ… It works without the Internet and phone.βœ… It's common for householders.❌ When you turn off the socket, the settings are lost (for example, color).❌ You can't set up complicated scenarios.
Automation (Mi) Home/Aqara)Scenarios by time, motion sensors, temperature, etc.βœ… Full customization ("turn on the light if the movement is darkΒ»).βœ… It can be associated with other devices (e.g., a door opening sensor).❌ It's hard to set up a beginner.❌ Some scenarios require a hub (e.g. Aqara Hub).

Hidden feature: Yeelight has an undocumented music mode feature that lets you synchronize color with music through your phone's microphone.

  1. Open the Yeelight app (not Mi Home!).
  2. Choose a lamp. β†’ Additionally. β†’ Musical regime.
  3. Adjust the sensitivity of the microphone and the color palette.

πŸ’‘

For stable voice control, link the lamp to your Yandex account/Google before setting up the scripts, otherwise the assistant may not see the device.

5. Common Problems and Their Solutions

Even the most reliable devices sometimes fail, and here are the typical Xiaomi smart bulb problems and how to fix them:

⚠️ Warning: If the lamp has stopped responding to commands but is lit with white light, it means that it has lost communication with the cloud. only reconnect via Mi Home (hold the button on the lamp for 5 seconds to reset).

  • πŸ”„ Lamp flashes and doesn't connect: Check if the router is blocking the connection to Xiaomi servers (domains miot-specs.org, api.io.mi.com).If you use Mi Home on iPhone, try connecting via Android - sometimes helps.
  • πŸ•’ Delayed commands: In the router settings, enable traffic prioritization (QoS) for the lamp device. If the lamp is far from the router, use a Wi-Fi repetitor.
  • 🎨 Colors are displayed incorrectly: In the Mi Home app, update the lamp firmware (Device settings) β†’ Software updates. RGB-Calibrate the colors manually (Settings) β†’ Color temperature β†’ Sizing).
  • πŸ”Œ Lamp does not remember the state after switching off: This is a feature of the work - when the power is physically turned off, all settings are reset.Solution: use Xiaomi's smart socket to simulate turning off.

If nothing helps, try a full lamp reset:

  1. Turn the lamp off the socket.
  2. Turn it back on and immediately turn it off/on 5 times in a row (with intervals). ~1 second).
  3. The lamp should start flashing yellow, and now it can be reconnected.

⚠️ Note: Xiaomi lamps do not support Zigbee protocol (except the Aqara line).If you want a stable local area network without a cloud, consider buying the Aqara Hub and compatible lamps.

Automation scenarios: how to make light β€œsmarter”?

The main advantage of smart lamps is the ability to automate lighting. The Mi Home has a built-in script builder, but it's limited. Let's take a few useful examples:

  • πŸŒ… Scenario: If it's 06:30, set the brightness 1%, color temperature 2000K, Then smoothly increase the brightness to 100% in 30 minutes. Effect: Awakening becomes softer, as at natural dawn.
  • πŸšͺ Light when opening the door: Required: Aqara open sensor + Screenplay: If the door sensor is activated and the light level is activated < 50 lux, turn on the lamp at 100% brightnessΒ».
  • 🎬 Movie Review: If the TV Mi TV switched on, set the lamp in a warm light (2700K) You need to link the lamp and the TV in the same Mi Home account.
  • πŸ’€ Nightlight for the child: Scenario: "If it's 22:00, turn on the lamp at 5% brightness with a blue hue; if it's 6:00, turn off." You can add a motion sensor condition (for example, if the child wakes up at night).

For advanced users, if standard scripts are scarce, you can use Home Assistant or Node-RED to create complex logic.

automation:


Alias: "Adaptive lighting by time of day"




trigger:




- platform: time_pattern




minutes: "/5"




action:




- service: light.turn_on




target:




entity_id: light.yeelight_color




data:




brightness_pct: "{{ (now().hour - 6) * 10 if (now().hour > 6 and now().hour < 22) else 10 }}"




color_temp: "{{ 200 + (now().hour * 20) if (now().hour < 22) else 2000 }}"

This code smoothly changes the brightness and color temperature of the lamp depending on the time of day.

7. Model comparison: which Xiaomi lamp to choose?

Xiaomi has several types of smart lamps in its lineup, and here is a comparison table to help you choose:

ModelType of lightBrightness (lm)Color temperatureRGBFeaturesPrice (2026)
Mi LED Smart BulbWhite8001700–6500K❌Budget model, no RGB, steady-work.~1 200 β‚½
Yeelight ColorRGB + white6001700–6500Kβœ…16 million colors, music mode, local management.~2 500 β‚½
Yeelight ProRGB + white10001700–6500Kβœ…Brighter than standard Yeelight, HomeKit support.~3 500 β‚½
Aqara LED Bulb T1White8002700–6500K❌It works through Zigbee (needs a hub), there is no cloud dependency.~1 800 β‚½

Selection recommendations:

  • πŸ’° Budget option: Mi LED Smart Bulb – if you only need adjustable white light.
  • 🎨 For color lighting: Yeelight Color – the best price/functional ratio.
  • 🏠 For a reliable system: Aqara + Hub – if local work without cloud is important.
  • 🍎 For Apple ecosystem: Yeelight Pro is the only model with HomeKit support.

8.Alternative firmware and hacking lamps

For enthusiasts, there is an option to flash Xiaomi smart lamp with alternative software, such as Tasmota or ESPHome.

  • ⚑ Local management without the cloud Xiaomi.
  • πŸ”§ Advanced settings (e.g. customization of colors, integration with MQTT).
  • πŸ›‘οΈ Increased security (no reliance on Chinese servers).

How to flash a lamp? A brief instruction for Yeelight:

  1. Download the Tasmota firmware for ESP8266 official website.
  2. Connect the lamp to the computer through USB-TTL adapter (you need to open the case and solder the contacts to the board).
  3. Use the esptool program to record firmware: esptool.py --port COM3 write_flash 0x0 firmware.bin
  4. Set up Wi-Fi and MQTT in the Tasmota web interface.

⚠️ Warning: Firmware on alternative software is warranty-free and can cause the lamp to fail. Do this only if you understand the risks! LED Smart Bulb (not Yeelight) process is more complicated – a soldering iron and electronics experience are required.

Once installed, the lamp can be integrated into Home Assistant, OpenHAB, or other smart home systems, such as the configuration for Home Assistant will look like this:

light:


- platform: mqtt




name: "Yeelight Hacked"




command_topic: "cmnd/yeelight/Power"




brightness_command_topic: "cmnd/yeelight/Dimmer"




brightness_scale: 100




rgb_command_topic: "cmnd/yeelight/Color"




color_temp_command_topic: "cmnd/yeelight/CT"

πŸ’‘

Tasmota's firmware allows you to operate a lamp even without the Internet, but requires soldering iron skills and patience. For most users, standard Xiaomi software is enough.

FAQ: Frequent questions about Xiaomi smart lamps

❓ Can you control a lamp without the internet?
Yes, but with reservations: the lamp will work on the local network if the phone and the lamp are connected to the same router, remote control (from another network) and some scenarios require the Internet. Aqara models with Zigbee work entirely locally (need a hub).
❓ Why the lamp does not turn on after updating the firmware?
This is a typical problem after automatic updates. Solutions: Turn off/on the lamp 5 times to reset. Remove it from Mi Home and add it again. If it doesn't work, roll back the firmware through Yeelight App (if available). In extreme cases, contact Xiaomi with error logs (you can get them in Settings). β†’ About the programme β†’ Book of errors).
❓ How to connect the lamp to Alice or Google Assistant?
Instructions for Alice: Open the Yandex app β†’ Devices β†’ Add a device. Choose Xiaomi and log in to your Mi Home account. Allow access to your devices. Now you can control your voice: "Alice, turn on the light in the bedroom by 50%." For Google Assistant: In Mi Home, go to Profile β†’ Settings β†’ Google Assistant. Follow the instructions for bundling accounts.
❓ Can I use the lamp on the street or in wet rooms?
All Xiaomi smart lamps have a protection class IP20,: ❌ No protection from moisture. ❌ No dust protection. For the street or bathroom, choose a special model with a IP65 (For example, Yeelight Outdoor, but you need to buy them separately.
❓ How to Reset the Lamp to Factory Settings?
There are two ways: Software reset: In Mi Home, go to the lamp settings β†’ Delete the device. Confirm the deletion, the lamp will reset and start flashing yellow. Hardware reset (if the lamp does not respond): Turn the lamp out of the socket. Turn it on and immediately turn it off / turn it on 5 times in a row (with intervals). ~1 second. The lamp should start flashing yellow, so you can reconnect it.