Robotic Player Guitar Rocks Out on Its Own

Back in 1988 [Ben Reardon] walked through the Japanese pavilion at the World Expo held in Brisbane, Australia. He saw a robot playing a classical guitar, and was in awe. Later in his life, he decided to learn guitar, and always thought back to that robot. After going to SIGGRAPH 2014 and being inspired by all the creative makers out there, he realized the technology was here — to build his own Robot Guitar.

He started small though — with a prototype robotic Tambourine. It helped flush out some of the ideas for coding that he would eventually employ on the Robot Guitar. The guitar features both an Arduino and a Raspberry Pi, along with six RC servos — one for each string. The biggest challenge with the project was getting the servos mounted just right — stiff, but with adjustment so each pick could be tuned for identical timing. He ended up using aluminum extrusion to mount the servos, three per side in order to leave space for the picks.

Once the mechanical portion was done — onto the coding…

In the end, it ended up being only 460 lines of code. Python and a bit of Bash for the Raspberry Pi — and of course a few sketches for the Arduino. But enough talking about it — let’s hear it!

Continue reading “Robotic Player Guitar Rocks Out on Its Own”

Blink Thrice To Let Me In

Now here’s a really cool home hack. [Luis Rodrigues] has automated his garage door to open, simply by flashing his headlights at it.

But wait, doesn’t that mean anyone could break into his house? Nope. At first we thought he had just added some photo-sensors and a bit of computer logic in order to turn a pattern of lights into an output to open the garage, but no, it’s actually specific to his car only. Which is awesome because if anyone ever tried to copy him to break in, all they break into is a very confused state of mind.

You see how it actually works is the headlight output is connected to a control box under the hood of his car. A Moteino (RF Arduino variant) reads the input signal of the headlights flashing three times, and then communicates wirelessly to the garage door in order to open it.

But [Luis] also has a gate outside his property — so if you hold the lights on for a second, both the garage door and the external gate will open as well.

Continue reading “Blink Thrice To Let Me In”

Robo Foam Cutter Makes Short Work of your Foam Rolls

Tired of cutting your foam sheets down to size? [jgschmidt] certainly was, and after one-too-many hours cutting foam manually, he built himself a machine that cuts sheets automatically, and he guides you through the process step-by-step.

[jgschmidt’s] build is a clever assembly of stock parts acquired from ServoCity. That’s a nice touch, considering we don’t often see their components in quick hacks. With a stepper to feed more foam, and a stepper to drive the blade mechanism, the device can consistently cut foam from a roll to desired lengths.

The blade mechanism consists of two exacto blades fixed nose-to-nose such that the machine can cut on both forward and reverse sweeps. While we’ve certainly seen some stellar past foam cutter builds, we can’t resist drooling over the speedy throughput of [jgschmidt’s] machine as it cuts on both forward and back-strokes. Finally, when the blades dull, they can be swapped out for a few dime’s worth of new parts.

Many of the steps in [jgschmidt’s] build are laudably practical with a “get it done” attitude. From hot-glued wire insulation to the double-edged blade formed from exacto knives, we’re thrilled to see him take a few pieces off the shelf and few pieces off the web and build himself a new workshop tool. Perhaps the neatest feature of this hack is its ability to rapidly transform a raw material into numerous repeatable, useful forms for his customers.

via [Instructables]

Continue reading “Robo Foam Cutter Makes Short Work of your Foam Rolls”

