At the beginning of the week, I was working on the ethics assignment, reading the two papers that were assigned. After I had finished that, I began focusing on implementing network communication between two nodes on the same network. All development testing that we had done on the ESP32s thus far has been on either Aidan’s or Neha’s computers, so I had to work on setting up the Arduino IDE to interface with these boards. One unique thing that I had to deal with though, was that my drivers were installed incorrectly. It took a while to sort out but I had to go to SiliconLabs website and install their CP210X USB to UART drivers before my computer would recognize the ESP32s. After doing that, I was able to download to the boards as expected.
After running a HelloWorld-type programming to ensure everything was working as expected, I began working on setting up each node’s network connections. Something that I overlooked, which caused me a bit of trouble at the beginning was that I was trying to connect to my main WiFi network; this was an issue because while there are some ESP32 models that can use the 5GHz frequency of WiFi, the C3 – which is the model that we have – can only use the 2.4GHz frequency. Once I realized that I quickly set up a 2.4GHz channel on my router, specifically for IoT-type devices, where the nodes could be isolated from the rest of my network and talk to each other.
Once I got the nodes connected to the network, I could verify their MAC addresses on my router’s interface, and use that information to establish a connection between the two nodes. From that point, I wrote some test code to verify that I could correctly send information between the two nodes, so long as I have each of their MAC addresses, and they are on the same network.
I was slightly behind last week and needed to focus on integrating communication over WiFi. I now have that implemented but at a very rudimentary level. Currently, to get two nodes to talk, their MAC addresses need to be hardcoded into the file and sent directly to this address over the shared network. This implementation has issues, for example, if that MAC address is no longer on the shared network. I technically accomplished what I sent out to as per my last Weekly Status Report, and am on track with my Gantt chart plans, but I would like to improve the usability of the current implementation of the network connections.
Next week, I want to make make the data transfer a bit smarter: rather than relying on hardcoding the individual MAC addresses, I would like to try and figure out how to recognize all of our ESPs that are on the network, add them to a list, and broadcast to all of them automatically. This would avoid the manual setup and would be important if this were to actually be a viable product. I also want to look into using ESP-IDF rather than Arduino IDE. It seems that there are some additional features available there, as it is actively developed directly by Espressif, whereas, when we are using Arduino IDE, we are limited by their update schedule to support some of these features.