Microsoft has introduced a few interesting bits of hardware recently, and the most drool worthy by far is the Microsoft Surface Dial. What is this magical input device that will revolutionize creative work on a computer? Basically, it’s a Griffin PowerMate — a rotary encoder and button — an interface that really hasn’t changed in a decade and a half.
[K.C. Lee] figures a device this simple would make for a great Hackaday Prize entry, so he built a USB HID multimedia dial. It’s a rotary encoder and a button. This one lights up, though, making this a gamer USB HID multimedia dial.
The electronics for this build are based around the STM8S003, an extraordinarily cheap microcontroller that will work well enough in this application. The mechanical part of this build is a little more interesting; [K.C.] says not everyone has access to fancy CNC or 3D printing equipment, so he built this model out of bits of plastic, metal, and superglue. This enclosure is literally an old superglue bottle cap, an empty dental floss spool, and bits of metal. It works, and took less time to build than it would take to design in a CAD program.
Right now, [K.C.] is working through some USB issues with the STM8 microcontroller. Once those issues are behind him, he’ll have a very cool and very useful input device sitting on his desk. It might look like parts waiting for the recycling bin, but it will be at least as useful as the fancy Microsoft version.
There was a time when building something yourself probably meant it didn’t look very much like a commercial product. That’s not always a bad thing. We’ve seen many custom builds that are nearly works of art. We’ve also seen plenty of builds that are–ahem–let’s say were “hacker chic”.
[AlexanderBrevig] decided to take on a project using a PSoC development board he picked up. In particular, he wanted to build a custom game keypad. He prototyped a number of switches with the board and got the firmware working so that the device looks like a USB HID keyboard.
Continue reading “Custom Gaming Keypad Developed with PSoC and Fusion 360”
Motion control is a Holy Grail of input technology. Who doesn’t want an interface that they can control with simple and natural movements? But making this feel intuitive to the user, and making it work robustly are huge hills to climb. Leap Motion has done an excellent job creating just such a sensor, but what about bootstrapping your own? It’s a fun hack, and it will give you much greater appreciation for the currently available hardware.
Let’s get one thing straight: This device isn’t going to perform like a Leap controller. Sure the idea is the same. Wave your hands and control your PC. However, the Leap is a pretty sophisticated device and we are going to use a SONAR (or is it really SODAR?) device that costs a couple of bucks. On the plus side, it is very customizable, requires absolutely no software on the computer side, and is a good example of using SONAR and sending keyboard commands from an Arduino Leonardo to a PC. Along the way, I had to deal with the low quality of the sensor data and figure out how to extend the Arduino to send keys it doesn’t know about by default.
The plan is to take an inexpensive SONAR module (the HC-SR04) and an Arduino Leonardo and use it to perform some simple tasks by mimicking keyboard input from the user. The Leonardo is a key element because it is one of the Arduinos that can impersonate a USB keyboard (or mouse) easily. The Due, Zero, and Micro can also do the trick using the Arduino library.
I wanted to determine how many gestures I could really determine from the HC-SR04 and then do different things depending on the gesture. My first attempt was just to have the Arduino detect a few fingers or a hand over the sensor and adjust the volume based on moving your hand up or down. What I didn’t know is that the default Arduino library doesn’t send multimedia keys! More on that later.
Continue reading “Bootstrapping Motion Input with Cheap Components”
What is better than making your own smart watch? Making one with an OLED display. This is exactly what [Jared] set out to do with his DIY OLED smart watch, which combines an impressive build with some pretty cool hardware.
When building a DIY smart watch, getting the hardware right is arguably the hardest part. After a few iterations, [Jared’s] OLED smart watch is all packaged up and looks great! The firmware for his watch can communicate with the PC via USB HID (requiring no drivers), contains a “watch face” for telling time, includes an integrated calendar, and support for an accelerometer. His post also includes all of the firmware and goes into some build details. With the recent popularity of smart watches and wearable electronics, we really love seeing functional DIY versions. This is just the beginning. In the future, [Jared] plans on adding Bluetooth Low Energy (BLE), a magnetometer, a smart sleep based alarm clock, and more! So be sure to look at his two older posts and keep an eye on this project as it unfolds. It is a very promising smart watch!
With Android L including support for smart watches (in the near future), it would be amazing to see DIY watches (such as this one) modified to run the new mobile OS. How great would it be to have an open hardware platform running such a powerful (open source-ish) OS? the possibilities are endless!
If you’re using an AVR microcontroller and you’d like to add USB to a project, there are a lot of options out there for you. Both LUFA and V-USB add some USB functionality to just about every AVR micro, but if you’d like a native serial port, your only options are to look towards the USB-compatible Atmel micros.
[Ray] looked at the options for adding a USB serial port and didn’t like what he saw; seemingly, this was an impossible task without a second, more capable microcontroller. Then he had an idea: if the goal is only to transfer data back and forth between a computer and a microcontroller, why not write an HID-class USB serial port?
[Ray] based his project on The V-USB library and created a new HID descriptor to transfer data between a micro and a computer. While it won’t work with a proper terminal such as Putty, [Ray] managed to whip up a serial monitor program in Processing that’s compatible with Windows, Linux and OS X.
In the video below, you can see [Ray] using an ATmega328p with a standard V-USB setup. He’s transferring analog values from a photoresistor as a proof of concept, but just about everything that would work with a normal serial port will work with [Ray]’s library.
Continue reading “Serial USB for Any AVR Microcontroller”
High security workstations have some pretty peculiar ways of securing data. One of these is disabling any USB flash drives that may find their way into a system’s USB port. Security is a cat and mouse game, so of course there’s a way around these measures. [d3ad0ne] came up with a way of dumping files onto an SD card by using the USB HID protocol.
We’ve seen this sort of thing before where a microcontroller carries an executable to extract data. Previously, the best method was to blink the Caps Lock LED on a keyboard, sending one bit at a time to a micocontroller. [d3ad0ne]’s build exploits the USB HID protocol, but instead of 1 bit per second, he’s getting about 10kBps.
To extract data from a system, [ d3ad0ne] connects a Teensy microcontroller to the USB port. After opening up Notepad, [ d3ad0ne] mashes the Caps Lock key to force the Teensy to type out a script that can be made into an executable. This executable is a bare-bones application that can send any file back over the USB cable to the Teensy where it’s stored on an SD card. Short of filling the USB ports in a workstation with epoxy, there’s really no way to prevent secure files from leaking out of a computer.
A common challenge for computer security specialists is getting data out of a very locked-down system. Of course all network traffic on these test machines is monitored, and burning a CD or writing to a USB Flash drive is out of the question. Where there’s a will there’s a way, so [András] figured out how to extract data from a computer by emulating a keyboard.
Emulating a USB HID device is nothing new; the newest Arduino can do it, as can any AVR with the help of V-USB. [András]’s build emulates a USB keyboard that can download data from a computer by listening to the NUM, CAPS and SCROLL lock LEDs.
Of course, [András] first needs an app to transmit data through these keyboard status LEDs. To do this, his build carries with it a Windows executable file on the AVR’s Flash memory. After plugging his device into the computer, it writes this program to disk and is then able to send data out through keyboard status LEDs.
It’s not very fast – just over one byte per second – but [András] did manage to extract data from a computer, circumventing just about every anti-leaking solution.