Difference between revisions of "NeoPixel Web Server"

From LVL1
Jump to navigation Jump to search
Line 5: Line 5:
 
2.  Install the NodeMCU software using the instructions on this page https://randomnerdtutorials.com/how-to-install-esp8266-board-arduino-ide/
 
2.  Install the NodeMCU software using the instructions on this page https://randomnerdtutorials.com/how-to-install-esp8266-board-arduino-ide/
  
3.  Install the FASTLED library  Arduino->sketch->include library->manage libraries  Search for FASTLED and install
+
* On step 5, select the current version (v2.4.2 at the time of this workshop, December 2018).
 +
* On step 6, select the NodeMCU 1.0 (ESP-12E Module) board for this workshop.
 +
 
 +
3.  Install the FASTLED library   
 +
* Select Arduino->sketch->include library->manage libraries   
 +
* Search for FASTLED and install (version 3.2.1 at the time of this workshop, December 2018).
  
 
4.  Download the arduino software for the fastled webserver https://github.com/jasoncoon/esp8266-fastled-webserver
 
4.  Download the arduino software for the fastled webserver https://github.com/jasoncoon/esp8266-fastled-webserver
  
* Click clone or download and download the zip.  Put this zip file on your desktop or in the documents folder
+
* Click the "Clone or download" button and download the zip.  Save this zip file on your desktop or in the documents folder
 
* Right click to unzip the software  
 
* Right click to unzip the software  
 +
* Rename the folder to "esp8266-fastled-webserver" (removing the "-master" from the default name).
  
 
5.  Navigate to the folder and run the esp8266-fastled-webserver.ino file
 
5.  Navigate to the folder and run the esp8266-fastled-webserver.ino file
  
6. Edit this file above to be like this
+
* Find the section that starts with #include "FSBrowser.h" and replace that section with this:
  
 
  #include "FSBrowser.h"
 
  #include "FSBrowser.h"
Line 42: Line 48:
 
  char* password = "your-password";
 
  char* password = "your-password";
  
 +
* Save the changes.
 +
 +
6. Install the Arduino ESP8266FS tool from http://esp8266.github.io/Arduino/versions/2.3.0/doc/filesystem.html#uploading-files-to-file-system
  
7. The web app needs to be uploaded to the ESP8266's SPIFFS. You can do this within the Arduino IDE after installing the Arduino ESP8266FS tool.  http://esp8266.github.io/Arduino/versions/2.3.0/doc/filesystem.html#uploading-files-to-file-system
+
7. In the Arduino IDE select Tools->ESP8266 Sketch Data Upload.
With ESP8266FS installed upload the web app using ESP8266 Sketch Data Upload command in the Arduino Tools menu.
 

Revision as of 17:11, 19 December 2018

Instructions

1. Install Arduino IDE software. Not the web one. https://www.arduino.cc/en/Main/Software

2. Install the NodeMCU software using the instructions on this page https://randomnerdtutorials.com/how-to-install-esp8266-board-arduino-ide/

  • On step 5, select the current version (v2.4.2 at the time of this workshop, December 2018).
  • On step 6, select the NodeMCU 1.0 (ESP-12E Module) board for this workshop.

3. Install the FASTLED library

  • Select Arduino->sketch->include library->manage libraries
  • Search for FASTLED and install (version 3.2.1 at the time of this workshop, December 2018).

4. Download the arduino software for the fastled webserver https://github.com/jasoncoon/esp8266-fastled-webserver

  • Click the "Clone or download" button and download the zip. Save this zip file on your desktop or in the documents folder
  • Right click to unzip the software
  • Rename the folder to "esp8266-fastled-webserver" (removing the "-master" from the default name).

5. Navigate to the folder and run the esp8266-fastled-webserver.ino file

  • Find the section that starts with #include "FSBrowser.h" and replace that section with this:
#include "FSBrowser.h"

#define DATA_PIN      5 //LVL1 change this!  This is D5
#define LED_TYPE      WS2811
#define COLOR_ORDER   RGB
#define NUM_LEDS      30 //change this!

#define MILLI_AMPS         2000 // IMPORTANT: set the max milli-Amps of your power supply (4A = 4000mA)
#define FRAMES_PER_SECOND  120  // here you can control the speed. With the Access Point / Web Server the animations run a bit slower.

//LVL1 change this to true!
const bool apMode = true;

//LVL1 Comment this secrets.h
//#include "Secrets.h" // this file is intentionally not included in the sketch, so nobody accidentally commits their secret information.
// create a Secrets.h file with the following:

// AP mode password
//LVL1 uncomment this!
const char WiFiAPPSK[] = "your-password";

// Wi-Fi network to connect to (if not in AP mode)
//LVL1 uncomment this!
char* ssid = "your-ssid";
char* password = "your-password";
  • Save the changes.

6. Install the Arduino ESP8266FS tool from http://esp8266.github.io/Arduino/versions/2.3.0/doc/filesystem.html#uploading-files-to-file-system

7. In the Arduino IDE select Tools->ESP8266 Sketch Data Upload.