Building a Wi-Fi-Connected Smart LED Ping Pong Ball

Carl Bugeja's RGB ping pong ball comes packed with 242 individual LEDs and can be controlled with its onboard ESP32.

Inspired by the intriguing RGB balls that other makers have created, Carl Bugeja wanted to make his own with a twist: the device would not only be filled to the brim with LEDs, but also feature intelligent lighting patterns and have wireless connectivity — all in a ping pong ball form factor.

To start, Bugeja experimented with several different methods for evenly wrapping small, square LEDs around a sphere, which turned out to be a very difficult task. His initial idea was to layer concentric rings going across the entire form, but this caused bending and creases. The next and far more successful design came about by creating a pair of starburst patterns that attach to each hemisphere, thus allowing a line of LEDs to go across the ball's lines of longitude rather than latitude.

Circuit design

The next course of action for this project was figuring out the best way to combine nearly 250 tiny 2x2mm WS2812B LEDs into a circuit that could withstand hits, drops, and bends simultaneously. Bugeja's design was based on a four-layer flexible PCB, and each side holds 121 LEDs in a circular pattern. Control for the LEDs is provided by a singular ESP32 that is in close proximity to a 3.3v regulator for power delivery and an accelerometer to detect hits. The last component is a reed switch, and it is responsible for turning the device on or off without having to open it up first.

Assembling the ball

After applying solder paste and carefully placing each LED by hand with a pair of tweezers, Bugeja's first PCB prototype was done, albeit with a minor revision to correct a footprint mistake. He then designed and 3D-printed two hemispheres that each hold a series of tiny magnets that allow them to tightly close together while also not being too difficult to pull apart. Once the flexible PCB had been attached with an adhesive backing, the next step was creating the code.

Programming

The ESP32 was programmed with several animations that send pulses of color across the sphere, and the onboard accelerometer can respond in real-time to change the current pattern as well. Additionally, new firmware can be flashed wirelessly thanks to the module's over-the-air update functionality.

Playing ping pong

Even though the ball is quite a bit heavier compared to a regular ping pong ball, it can still be used in conjunction with a paddle to play an even cooler version of table tennis in the dark. In the future, Bugeja hopes to return to this project and perform a few modifications in order to make a better experience.

Evan Rust
IoT, web, and embedded systems enthusiast. Contact me for product reviews or custom project requests.
Latest articles
Sponsored articles
Related articles
Latest articles
Read more
Related articles