{"id":26590088,"url":"https://github.com/nopnop2002/esp-mesh-lite-examples","last_synced_at":"2026-05-08T18:34:20.413Z","repository":{"id":283910014,"uuid":"953257082","full_name":"nopnop2002/esp-mesh-lite-examples","owner":"nopnop2002","description":"esp-mesh-lite example code","archived":false,"fork":false,"pushed_at":"2025-07-30T09:10:52.000Z","size":183,"stargazers_count":9,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-07-30T10:38:25.044Z","etag":null,"topics":["esp-idf","esp-mesh","esp32"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nopnop2002.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-03-22T23:29:38.000Z","updated_at":"2025-07-30T09:10:55.000Z","dependencies_parsed_at":"2025-03-23T01:17:58.850Z","dependency_job_id":"6b07e7b5-ea62-4ff0-b6fd-1ca023330926","html_url":"https://github.com/nopnop2002/esp-mesh-lite-examples","commit_stats":null,"previous_names":["nopnop2002/esp-mesh-lite-examples"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nopnop2002/esp-mesh-lite-examples","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nopnop2002%2Fesp-mesh-lite-examples","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nopnop2002%2Fesp-mesh-lite-examples/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nopnop2002%2Fesp-mesh-lite-examples/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nopnop2002%2Fesp-mesh-lite-examples/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nopnop2002","download_url":"https://codeload.github.com/nopnop2002/esp-mesh-lite-examples/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nopnop2002%2Fesp-mesh-lite-examples/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32792212,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-08T08:22:46.396Z","status":"ssl_error","status_checked_at":"2026-05-08T08:22:45.650Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["esp-idf","esp-mesh","esp32"],"created_at":"2025-03-23T13:20:42.102Z","updated_at":"2026-05-08T18:34:20.403Z","avatar_url":"https://github.com/nopnop2002.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# esp-mesh-lite-examples\nThe release version of esp-mesh-lite is available [here](https://components.espressif.com/components/espressif/mesh_lite/).   \nA development version of esp-mesh-lite is available [here](https://github.com/espressif/esp-mesh-lite).   \n\nYou can create a wide-area mesh network.   \nThe official repository comes with some example code.   \nThe official examples are very helpful when creating an application for esp-mesh-lite.   \nThis repository contains example code for esp-mesh-lite that is not in the official repository.   \n\n# The differences between ESP-MESH-LITE and ESP-MESH\nESP-MESH is a standard feature of ESP-IDF.   \nAn ESP-MESH example is available [here](https://github.com/espressif/esp-idf/tree/master/examples/mesh).   \nESP-MESH and ESP-MESH-LITE have different architectures.   \n\nThe ESP-MESH-LITE documentation is available [here](https://github.com/espressif/esp-mesh-lite/blob/master/components/mesh_lite/User_Guide.md).   \nAmong them, the following is particularly important:   \n```Each node in ESP-Mesh-Lite enables the LWIP stack and can be treated as a device directly connected to the router, which can independently invoke network interfaces such as Socket, MQTT, HTTP, etc., on the application layer.```   \nThis makes communication with external networks incredibly easy.   \n\nMESH-LITE uses [this](https://github.com/espressif/esp-iot-bridge/blob/master/components/iot_bridge/User_Guide.md) esp-iot-bridge.   \n[Here](https://raw.githubusercontent.com/espressif/esp-iot-bridge/master/components/iot_bridge/docs/_static/wifi_router_en.png) is a typical block diagram of this technology.\n\n# Mesh Solutions\nIn addition to ESP-MESH-LITE, we can use the following Mesh Solutions:   \nMesh Solution Comparison is [here](https://docs.espressif.com/projects/esp-techpedia/en/latest/esp-friends/solution-introduction/mesh/mesh-comparison.html).   \n- ESP BLE Mesh   \n- ESP Thread Mesh   \n- ZigBee Mesh   \n- ESP-Now   \n\n\n# Software requirements\nESP-IDF V5.0 or later.   \nESP-IDF V4.4 release branch reached EOL in July 2024.   \n\n# mesh_mqtt_client\nMQTT client using esp-mesh-lite.   \n\n# mesh_sntp_client\nSNTP client using esp-mesh-lite.   \n\n# mesh_http_client\nHTTP client using esp-mesh-lite.   \n\n# mesh_http_server\nHTTP server using esp-mesh-lite.   \n\n# mesh_websocket_client\nWebSocket client using esp-mesh-lite.   \n\n# mesh_websocket_server\nWebSocket server using esp-mesh-lite.   \n\n# mesh_ftp_client\nFTP client using esp-mesh-lite.   \n\n# mesh_local_control\nesp-mesh-lite comes with [this](https://github.com/espressif/esp-mesh-lite/tree/master/examples/mesh_local_control) TCP client example.   \nHowever, it does not include a server-side script.   \nThis is a TCP server script that can communicate with multiple ESP32s.   \nYou can try esp-mesh-lite now.   \n\n# router_less_message_exchange\nAn example of a routerless mesh network that exchanges data between nodes.   \nesp-mesh-lite comes with [this](https://github.com/espressif/esp-mesh-lite/tree/master/examples/no_router) router less example.   \nHowever, this example does not have communication functionality between nodes.   \n\n# mesh2uart\nesp-mesh-lite and UART/USB gateway application for routerless mesh networks.\n\n# mesh2ble\nesp-mesh-lite and BLE gateway application for routerless mesh networks.   \n\n# Restructuring network topology   \n\n### Loss of a child node   \nIf a child node is lost for any reason, the parent node disconnects the child node from the MESH network.   \nThis is the logging of the parent node at that time.   \nThe parent node has two child nodes up to tick 481219.   \nFrom tick 486019 onwards, the parent node has one child node.\n```\nI (481219) no_router: System information, channel: 11, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: 00:00:00:00:00:00, parent rssi: -120, free heap: 181260\nI (481219) no_router: Child mac: 24:0a:c4:c5:46:fc\nI (481219) no_router: Child mac: a4:cf:12:05:c6:34\nW (486019) wifi:inactive timer: now=1cec87a2 last_rx_time=b0346d1 diff=495d3, aid[2]a4:cf:12:05:c6:34 leave\nI (486049) wifi:station: a4:cf:12:05:c6:34 leave, AID = 2, reason = 4, bss_flags is 756851, bss:0x3ffbad54\nI (486049) wifi:new:\u003c11,2\u003e, old:\u003c11,2\u003e, ap:\u003c11,2\u003e, sta:\u003c0,0\u003e, prof:11, snd_ch_cfg:0x0\nI (486049) wifi:\u003cba-del\u003eidx:3, tid:0\nE (486059) bridge_wifi: STA Disconnect to the AP\nI (491219) no_router: System information, channel: 11, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: 00:00:00:00:00:00, parent rssi: -120, free heap: 183456\nI (491219) no_router: Child mac: 24:0a:c4:c5:46:fc\nI (501219) no_router: System information, channel: 11, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: 00:00:00:00:00:00, parent rssi: -120, free heap: 183456\nI (501219) no_router: Child mac: 24:0a:c4:c5:46:fc\n```\n\n### Loss of a root node   \nIf the root node is lost for any reason, one of the leaf nodes is promoted to root node.   \nThis is the logging of the root node at that time.   \nThis node was in layer 2 until tick 91204, but was promoted to the root node from tick 95683 onwards.   \n```\nI (61204) local_control: System information, channel: 1, layer: 2, self mac: 08:3a:f2:50:de:5c, parent bssid: a4:cf:12:05:c6:35, parent rssi: -46, free heap: 180504\nI (71204) local_control: System information, channel: 1, layer: 2, self mac: 08:3a:f2:50:de:5c, parent bssid: a4:cf:12:05:c6:35, parent rssi: -47, free heap: 180504\nI (81204) local_control: System information, channel: 1, layer: 2, self mac: 08:3a:f2:50:de:5c, parent bssid: a4:cf:12:05:c6:35, parent rssi: -46, free heap: 180504\nI (91204) local_control: System information, channel: 1, layer: 2, self mac: 08:3a:f2:50:de:5c, parent bssid: a4:cf:12:05:c6:35, parent rssi: -56, free heap: 178808\nI (95683) wifi:bcn_timeout,ap_probe_send_start\nI (98186) wifi:ap_probe_send over, reset wifi status to disassoc\nI (98187) wifi:state: run -\u003e init (0xc800)\nI (98189) wifi:pm stop, total sleep time: 0 us / 94021266 us\n\nI (98191) wifi:\u003cba-del\u003eidx:0, tid:0\nI (98195) wifi:new:\u003c1,0\u003e, old:\u003c1,1\u003e, ap:\u003c1,1\u003e, sta:\u003c1,1\u003e, prof:1, snd_ch_cfg:0x0\nE (98207) [ESP_Mesh_Lite_Comm]: Disconnect reason : 200\nE (98801) local_control: \u003cSoftware caused connection abort\u003e TCP write\nW (99044) wifi:Password length matches WPA2 standards, authmode threshold changes from OPEN to WPA2\nI (99047) [vendor_ie]: esp_wifi_connect return ESP_OK\nI (99049) [vendor_ie]: RTC store: temp_mesh_id:115; ssid:aterm-d5a4ee-g; bssid:00:00:00:00:00:00; crc:3383892968\nI (99057) [ESP_Mesh_Lite_Comm]: As the first inherited device, try to connect to the router\nI (99058) wifi:new:\u003c1,1\u003e, old:\u003c1,0\u003e, ap:\u003c1,1\u003e, sta:\u003c1,0\u003e, prof:1, snd_ch_cfg:0x0\nI (99074) wifi:state: init -\u003e auth (0xb0)\nI (99080) wifi:state: auth -\u003e assoc (0x0)\nI (99105) wifi:state: assoc -\u003e run (0x10)\nI (99210) wifi:connected with aterm-d5a4ee-g, aid = 15, channel 1, BW20, bssid = f8:b7:97:36:de:52\nI (99211) wifi:security: WPA2-PSK, phy: bgn, rssi: -53\nI (99214) wifi:pm start, type: 1\n\nI (99295) wifi:AP's beacon interval = 102400 us, DTIM period = 1\nI (100354) esp_netif_handlers: sta ip: 192.168.10.121, mask: 255.255.255.0, gw: 192.168.10.1\nI (100355) bridge_wifi: Connected with IP Address:192.168.10.121\nI (100359) [vendor_ie]: RTC store: temp_mesh_id:121; ssid:aterm-d5a4ee-g; bssid:00:00:00:00:00:00; crc:2665160230\nI (101143) wifi:\u003cba-add\u003eidx:0 (ifx:0, f8:b7:97:36:de:52), tid:5, ssn:0, winSize:64\nI (101204) local_control: System information, channel: 1, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: f8:b7:97:36:de:52, parent rssi: -55, free heap: 180284\nI (101247) wifi:\u003cba-add\u003eidx:1 (ifx:0, f8:b7:97:36:de:52), tid:0, ssn:6, winSize:64\nI (111204) local_control: System information, channel: 1, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: f8:b7:97:36:de:52, parent rssi: -55, free heap: 180484\n```\n\n### Adding leaf nodes   \nWhen a leaf node is added, the root node or leaf node automatically adds it to the network.   \nThe parent node is determined automatically based on the surrounding circumstances.   \nThis is the logging of the root node at that time.   \nThe root node has one child node up to tick 1031209.    \nFrom tick 1038584 onwards, the root node has two child nodes.   \n```\nI (1021204) local_control: System information, channel: 1, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: f8:b7:97:36:de:52, parent rssi: -56, free heap: 178116\nI (1021211) local_control: Child mac: 24:0a:c4:c5:46:fc\nI (1031204) local_control: System information, channel: 1, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: f8:b7:97:36:de:52, parent rssi: -56, free heap: 178116\nI (1031209) local_control: Child mac: 24:0a:c4:c5:46:fc\nI (1038584) wifi:new:\u003c1,1\u003e, old:\u003c1,1\u003e, ap:\u003c1,1\u003e, sta:\u003c1,0\u003e, prof:1, snd_ch_cfg:0x0\nI (1038585) wifi:station: a4:cf:12:05:c6:34 join, AID=2, bgn, 40U\nI (1038614) bridge_wifi: STA Connecting to the AP again...\nI (1038637) esp_netif_lwip: DHCP server assigned IP to a client, IP is: 192.168.4.3\nI (1039679) wifi:\u003cba-add\u003eidx:3 (ifx:1, a4:cf:12:05:c6:34), tid:0, ssn:0, winSize:64\nI (1041204) local_control: System information, channel: 1, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: f8:b7:97:36:de:52, parent rssi: -56, free heap: 175748\nI (1041209) local_control: Child mac: 24:0a:c4:c5:46:fc\nI (1041214) local_control: Child mac: a4:cf:12:05:c6:34\nI (1051204) local_control: System information, channel: 1, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: f8:b7:97:36:de:52, parent rssi: -56, free heap: 175748\nI (1051209) local_control: Child mac: 24:0a:c4:c5:46:fc\nI (1051214) local_control: Child mac: a4:cf:12:05:c6:34\nI (1061204) local_control: System information, channel: 1, layer: 1, self mac: 08:3a:f2:50:de:5c, parent bssid: f8:b7:97:36:de:52, parent rssi: -57, free heap: 175560\nI (1061209) local_control: Child mac: 24:0a:c4:c5:46:fc\nI (1061214) local_control: Child mac: a4:cf:12:05:c6:34\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnopnop2002%2Fesp-mesh-lite-examples","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnopnop2002%2Fesp-mesh-lite-examples","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnopnop2002%2Fesp-mesh-lite-examples/lists"}