Using librtlsdr Over TCP

[Texane] built a low-cost software defined radio rig which could be remotely controlled. This allows the hardware to be placed outside for better reception, while being controlled from any PC that can connect over TCP. To do this, he created a fork of librtlsdr, the library used to turn cheap TV tuners into software defined radios.

The official release of rtl-sdr includes the rtl_tcp utility, which is meant for this purpose. Unfortunately, not all of the SDR tools for Linux support this. By modifying the library itself, remote devices interact with software in the same way as local devices. This means that any software that supports librtlsdr should work.

The outdoor rig contains a BeagleBone Black and the SDR hardware, sealed up in a weather-resistant box. This connects to [Texane]’s home network over ethernet, and allows SDR utilities to be run elsewhere.

This feature is quite experimental, but the source for the fork is provided for those who want to build the code and try it out.

Sheet Music to MIDI Converter

Learning to read sheet music is a challenge for new musicians, so a group of Cornell students decided to make a robot do it instead. For their final project, they built a robotic sheet music reader (link warning: this page seems to automatically start a .mov file download when loaded).

As an input, the robot takes a piano roll. This is a long strip of paper with music printed on it, which can easily be fed through the reader. A rotational servo keeps the strip feeding at a constant speed, and passes it through the reader.

The reader is based on a Melexis MLX75306 linear optical array. This IC is a 142 x 1 array of photodiodes, which is designed for fuel quality sensing in cars. In this project, it’s been repurposed as a camera to read the music as it passes by. An array of LEDs illuminates the piano roll, providing a more accurate reading.

The components are connected to an Atmel ATmega1284P, which does all the required control and processing. It creates a MIDI output of the piano roll, which can be connected to any hardware or software synthesizer.

Plug Into USB, Get a Reverse Shell

Computers blindly trust USB devices connected to them. There’s no pop-up to confirm a device was plugged in, and no validation of whether the device should be trusted. This lets you do some nefarious things with a simple USB microcontroller.

We’ve recently seen two examples of this: the USBdriveby and the Teensyterpreter. Both devices are based on the Teensy development board. When connected to a computer, they act as a Human Interface Device to emulate a keyboard and mouse.

The USBdriveby targets OS X. When connected, it changes the DNS server settings to a custom IP, to allow for DNS spoofing of the victim’s machine. This is possible without a password through the OS X System Preferences, but it requires emulating both keystrokes and clicks. AppleScript is used to position the window in a known location, then the buttons can be reliably clicked by code running on the Teensy. After modifying DNS, a reverse shell is opened using netcat. This allows for remote code execution on the machine.

The Teensyterpreter gives a reverse shell on Windows machines. It runs command prompt as administrator, then enters a one-liner to fire up the reverse shell using Powershell. The process happens in under a minute, and works on all Windows versions newer than XP.

With a $20 microcontroller board you can quickly fire up remote shells for… “support purposes”. We’d like to see the two projects merge into a single codebase that supports both operating systems. Bonus points if you can do it on our Trinket Pro. Video demos of both projects after the break.

Continue reading “Plug Into USB, Get a Reverse Shell”

Building a Portable Ham Radio Station

Nowadays, you can get into ham radio on the cheap. A handheld radio can be had for less than $30, and licensing is cheap or free depending on where you live. However, like most hobbies, you tend to invest in better kit over time.

[Günther] just finished up building this portable ham station to meet his own requirements. It runs off 230 VAC, or a backup 12 V car battery for emergency purposes. The Yaesu FT897d transceiver can communicate on HF + 6m, 2m, and 70 cm bands.

This transceiver can be controlled using a Microham USB-3 interface, which provides both CAT control and a soundcard. This pre-built solution is a bit simpler than the DIY option. With the interface in place, the whole rig can be controlled by a laptop running Ubuntu and open-source HAM software.

With the parts chosen, [Günther] picked up a standard 5 U 19″ rack, which is typically used for audio gear. This case has the advantage of being durable, portable, and makes it easy to add shelves and drawers. With an automotive fuse block for power distribution and some power supplies, the portable rig is a fully self-contained HAM station.

PeriUSBoost: A DIY USB Battery Pack

If you travel often, use your mobile devices a lot, or run questionable ROMs on your phone, you likely have an external USB battery pack. These handy devices let you give a phone, tablet, or USB powered air humidifier (yes, those exist) some extra juice.

[Pedro]’s PeriUSBoost is a DIY phone charging solution. It’s a switching regulator that can boost battery voltages up to the 5 volt USB standard. This is accomplished using the LTC3426, a DC/DC converter with a built in switching element. The IC is a tiny SOT-23 package, and requires a few external passives work.

One interesting detail of USB charging is the resistor configuration on the USB data lines. These tell the device how much current can be drawn from the charger. For this device, the resistors are chosen to set the charge current to 0.5 A.

While a 0.5 A charge current isn’t exactly fast, it does allow for charging off AA batteries. [Pedro]’s testing resulted in a fully charged phone off of two AA batteries, but they did get a bit toasty while powering the device. It might not be the best device to stick in your pocket, but it gets the job done.

An ATtiny Boost Converter

This schematic is all you need to build your own voltage converter. [Lutz] needed a converter that could boost 5 V to 30 V to power a string of LEDs. The solution was to use low cost ATtiny85 and some passive components to implement a boost converter.

This circuit follows the classic boost converter topology, using the ATtiny85 to control the switch. The 10 ohm resistor is fed back into the microcontroller’s ADC input, allowing it to sense the output voltage. By measuring the output voltage and adjusting the duty cycle accordingly, the circuit can regulate to a specified voltage setpoint.

A potentiometer is used to change the brightness of the LEDs. The software reads the potentiometer’s output voltage and adjusts the voltage output of the circuit accordingly. Higher voltages result in brighter LEDs.

Of course, there’s many other ways to implement a boost converter. Most practical designs will use a chip designed for this specific purpose. However, if you’re interested in rolling your own, the source and LTSpice simulation files are available.

Running Debian on a Graphing Calculator

While the ubiquitous TI-83 still runs off an ancient Zilog Z80 processor, the newer TI-Nspire series of graphing calculators uses modern ARM devices. [Codinghobbit] managed to get Debian Linux running on a TI-Nspire calculator, and has written a guide explaining how it’s done.

The process uses Ndless, a jailbreak which allows code to run at a low level on the device. Ndless also includes a full SDK, emulator, and debugger for developing apps. In this case, Ndless is used to load the Linux kernel.

The root filesystem is built on a PC using debootstrap and the QEMU ARM emulator. This allows you to install whatever packages are needed via apt, before transitioning to the calculator itself.

With the root filesystem on a USB flash drive, Ndless runs the Linux loader, which starts the kernel, mounts the root filesystem, and boots in to a Debian system in about two minutes. As the video after the break demonstrates, this leaves you with a shell on the calculator. We’re not exactly sure what to do with Linux on a graphing calculator, but it is a neat demonstration.

Continue reading “Running Debian on a Graphing Calculator”