This week I took a break from HackTheBox to work on a hardware project that I got a few weeks ago. During the holiday, I subscribed to a monthly subscription box service called ‘Hackerboxes‘, catchy right? Anyways, HB subscription includes a monthly hardware project that requires soldering together components onto some cool custom PCB’s and then installing and modifying some files/programs to get them to do cool things.

This month’s box is called ‘Relay‘, and the overall goal was to build two LoRa IoT devices, a controller and a relay that can be controlled via the controller. Let’s get into it!
The first step was to power on the ESP32C Dev board which become the main IoT Controller and compile a simple program to make it blink thus testing it’s functionality:


This was simple enough, so the next program was to test the mini OLED display with a text string:
Disclaimer, I do not know how to program C++ or Arduino specifically, most of this code came with the project and it only requires a few small changes to change the string. That said, I did like this project enough to get me into it a bit, which I’ll talk more about later.
Putting It together
The next step was to attach the LoRa module and ESP32C3 dev boards to the custom PCB and build the completed controller, this was tricky as the SMA/antenna connector was made of brass so soldering was a bit more difficult. After these were fitted, I had to trim and solder the LED Ring to the PCB:


Once It was all put together, it was time to compile the webserver and light control programs that would turn this blank slate into an IoT light. Behold, a light so bright that it burned spots into my retinas for like half an hour:




At this point the board pulled an IP from the local network and the webpage allowed interaction with the LED ring via a web panel! One thing that I noted here, the WiFi credentials are hardcoded, which is a pretty good indicator of how secure IoT devices are in my experience. At this point the first half of this project was done, I now have a cool little smart light that I’m planning on building a mount/lamp for and I’ve learned a bit about the LoRa protocol and IoT construction.
The second half of the project was constructing a LoRa Relay that can be controlled by the LoRa controller from the first half of the project on an ESP32 board, with a handful of terminal blocks for input/output to other components. These include sensors, actuators, etc. and is something that I definitely want to explore more of, so there may be an update to this post in the future.


Overall this was a pretty cool project, it wasn’t super involved but I did enjoy putting everything together and learning some Arduino programming. Huge shout-out to Hackerboxes, I’d definitely recommend checking them out if you see anything that interests you! Anyways, I’ll be back to the next HackTheBox module ‘File Transfers‘ this week, so expect another post about that soon here. Thanks for reading!



Leave a comment