This polar graph draws some amazing shapes on a dry erase board. Part of that is due to the mounting brackets used for the two stepper motors and the stylus. But credit is also due for the code which takes velocity into account in order to plan for the next set of movements.
The Go language is used to translate data into step commands for the two motors. This stream of commands is fed over a serial connection between the RPi board and an Arduino. The Arduino simply pushes the steps to the motor controllers. The inclusion of the RPi provides the horsepower needed to make such smooth designs. This is explained in the second half of [Brandon Green’s] post. The technique uses constant acceleration, speed, and deceleration for most cases which prevents any kind of oscillation in the hanging stylus. But there are also contingencies used when there is not enough room to accelerate or decelerate smoothly.
You can catch a very short clip of the hardware drawing a tight spiral in the video embedded after the break.
Continue reading “Raspberry Pi driven Polargraph exhibits high precision drawing ability”
[Andreas] has created this tutorial on real-time (RT) tasks in Linux. At first blush that sounds like a rather dry topic, but [Andreas] makes things interesting by giving us some real-world demos using a Raspberry Pi and a stepper motor. Driving a stepper motor requires relatively accurate timing. Attempting to use a desktop operating system for a task like this is generally ill-advised. Accurate timing is best left to a separate microcontroller. This is why we often see the Raspi paired with an Arduino here on Hackaday. The rationale behind this is not often explained.
[Andreas] connects a common low-cost 28BYJ-48 geared stepper motor with a ULN2003 driver board to a Raspberry Pi’s GPIO pins. These motors originally saw use moving the louvers of air conditioners. In general, they get the job done, but aren’t exactly high quality. [Andreas] uses a simple program to pulse the pins in the correct order to spin the motor. Using an oscilloscope, a split screen display, and a camera on the stepper motor, [Andreas] walks us through several common timing hazards, and how to avoid them.
The most telling hazard is shown last. While running his stepper program, [Andreas] runs a second program which allocates lots of memory. Eventually, Linux swaps out the stepper program’s memory, causing the stepper motor to stop spinning for a couple of seconds. All is not lost though, as the swapping can be prevented with an mlockall() call.
The take away from this is that Linux is not a hard real-time operating system. With a few tricks and extensions, it can do some soft real-time tasks. The best solution is to either use an operating system designed for real-time operation, or offload real-time operations to a separate controller.
Continue reading “A Tutorial on Using Linux for Real-Time Tasks”
[Jack Boland], a mechanical engineer at the University of Wisconsin, built a cool hanging plotter project called HangBot. It’s a fairly standard setup, where he converts an image to G-Code files, and it is plotted using two stepper motors for control. We’ve seen vertical plotters before, but they tend to only have a single pen. [Jack] expanded this one to bring color into the mix by splitting an image into separate CMYK layers, and plotting each onto separate transparency film. When overlaid, they create something close to a full color image. His idea is to use this setup as a replacement for typical window signage.
Since it’s drawing a continuous line, he appears to be employing a grid instead of a traditional dot pattern. That, combined with the inaccuracy of a marker tip means resolution will be limited. Still, you can tell that he’s made a great start in this (albeit blurry) photo. Check out the video of it’s operation after the break.
Continue reading “Hanging Plotter With a Color Twist”
A while back, we saw [Euphy]’s polar pen plotter project. The mechanics of the build are very simple – just a pair of motors attached to a pen by a beaded cord. Even though the build is very simple, it’s possible to create awesome works of art albeit very slowly.
Since we featured [Euphy]’s polar pen plotter, a lot of improvements have been made. Now the Polargraph has an SD card slot for computer-less printing, a touch screen for manual control of the plotter, and a few new drawing styles that improve on the previous version a lot.
Right now the improved version of the Polargraph is set up in the front of a graffiti art supply shop in Edinburgh where it spends its time slowly drawing a window dressing. [Euphy] put up a few videos of what the Polargraph is capable of doing, very impressive and we hope he gets a few more PCBs in soon.
Continue reading “Drawing things very slowly, very easily”
[Euphy] just posted and Instructable of his Polargraph drawing machine that’s able to draw huge images slower than molasses in November. The plotter only uses two stepper motors to control the position of the pen and can be made nearly entirely from salvaged parts – [Euphy] built his for just about £150.
The Polargraph uses two stepper motor on the top corners of a large, flat surface. A weighted pen carriage is attached to both motors with beaded cord that’s often seen in window blinds. By controlling the distance from the carriage to each motor, the position of the pen can be precisely controlled. It’s not a very fast way of drawing an image (check out the real-time video), but it sure is interesting to watch.
There have been a few other rope-and-chain plotters, like Der Kritzler and Hektor. [Euphy]’s work is the is one of the best documented builds we’ve seen, and he’s also put up the code and a website.
We really could have used [Euphy]’s plotter when we wanted to draw some whiteboard art. While we’re out dumpster diving for some small stepper motors, check out the time-lapse video of the Polargraph after the break.
Continue reading “Polar pen plotter draws huge images very slowly”