Testing project
We have two devices in the solution. Let’s begin with the plug. We will flash the application on the devkit, then provision it to ESP RainMaker and see how the plug application behaves.
Testing plug
We can test the plug application as follows:
- Make sure the plug hardware is ready with ESP32-C3 DevkitM-1 and the relay module connected to it.
- Go to the plug ESP-IDF project directory and flash the application on the devkit:
$ idf.py erase-flash flash monitor Executing action: erase-flash Serial port /dev/ttyUSB0 Connecting.... Detecting chip type... ESP32-C3 <more logs> I (9447) app_wifi: Scan this QR code from the ESP RainMaker phone app for Provisioning. <QR-code is here>
- Start the RainMaker application on your mobile device and add the plug. The application runs a wizard for provisioning. When the provisioning is completed, tap on the Done button and return to the main screen.
Figure 9.7: Adding...