Navigation Menu

Skip to content

Commit

Permalink
Update Instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
msraynsford committed Oct 3, 2018
1 parent 5b077f3 commit 341d32a
Show file tree
Hide file tree
Showing 9 changed files with 35 additions and 2 deletions.
Binary file added APConfig.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Admin.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Browser.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Device.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
32 changes: 32 additions & 0 deletions README.md
@@ -0,0 +1,32 @@
# APConfig
A simple framework for creating an standalone access point for an ESP8266.
Once connected to the device it is possible to change the SSID and Password from within a browser, it is also possible to reset the device should the password be forgotten.

# Connecting to the access point
When the micro controller device is connected to a power supply via a usb cable,
The ESP8266 will start a new WiFi connection called "APConfig XXXXXX". You should be able to find this network from your phone/laptop and connect to it using the password:'password'.

![alt text](https://github.com/msraynsford/APConfig/blob/master/WifiNetwork.png "Wifi List")

Once the connection has been established you can connect to the device through a browser using the default IP address http://192.168.4.1/

![alt text](https://github.com/msraynsford/APConfig/blob/master/Browser.png "Browser Image")


#Changing the SSID and Password
It is recommended to change the password for the WiFi network as soon as possible, there is a separate admin page that allows you to do this. If you navigate the browser to http://192.168.4.1/admin you will be presented with this page

![alt text](https://github.com/msraynsford/APConfig/blob/master/Admin.png "Admin Image")

This page allows you to change the password without entering the previous password because you already have to be connected to the WiFi using the existing password.

#Connecting to the device without a password
If you forget the password it is still possible to connect to the device and update the SSID and password. When you turn the device on, the led will illuminate after 2 seconds and remain on for 1 second.

![alt text](https://github.com/msraynsford/APConfig/blob/master/Device.png "Device Image")

If you press the reset button during this window the device will start a new wifi network called "APConfig". This network has no password so anybody can connect to it, the next time the device is turned on it will return to normal, passworded, operation.

![alt text](https://github.com/msraynsford/APConfig/blob/master/APConfig.png "APConfig Image")


1 change: 0 additions & 1 deletion Source/APConfig/APConfig.ino
Expand Up @@ -20,7 +20,6 @@ void setup() {
WiFi.mode(WIFI_AP);

LoadConfig();
ResetConfig();
PrintConfig();

//Check to see if the flag is still set from the previous boot
Expand Down
2 changes: 2 additions & 0 deletions Source/APConfig/AdminPage.h
Expand Up @@ -35,6 +35,8 @@ void serveAdmin(ESP8266WebServer *webServer) {
else {
// Create a string containing all the arguments, send them out to the serial port
// Check to see if there are new values (also doubles to check the length of the new value is long enough)
Serial.println(webServer->arg("newssid"));

if((webServer->arg("newssid").length() >= MIN_STR_LEN) &&
(webServer->arg("newssid").length() < MAX_STR_LEN))
webServer->arg("newssid").toCharArray(config.ssid, sizeof(config.ssid));
Expand Down
2 changes: 1 addition & 1 deletion Source/APConfig/Config.h
Expand Up @@ -6,8 +6,8 @@

#include "EEPROMAnything.h"

#define MIN_STR_LEN 8
#define MAX_STR_LEN 17
#define MIN_STR_LEN 17

#define SSID_DEFAULT "APConfig"
#define PASS_DEFAULT "password"
Expand Down
Binary file added WifiNetwork.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 341d32a

Please sign in to comment.