USB Datalogging With Arduino Using V-USB

Adding USB functionality to your Arduino projects used to be a pain, but thankfully, the V-USB project came along and gave your ATMEGA328 the ability to control the USB lines directly and mimic simple (low-speed) USB peripherals. [Ray] shows an implementation of the V-USB project by logging the status of the Arduino’s I/O pins to an open Excel spreadsheet

V-USB (Virtual USB) is especially useful for those of us who build standalone Arduino projects with the ATMEGA328. Unlike the Arduino Leonardo and its ATMEGA32U4, the ATMEGA328 does not have a built-in USB controller. The circuit required to tie into the USB lines is made up of just a few basic components, and [Ray] provides a reference schematic and BOM to get you started. The Arduino is programmed to mimic a keyboard, so the datalogging is achieved by allowing the Arduino to ‘type’ the data into an open Excel spreadsheet. In this example, the status of 8 digital pins and all 6 Analog Input pins are logged.

For those of you who prefer the PIC microcontroller and are in a similar position of not having a built-in USB controller, there is the 16FUSB project to help you out.

Move Over, Google Nest: Open Source Thermostat Is Heating Up The Internet Of Things

In the wake of Google’s purchase of connected devices interest Nest, the gents at [Spark] set about to making one in roughly a day and for a fraction of the cost it took Nest to build their initial offering. [Spark]’s aim is to put connected devices within reach of the average consumer, and The Next Big Thing within the reach of the average entrepreneur.

The brain is, of course, [Spark]’s own Spark Core wi-fi dev board. The display is made of three adafruit 8×8 LED matrices driven over I²C. Also on the bus is a combination temperature and humidity sensor, the Honeywell HumidIcon. They added some status LEDs for the furnace and the fan, and a Panasonic PIR motion detector to judge whether you are home. The attractive enclosure is made of two CNC-milled wood rings. The face plate, mounting plate, and connection from the twistable wood ring to the potentiometer is laser-cut acrylic.

[Spark]’s intent is for this, like the Nest, to be a learning thermostat for the purpose of increasing energy efficiency over time, so they’ve built a web interface with a very simple UI. The interface also displays historical data, which is always nice. This project is entirely open source and totally awesome.

If you have an old Android phone lying around, you could make this open source Android thermostat.

Continue reading “Move Over, Google Nest: Open Source Thermostat Is Heating Up The Internet Of Things”

Microcorruption Embedded CTF

The folks at Matasano Security and Square have teamed up to build an online capture the flag (CTF) competition. The Microcorruption CTF focuses on embedded security and challenges players to reverse engineer a fictional “Lockitall LockIT Pro” lock system.

Each level places you in a debugging environment with a disassembly listing, live memory view, register view, and debugging console. You can set breakpoints, step through code, and modify registers like in a real debugging environment. Your goal is to figure out how to bypass the lock to collect bearer bonds.

While the device and motive may be fictional, the assembly is actual MSP430 code. The debugger is similar to GDB connected to a remote target using OpenOCD. There’s even a manual (PDF) to help you get up to speed with writing MSP430 code for the device.

This CTF looks like a great introduction to embedded security, and doesn’t require buying real hardware. It even includes a full tutorial to get you started.

Sucking PIC Firmware Out Of An Old APC Battery Backup

reverse-engineering-pic-firmware-of-APC-power-supply

Looking at this huge Uninterruptible Power Supply we are a little envious. It’s meant to hang on the wall of a utility room and power your critical devices. [Radek Hvizdos] has had it in service for quite some time, and when he started thinking of replacing the internal battery he decided to see if he could also extend the functionality. To do so he needed to get at the firmware of the chip controlling the device. And so began his adventure of dumping the firmware from the read-protected PIC 18F452.

The challenge of dumping code from a write-protected chip is in itself a fun project. But [Radek] was actually interested in fixing bugs and adding features. The wishlist feature we’d be most interested in is a kind of triage for shutting down devices as the internal battery starts to run low. Nice! But starting from scratch with the firmware is a no-go. You can see the two places where he connected to the PCB. The upper is for using a PIC programmer. The lower is an I2C connection used to dump the EEPROM with an improvised Bus Pirate.

In the end it was improper lock bit settings that opened the door to grabbing the firmware. The bootloader section of the PIC is not locked, and neither is the ability to read from FLASH at run-time. These two combined allowed him to write his own code which, when flashed to the bootloader section, dumps the rest of the firmware so that it may be combined into a complete file afterward. Since posting this fascinating article he has made a follow-up about disassembling the code.

Sniffing Wired Garage Door Opener Signals

sniffing-garage-door-signals

In addition to being something fun to do with an oscilloscope, this could be a valuable time-saver for anyone looking to tap into the wired communications on a garage door opener. If you own an older model you might be scratching your head. But newer units have more than just one button operation, usually extending to at least two extra buttons that control the lights on the motor unit and lock out wireless control. A quick probing turned up the communication scheme used by the button unit mounted next to the door into the house.

We’ve patched into our own garage door using a simple relay to interface with a microcontroller which will still work for opening and closing the door But if you’re looking for extended control you need to spoof one of the timing signals detailed in this post. We like the stated examples for future hacks: building a better wired button unit, or adding some type of RFID integration. We could see this approach for hacking in motion light control for door openers that don’t have it.

[Thanks Victor]

Mephisto III Internet Radio

Avid Hackaday reader [Matthias] told us he takes a lot of inspiration from our site. That’s quite a compliment, because his work is both inspiring and beautiful. [Matthias] wanted to build a UI using JavaFX, so he made a really nice-looking Raspberry Pi-based Internet radio. We featured his previous radio build a few months ago when he modified an old Bakelite unit.

The Mephisto III is enclosed in a handsome oak cabinet built by [Matthias]’ father. Like his previous build, this one uses the Google Music interface to play MP3s and streams radio from the web. He also added weather and a clock, which is a nice touch. In addition to the Raspi and a USB WLAN stick, [Matthias] is using two relays. One relay powers the amplifier and the other enables the display. [Matthias] is impressed with the JavaFX API, but found that the performance of the Raspberry Pi is insufficient for smooth multithreading. He considered switching to a BeagleBone Black, but it has no component out.

If you want to be able to listen to vinyl, too, check out this killer media center. If you have lost your taste for Pi, build yourself a web radio from a tiny router.

[Thanks Matthias]

$20 GPS/GLONASS/Beidou Receiver

Sticking a GPS module in a project has been a common occurrence for a while now, whether it be for a reverse geocache or for a drone telemetry system. These GPS modules are expensive, though, and they only listen in on GPS satellites – not the Russian GLONASS satellites or the Chinese Beidou satellites. NavSpark has the capability to listen to all these positioning systems, all while being an Arduino-compatible board that costs about $20.

Inside the NavSpark is a 32-bit microcontroller core (no, not ARM. LEON) with 1 MB of Flash 212kB of RAM, and a whole lot of horsepower. Tacked onto this core is a GPS unit that’s capable of listening in on GPS, GPS and GLONASS, or GPS and Beidou signals.

On paper, it’s an extremely impressive board for any application that needs any sort of global positioning and a powerful microcontroller. There’s also the option of using two of these boards and active antennas to capture carrier phase information, bringing the accuracy of this setup down to a few centimeters. Very cool, indeed.

Thanks [Steve] for sending this in.