Project contents
Why I started from a kit
The Yahboom kit helped me get started quickly and gave me working code to review while rebuilding the firmware.
While searching for parts to build a self-balancing robot, I came across the Yahboom kit. This is not an affiliate link. The parts looked decent, and I liked that I could experiment with their working code before diving into my own rebuild.
Why I chose the Yahboom kit
After a bit of Googling, I found that the reviews were generally positive. The main complaint was that the kit could be quite complicated. That was not really a problem for me because learning how everything worked was the main reason I wanted it.
I could have sourced every component and built the entire robot from scratch, but using a kit was a quicker way to reach the parts I was actually interested in: the embedded software, control loop and communication between the IMU and motors. It also gave me an assembled chassis and working reference firmware, which meant I was not debugging new hardware and new software at the same time.
The supplied tutorials were better than I expected. Yahboom also provides a YouTube series. The videos are in Chinese, but they were still useful for seeing the hardware and the intended behaviour.
However, I have always found that I learn more once I stop following the tutorial exactly and start changing things myself. Instead of keeping the original application, I began rebuilding most of the application and board-support code in C++ while retaining the lower-level vendor libraries.
The biggest benefit of Yahboom’s code was not simply being able to follow it. It became a reference I could return to whenever my version behaved differently. For example, I could check the original timer configuration, pin assignments and motor constants instead of relying on memory.
This has already saved me quite a lot of time. When only one wheel worked under my firmware, I could flash Yahboom’s image onto the same board and confirm that both motors and driver channels were healthy. That moved the fault back into my code, where it turned out to be an uninitialised timer structure.