An Apple ][ emulator on an Arduino Uno

April Fools’ Day may have passed, but we really had to check the calendar on this hack. [Damian Peckett] has implemented an Apple ][, its 6502 processor, and a cassette port, all on an Arduino Uno. If that wasn’t enough, he also uses a PS/2 keyboard for input and outputs analog VGA. [Damian] is doing all this with very few additional components. A couple of resistors, a capacitor and some very clever hacking were all [Damian] needed to convince an Arduino Uno that it was an Apple.

Making all this work boiled down to a case of resource management. The original Apple ][ had 4KB of RAM and 8KB of ROM. The ATmega328 has only 2KB of RAM, but 32KB of Flash. The only way to make this hack work would be to keep as much of the emulation and other routines in Flash, using as little RAM as possible.

The core of this hack starts with the MOS 6502, the processor used in the Apple. [Damian] wrote a simple assembler which translates the 6502 opcodes and address modes to instructions which can be executed by the Arduino’s ATmega328. To keep everything in ROM and make the emulator portable, [Damian] used two large switch statements. One for address modes, and a 352 line switch statement for the opcodes themselves.

A CPU alone is not an Apple though. [Damian] still needed input, output, and the ROM which made the Apple so special. Input was through a PS/2 keyboard. The PS/2 synchronous serial clock is easy to interface with an Arduino. Output was through a custom VGA implementation, which is a hack all its own. [Damian] used the lowly ATmega16u2 to generate the video timing. The 16u2 is normally used as the Arduino Uno’s USB interface. The only external hardware needed is a single 120 ohm resistor.

The original Apples had cassette and speaker interfaces. So does this emulated Apple. [Woz’s] original cassette and speaker interface accurate loops to generate and measure frequencies. One of the trade-offs [Damian] accepted in his 6502 was cycle accuracy, so he couldn’t use the original routines. Not a problem though, as he was able to write simple functions to replace these routines and drop them in place of the Apple’s own ROM calls.

The Apple ][ ROM itself is handled as one giant character array. This includes the system monitor, Mini-Assembler, Sweet-16, and [Woz’s] own Integer Basic. [Damian] caps off this incredible project by booting his new computer, loading a  Mandelbrot set program from cassette -or in this case an audio file stored on his cell phone, and running it. The well-known fractal is displayed in all its glory on a modern LCD monitor, driven by a microcontroller, emulating a computer from nearly 40 years ago.

Continue reading “An Apple ][ emulator on an Arduino Uno”

Arduino IDE Forked

As if it weren’t confusing enough in the Arduino world these days, now we’re going to have to deal with conflicting version numbers for the IDE. Yup, it’s been forked. Arduino LLC is offering a recently-updated version 1.6.3 at arduino.cc, but Arduino SRL has bumped up the version number to 1.7.0 at arduino.org. The conflict in naming and versioning has not gone unnoticed.

For those of you who’ve been living under a rock lately, the company that developed the Arduino (Arduino LLC) and the company that’s been manufacturing most of the hardware (Smart Projects SRL, now Arduino SRL) have stopped cooperating, filed a bunch of lawsuits, and now maintain separate websites.

According to this article (Google translate here) the versions don’t differ by much, and the 1.7.0 IDE may even be a step backwards versus 1.6.3. It certainly seems to us that the majority of the active developers in the Arduino project have been sticking with [Massimo Banzi] and the Arduino LLC camp. Of course, everything’s open source and there’s nothing stopping Arduino SRL from porting worthwhile IDE changes across to their version of the codebase.

It doesn’t take a clairvoyant to sense that this may be in response to the warning about non-licensed boards that was included in the “official” 1.6.1 release. Nor does it take a psychic to foresee confusing times ahead.

If you’re interested in doing some code-sleuthing, have a look at the two versions and leave a comment below letting us know of any substantive differences you unearth.

Thanks [Kai], and via [Golem.de].

Repurposing a Palm Portable Keyboard

Typing comfortably on a Smart Phone is best done using an external keyboard, especially if you spend a lot of time on IRC or use other chat apps. Obviously, the keyboard needs to be portable too. [cy384] felt the current crop of portable keyboards left a lot to be desired in terms of build quality and feel. That’s when the Palm Portable Keyboard (PPK) caught his eye. It’s small enough to fold up and fit in a pocket, yet unfolds to a size big enough to feel comfortable while typing. Unfortunately, the version he preferred to use did not have either a Bluetooth or a USB interface, so he built up this Palm keyboard adapter.

The portable keyboards have a serial interface and custom connectors depending on the Palm model they were designed to connect to. [cy384]’s goal was to adapt the PPK as a generic USB HID keyboard using an Arduino Pro Mini clone, with a 3D printed adapter for both of the keyboard types that he had. The keyboards  use inverted TTL logic at 9600 baud with no parity and one stop bit. Some handshaking needs to be taken care of and there’s a low power mode that needs to be managed via the Arduino code. He was lucky to get his hands on a reference document that provided the hardware and software details to help him crack all of this. His Github repository has the code and 3D printable files for the adapters.

High Speed SSD1306 Library

[Lewin] wrote in to tell us about a high speed library for Arduino Due that he helped develop which allows interfacing OLED displays that use the SSD1306 display controller, using DMA routines for faster display refresh time.

Typically, displays such as the Monochrome 1.3″ 128×64 OLED graphic display , are interfaced with an Arduino board via the SPI or I2C bus. The Adafruit_SSD1306 library written by [Limor Fried] makes it simple to use these displays with a variety of Arduinos, using either software or hardware SPI. With standard settings using hardware SPI, calls to display() take about 2ms on the Due.

[Lewin] wanted to make it faster, and the SAM3X8E on the Due seemed like it could deliver. He first did a search to find out if this was already done, but came up blank. He did find [Marek Buriak]’s library for ILI9341-based TFT screens. [Marek] used code from [William Greiman], who developed SD card libraries for the Arduino. [William] had taken advantage of the SAM3X8E’s DMA capabilities to enable faster SD card transfers, and [Marek] then adapted this code to allow faster writes to ILI9341-based screens. All [Lewin] had to do was to find the code that sent a buffer out over SPI using DMA in Marek’s code, and adapt that to the Adafruit library for the SSD1306.

There is a caveat though: using this library will likely cause trouble if you are also using SPI to interface to other hardware, since the regular SPI.h library will no longer work in tandem with [Lewin]’s library. He offers some tips on how to overcome these issues, and would welcome any feedback or testing to help improve the code. The speed improvement is substantial. Up to 4 times quicker using standard SPI clock, or 8 times if you increase SPI clock speed. The code is available on his Github repo.