{"id":332988,"date":"2022-05-11T15:00:07","date_gmt":"2022-05-11T15:00:07","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=332988"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=332988","title":{"rendered":"<span>\u0423\u043b\u0438\u0447\u043d\u043e\u0435 \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 ESP8266<\/span>"},"content":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p>\u041f\u0440\u0438\u0432\u0435\u0442, \u0425\u0430\u0431\u0440! \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u0440\u0430\u0441\u0441\u043a\u0430\u0436\u0443 \u043e \u0441\u0432\u043e\u0435\u043c \u043e\u043f\u044b\u0442\u0435 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0443\u043b\u0438\u0447\u043d\u043e\u0433\u043e \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u044f, \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0439 \u043d\u0430 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0435 ESP8266. \u0425\u043e\u0442\u044c \u0434\u0430\u043d\u043d\u0430\u044f \u0438\u0434\u0435\u044f \u0438 \u043d\u0435 \u043d\u043e\u0432\u0430 \u0438 \u0432 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0435 \u043e\u0433\u0440\u043e\u043c\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0433\u043e\u0442\u043e\u0432\u044b\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432 \u043d\u0430 \u0431\u0430\u0437\u0435 \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430, \u044f \u0445\u043e\u0442\u0435\u043b \u0431\u044b \u043f\u043e\u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f \u0442\u0435\u043c, \u0447\u0442\u043e \u0443 \u043c\u0435\u043d\u044f \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u0432 \u043d\u0430\u0434\u0435\u0436\u0434\u0435, \u0447\u0442\u043e \u0434\u043b\u044f \u043a\u043e\u0433\u043e-\u043d\u0438\u0431\u0443\u0434\u044c \u044d\u0442\u043e \u043e\u043a\u0430\u0436\u0435\u0442\u0441\u044f \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u043c.<\/p>\n<p>\u041f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043d\u0430\u0447\u0430\u0442\u044c, \u043f\u043e\u0437\u0432\u043e\u043b\u044c\u0442\u0435 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u0440\u0435\u0434\u044b\u0441\u0442\u043e\u0440\u0438\u0438. \u042f \u0436\u0438\u0432\u0443 \u0432 \u0447\u0430\u0441\u0442\u043d\u043e\u043c \u0434\u043e\u043c\u0435 \u0438 \u0443\u043b\u0438\u0446\u0430, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d \u043c\u043e\u0439 \u0434\u043e\u043c, \u043d\u0435 \u0438\u043c\u0435\u0435\u0442 \u0445\u043e\u0440\u043e\u0448\u0435\u0433\u043e \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u044f. \u041e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u0434\u0430\u043d\u043d\u0430\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u043e\u0441\u0442\u0440\u043e \u043e\u0449\u0443\u0449\u0430\u0435\u0442\u0441\u044f \u0437\u0438\u043c\u043e\u0439, \u043a\u043e\u0433\u0434\u0430 \u0442\u0435\u043c\u043d\u0435\u0435\u0442 \u043e\u0447\u0435\u043d\u044c \u0440\u0430\u043d\u043e. \u0418\u043c\u0435\u043d\u043d\u043e \u0432 \u043e\u0434\u0438\u043d \u0438\u0437 \u0442\u0430\u043a\u0438\u0445 \u0434\u043d\u0435\u0439, \u043f\u0440\u0438\u043f\u0430\u0440\u043a\u043e\u0432\u0430\u0432 \u0430\u0432\u0442\u043e\u043c\u043e\u0431\u0438\u043b\u044c \u0438 \u0437\u0430\u043a\u0440\u044b\u0432\u0430\u044f \u0437\u0430 \u043d\u0438\u043c \u0432\u043e\u0440\u043e\u0442\u0430 \u0432 \u043f\u043e\u043b\u043d\u043e\u0439 \u0442\u0435\u043c\u043d\u043e\u0442\u0435 \u044f \u0440\u0435\u0448\u0438\u043b, \u0447\u0442\u043e \u043f\u043e\u0440\u0430 \u0437\u0430\u043d\u044f\u0442\u044c\u0441\u044f \u0432\u043d\u0435\u0448\u043d\u0438\u043c \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u0435\u043c. \u041f\u0435\u0440\u0432\u0430\u044f \u043c\u044b\u0441\u043b\u044c \u0431\u044b\u043b\u0430 &#8212; \u043f\u043e\u0432\u0435\u0441\u0438\u0442\u044c \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434\u043d\u044b\u0439 \u043f\u0440\u043e\u0436\u0435\u043a\u0442\u043e\u0440 \u0441 \u0434\u0430\u0442\u0447\u0438\u043a\u043e\u043c \u0434\u0432\u0438\u0436\u0435\u043d\u0438\u044f \u0438 \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u043d\u043e\u0441\u0442\u0438. \u0412\u0430\u0440\u0438\u0430\u043d\u0442 \u043e\u0442\u043b\u0438\u0447\u043d\u044b\u0439, \u043d\u043e \u043c\u043d\u0435 \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0432\u0441\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0430\u043c\u043e\u043c\u0443, \u043a \u0442\u043e\u043c\u0443 \u0436\u0435 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0438\u0439 Pet-project \u0431\u044b\u043b \u0437\u0430\u043a\u043e\u043d\u0447\u0435\u043d \u0438 \u0432\u0440\u0435\u043c\u044f \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u043b\u043e \u0437\u0430\u043d\u044f\u0442\u044c\u0441\u044f \u0447\u0435\u043c-\u0442\u043e \u0434\u0440\u0443\u0433\u0438\u043c. \u041e\u0431\u0434\u0443\u043c\u0430\u0432 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438, \u0432\u043a\u043b\u044e\u0447\u0430\u044f \u043a\u0430\u043a \u0441 \u0434\u0430\u0442\u0447\u0438\u043a\u0430\u043c\u0438 \u0442\u0430\u043a \u0438 \u0431\u0435\u0437, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u044f, \u0447\u0442\u043e \u043d\u0430 \u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442 \u0443 \u043c\u0435\u043d\u044f \u0432 \u043d\u0430\u043b\u0438\u0447\u0438\u0438 \u0443\u0436\u0435 \u0431\u044b\u043b\u043e \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043c\u043e\u0434\u0443\u043b\u0435\u0439 \u0440\u0435\u043b\u0435 \u0441 ESP-01S, \u043a\u0443\u043f\u043b\u0435\u043d\u043d\u044b\u0445 \u0440\u0430\u043d\u0435\u0435 \u0434\u043b\u044f \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u043b\u0435\u043d\u0438\u044f, \u044f \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043b\u0441\u044f \u043d\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u043c &#8212; \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u0443\u043b\u0438\u0447\u043d\u043e\u0433\u043e \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u043d\u0430 \u0431\u0430\u0437\u0435 ESP8266 \u0441 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c \u0447\u0435\u0440\u0435\u0437 web-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441. \u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e\u0439 \u043f\u043b\u043e\u0449\u0430\u0434\u043a\u0438 \u0431\u044b\u043b\u043e \u0432\u044b\u0431\u0440\u0430\u043d\u043e \u043c\u0435\u0441\u0442\u043e \u043f\u0430\u0440\u043a\u043e\u0432\u043a\u0438 \u0430\u0432\u0442\u043e\u043c\u043e\u0431\u0438\u043b\u044f.<\/p>\n<h2>\u041c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 ESP8266<\/h2>\n<p>\u0418\u0441\u0442\u043e\u0440\u0438\u044f ESP8266 \u043d\u0430\u0447\u0430\u043b\u0430\u0441\u044c \u0432 2014 \u0433\u043e\u0434\u0443. \u0417\u0430 \u044d\u0442\u043e \u0432\u0440\u0435\u043c\u044f \u043e\u043d \u043e\u0431\u0440\u043e\u0441 \u0441\u0435\u0440\u044c\u0435\u0437\u043d\u044b\u043c \u043a\u043e\u043c\u044c\u044e\u043d\u0438\u0442\u0438 \u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u043b \u0448\u0438\u0440\u043e\u043a\u0443\u044e \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u043e\u0441\u0442\u044c \u0431\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044f \u043d\u0430\u043b\u0438\u0447\u0438\u044e Wi-Fi, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0432\u0432\u0438\u0434\u0443 \u0435\u0433\u043e \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0438\u0437\u043a\u043e\u0439 \u0441\u0442\u043e\u0438\u043c\u043e\u0441\u0442\u0438. \u041d\u0430 \u0431\u0430\u0437\u0435 ESP8266 \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u043e \u0431\u043e\u043b\u044c\u0448\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u043c\u043e\u0434\u0443\u043b\u0435\u0439, \u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u043e \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u043d\u0430 \u0425\u0430\u0431\u0440\u0435 <a href=\"https:\/\/habr.com\/ru\/post\/390593\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a> \u0438 <a href=\"https:\/\/habr.com\/ru\/post\/547330\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>. \u0412 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0435\u0447\u044c \u0431\u0443\u0434\u0435\u0442 \u0438\u0434\u0442\u0438 \u043e \u043c\u043e\u0434\u0443\u043b\u0435 ESP-01S, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u044f \u043f\u0440\u0438\u043e\u0431\u0440\u0435\u043b \u0432 \u043f\u0430\u0440\u0435 \u0441 \u043c\u043e\u0434\u0443\u043b\u0435\u043c \u0440\u0435\u043b\u0435 \u0434\u043b\u044f \u043d\u0435\u0433\u043e. <\/p>\n<figure class=\"\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/523\/f0a\/e9f\/523f0ae9fb455ff376b6755306b9075e.png\" alt=\"\" title=\"\" width=\"320\" height=\"242\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/523\/f0a\/e9f\/523f0ae9fb455ff376b6755306b9075e.png\"\/><figcaption><\/figcaption><\/figure>\n<p>\u041d\u0435\u0431\u043e\u043b\u044c\u0448\u0430\u044f \u0441\u043f\u0440\u0430\u0432\u043a\u0430 &#8212; \u043c\u043e\u0434\u0443\u043b\u044c \u0440\u0435\u043b\u0435 \u0434\u043b\u044f ESP-01S \u0443\u0436\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0441\u0442\u0430\u0431\u0438\u043b\u0438\u0437\u0430\u0442\u043e\u0440 \u043d\u0430\u043f\u0440\u044f\u0436\u0435\u043d\u0438\u044f AMS1117, \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u044e\u0449\u0438\u0439 \u043f\u0438\u0442\u0430\u043d\u0438\u0435 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u0440\u0430\u0432\u043d\u043e\u0435 3.3V. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u043d\u0430\u043f\u0440\u044f\u0436\u0435\u043d\u0438\u0435 \u043f\u0438\u0442\u0430\u043d\u0438\u0435 \u043c\u043e\u0434\u0443\u043b\u044f \u0440\u0435\u043b\u0435 \u0441\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 5V, \u0447\u0442\u043e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0443\u043f\u0440\u043e\u0449\u0430\u0435\u0442 \u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435. \u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0440\u0435\u043b\u0435 \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0430\u043c GPIO0.<\/p>\n<p>\u041e\u0434\u043d\u0430\u043a\u043e, \u0434\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0435\u0439 \u043d\u0430\u0433\u043b\u044f\u0434\u043d\u043e\u0441\u0442\u0438, \u0432\u043e \u0432\u0441\u0435\u0445 \u043f\u043e\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0445 \u0441\u0445\u0435\u043c\u0430\u0445 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e \u0441 ESP-01S \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0431\u044b\u0447\u043d\u043e\u0435 \u0440\u0435\u043b\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043f\u0440\u0438 \u0436\u0435\u043b\u0430\u043d\u0438\u0438 \u0432\u0441\u0435\u0433\u0434\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043c\u0435\u043d\u0435\u043d\u043e \u043d\u0430 \u043c\u043e\u0434\u0443\u043b\u044c \u0440\u0435\u043b\u0435 \u0434\u043b\u044f ESP-01S.<\/p>\n<h2>\u041f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043a\u0430 \u043a \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044e<\/h2>\n<p>\u041f\u0440\u043e\u0446\u0435\u0441\u0441 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f ESP-01S \u0432 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e\u0441\u0442\u044f\u0445 \u043e\u043f\u0438\u0441\u0430\u043d \u043d\u0430 \u0425\u0430\u0431\u0440\u0435 <a href=\"https:\/\/habr.com\/ru\/post\/390593\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a> \u0438 <a href=\"https:\/\/habr.com\/ru\/post\/547330\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u044f \u0440\u0435\u0448\u0438\u043b \u043d\u0435 \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0442\u044c\u0441\u044f, \u0430 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0442\u044c\u0441\u044f \u043b\u0438\u0448\u044c \u0441\u0445\u0435\u043c\u043e\u0439 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/99f\/2d9\/32d\/99f2d932d94bf91ad55dfa07c66a34da.png\" alt=\"\" title=\"\" width=\"1869\" height=\"939\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/99f\/2d9\/32d\/99f2d932d94bf91ad55dfa07c66a34da.png\"\/><figcaption><\/figcaption><\/figure>\n<p>\u0414\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0443 \u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b \u043a\u0430\u0431\u0435\u043b\u044c USB &lt;\u2013> UART TTL.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/6ee\/c39\/9fa\/6eec399fac1d2f1abe595e196b59c130.png\" width=\"2016\" height=\"1512\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6ee\/c39\/9fa\/6eec399fac1d2f1abe595e196b59c130.png\"\/><figcaption><\/figcaption><\/figure>\n<h3>\u041f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435. \u041d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438<\/h3>\n<p>\u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0441\u0440\u0435\u0434\u044b \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u044f \u0432\u044b\u0431\u0440\u0430\u043b Arduino IDE, \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043a\u043e\u0442\u043e\u0440\u043e\u0439, \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 ESP8266, \u0432 \u0434\u0435\u0442\u0430\u043b\u044f\u0445 \u043e\u043f\u0438\u0441\u0430\u043d \u043d\u0430 \u0425\u0430\u0431\u0440\u0435 <a href=\"https:\/\/habr.com\/ru\/post\/371853\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a> \u0438 <a href=\"https:\/\/habr.com\/ru\/post\/547330\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043e\u043f\u044f\u0442\u044c \u0436\u0435 \u043d\u0435 \u0441\u0442\u0430\u043d\u0435\u043c \u043e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u043d\u0435\u043c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e.<\/p>\n<p>\u041f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0438\u0442\u044c, \u044f \u0445\u043e\u0442\u0435\u043b \u0431\u044b \u043e\u0442\u043c\u0435\u0442\u0438\u0442\u044c, \u0447\u0442\u043e \u043e\u0434\u043d\u0438\u043c \u0438\u0437 \u043d\u0435\u043e\u0441\u043f\u043e\u0440\u0438\u043c\u044b\u0445 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432 Arduino IDE \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0442\u043e, \u0447\u0442\u043e \u043e\u043d\u0430 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043e\u0433\u0440\u043e\u043c\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0433\u043e\u0442\u043e\u0432\u044b\u0445 \u043f\u0440\u0438\u043c\u0435\u0440\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u044b \u0434\u043b\u044f \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u043b\u0435\u043d\u0438\u044f \u0438\u043b\u0438 \u043f\u0440\u043e\u0441\u0442\u043e \u0432\u0437\u044f\u0442\u044b \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043e\u0441\u043d\u043e\u0432\u044b, \u0447\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u043f\u0440\u043e\u0449\u0430\u0435\u0442 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0443.  <\/p>\n<p>\u041f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u0435\u043c \u043f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043b\u043e\u0441\u044c \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0442\u044c \u0447\u0435\u0440\u0435\u0437 web-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441, \u0442\u043e \u043f\u0435\u0440\u0432\u044b\u043c \u0434\u0435\u043b\u043e\u043c \u044f \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u0438\u043b \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e html \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443. <\/p>\n<figure class=\"\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/4e1\/a06\/b8e\/4e1a06b8ec8993fb4f0f0bd9aa10501b.png\" width=\"336\" height=\"346\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/4e1\/a06\/b8e\/4e1a06b8ec8993fb4f0f0bd9aa10501b.png\"\/><figcaption><\/figcaption><\/figure>\n<details class=\"spoiler\">\n<summary>\u0418\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 html \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"xml\">&lt;!doctype html>  &lt;html> &lt;head>   &lt;meta charset=\"utf-8\">   &lt;meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">    &lt;title>Remlight&lt;\/title>   &lt;meta name=\"description\" content=\"Remote lighting control\">    &lt;style>     body      {       margin:30px auto;       text-align: center;       font-family: 'Arial';     }      #title     {       color: #444444;       font-weight: bold;       font-size: 13pt;       outline: none;     }      #button-container      {       display: inline-block;     }      #button-container > div      {       padding: 10px;       width: 100%;     }      button      {       color: #444444;       background: #F3F3F3;       border: 1px #DADADA solid;       padding: 10px 40px;       border-radius: 2px;       font-weight: bold;       font-size: 9pt;       outline: none;       width: 100%;     }      button:hover      {       color: #333333;       background: #F7F7F7;       border: 1px #C6C6C6 solid;       box-shadow: 1px 1px 1px #EAEAEA;     }      button:active      {       box-shadow: inset 1px 1px 1px #DFDFDF;     }      button.red      {       color: white;       background: -webkit-linear-gradient(top, #DD4B39, #D14836);        background: -moz-linear-gradient(top, #DD4B39, #D14836);        background: -ms-linear-gradient(top, #DD4B39, #D14836);        border: 1px solid #DD4B39;       text-shadow: 0 1px 0 #C04131;     }      button.red:hover      {       background: -webkit-linear-gradient(top, #DD4B39, #C53727);       background: -moz-linear-gradient(top, #DD4B39, #C53727);       background: -ms-linear-gradient(top, #DD4B39, #C53727);       border: 1px solid #AF301F;     }      button.red:active      {       background: -webkit-linear-gradient(top, #D74736, #AD2719);       background: -moz-linear-gradient(top, #D74736, #AD2719);       background: -ms-linear-gradient(top, #D74736, #AD2719);       box-shadow: inset 0 1px 1px rgba(0,0,0,0.2);     }   &lt;\/style> &lt;\/head>  &lt;body>   &lt;p id=\"title\">\u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u0435\u043c (\u0433\u0430\u0440\u0430\u0436)&lt;\/p>   &lt;div id=\"button-container\">     &lt;div>&lt;a href=\"\/light?action=on&amp;time=5\">       &lt;button>\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442 \u043d\u0430 5 \u043c\u0438\u043d\u0443\u0442&lt;\/button>     &lt;\/a>&lt;\/div>     &lt;div>&lt;a href=\"\/light?action=on&amp;time=10\">       &lt;button>\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442 \u043d\u0430 10 \u043c\u0438\u043d\u0443\u0442&lt;\/button>     &lt;\/a>&lt;\/div>     &lt;div>&lt;a href=\"\/light?action=on&amp;time=15\">       &lt;button>\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442 \u043d\u0430 15 \u043c\u0438\u043d\u0443\u0442&lt;\/button>     &lt;\/a>&lt;\/div>     &lt;div>&lt;a href=\"\/light?action=on\">       &lt;button>\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442 (\u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u043e)&lt;\/button>     &lt;\/a>&lt;\/div>     &lt;div>&lt;a href=\"\/light?action=off\">       &lt;button class=\"red\">\u0412\u044b\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442&lt;\/button>     &lt;\/a>&lt;\/div>   &lt;\/div> &lt;\/body> &lt;\/html> <\/code><\/pre>\n<\/p>\n<\/div>\n<\/details>\n<p>\u0414\u043b\u044f \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0435\u043d\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u044b ESP-01S \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 web-\u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0434\u043b\u044f \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 \u0431\u0430\u0437\u043e\u0432\u043e\u0439 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0431\u044b\u043b \u0432\u044b\u0431\u0440\u0430\u043d \u043a\u043b\u0430\u0441\u0441 ESP8266WebServer. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 html-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0431\u044b\u043b \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d \u0432 \u0448\u0435\u0441\u0442\u043d\u0430\u0434\u0446\u0430\u0442\u0435\u0440\u0438\u0447\u043d\u044b\u0439 \u0432\u0438\u0434 \u0438 \u0437\u0430\u043f\u0438\u0441\u0430\u043d \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0433\u043e \u043c\u0430\u0441\u0441\u0438\u0432\u0430 `data_light_html`.<\/p>\n<details class=\"spoiler\">\n<summary>\u0418\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"cpp\">#include &lt;ESP8266WiFi.h> #include &lt;ESP8266mDNS.h> #include &lt;ArduinoOTA.h> #include &lt;ESP8266WebServer.h> \/\/-----------------------------------------------------------------------------  #define WIFI_SSID \"ssid\" #define WIFI_PASSWORD \"password\"  #define WWW_USER \"user\" #define WWW_PASSWORD \"password\" \/\/-----------------------------------------------------------------------------  #define AUTHENTICATE_OR_RETURN()                                              \\ if (!g_Server.authenticate(WWW_USER, WWW_PASSWORD)) {                         \\   return g_Server.requestAuthentication();                                    \\ } \/\/-----------------------------------------------------------------------------  static const char data_light_html[] = {   0x3c, 0x21, 0x64, 0x6f, 0x63, 0x74, 0x79, 0x70, 0x65, 0x20,    0x68, 0x74, 0x6d, 0x6c, 0x3e, 0xd, 0xa, 0xd, 0xa, 0x3c,    0x68, 0x74, 0x6d, 0x6c, 0x3e, 0xd, 0xa, 0x3c, 0x68, 0x65,    0x61, 0x64, 0x3e, 0xd, 0xa, 0x20, 0x20, 0x3c, 0x6d, 0x65,    0x74, 0x61, 0x20, 0x63, 0x68, 0x61, 0x72, 0x73, 0x65, 0x74,    0x3d, 0x22, 0x75, 0x74, 0x66, 0x2d, 0x38, 0x22, 0x3e, 0xd,    0xa, 0x20, 0x20, 0x3c, 0x6d, 0x65, 0x74, 0x61, 0x20, 0x6e,    0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x65, 0x77, 0x70,    0x6f, 0x72, 0x74, 0x22, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65,    0x6e, 0x74, 0x3d, 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x3d,    0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x2d, 0x77, 0x69, 0x64,    0x74, 0x68, 0x2c, 0x20, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61,    0x6c, 0x2d, 0x73, 0x63, 0x61, 0x6c, 0x65, 0x3d, 0x31, 0x22,    0x3e, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x3c, 0x74, 0x69,    0x74, 0x6c, 0x65, 0x3e, 0x52, 0x65, 0x6d, 0x6c, 0x69, 0x67,    0x68, 0x74, 0x3c, 0x2f, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x3e,    0xd, 0xa, 0x20, 0x20, 0x3c, 0x6d, 0x65, 0x74, 0x61, 0x20,    0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x64, 0x65, 0x73, 0x63,    0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x20, 0x63,    0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x3d, 0x22, 0x52, 0x65,    0x6d, 0x6f, 0x74, 0x65, 0x20, 0x6c, 0x69, 0x67, 0x68, 0x74,    0x69, 0x6e, 0x67, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x6f,    0x6c, 0x22, 0x3e, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x3c,    0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x62, 0x6f, 0x64, 0x79, 0x20, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x7b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x20, 0x20, 0x6d, 0x61, 0x72, 0x67, 0x69, 0x6e, 0x3a, 0x33,    0x30, 0x70, 0x78, 0x20, 0x61, 0x75, 0x74, 0x6f, 0x3b, 0xd,    0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x74, 0x65, 0x78,    0x74, 0x2d, 0x61, 0x6c, 0x69, 0x67, 0x6e, 0x3a, 0x20, 0x63,    0x65, 0x6e, 0x74, 0x65, 0x72, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x6e, 0x74, 0x2d, 0x66,    0x61, 0x6d, 0x69, 0x6c, 0x79, 0x3a, 0x20, 0x27, 0x41, 0x72,    0x69, 0x61, 0x6c, 0x27, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x23, 0x74, 0x69, 0x74, 0x6c, 0x65, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x7b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20,    0x20, 0x63, 0x6f, 0x6c, 0x6f, 0x72, 0x3a, 0x20, 0x23, 0x34,    0x34, 0x34, 0x34, 0x34, 0x34, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x6e, 0x74, 0x2d, 0x77,    0x65, 0x69, 0x67, 0x68, 0x74, 0x3a, 0x20, 0x62, 0x6f, 0x6c,    0x64, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,    0x66, 0x6f, 0x6e, 0x74, 0x2d, 0x73, 0x69, 0x7a, 0x65, 0x3a,    0x20, 0x31, 0x33, 0x70, 0x74, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x6f, 0x75, 0x74, 0x6c, 0x69, 0x6e,    0x65, 0x3a, 0x20, 0x6e, 0x6f, 0x6e, 0x65, 0x3b, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x23, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e,    0x2d, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72,    0x20, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x7b, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x64, 0x69, 0x73, 0x70,    0x6c, 0x61, 0x79, 0x3a, 0x20, 0x69, 0x6e, 0x6c, 0x69, 0x6e,    0x65, 0x2d, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x3b, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x23, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e,    0x2d, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72,    0x20, 0x3e, 0x20, 0x64, 0x69, 0x76, 0x20, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x7b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x20, 0x20, 0x70, 0x61, 0x64, 0x64, 0x69, 0x6e, 0x67, 0x3a,    0x20, 0x31, 0x30, 0x70, 0x78, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x77, 0x69, 0x64, 0x74, 0x68, 0x3a,    0x20, 0x31, 0x30, 0x30, 0x25, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x20, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x7b, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x20, 0x20, 0x63, 0x6f, 0x6c, 0x6f, 0x72, 0x3a, 0x20,    0x23, 0x34, 0x34, 0x34, 0x34, 0x34, 0x34, 0x3b, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x62, 0x61, 0x63, 0x6b,    0x67, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x3a, 0x20, 0x23, 0x46,    0x33, 0x46, 0x33, 0x46, 0x33, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x62, 0x6f, 0x72, 0x64, 0x65, 0x72,    0x3a, 0x20, 0x31, 0x70, 0x78, 0x20, 0x23, 0x44, 0x41, 0x44,    0x41, 0x44, 0x41, 0x20, 0x73, 0x6f, 0x6c, 0x69, 0x64, 0x3b,    0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x70, 0x61,    0x64, 0x64, 0x69, 0x6e, 0x67, 0x3a, 0x20, 0x31, 0x30, 0x70,    0x78, 0x20, 0x34, 0x30, 0x70, 0x78, 0x3b, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x20, 0x20, 0x62, 0x6f, 0x72, 0x64, 0x65,    0x72, 0x2d, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x3a, 0x20,    0x32, 0x70, 0x78, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x20, 0x20, 0x66, 0x6f, 0x6e, 0x74, 0x2d, 0x77, 0x65, 0x69,    0x67, 0x68, 0x74, 0x3a, 0x20, 0x62, 0x6f, 0x6c, 0x64, 0x3b,    0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f,    0x6e, 0x74, 0x2d, 0x73, 0x69, 0x7a, 0x65, 0x3a, 0x20, 0x39,    0x70, 0x74, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20,    0x20, 0x6f, 0x75, 0x74, 0x6c, 0x69, 0x6e, 0x65, 0x3a, 0x20,    0x6e, 0x6f, 0x6e, 0x65, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x20, 0x20, 0x77, 0x69, 0x64, 0x74, 0x68, 0x3a, 0x20,    0x31, 0x30, 0x30, 0x25, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x3a, 0x68, 0x6f, 0x76,    0x65, 0x72, 0x20, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x7b,    0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x63, 0x6f,    0x6c, 0x6f, 0x72, 0x3a, 0x20, 0x23, 0x33, 0x33, 0x33, 0x33,    0x33, 0x33, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20,    0x20, 0x62, 0x61, 0x63, 0x6b, 0x67, 0x72, 0x6f, 0x75, 0x6e,    0x64, 0x3a, 0x20, 0x23, 0x46, 0x37, 0x46, 0x37, 0x46, 0x37,    0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x62,    0x6f, 0x72, 0x64, 0x65, 0x72, 0x3a, 0x20, 0x31, 0x70, 0x78,    0x20, 0x23, 0x43, 0x36, 0x43, 0x36, 0x43, 0x36, 0x20, 0x73,    0x6f, 0x6c, 0x69, 0x64, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x20, 0x20, 0x62, 0x6f, 0x78, 0x2d, 0x73, 0x68, 0x61,    0x64, 0x6f, 0x77, 0x3a, 0x20, 0x31, 0x70, 0x78, 0x20, 0x31,    0x70, 0x78, 0x20, 0x31, 0x70, 0x78, 0x20, 0x23, 0x45, 0x41,    0x45, 0x41, 0x45, 0x41, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x3a, 0x61, 0x63, 0x74,    0x69, 0x76, 0x65, 0x20, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x7b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x62,    0x6f, 0x78, 0x2d, 0x73, 0x68, 0x61, 0x64, 0x6f, 0x77, 0x3a,    0x20, 0x69, 0x6e, 0x73, 0x65, 0x74, 0x20, 0x31, 0x70, 0x78,    0x20, 0x31, 0x70, 0x78, 0x20, 0x31, 0x70, 0x78, 0x20, 0x23,    0x44, 0x46, 0x44, 0x46, 0x44, 0x46, 0x3b, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x2e, 0x72,    0x65, 0x64, 0x20, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x7b,    0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x63, 0x6f,    0x6c, 0x6f, 0x72, 0x3a, 0x20, 0x77, 0x68, 0x69, 0x74, 0x65,    0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x62,    0x61, 0x63, 0x6b, 0x67, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x3a,    0x20, 0x2d, 0x77, 0x65, 0x62, 0x6b, 0x69, 0x74, 0x2d, 0x6c,    0x69, 0x6e, 0x65, 0x61, 0x72, 0x2d, 0x67, 0x72, 0x61, 0x64,    0x69, 0x65, 0x6e, 0x74, 0x28, 0x74, 0x6f, 0x70, 0x2c, 0x20,    0x23, 0x44, 0x44, 0x34, 0x42, 0x33, 0x39, 0x2c, 0x20, 0x23,    0x44, 0x31, 0x34, 0x38, 0x33, 0x36, 0x29, 0x3b, 0x20, 0xd,    0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x62, 0x61, 0x63,    0x6b, 0x67, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x3a, 0x20, 0x2d,    0x6d, 0x6f, 0x7a, 0x2d, 0x6c, 0x69, 0x6e, 0x65, 0x61, 0x72,    0x2d, 0x67, 0x72, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x74, 0x28,    0x74, 0x6f, 0x70, 0x2c, 0x20, 0x23, 0x44, 0x44, 0x34, 0x42,    0x33, 0x39, 0x2c, 0x20, 0x23, 0x44, 0x31, 0x34, 0x38, 0x33,    0x36, 0x29, 0x3b, 0x20, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x20, 0x20, 0x62, 0x61, 0x63, 0x6b, 0x67, 0x72, 0x6f, 0x75,    0x6e, 0x64, 0x3a, 0x20, 0x2d, 0x6d, 0x73, 0x2d, 0x6c, 0x69,    0x6e, 0x65, 0x61, 0x72, 0x2d, 0x67, 0x72, 0x61, 0x64, 0x69,    0x65, 0x6e, 0x74, 0x28, 0x74, 0x6f, 0x70, 0x2c, 0x20, 0x23,    0x44, 0x44, 0x34, 0x42, 0x33, 0x39, 0x2c, 0x20, 0x23, 0x44,    0x31, 0x34, 0x38, 0x33, 0x36, 0x29, 0x3b, 0x20, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x62, 0x6f, 0x72, 0x64,    0x65, 0x72, 0x3a, 0x20, 0x31, 0x70, 0x78, 0x20, 0x73, 0x6f,    0x6c, 0x69, 0x64, 0x20, 0x23, 0x44, 0x44, 0x34, 0x42, 0x33,    0x39, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,    0x74, 0x65, 0x78, 0x74, 0x2d, 0x73, 0x68, 0x61, 0x64, 0x6f,    0x77, 0x3a, 0x20, 0x30, 0x20, 0x31, 0x70, 0x78, 0x20, 0x30,    0x20, 0x23, 0x43, 0x30, 0x34, 0x31, 0x33, 0x31, 0x3b, 0xd,    0xa, 0x20, 0x20, 0x20, 0x20, 0x7d, 0xd, 0xa, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e,    0x2e, 0x72, 0x65, 0x64, 0x3a, 0x68, 0x6f, 0x76, 0x65, 0x72,    0x20, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x7b, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x62, 0x61, 0x63, 0x6b,    0x67, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x3a, 0x20, 0x2d, 0x77,    0x65, 0x62, 0x6b, 0x69, 0x74, 0x2d, 0x6c, 0x69, 0x6e, 0x65,    0x61, 0x72, 0x2d, 0x67, 0x72, 0x61, 0x64, 0x69, 0x65, 0x6e,    0x74, 0x28, 0x74, 0x6f, 0x70, 0x2c, 0x20, 0x23, 0x44, 0x44,    0x34, 0x42, 0x33, 0x39, 0x2c, 0x20, 0x23, 0x43, 0x35, 0x33,    0x37, 0x32, 0x37, 0x29, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x20, 0x20, 0x62, 0x61, 0x63, 0x6b, 0x67, 0x72, 0x6f,    0x75, 0x6e, 0x64, 0x3a, 0x20, 0x2d, 0x6d, 0x6f, 0x7a, 0x2d,    0x6c, 0x69, 0x6e, 0x65, 0x61, 0x72, 0x2d, 0x67, 0x72, 0x61,    0x64, 0x69, 0x65, 0x6e, 0x74, 0x28, 0x74, 0x6f, 0x70, 0x2c,    0x20, 0x23, 0x44, 0x44, 0x34, 0x42, 0x33, 0x39, 0x2c, 0x20,    0x23, 0x43, 0x35, 0x33, 0x37, 0x32, 0x37, 0x29, 0x3b, 0xd,    0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x62, 0x61, 0x63,    0x6b, 0x67, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x3a, 0x20, 0x2d,    0x6d, 0x73, 0x2d, 0x6c, 0x69, 0x6e, 0x65, 0x61, 0x72, 0x2d,    0x67, 0x72, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x74, 0x28, 0x74,    0x6f, 0x70, 0x2c, 0x20, 0x23, 0x44, 0x44, 0x34, 0x42, 0x33,    0x39, 0x2c, 0x20, 0x23, 0x43, 0x35, 0x33, 0x37, 0x32, 0x37,    0x29, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,    0x62, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x3a, 0x20, 0x31, 0x70,    0x78, 0x20, 0x73, 0x6f, 0x6c, 0x69, 0x64, 0x20, 0x23, 0x41,    0x46, 0x33, 0x30, 0x31, 0x46, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x2e, 0x72, 0x65,    0x64, 0x3a, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x20, 0xd,    0xa, 0x20, 0x20, 0x20, 0x20, 0x7b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x62, 0x61, 0x63, 0x6b, 0x67, 0x72,    0x6f, 0x75, 0x6e, 0x64, 0x3a, 0x20, 0x2d, 0x77, 0x65, 0x62,    0x6b, 0x69, 0x74, 0x2d, 0x6c, 0x69, 0x6e, 0x65, 0x61, 0x72,    0x2d, 0x67, 0x72, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x74, 0x28,    0x74, 0x6f, 0x70, 0x2c, 0x20, 0x23, 0x44, 0x37, 0x34, 0x37,    0x33, 0x36, 0x2c, 0x20, 0x23, 0x41, 0x44, 0x32, 0x37, 0x31,    0x39, 0x29, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20,    0x20, 0x62, 0x61, 0x63, 0x6b, 0x67, 0x72, 0x6f, 0x75, 0x6e,    0x64, 0x3a, 0x20, 0x2d, 0x6d, 0x6f, 0x7a, 0x2d, 0x6c, 0x69,    0x6e, 0x65, 0x61, 0x72, 0x2d, 0x67, 0x72, 0x61, 0x64, 0x69,    0x65, 0x6e, 0x74, 0x28, 0x74, 0x6f, 0x70, 0x2c, 0x20, 0x23,    0x44, 0x37, 0x34, 0x37, 0x33, 0x36, 0x2c, 0x20, 0x23, 0x41,    0x44, 0x32, 0x37, 0x31, 0x39, 0x29, 0x3b, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x20, 0x20, 0x62, 0x61, 0x63, 0x6b, 0x67,    0x72, 0x6f, 0x75, 0x6e, 0x64, 0x3a, 0x20, 0x2d, 0x6d, 0x73,    0x2d, 0x6c, 0x69, 0x6e, 0x65, 0x61, 0x72, 0x2d, 0x67, 0x72,    0x61, 0x64, 0x69, 0x65, 0x6e, 0x74, 0x28, 0x74, 0x6f, 0x70,    0x2c, 0x20, 0x23, 0x44, 0x37, 0x34, 0x37, 0x33, 0x36, 0x2c,    0x20, 0x23, 0x41, 0x44, 0x32, 0x37, 0x31, 0x39, 0x29, 0x3b,    0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x62, 0x6f,    0x78, 0x2d, 0x73, 0x68, 0x61, 0x64, 0x6f, 0x77, 0x3a, 0x20,    0x69, 0x6e, 0x73, 0x65, 0x74, 0x20, 0x30, 0x20, 0x31, 0x70,    0x78, 0x20, 0x31, 0x70, 0x78, 0x20, 0x72, 0x67, 0x62, 0x61,    0x28, 0x30, 0x2c, 0x30, 0x2c, 0x30, 0x2c, 0x30, 0x2e, 0x32,    0x29, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x7d, 0xd,    0xa, 0x20, 0x20, 0x3c, 0x2f, 0x73, 0x74, 0x79, 0x6c, 0x65,    0x3e, 0xd, 0xa, 0x3c, 0x2f, 0x68, 0x65, 0x61, 0x64, 0x3e,    0xd, 0xa, 0xd, 0xa, 0x3c, 0x62, 0x6f, 0x64, 0x79, 0x3e,    0xd, 0xa, 0x20, 0x20, 0x3c, 0x70, 0x20, 0x69, 0x64, 0x3d,    0x22, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x22, 0x3e, 0xd0, 0xa3,    0xd0, 0xbf, 0xd1, 0x80, 0xd0, 0xb0, 0xd0, 0xb2, 0xd0, 0xbb,    0xd0, 0xb5, 0xd0, 0xbd, 0xd0, 0xb8, 0xd0, 0xb5, 0x20, 0xd0,    0xbe, 0xd1, 0x81, 0xd0, 0xb2, 0xd0, 0xb5, 0xd1, 0x89, 0xd0,    0xb5, 0xd0, 0xbd, 0xd0, 0xb8, 0xd0, 0xb5, 0xd0, 0xbc, 0x20,    0x28, 0xd0, 0xb3, 0xd0, 0xb0, 0xd1, 0x80, 0xd0, 0xb0, 0xd0,    0xb6, 0x29, 0x3c, 0x2f, 0x70, 0x3e, 0xd, 0xa, 0x20, 0x20,    0x3c, 0x64, 0x69, 0x76, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x62,    0x75, 0x74, 0x74, 0x6f, 0x6e, 0x2d, 0x63, 0x6f, 0x6e, 0x74,    0x61, 0x69, 0x6e, 0x65, 0x72, 0x22, 0x3e, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x3c, 0x64, 0x69, 0x76, 0x3e, 0x3c, 0x61,    0x20, 0x68, 0x72, 0x65, 0x66, 0x3d, 0x22, 0x2f, 0x6c, 0x69,    0x67, 0x68, 0x74, 0x3f, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e,    0x3d, 0x6f, 0x6e, 0x26, 0x74, 0x69, 0x6d, 0x65, 0x3d, 0x35,    0x22, 0x3e, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,    0x3c, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x3e, 0xd0, 0x92,    0xd0, 0xba, 0xd0, 0xbb, 0xd1, 0x8e, 0xd1, 0x87, 0xd0, 0xb8,    0xd1, 0x82, 0xd1, 0x8c, 0x20, 0xd1, 0x81, 0xd0, 0xb2, 0xd0,    0xb5, 0xd1, 0x82, 0x20, 0xd0, 0xbd, 0xd0, 0xb0, 0x20, 0x35,    0x20, 0xd0, 0xbc, 0xd0, 0xb8, 0xd0, 0xbd, 0xd1, 0x83, 0xd1,    0x82, 0x3c, 0x2f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x3e,    0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x3c, 0x2f, 0x61, 0x3e,    0x3c, 0x2f, 0x64, 0x69, 0x76, 0x3e, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x3c, 0x64, 0x69, 0x76, 0x3e, 0x3c, 0x61, 0x20,    0x68, 0x72, 0x65, 0x66, 0x3d, 0x22, 0x2f, 0x6c, 0x69, 0x67,    0x68, 0x74, 0x3f, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x3d,    0x6f, 0x6e, 0x26, 0x74, 0x69, 0x6d, 0x65, 0x3d, 0x31, 0x30,    0x22, 0x3e, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,    0x3c, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x3e, 0xd0, 0x92,    0xd0, 0xba, 0xd0, 0xbb, 0xd1, 0x8e, 0xd1, 0x87, 0xd0, 0xb8,    0xd1, 0x82, 0xd1, 0x8c, 0x20, 0xd1, 0x81, 0xd0, 0xb2, 0xd0,    0xb5, 0xd1, 0x82, 0x20, 0xd0, 0xbd, 0xd0, 0xb0, 0x20, 0x31,    0x30, 0x20, 0xd0, 0xbc, 0xd0, 0xb8, 0xd0, 0xbd, 0xd1, 0x83,    0xd1, 0x82, 0x3c, 0x2f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e,    0x3e, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x3c, 0x2f, 0x61,    0x3e, 0x3c, 0x2f, 0x64, 0x69, 0x76, 0x3e, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x3c, 0x64, 0x69, 0x76, 0x3e, 0x3c, 0x61,    0x20, 0x68, 0x72, 0x65, 0x66, 0x3d, 0x22, 0x2f, 0x6c, 0x69,    0x67, 0x68, 0x74, 0x3f, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e,    0x3d, 0x6f, 0x6e, 0x26, 0x74, 0x69, 0x6d, 0x65, 0x3d, 0x31,    0x35, 0x22, 0x3e, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20,    0x20, 0x3c, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x3e, 0xd0,    0x92, 0xd0, 0xba, 0xd0, 0xbb, 0xd1, 0x8e, 0xd1, 0x87, 0xd0,    0xb8, 0xd1, 0x82, 0xd1, 0x8c, 0x20, 0xd1, 0x81, 0xd0, 0xb2,    0xd0, 0xb5, 0xd1, 0x82, 0x20, 0xd0, 0xbd, 0xd0, 0xb0, 0x20,    0x31, 0x35, 0x20, 0xd0, 0xbc, 0xd0, 0xb8, 0xd0, 0xbd, 0xd1,    0x83, 0xd1, 0x82, 0x3c, 0x2f, 0x62, 0x75, 0x74, 0x74, 0x6f,    0x6e, 0x3e, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x3c, 0x2f,    0x61, 0x3e, 0x3c, 0x2f, 0x64, 0x69, 0x76, 0x3e, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x3c, 0x64, 0x69, 0x76, 0x3e, 0x3c,    0x61, 0x20, 0x68, 0x72, 0x65, 0x66, 0x3d, 0x22, 0x2f, 0x6c,    0x69, 0x67, 0x68, 0x74, 0x3f, 0x61, 0x63, 0x74, 0x69, 0x6f,    0x6e, 0x3d, 0x6f, 0x6e, 0x22, 0x3e, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x3c, 0x62, 0x75, 0x74, 0x74, 0x6f,    0x6e, 0x3e, 0xd0, 0x92, 0xd0, 0xba, 0xd0, 0xbb, 0xd1, 0x8e,    0xd1, 0x87, 0xd0, 0xb8, 0xd1, 0x82, 0xd1, 0x8c, 0x20, 0xd1,    0x81, 0xd0, 0xb2, 0xd0, 0xb5, 0xd1, 0x82, 0x20, 0x28, 0xd0,    0xbf, 0xd0, 0xbe, 0xd1, 0x81, 0xd1, 0x82, 0xd0, 0xbe, 0xd1,    0x8f, 0xd0, 0xbd, 0xd0, 0xbd, 0xd0, 0xbe, 0x29, 0x3c, 0x2f,    0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x3e, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x3c, 0x2f, 0x61, 0x3e, 0x3c, 0x2f, 0x64,    0x69, 0x76, 0x3e, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x3c,    0x64, 0x69, 0x76, 0x3e, 0x3c, 0x61, 0x20, 0x68, 0x72, 0x65,    0x66, 0x3d, 0x22, 0x2f, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x3f,    0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x3d, 0x6f, 0x66, 0x66,    0x22, 0x3e, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,    0x3c, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x20, 0x63, 0x6c,    0x61, 0x73, 0x73, 0x3d, 0x22, 0x72, 0x65, 0x64, 0x22, 0x3e,    0xd0, 0x92, 0xd1, 0x8b, 0xd0, 0xba, 0xd0, 0xbb, 0xd1, 0x8e,    0xd1, 0x87, 0xd0, 0xb8, 0xd1, 0x82, 0xd1, 0x8c, 0x20, 0xd1,    0x81, 0xd0, 0xb2, 0xd0, 0xb5, 0xd1, 0x82, 0x3c, 0x2f, 0x62,    0x75, 0x74, 0x74, 0x6f, 0x6e, 0x3e, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x3c, 0x2f, 0x61, 0x3e, 0x3c, 0x2f, 0x64, 0x69,    0x76, 0x3e, 0xd, 0xa, 0x20, 0x20, 0x3c, 0x2f, 0x64, 0x69,    0x76, 0x3e, 0xd, 0xa, 0x3c, 0x2f, 0x62, 0x6f, 0x64, 0x79,    0x3e, 0xd, 0xa, 0x3c, 0x2f, 0x68, 0x74, 0x6d, 0x6c, 0x3e,    0xd, 0xa, 0 }; \/\/-----------------------------------------------------------------------------  ESP8266WebServer g_Server(80); \/\/-----------------------------------------------------------------------------  bool g_fLightOn = false; int g_LightOnMillis = 0; int g_LightOnTimeInMs = 0; \/\/-----------------------------------------------------------------------------  void handlerLight(); void lightOn(int aTime); void lightOff(); \/\/-----------------------------------------------------------------------------  void setup()  {   pinMode(0, OUTPUT);   digitalWrite(0, 1);      Serial.begin(115200);   WiFi.mode(WIFI_STA);   WiFi.begin(WIFI_SSID, WIFI_PASSWORD);   if (WiFi.waitForConnectResult() != WL_CONNECTED)    {     Serial.println(\"WiFi Connect Failed! Rebooting...\");     delay(1000);     ESP.restart();   }   ArduinoOTA.begin();    g_Server.on(\"\/light\", handlerLight);   g_Server.begin();    Serial.print(\"Open http:\/\/\");   Serial.print(WiFi.localIP());   Serial.println(\"\/light in your browser to see it working\");    WiFi.setAutoReconnect(true); } \/\/-----------------------------------------------------------------------------  void loop()  {   ArduinoOTA.handle();   g_Server.handleClient();    if(g_fLightOn &amp;&amp; g_LightOnTimeInMs &amp;&amp;     (millis() - g_LightOnMillis) > g_LightOnTimeInMs) { lightOff(); } } \/\/-----------------------------------------------------------------------------  void handlerLight() {   AUTHENTICATE_OR_RETURN();    auto action = g_Server.arg(\"action\");   if(action == \"on\")   {     lightOn(g_Server.arg(\"time\").toInt());   }   else if(action == \"off\")   {     lightOff();   }   else   {     \/\/ unknown action   }      g_Server.send(200, \"text\/html\", data_light_html); } \/\/-----------------------------------------------------------------------------  void lightOn(int aTime) {   Serial.println(\"Turn light on \" + (aTime ? (\"for \" + String(aTime) + \" minutes\") : \"permanently\"));      g_fLightOn = true;   g_LightOnMillis = millis();   g_LightOnTimeInMs = aTime * 60 * 1000;    digitalWrite(0, 0); } \/\/-----------------------------------------------------------------------------  void lightOff() {   Serial.println(\"Turn light off\");      g_fLightOn = false;    digitalWrite(0, 1); } \/\/----------------------------------------------------------------------------- <\/code><\/pre>\n<\/p>\n<\/div>\n<\/details>\n<p>\u041b\u043e\u0433\u0438\u043a\u0430 \u0440\u0430\u0431\u043e\u0442\u044b \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f. \u041f\u043e\u0441\u043b\u0435 \u0441\u0442\u0430\u0440\u0442\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u043f\u043e\u043f\u044b\u0442\u043a\u0430 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u0442\u043e\u0447\u043a\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 Wi-Fi, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 SSID \u0438 \u043f\u0430\u0440\u043e\u043b\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f WIFI_SSID \u0438 WIFI_PASSWORD. \u0412 \u0441\u043b\u0443\u0447\u0430\u0435 \u0443\u0441\u043f\u0435\u0448\u043d\u043e\u0433\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442\u0441\u044f \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0435\u0440 \u043d\u0430 80 \u043f\u043e\u0440\u0442\u0443 \u0438 html-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u043e\u0439, \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u043e\u0439 \u043f\u043e \u0430\u0434\u0440\u0435\u0441\u0443 `http:\/\/&lt;ip \u0430\u0434\u0440\u0435\u0441>\/light`. \u041b\u043e\u0433\u0438\u043d \u0438 \u043f\u0430\u0440\u043e\u043b\u044c, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0435 \u043f\u0440\u0438 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438, \u0443\u043a\u0430\u0437\u0430\u043d\u044b \u0432 WWW_USER \u0438 WWW_PASSWORD. <\/p>\n<p>\u0414\u043b\u044f \u0443\u0434\u043e\u0431\u0441\u0442\u0432\u0430 \u043e\u0442\u043b\u0430\u0434\u043a\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0434\u043b\u044f \u0432\u044b\u0432\u043e\u0434\u0430 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043f\u0440\u0438\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u044e\u0442 \u0432\u044b\u0437\u043e\u0432\u044b `Serial.println`, \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0440\u0430\u0431\u043e\u0442\u044b \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043c\u043e\u0436\u043d\u043e \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0432 `Serial Monitor`. \u0422\u0430\u043a, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0441\u0440\u0435\u0434\u0438 \u0432\u044b\u0432\u043e\u0434\u0438\u043c\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043c\u043e\u0436\u043d\u043e \u0443\u0432\u0438\u0434\u0435\u0442\u044c ip \u0430\u0434\u0440\u0435\u0441, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u044b\u043b \u043f\u0440\u0438\u0441\u0432\u043e\u0435\u043d \u043f\u0440\u0438 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0438 \u043a \u0442\u043e\u0447\u043a\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 Wi-Fi.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/79a\/d98\/47e\/79ad9847e9d21a048e0fc63bb5923c02.png\" width=\"733\" height=\"445\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/79a\/d98\/47e\/79ad9847e9d21a048e0fc63bb5923c02.png\"\/><figcaption><\/figcaption><\/figure>\n<h2>\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0433\u043e \u043e\u0431\u0440\u0430\u0437\u0446\u0430<\/h2>\n<p>\u041f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043f\u0440\u0438\u0441\u0442\u0443\u043f\u0438\u0442\u044c \u043a \u0441\u0431\u043e\u0440\u043a\u0435 \u0440\u0430\u0431\u043e\u0447\u0435\u0433\u043e \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c \u0443\u043b\u0438\u0447\u043d\u044b\u043c \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u0435\u043c, \u044f \u0441\u043e\u0431\u0440\u0430\u043b \u043f\u0440\u043e\u0441\u0442\u0443\u044e \u0441\u0445\u0435\u043c\u0443 \u043d\u0430 \u043c\u0430\u043a\u0435\u0442\u043d\u043e\u0439 \u043f\u043b\u0430\u0442\u0435 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434\u0430 \u0432\u043c\u0435\u0441\u0442\u043e \u043f\u0440\u043e\u0436\u0435\u043a\u0442\u043e\u0440\u0430.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/ad9\/fe0\/abb\/ad9fe0abb3fa0fe1605c4090fa07bf7b.png\" width=\"1865\" height=\"899\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ad9\/fe0\/abb\/ad9fe0abb3fa0fe1605c4090fa07bf7b.png\"\/><figcaption><\/figcaption><\/figure>\n<p>\u0412 \u043c\u043e\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u043c\u043e\u0434\u0443\u043b\u044c \u0440\u0435\u043b\u0435 \u0434\u043b\u044f ESP-01S, \u044d\u0442\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/dff\/32f\/3c2\/dff32f3c2544d6503ccae41ce51a45d3.png\" width=\"2016\" height=\"1512\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/dff\/32f\/3c2\/dff32f3c2544d6503ccae41ce51a45d3.png\"\/><figcaption><\/figcaption><\/figure>\n<h2>\u0421\u0431\u043e\u0440\u043a\u0430 \u0438 \u043c\u043e\u043d\u0442\u0430\u0436 \u0440\u0430\u0431\u043e\u0447\u0435\u0433\u043e \u043e\u0431\u0440\u0430\u0437\u0446\u0430<\/h2>\n<p>\u0414\u043b\u044f \u0441\u0431\u043e\u0440\u043a\u0438 \u0440\u0430\u0431\u043e\u0447\u0435\u0433\u043e \u043e\u0431\u0440\u0430\u0437\u0446\u0430 \u044f \u043f\u0440\u0438\u043e\u0431\u0440\u0435\u043b \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434\u043d\u044b\u0445 \u043f\u0440\u043e\u0436\u0435\u043a\u0442\u043e\u0440\u043e\u0432 \u0438 \u0440\u0430\u0441\u043f\u0430\u044f\u0447\u043d\u0443\u044e \u043a\u043e\u0440\u043e\u0431\u043a\u0443, \u043a\u0443\u0434\u0430 \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u043b \u043c\u043e\u0434\u0443\u043b\u044c \u0440\u0435\u043b\u0435. \u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430 \u043f\u0438\u0442\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u043c\u043e\u0434\u0443\u043b\u044f \u0440\u0435\u043b\u0435 \u044f \u0440\u0435\u0448\u0438\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0435\u0442\u0435\u0432\u043e\u0435 \u0437\u0430\u0440\u044f\u0434\u043d\u043e\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e, \u0430 \u0442\u043e\u0447\u043d\u0435\u0435 \u0435\u0433\u043e \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435, \u043c\u043e\u0449\u043d\u043e\u0441\u0442\u044c\u044e 5 \u0412\u0442.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/2f9\/217\/af0\/2f9217af0a3ba8d659b7e59fa16b57e4.png\" width=\"2016\" height=\"1512\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/2f9\/217\/af0\/2f9217af0a3ba8d659b7e59fa16b57e4.png\"\/><figcaption><\/figcaption><\/figure>\n<p>\u0414\u043b\u044f \u0442\u043e\u0433\u043e \u0447\u0442\u043e\u0431\u044b \u0432\u0435\u0431-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0431\u044b\u043b\u0430 \u0442\u0430\u043a\u0436\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u0430 \u0437\u0430 \u043f\u0440\u0435\u0434\u0435\u043b\u0430\u043c\u0438 \u0434\u043e\u043c\u0430\u0448\u043d\u0435\u0439 \u0441\u0435\u0442\u0438 \u043d\u0430 \u0440\u043e\u0443\u0442\u0435\u0440\u0435 \u0431\u044b\u043b\u043e \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u043e, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0435\u0435 \u043f\u0440\u043e\u0431\u0440\u043e\u0441 \u043f\u043e\u0440\u0442\u0430 \u043d\u0430 ESP-01S. <\/p>\n<p>\u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u0435 \u043f\u0440\u043e\u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c, \u0447\u0442\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u0432 \u0438\u0442\u043e\u0433\u0435.<\/p>\n<div class=\"tm-iframe_temp\" data-src=\"https:\/\/embedd.srv.habr.com\/iframe\/6272a5a258b073b4525f7895\" data-style=\"\" id=\"6272a5a258b073b4525f7895\" width=\"\"><\/div>\n<p>\u0421\u043f\u0430\u0441\u0438\u0431\u043e \u0437\u0430 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435!<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"v-portal\" style=\"display:none;\"><\/div>\n<\/div>\n<p> <!----> <!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/665226\/\"> https:\/\/habr.com\/ru\/post\/665226\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p>\u041f\u0440\u0438\u0432\u0435\u0442, \u0425\u0430\u0431\u0440! \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u0440\u0430\u0441\u0441\u043a\u0430\u0436\u0443 \u043e \u0441\u0432\u043e\u0435\u043c \u043e\u043f\u044b\u0442\u0435 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0443\u043b\u0438\u0447\u043d\u043e\u0433\u043e \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u044f, \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0439 \u043d\u0430 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0435 ESP8266. \u0425\u043e\u0442\u044c \u0434\u0430\u043d\u043d\u0430\u044f \u0438\u0434\u0435\u044f \u0438 \u043d\u0435 \u043d\u043e\u0432\u0430 \u0438 \u0432 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0435 \u043e\u0433\u0440\u043e\u043c\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0433\u043e\u0442\u043e\u0432\u044b\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432 \u043d\u0430 \u0431\u0430\u0437\u0435 \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430, \u044f \u0445\u043e\u0442\u0435\u043b \u0431\u044b \u043f\u043e\u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f \u0442\u0435\u043c, \u0447\u0442\u043e \u0443 \u043c\u0435\u043d\u044f \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u0432 \u043d\u0430\u0434\u0435\u0436\u0434\u0435, \u0447\u0442\u043e \u0434\u043b\u044f \u043a\u043e\u0433\u043e-\u043d\u0438\u0431\u0443\u0434\u044c \u044d\u0442\u043e \u043e\u043a\u0430\u0436\u0435\u0442\u0441\u044f \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u043c.<\/p>\n<p>\u041f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043d\u0430\u0447\u0430\u0442\u044c, \u043f\u043e\u0437\u0432\u043e\u043b\u044c\u0442\u0435 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u0440\u0435\u0434\u044b\u0441\u0442\u043e\u0440\u0438\u0438. \u042f \u0436\u0438\u0432\u0443 \u0432 \u0447\u0430\u0441\u0442\u043d\u043e\u043c \u0434\u043e\u043c\u0435 \u0438 \u0443\u043b\u0438\u0446\u0430, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d \u043c\u043e\u0439 \u0434\u043e\u043c, \u043d\u0435 \u0438\u043c\u0435\u0435\u0442 \u0445\u043e\u0440\u043e\u0448\u0435\u0433\u043e \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u044f. \u041e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u0434\u0430\u043d\u043d\u0430\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u043e\u0441\u0442\u0440\u043e \u043e\u0449\u0443\u0449\u0430\u0435\u0442\u0441\u044f \u0437\u0438\u043c\u043e\u0439, \u043a\u043e\u0433\u0434\u0430 \u0442\u0435\u043c\u043d\u0435\u0435\u0442 \u043e\u0447\u0435\u043d\u044c \u0440\u0430\u043d\u043e. \u0418\u043c\u0435\u043d\u043d\u043e \u0432 \u043e\u0434\u0438\u043d \u0438\u0437 \u0442\u0430\u043a\u0438\u0445 \u0434\u043d\u0435\u0439, \u043f\u0440\u0438\u043f\u0430\u0440\u043a\u043e\u0432\u0430\u0432 \u0430\u0432\u0442\u043e\u043c\u043e\u0431\u0438\u043b\u044c \u0438 \u0437\u0430\u043a\u0440\u044b\u0432\u0430\u044f \u0437\u0430 \u043d\u0438\u043c \u0432\u043e\u0440\u043e\u0442\u0430 \u0432 \u043f\u043e\u043b\u043d\u043e\u0439 \u0442\u0435\u043c\u043d\u043e\u0442\u0435 \u044f \u0440\u0435\u0448\u0438\u043b, \u0447\u0442\u043e \u043f\u043e\u0440\u0430 \u0437\u0430\u043d\u044f\u0442\u044c\u0441\u044f \u0432\u043d\u0435\u0448\u043d\u0438\u043c \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u0435\u043c. \u041f\u0435\u0440\u0432\u0430\u044f \u043c\u044b\u0441\u043b\u044c \u0431\u044b\u043b\u0430 &#8212; \u043f\u043e\u0432\u0435\u0441\u0438\u0442\u044c \u0441\u0432\u0435\u0442\u043e\u0434\u0438\u043e\u0434\u043d\u044b\u0439 \u043f\u0440\u043e\u0436\u0435\u043a\u0442\u043e\u0440 \u0441 \u0434\u0430\u0442\u0447\u0438\u043a\u043e\u043c \u0434\u0432\u0438\u0436\u0435\u043d\u0438\u044f \u0438 \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u043d\u043e\u0441\u0442\u0438. \u0412\u0430\u0440\u0438\u0430\u043d\u0442 \u043e\u0442\u043b\u0438\u0447\u043d\u044b\u0439, \u043d\u043e \u043c\u043d\u0435 \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0432\u0441\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0430\u043c\u043e\u043c\u0443, \u043a \u0442\u043e\u043c\u0443 \u0436\u0435 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0438\u0439 Pet-project \u0431\u044b\u043b \u0437\u0430\u043a\u043e\u043d\u0447\u0435\u043d \u0438 \u0432\u0440\u0435\u043c\u044f \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u043b\u043e \u0437\u0430\u043d\u044f\u0442\u044c\u0441\u044f \u0447\u0435\u043c-\u0442\u043e \u0434\u0440\u0443\u0433\u0438\u043c. \u041e\u0431\u0434\u0443\u043c\u0430\u0432 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438, \u0432\u043a\u043b\u044e\u0447\u0430\u044f \u043a\u0430\u043a \u0441 \u0434\u0430\u0442\u0447\u0438\u043a\u0430\u043c\u0438 \u0442\u0430\u043a \u0438 \u0431\u0435\u0437, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u044f, \u0447\u0442\u043e \u043d\u0430 \u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442 \u0443 \u043c\u0435\u043d\u044f \u0432 \u043d\u0430\u043b\u0438\u0447\u0438\u0438 \u0443\u0436\u0435 \u0431\u044b\u043b\u043e \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043c\u043e\u0434\u0443\u043b\u0435\u0439 \u0440\u0435\u043b\u0435 \u0441 ESP-01S, \u043a\u0443\u043f\u043b\u0435\u043d\u043d\u044b\u0445 \u0440\u0430\u043d\u0435\u0435 \u0434\u043b\u044f \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u043b\u0435\u043d\u0438\u044f, \u044f \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043b\u0441\u044f \u043d\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u043c &#8212; \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u0443\u043b\u0438\u0447\u043d\u043e\u0433\u043e \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u043d\u0430 \u0431\u0430\u0437\u0435 ESP8266 \u0441 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c \u0447\u0435\u0440\u0435\u0437 web-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441. \u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e\u0439 \u043f\u043b\u043e\u0449\u0430\u0434\u043a\u0438 \u0431\u044b\u043b\u043e \u0432\u044b\u0431\u0440\u0430\u043d\u043e \u043c\u0435\u0441\u0442\u043e \u043f\u0430\u0440\u043a\u043e\u0432\u043a\u0438 \u0430\u0432\u0442\u043e\u043c\u043e\u0431\u0438\u043b\u044f.<\/p>\n<h2>\u041c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 ESP8266<\/h2>\n<p>\u0418\u0441\u0442\u043e\u0440\u0438\u044f ESP8266 \u043d\u0430\u0447\u0430\u043b\u0430\u0441\u044c \u0432 2014 \u0433\u043e\u0434\u0443. \u0417\u0430 \u044d\u0442\u043e \u0432\u0440\u0435\u043c\u044f \u043e\u043d \u043e\u0431\u0440\u043e\u0441 \u0441\u0435\u0440\u044c\u0435\u0437\u043d\u044b\u043c \u043a\u043e\u043c\u044c\u044e\u043d\u0438\u0442\u0438 \u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u043b \u0448\u0438\u0440\u043e\u043a\u0443\u044e \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u043e\u0441\u0442\u044c \u0431\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044f \u043d\u0430\u043b\u0438\u0447\u0438\u044e Wi-Fi, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0432\u0432\u0438\u0434\u0443 \u0435\u0433\u043e \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0438\u0437\u043a\u043e\u0439 \u0441\u0442\u043e\u0438\u043c\u043e\u0441\u0442\u0438. \u041d\u0430 \u0431\u0430\u0437\u0435 ESP8266 \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u043e \u0431\u043e\u043b\u044c\u0448\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u043c\u043e\u0434\u0443\u043b\u0435\u0439, \u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u043e \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u043d\u0430 \u0425\u0430\u0431\u0440\u0435 <a href=\"https:\/\/habr.com\/ru\/post\/390593\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a> \u0438 <a href=\"https:\/\/habr.com\/ru\/post\/547330\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>. \u0412 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0435\u0447\u044c \u0431\u0443\u0434\u0435\u0442 \u0438\u0434\u0442\u0438 \u043e \u043c\u043e\u0434\u0443\u043b\u0435 ESP-01S, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u044f \u043f\u0440\u0438\u043e\u0431\u0440\u0435\u043b \u0432 \u043f\u0430\u0440\u0435 \u0441 \u043c\u043e\u0434\u0443\u043b\u0435\u043c \u0440\u0435\u043b\u0435 \u0434\u043b\u044f \u043d\u0435\u0433\u043e. <\/p>\n<figure class=\"\"><figcaption><\/figcaption><\/figure>\n<p>\u041d\u0435\u0431\u043e\u043b\u044c\u0448\u0430\u044f \u0441\u043f\u0440\u0430\u0432\u043a\u0430 &#8212; \u043c\u043e\u0434\u0443\u043b\u044c \u0440\u0435\u043b\u0435 \u0434\u043b\u044f ESP-01S \u0443\u0436\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0441\u0442\u0430\u0431\u0438\u043b\u0438\u0437\u0430\u0442\u043e\u0440 \u043d\u0430\u043f\u0440\u044f\u0436\u0435\u043d\u0438\u044f AMS1117, \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u044e\u0449\u0438\u0439 \u043f\u0438\u0442\u0430\u043d\u0438\u0435 \u043c\u0438\u043a\u0440\u043e\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u0440\u0430\u0432\u043d\u043e\u0435 3.3V. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u043d\u0430\u043f\u0440\u044f\u0436\u0435\u043d\u0438\u0435 \u043f\u0438\u0442\u0430\u043d\u0438\u0435 \u043c\u043e\u0434\u0443\u043b\u044f \u0440\u0435\u043b\u0435 \u0441\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 5V, \u0447\u0442\u043e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0443\u043f\u0440\u043e\u0449\u0430\u0435\u0442 \u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435. \u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0440\u0435\u043b\u0435 \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0430\u043c GPIO0.<\/p>\n<p>\u041e\u0434\u043d\u0430\u043a\u043e, \u0434\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0435\u0439 \u043d\u0430\u0433\u043b\u044f\u0434\u043d\u043e\u0441\u0442\u0438, \u0432\u043e \u0432\u0441\u0435\u0445 \u043f\u043e\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0445 \u0441\u0445\u0435\u043c\u0430\u0445 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e \u0441 ESP-01S \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0431\u044b\u0447\u043d\u043e\u0435 \u0440\u0435\u043b\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043f\u0440\u0438 \u0436\u0435\u043b\u0430\u043d\u0438\u0438 \u0432\u0441\u0435\u0433\u0434\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043c\u0435\u043d\u0435\u043d\u043e \u043d\u0430 \u043c\u043e\u0434\u0443\u043b\u044c \u0440\u0435\u043b\u0435 \u0434\u043b\u044f ESP-01S.<\/p>\n<h2>\u041f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043a\u0430 \u043a \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044e<\/h2>\n<p>\u041f\u0440\u043e\u0446\u0435\u0441\u0441 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f ESP-01S \u0432 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e\u0441\u0442\u044f\u0445 \u043e\u043f\u0438\u0441\u0430\u043d \u043d\u0430 \u0425\u0430\u0431\u0440\u0435 <a href=\"https:\/\/habr.com\/ru\/post\/390593\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a> \u0438 <a href=\"https:\/\/habr.com\/ru\/post\/547330\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u044f \u0440\u0435\u0448\u0438\u043b \u043d\u0435 \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0442\u044c\u0441\u044f, \u0430 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0442\u044c\u0441\u044f \u043b\u0438\u0448\u044c \u0441\u0445\u0435\u043c\u043e\u0439 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438.<\/p>\n<figure class=\"full-width\"><figcaption><\/figcaption><\/figure>\n<p>\u0414\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0443 \u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b \u043a\u0430\u0431\u0435\u043b\u044c USB &lt;\u2013> UART TTL.<\/p>\n<figure class=\"full-width\"><figcaption><\/figcaption><\/figure>\n<h3>\u041f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435. \u041d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438<\/h3>\n<p>\u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0441\u0440\u0435\u0434\u044b \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u044f \u0432\u044b\u0431\u0440\u0430\u043b Arduino IDE, \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043a\u043e\u0442\u043e\u0440\u043e\u0439, \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 ESP8266, \u0432 \u0434\u0435\u0442\u0430\u043b\u044f\u0445 \u043e\u043f\u0438\u0441\u0430\u043d \u043d\u0430 \u0425\u0430\u0431\u0440\u0435 <a href=\"https:\/\/habr.com\/ru\/post\/371853\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a> \u0438 <a href=\"https:\/\/habr.com\/ru\/post\/547330\/\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043e\u043f\u044f\u0442\u044c \u0436\u0435 \u043d\u0435 \u0441\u0442\u0430\u043d\u0435\u043c \u043e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u043d\u0435\u043c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e.<\/p>\n<p>\u041f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0438\u0442\u044c, \u044f \u0445\u043e\u0442\u0435\u043b \u0431\u044b \u043e\u0442\u043c\u0435\u0442\u0438\u0442\u044c, \u0447\u0442\u043e \u043e\u0434\u043d\u0438\u043c \u0438\u0437 \u043d\u0435\u043e\u0441\u043f\u043e\u0440\u0438\u043c\u044b\u0445 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432 Arduino IDE \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0442\u043e, \u0447\u0442\u043e \u043e\u043d\u0430 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043e\u0433\u0440\u043e\u043c\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0433\u043e\u0442\u043e\u0432\u044b\u0445 \u043f\u0440\u0438\u043c\u0435\u0440\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u044b \u0434\u043b\u044f \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u043b\u0435\u043d\u0438\u044f \u0438\u043b\u0438 \u043f\u0440\u043e\u0441\u0442\u043e \u0432\u0437\u044f\u0442\u044b \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043e\u0441\u043d\u043e\u0432\u044b, \u0447\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u043f\u0440\u043e\u0449\u0430\u0435\u0442 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0443.  <\/p>\n<p>\u041f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u0435\u043c \u043f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043b\u043e\u0441\u044c \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0442\u044c \u0447\u0435\u0440\u0435\u0437 web-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441, \u0442\u043e \u043f\u0435\u0440\u0432\u044b\u043c \u0434\u0435\u043b\u043e\u043c \u044f \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u0438\u043b \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e html \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443. <\/p>\n<figure class=\"\"><figcaption><\/figcaption><\/figure>\n<details class=\"spoiler\">\n<summary>\u0418\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 html \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"xml\">&lt;!doctype html>  &lt;html> &lt;head>   &lt;meta charset=\"utf-8\">   &lt;meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">    &lt;title>Remlight&lt;\/title>   &lt;meta name=\"description\" content=\"Remote lighting control\">    &lt;style>     body      {       margin:30px auto;       text-align: center;       font-family: 'Arial';     }      #title     {       color: #444444;       font-weight: bold;       font-size: 13pt;       outline: none;     }      #button-container      {       display: inline-block;     }      #button-container > div      {       padding: 10px;       width: 100%;     }      button      {       color: #444444;       background: #F3F3F3;       border: 1px #DADADA solid;       padding: 10px 40px;       border-radius: 2px;       font-weight: bold;       font-size: 9pt;       outline: none;       width: 100%;     }      button:hover      {       color: #333333;       background: #F7F7F7;       border: 1px #C6C6C6 solid;       box-shadow: 1px 1px 1px #EAEAEA;     }      button:active      {       box-shadow: inset 1px 1px 1px #DFDFDF;     }      button.red      {       color: white;       background: -webkit-linear-gradient(top, #DD4B39, #D14836);        background: -moz-linear-gradient(top, #DD4B39, #D14836);        background: -ms-linear-gradient(top, #DD4B39, #D14836);        border: 1px solid #DD4B39;       text-shadow: 0 1px 0 #C04131;     }      button.red:hover      {       background: -webkit-linear-gradient(top, #DD4B39, #C53727);       background: -moz-linear-gradient(top, #DD4B39, #C53727);       background: -ms-linear-gradient(top, #DD4B39, #C53727);       border: 1px solid #AF301F;     }      button.red:active      {       background: -webkit-linear-gradient(top, #D74736, #AD2719);       background: -moz-linear-gradient(top, #D74736, #AD2719);       background: -ms-linear-gradient(top, #D74736, #AD2719);       box-shadow: inset 0 1px 1px rgba(0,0,0,0.2);     }   &lt;\/style> &lt;\/head>  &lt;body>   &lt;p id=\"title\">\u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u043e\u0441\u0432\u0435\u0449\u0435\u043d\u0438\u0435\u043c (\u0433\u0430\u0440\u0430\u0436)&lt;\/p>   &lt;div id=\"button-container\">     &lt;div>&lt;a href=\"\/light?action=on&amp;time=5\">       &lt;button>\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442 \u043d\u0430 5 \u043c\u0438\u043d\u0443\u0442&lt;\/button>     &lt;\/a>&lt;\/div>     &lt;div>&lt;a href=\"\/light?action=on&amp;time=10\">       &lt;button>\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442 \u043d\u0430 10 \u043c\u0438\u043d\u0443\u0442&lt;\/button>     &lt;\/a>&lt;\/div>     &lt;div>&lt;a href=\"\/light?action=on&amp;time=15\">       &lt;button>\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442 \u043d\u0430 15 \u043c\u0438\u043d\u0443\u0442&lt;\/button>     &lt;\/a>&lt;\/div>     &lt;div>&lt;a href=\"\/light?action=on\">       &lt;button>\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442 (\u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u043e)&lt;\/button>     &lt;\/a>&lt;\/div>     &lt;div>&lt;a href=\"\/light?action=off\">       &lt;button class=\"red\">\u0412\u044b\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0432\u0435\u0442&lt;\/button>     &lt;\/a>&lt;\/div>   &lt;\/div> &lt;\/body> &lt;\/html> <\/code><\/pre>\n<\/p>\n<\/div>\n<\/details>\n<p>\u0414\u043b\u044f \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0435\u043d\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u044b ESP-01S \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 web-\u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0434\u043b\u044f \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 \u0431\u0430\u0437\u043e\u0432\u043e\u0439 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0431\u044b\u043b \u0432\u044b\u0431\u0440\u0430\u043d \u043a\u043b\u0430\u0441\u0441 ESP8266WebServer. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 html-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0431\u044b\u043b \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d \u0432 \u0448\u0435\u0441\u0442\u043d\u0430\u0434\u0446\u0430\u0442\u0435\u0440\u0438\u0447\u043d\u044b\u0439 \u0432\u0438\u0434 \u0438 \u0437\u0430\u043f\u0438\u0441\u0430\u043d \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0433\u043e \u043c\u0430\u0441\u0441\u0438\u0432\u0430 `data_light_html`.<\/p>\n<details class=\"spoiler\">\n<summary>\u0418\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"cpp\">#include &lt;ESP8266WiFi.h> #include &lt;ESP8266mDNS.h> #include &lt;ArduinoOTA.h> #include &lt;ESP8266WebServer.h> \/\/-----------------------------------------------------------------------------  #define WIFI_SSID \"ssid\" #define WIFI_PASSWORD \"password\"  #define WWW_USER \"user\" #define WWW_PASSWORD \"password\" \/\/-----------------------------------------------------------------------------  #define AUTHENTICATE_OR_RETURN()                                              \\ if (!g_Server.authenticate(WWW_USER, WWW_PASSWORD)) {                         \\   return g_Server.requestAuthentication();                                    \\ } \/\/-----------------------------------------------------------------------------  static const char data_light_html[] = {   0x3c, 0x21, 0x64, 0x6f, 0x63, 0x74, 0x79, 0x70, 0x65, 0x20,    0x68, 0x74, 0x6d, 0x6c, 0x3e, 0xd, 0xa, 0xd, 0xa, 0x3c,    0x68, 0x74, 0x6d, 0x6c, 0x3e, 0xd, 0xa, 0x3c, 0x68, 0x65,    0x61, 0x64, 0x3e, 0xd, 0xa, 0x20, 0x20, 0x3c, 0x6d, 0x65,    0x74, 0x61, 0x20, 0x63, 0x68, 0x61, 0x72, 0x73, 0x65, 0x74,    0x3d, 0x22, 0x75, 0x74, 0x66, 0x2d, 0x38, 0x22, 0x3e, 0xd,    0xa, 0x20, 0x20, 0x3c, 0x6d, 0x65, 0x74, 0x61, 0x20, 0x6e,    0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x65, 0x77, 0x70,    0x6f, 0x72, 0x74, 0x22, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65,    0x6e, 0x74, 0x3d, 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x3d,    0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x2d, 0x77, 0x69, 0x64,    0x74, 0x68, 0x2c, 0x20, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61,    0x6c, 0x2d, 0x73, 0x63, 0x61, 0x6c, 0x65, 0x3d, 0x31, 0x22,    0x3e, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x3c, 0x74, 0x69,    0x74, 0x6c, 0x65, 0x3e, 0x52, 0x65, 0x6d, 0x6c, 0x69, 0x67,    0x68, 0x74, 0x3c, 0x2f, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x3e,    0xd, 0xa, 0x20, 0x20, 0x3c, 0x6d, 0x65, 0x74, 0x61, 0x20,    0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x64, 0x65, 0x73, 0x63,    0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x20, 0x63,    0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x3d, 0x22, 0x52, 0x65,    0x6d, 0x6f, 0x74, 0x65, 0x20, 0x6c, 0x69, 0x67, 0x68, 0x74,    0x69, 0x6e, 0x67, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x6f,    0x6c, 0x22, 0x3e, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x3c,    0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x62, 0x6f, 0x64, 0x79, 0x20, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x7b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x20, 0x20, 0x6d, 0x61, 0x72, 0x67, 0x69, 0x6e, 0x3a, 0x33,    0x30, 0x70, 0x78, 0x20, 0x61, 0x75, 0x74, 0x6f, 0x3b, 0xd,    0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x74, 0x65, 0x78,    0x74, 0x2d, 0x61, 0x6c, 0x69, 0x67, 0x6e, 0x3a, 0x20, 0x63,    0x65, 0x6e, 0x74, 0x65, 0x72, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x6e, 0x74, 0x2d, 0x66,    0x61, 0x6d, 0x69, 0x6c, 0x79, 0x3a, 0x20, 0x27, 0x41, 0x72,    0x69, 0x61, 0x6c, 0x27, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20,    0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20,    0x23, 0x74, 0x69, 0x74, 0x6c, 0x65, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x7b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20,    0x20, 0x63, 0x6f, 0x6c, 0x6f, 0x72, 0x3a, 0x20, 0x23, 0x34,    0x34, 0x34, 0x34, 0x34, 0x34, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x6e, 0x74, 0x2d, 0x77,    0x65, 0x69, 0x67, 0x68, 0x74, 0x3a, 0x20, 0x62, 0x6f, 0x6c,    0x64, 0x3b, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,    0x66, 0x6f, 0x6e, 0x74, 0x2d, 0x73, 0x69, 0x7a, 0x65, 0x3a,    0x20, 0x31, 0x33, 0x70, 0x74, 0x3b, 0xd, 0xa, 0x20, 0x20,    0x20, 0x20, 0x20, 0x20, 0x6f, 0x75, 0x74, 0x6c, 0x69, 0x6e,    0x65, 0x3a, 0x20, 0x6e, 0x6f, 0x6e, 0x65, 0x3b, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x7d, 0xd, 0xa, 0xd, 0xa, 0x20,    0x20, 0x20, 0x20, 0x23, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e,    0x2d, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72,    0x20, 0xd, 0xa, 0x20, 0x20, 0x20, 0x20, 0x7b, 0xd, 0xa,    0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x64, 0x69, 0x73, <\/code><\/pre>\n<\/div>\n<\/details>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-332988","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/332988","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=332988"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/332988\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=332988"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=332988"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=332988"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}