ESP-01S Serial Remote Controller
This repository contains custom firmware for the ESP-01S that runs a web server, which hosts a webpage. This webpage allows users to toggle values on a separate microcontroller that connects via UART.
ESP-01S Module
Flashing
The firmware has been developed using PlatformIO and the Arduino framework. To flash the firmware, connect the ESP module to a computer using a UART to USB adapter. The ESP must be in programming mode, this is achived by holding GPIO0 low during MCU initilization. Once the ESP is ready, flash the firmware using PlatformIO console tools.
At the moment, this firmware does not implement a Wi-Fi manager, so the firmware must be re-flashed whenever the Wi-Fi SSID or password changes. To configure the Wi-Fi credentials, environment variables are used during firmware compilation.
To set the environment variables, run the following commands in the same terminal session that will be used to compile and flash the firmware.
$ export WIFI_SSID="hello-world"
$ export WIFI_PASSWD="12345678"
Alternatively, the Wi-Fi credentials can be defined in the src/main.cpp file.
#define WIFI_SSID "hello-world"
#define WIFI_PASSWD "12345678"
After setting the credentials, flash the main firmware to the ESP.
$ pio run -t upload
Finally upload the files to the LittleFS filesystem.
$ pio run -t uploadfs
LICENSE
This software is licensed under the MIT License. See the LICENSE file for details.
1 # ESP-01S Serial Remote Controller 2 3 This repository contains custom firmware for the ESP-01S that runs a web server, 4 which hosts a webpage. This webpage allows users to toggle values on a separate 5 microcontroller that connects via UART. 6 7 <div style="text-align: center;"> 8 <img src="img/esp01s.jpg" style="padding: 10px;" width="35%"> 9 <img src="img/esp01s-pinout.jpg" style="padding: 10px;" width="55%"> 10 <p align="center"><em>ESP-01S Module </em></p> 11 </div> 12 13 ## Flashing 14 15 The firmware has been developed using PlatformIO and the Arduino framework. To 16 flash the firmware, connect the ESP module to a computer using a UART to USB 17 adapter. The ESP must be in programming mode, this is achived by holding 18 GPIO0 low during MCU initilization. Once the ESP is ready, flash the firmware 19 using PlatformIO console tools. 20 21 At the moment, this firmware does not implement a Wi-Fi manager, so the firmware 22 must be re-flashed whenever the Wi-Fi SSID or password changes. To configure the 23 Wi-Fi credentials, environment variables are used during firmware compilation. 24 25 To set the environment variables, run the following commands in the same terminal 26 session that will be used to compile and flash the firmware. 27 28 ```console 29 $ export WIFI_SSID="hello-world" 30 $ export WIFI_PASSWD="12345678" 31 ``` 32 33 Alternatively, the Wi-Fi credentials can be defined in the `src/main.cpp` file. 34 35 ```c 36 #define WIFI_SSID "hello-world" 37 #define WIFI_PASSWD "12345678" 38 ``` 39 40 After setting the credentials, flash the main firmware to the ESP. 41 42 ```console 43 $ pio run -t upload 44 ``` 45 46 Finally upload the files to the LittleFS filesystem. 47 48 ```console 49 $ pio run -t uploadfs 50 ``` 51 52 ## LICENSE 53 54 This software is licensed under the MIT License. See the [LICENSE](./LICENSE) 55 file for details.
