Creating a Drill-Printing Robot with Android and leJOS
Project Overview
This project is an exciting fusion of Android development and robotics, combining an Android application with the LEGO NXT cube (v1.0) enhanced by the leJOS firmware. The result? A robot capable of drilling images, among other things!
The project consists of two main components:
- Android Application: This app communicates with the NXT cube via Bluetooth, acting as a controller for various robotic functions.
- NXT Robot with leJOS Firmware: The NXT cube is upgraded with leJOS, allowing programming in Java, making it more versatile for complex tasks.
Android Application
The Android app isn't just for drilling images—it's a comprehensive controller for the NXT robot. Initially, it was designed as a multi-functional tool capable of:
- Controlling the robot’s movement using different programs, like line-following or accelerometer-based controls.
- Allowing the user to select the type of robot and the corresponding control programs.
After pairing the app with the NXT cube via Bluetooth, you're free to experiment and play with the robot. Below, you'll find screenshots showcasing the app's interface and capabilities.
Hand Gesture Control Experiment
At one point, I experimented with controlling the Tribot robot using hand gestures. I glued colored markers to my hand and used the phone’s rear camera, mounted on a tripod, to recognize these colors. Although the demo was functional, it didn’t meet my expectations—primarily due to the lag in data transfer. I needed the robot to change directions within half a second, but the system wasn’t fast enough. While the gesture control idea was shelved for now, it inspired me to pivot to the idea of a robotic printer.
NXT / leJOS Challenges
Building a stable, functional robot isn’t as simple as it seems—it can take many hours or even days, and requires a lot of LEGO pieces (I had to place multiple orders from Bricklink.com). One of the major challenges I faced was working with the NXT cube’s limited memory. Since the cube couldn’t handle an entire image at once, I had to divide the image into smaller parts and send them sequentially. Given that the printing process is slow, I had to keep my phone on a charger, with the screen active, sending image data piece by piece. The largest image I printed took a whopping 24 hours!
Overcoming Physical Challenges
The project also posed some physical challenges. For example, I needed a very thin and long drill bit, but after searching several modeling shops, I realized that the specific length I required wasn’t commercially available. To solve this, I superglued sand to the remaining length of the drill bit, extending it enough to do the job. This makeshift drill worked perfectly with the floral foam I chose as the printing medium—one of the finest materials I could find for this purpose.
Additional Features
But that’s not all! The robot's drill head is replaceable, meaning it can be swapped out to draw black-and-white images as well—a feature that, while also slow, adds another layer of creativity to the project. You can see some of the results at the bottom of this page.
This project allowed me to fulfill a childhood dream: building a robot that can perform intricate tasks. And I’m not stopping here—I plan to build even more robots in the future.
Update
As I mentioned earlier, the printing process is quite slow. To address this, I added an email notification feature that alerts me when the printing is finished, so I can monitor progress without constantly checking the robot.
Comments
Post a Comment