- Bluetooth Configuration: Enables configuration of WiFi credentials via Bluetooth communication.
- OTA Update: Supports Over-The-Air updates for the firmware, allowing easy maintenance and upgrades.
- Web Interface: Provides a web interface for firmware updates using HTTP POST requests.
- Authentication: Implements basic authentication for accessing the web interface.
To use this firmware for your IoT controller, follow these steps:
-
Requirements:
- ESP32 board compatible with the Arduino framework.
- Bluetooth module compatible with the ESP32.
- WiFi network credentials.
-
Installation:
- Clone or download this repository to your local machine.
-
Configuration:
- Open the
PAT_OTA.hfile and modify thessidandpasswordvariables to match your WiFi network credentials. - Optionally, adjust the
hostvariable to set a custom hostname for the device. - Configure the Bluetooth device name by modifying the
device_namevariable in thePAT_Bluetooth.hfile.
- Open the
-
Upload Firmware:
- Connect your ESP32 board to your computer.
- Compile and upload the firmware to your ESP32 board.
-
Bluetooth Configuration:
- Pair your Bluetooth-enabled device with the ESP32 using the device name specified in the configuration.
- Use a terminal emulator or Bluetooth app to send commands for WiFi configuration:
- To set the SSID, send
wlan0 <your_ssid>. - To set the password, send
pass <your_password>. - Restart the WiFi connection by sending
restart wlan0.
- To set the SSID, send
-
Web Interface for OTA Update:
- Once connected to the WiFi network, open a web browser and navigate to the device's IP address or hostname (e.g.,
http://Novaday.local). - Use the provided web interface to upload firmware files for OTA updates.
- Once connected to the WiFi network, open a web browser and navigate to the device's IP address or hostname (e.g.,
- Ensure that your firmware files are compatible with the ESP32 platform and follow the required format.
- Make sure to secure your device by changing the default credentials and implementing additional security measures as needed.
- Test the firmware update process in a controlled environment before deploying it in production to ensure reliability.
