# WiFiManager
## DEVELOPMENT Version
Espressif ESPx WiFi Connection manager with fallback web configuration portal
:warning: This Documentation is out of date, see notes below
![Build CI Status](https://github.com/tzapu/WiFiManager/actions/workflows/compile_library.yml/badge.svg)
![Build CI Status Examples](https://github.com/tzapu/WiFiManager/actions/workflows/compile_examples.yaml/badge.svg)
[![arduino-library-badge](https://www.ardu-badge.com/badge/WiFiManager.svg?)](https://www.ardu-badge.com/WiFiManager)
[![Build with PlatformIO](https://img.shields.io/badge/PlatformIO-Library-orange?)](https://platformio.org/lib/show/567/WiFiManager/installation)
![ESP8266](https://img.shields.io/badge/ESP-8266-000000.svg?longCache=true&style=flat&colorA=CC101F)
![ESP32](https://img.shields.io/badge/ESP-32-000000.svg?longCache=true&style=flat&colorA=CC101F)
Member to Member Support / Chat
[![Join the chat at https://gitter.im/tablatronix/WiFiManager](https://badges.gitter.im/tablatronix/WiFiManager.svg)](https://gitter.im/tablatronix/WiFiManager?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![Discord](https://img.shields.io/badge/Discord-WiFiManager-%237289da.svg?logo=discord)](https://discord.gg/dkjJbHwC)
The configuration portal is of the captive variety, so on various devices it will present the configuration dialogue as soon as you connect to the created access point.
**This works with the ESP8266 Arduino platform**
[https://github.com/esp8266/Arduino](https://github.com/esp8266/Arduino)
**This works with the ESP32 Arduino platform**
[https://github.com/espressif/arduino-esp32](https://github.com/espressif/arduino-esp32)
### Known Issues
* Documentation needs to be updated, see [https://github.com/tzapu/WiFiManager/issues/500](https://github.com/tzapu/WiFiManager/issues/500)
-------
## Contents
- [How it works](#how-it-works)
- [Wishlist](#wishlist)
- [Quick start](#quick-start)
- Installing
- [Arduino - Through Library Manager](#install-through-library-manager)
- [Arduino - From Github](#checkout-from-github)
- [PlatformIO](#install-using-platformio)
- [Using](#using)
- [Documentation](#documentation)
- [Access Point Password](#password-protect-the-configuration-access-point)
- [Callbacks](#callbacks)
- [Configuration Portal Timeout](#configuration-portal-timeout)
- [On Demand Configuration](#on-demand-configuration-portal)
- [Custom Parameters](#custom-parameters)
- [Custom IP Configuration](#custom-ip-configuration)
- [Filter Low Quality Networks](#filter-networks)
- [Debug Output](#debug)
- [Troubleshooting](#troubleshooting)
- [Releases](#releases)
- [Contributors](#contributions-and-thanks)
## How It Works
- When your ESP starts up, it sets it up in Station mode and tries to connect to a previously saved Access Point
- if this is unsuccessful (or no previous network saved) it moves the ESP into Access Point mode and spins up a DNS and WebServer (default ip 192.168.4.1)
- using any wifi enabled device with a browser (computer, phone, tablet) connect to the newly created Access Point
- because of the Captive Portal and the DNS server you will either get a 'Join to network' type of popup or get any domain you try to access redirected to the configuration portal
- choose one of the access points scanned, enter password, click save
- ESP will try to connect. If successful, it relinquishes control back to your app. If not, reconnect to AP and reconfigure.
- There are options to change this behavior or manually start the configportal and webportal independantly as well as run them in non blocking mode.
## How It Looks
![ESP8266 WiFi Captive Portal Homepage](http://i.imgur.com/YPvW9eql.png) ![ESP8266 WiFi Captive Portal Configuration](http://i.imgur.com/oicWJ4gl.png)
## Wishlist
- [x] remove dependency on EEPROM library
- [x] move HTML Strings to PROGMEM
- [x] cleanup and streamline code (although this is ongoing)
- [x] if timeout is set, extend it when a page is fetched in AP mode
- [x] add ability to configure more parameters than ssid/password
- [x] maybe allow setting ip of ESP after reboot
- [x] add to Arduino Library Manager
- [x] add to PlatformIO
- [ ] add multiple sets of network credentials
- [x] allow users to customize CSS
- [ ] rewrite documentation for simplicity, based on scenarios/goals
### Development
- [x] ESP32 support
- [x] rely on the SDK's built in auto connect more than forcing a connect
- [x] add non blocking mode
- [x] easy customization of strings
- [x] hostname support
- [x] fix various bugs and workarounds for esp SDK issues
- [x] additional info page items
- [x] last status display / faiilure reason
- [x] customizeable menu
- [x] seperate custom params page
- [x] ondemand webportal
- [x] complete refactor of code to segment functions
- [x] wiif scan icons or percentage display
- [x] invert class for dark mode
- [x] more template tokens
- [x] progmem for all strings
- [ ] new callbacks
- [ ] new callouts / filters
- [ ] shared web server instance
- [x] latest esp idf/sdk support
- [x] wm is now non persistent, will not erase or change stored esp config on esp8266
- [x] tons of debugging output / levels
- [ ] disable captiveportal
- [ ] preload wiifscans, faster page loads
- [ ] softap stability fixes when sta is not connected
## Quick Start
### Installing
You can either install through the Arduino Library Manager or checkout the latest changes or a release from github
#### Install through Library Manager
__Currently version 0.8+ works with release 2.4.0 or newer of the [ESP8266 core for Arduino](https://github.com/esp8266/Arduino)__
- in Arduino IDE got to Sketch/Include Library/Manage Libraries
![Manage Libraries](http://i.imgur.com/9BkEBkR.png)
- search for WiFiManager
![WiFiManager package](http://i.imgur.com/18yIai8.png)
- click Install and start [using it](#using)
#### Checkout from github
__Github version works with release 2.4.0 or newer of the [ESP8266 core for Arduino](https://github.com/esp8266/Arduino)__
- Checkout library to your Arduino libraries folder
### Using
- Include in your sketch
```cpp
#include <WiFiManager.h> //https://github.com/tzapu/WiFiManager WiFi Configuration Magic
```
- Initialize library, in your setup function add, NOTEif you are using non blocking you will make sure you create this in global scope or handle appropriatly , it will not work if in setup and using non blocking mode.
```cpp
WiFiManager wifiManager;
```
- Also in the setup function add
```cpp
//first parameter is name of access point, second is the password
wifiManager.autoConnect("AP-NAME", "AP-PASSWORD");
```
if you just want an unsecured access point
```cpp
wifiManager.autoConnect("AP-NAME");
```
or if you want to use and auto generated name from 'ESP' and the esp's Chip ID use
```cpp
wifiManager.autoConnect();
```
After you write your sketch and start the ESP, it will try to connect to WiFi. If it fails it starts in Access Point mode.
While in AP mode, connect to it then open a browser to the gateway IP, default 192.168.4.1, configure wifi, save and it should reboot and connect.
Also see [examples](https://github.com/tzapu/WiFiManager/tree/master/examples).
#### Install Using PlatformIO
[PlatformIO](https://platformio.org/) is an emerging ecosystem for IoT development, and
is an alternative to using the Arduino IDE. Install `WiFiManager`
using the platformio [library manager](https://docs.platformio.org/en/latest/librarymanager/index.htm) in your editor,
or using the [PlatformIO Core CLI](https://docs.platformio.org/en/latest/userguide/demo.html#library-manager),
or by adding it to your `platformio.ini` as shown below (recommended approach).
The simplest way is to open the `platformio.ini` file at the root of your project, and `WifiManager` to the common top-level env
`lib_deps` key like so:
```
[env]
lib_deps =
WiFiManager
```
```
[env]
lib_deps =
https://github.com/tzapu/WiFiManager.gi
没有合适的资源?快使用搜索试试~ 我知道了~
温馨提示
所有源码均经过严格测试,可以直接运行,可以放心下载使用。有任何使用问题欢迎随时与博主沟通,第一时间进行解答!该资源内项目代码都经过测试运行成功,功能ok的情况下才上传的,请放心下载使用!有问题请及时沟通交流。 基于STM32、ESP8266、PHP、QT、应用软件开发、系统软件开发、移动应用开发、网站开发C++、Java、python、web、C#、单片机、EDA、proteus、RTOS、包括计算机硬件、服务器、网络设备、存储设备、移动设备、LInux、IOS、树莓派、安卓开发、微机操作系统、网络操作系统、分布式操作系统等。此外,还有嵌入式操作系统、智能操作系统等、数据集、大数据分析、人工智能、机器学习等各种项目 项目具有较高的学习借鉴价值,也适用于小白学习入门进阶。当然也可作为毕设项目、课程设计、大作业、初期项目立项演示等。如果基础还行,或者热爱钻研,亦可在此项目代码基础上进行修改添加,实现其他不同功能。欢迎下载,沟通交流,互相学习,共同进步!
资源推荐
资源详情
资源评论
收起资源包目录
毕设&课设&项目&实训-基于esp8266的多功能桌面小时钟.zip (1185个子文件)
parrot.bmp 60KB
TestCard.bmp 46KB
Tiger.bmp 41KB
star.bmp 13KB
astronomy.c 337KB
tjpgd.c 74KB
Font32rle.c 34KB
Font16.c 28KB
TFT_eSPI_ESP32.c 27KB
TFT_eSPI_STM32.c 26KB
Font72rle.c 16KB
Font72x53rle.c 16KB
TFT_eSPI_ESP8266.c 13KB
Font64rle.c 12KB
Font7srle.c 11KB
TFT_eSPI_Generic.c 10KB
glcdfont.c 8KB
testCCompiler.c 234B
cmake.check_cache 85B
ci-compile 1KB
.clang-format 349B
cmake_install.cmake 1KB
CMakeDirectoryInformation.cmake 719B
DependInfo.cmake 665B
DependInfo.cmake 665B
DependInfo.cmake 665B
DependInfo.cmake 665B
DependInfo.cmake 665B
DependInfo.cmake 665B
DependInfo.cmake 665B
DependInfo.cmake 665B
DependInfo.cmake 665B
DependInfo.cmake 665B
cmake_clean.cmake 317B
cmake_clean.cmake 317B
cmake_clean.cmake 317B
cmake_clean.cmake 317B
cmake_clean.cmake 317B
cmake_clean.cmake 317B
cmake_clean.cmake 317B
cmake_clean.cmake 317B
cmake_clean.cmake 317B
cmake_clean.cmake 317B
workspace.code-workspace 70B
SD3.code-workspace 60B
TFT_eSPI.cpp 137KB
WiFiManager.cpp 109KB
starImage.cpp 77KB
Sprite.cpp 76KB
SmallDesktopDisplay.cpp 52KB
colorutils.cpp 36KB
noise.cpp 26KB
hsv2rgb.cpp 22KB
clockless_rmt_esp32.cpp 20KB
TJpg_Decoder.cpp 18KB
Smooth_font.cpp 18KB
Touch.cpp 13KB
DHT.cpp 12KB
DHT.cpp 12KB
Time.cpp 9KB
Button2.cpp 8KB
FastLED.cpp 7KB
wiring.cpp 7KB
lib8tion.cpp 7KB
Animate.cpp 6KB
DHT_U.cpp 6KB
DHT_U.cpp 6KB
power_mgt.cpp 6KB
colorpalettes.cpp 5KB
Adafruit_Sensor.cpp 4KB
number.cpp 3KB
DateStrings.cpp 3KB
user_bat.cpp 3KB
user_bat.cpp 3KB
Button.cpp 3KB
user.cpp 3KB
user.cpp 3KB
user_xmas.cpp 2KB
user_xmas.cpp 2KB
timeClockDraw.cpp 2KB
Adafruit_Sensor.cpp 2KB
ThreadController.cpp 2KB
weatherNum.cpp 2KB
platforms.cpp 1KB
Thread.cpp 1KB
Animate.cpp 953B
bitswap.cpp 866B
wifiReFlash.cpp 66B
test.cpp 40B
integrity.dat 228B
.DS_Store 14KB
.DS_Store 14KB
.gitattributes 378B
.gitattributes 378B
.gitattributes 29B
.gitignore 1KB
.gitignore 649B
.gitignore 315B
.gitignore 269B
.gitignore 198B
共 1185 条
- 1
- 2
- 3
- 4
- 5
- 6
- 12
资源评论
妄北y
- 粉丝: 1w+
- 资源: 1万+
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功