The rust language logo being branded onto a microcontroller housing

Baremetal Rust On The Horizon

Rust Programming Langauge has grown by leaps and bounds since it was announced in 2010 by Mozilla. It has since become a very popular language owing to features such as memory safety and its ownership system. And now, news has arrived of an Embedded Devices Working Group for Rust aiming at improving support for microcontrollers.

Rust is quite similar to C++ in terms of syntax, however Rust does not allow for null or dangling pointers which makes for more reliable code in the hands of a newbie. With this new initiative, embedded development across different microcontroller architectures could see a more consistent and standardized experience which will result in code portability out of the box. The proposed improvements include IDE and CLI tools for development and setup code generation. There is also talk of RTOS implementations and protocol stack integration which would take community involvement to a whole new level.

This is something to be really excited about because Rust has the potential to be an alternative to C++ for embedded development as rust code runs with a very minimal runtime. Before Arduino many were afraid of the outcome of a simple piece of code but with rust, it would be possible to write memory-safe code without a significant performance hit. With a little community support, Rust could be a more efficient alternative. We have seen some Rust based efforts on ARM controllers and have covered the basics of Rust programming in the past if you want to get started. Good times ahead for hardware hackers.

Hijacking A Sony Watchman For Pong

The era of the vintage television was a great one, and one of the transitional by-products was the Sony Watchman. It was a portable TV which Sony started selling in 1982, and the amazing thing about it was that it had an actual 4-inch cathode ray tube or CRT. [Sideburn] just posted a video in which he hijacks the internals of a Watchman to make it into a portable game of Pong.

The hack begins with removing the TV tuner module inside to make some room for the new residents. Next comes the M51364P which is VIF video decoder chip, and for which surprisingly there is not a lot of info on the web. They were able to find a part of the schematic, which though it was in Russian may still be useful for enthusiasts. Removing the VIF revealed the audio and video pins that needed the appropriate signals for the hack to be successful. In an age of multilayer boards it is amazing how a two-layer PCB makes life so easier for the tinkerer.

For the new brains an Arduino Nano clone was selected, and instead of adding modern buttons the existing volume and band select switches were convinced to be the paddle control and play/pause button. Getting everything to fit was easy with the absence of the tuner module, and voila! New(ish) hardware. For the firmware, [Sideburn] turns to Hackvision firmware which has a host of games such as Space Invaders, Asteroids, and even Tetris.

We covered Hackvision a few years ago as a hardware/firmware bundle, and if you are more into CRTs then check out the Arduino driven 6845 CRT controller.

Continue reading “Hijacking A Sony Watchman For Pong”

Customising A $30 IP Camera For Fun

WiFi cameras like many other devices these days come equipped with some sort of Linux subsystem. This makes the life of a tinkerer easier and you know what that means. [Tomas C] saw an opportunity to mod his Xiaomi Dafang IP camera which comes configured to work only with proprietary apps and cloud.

The hack involves voiding the warranty by taking the unit apart and installing custom firmware onto it. Photos posted by [Tomas C] show the mainboard powered by an Ingenic T20 which is a popular IP Camera processor featuring some image and video processing sub-cores. Upon successful flashing of the firmware, the IP camera is now capable of a multitude of things such as remote recording and playback which can be configured using the web UI as documented by [Tomas C]

We did a little more digging on the custom firmware and discovered that the original author of the custom firmware, [EliasKotlyar] has done a lot of work on this project. There are loads of images of the teardown of a camera and an excellent set of documentation of how he made the hack. Everything from adding serial headers, getting root access, dumping the firmware and even toolchain links are given on the page. This is extremely handy for a newbie looking to get into the game.

And IP Cameras are not of the only hackable hardware out in the wild. There are other devices that are running Linux based firmware such as the Wifi SD Cards that run OpenWRT. Check out the essential guide to compiling OpenWRT from source if you are looking to get started with your next IP Camera hack.

Thanks for the tip [Orlin82]

Smell That? It’s Time.

Steampunk is beautiful. There is something about the exposed metal and primitive looking artifacts that visually appeal to the brain of a maker and engineer alike. Makers have been busy the last decade building clocks with this theme because hey, everyone needs a clock. [Fuselage] has put together a Steam Punk Clock that releases actual steam(actually steam oil smoke) for its hourly chime. How cool is that?

The clock is designed around the Conrad C-Control Unit (translated) which has the Motorola 68HC08 and [Fuselage] uses BASIC to write the routines for the system. Unlike a lot of steampunk clocks that use Nixie Tubes, this one uses 4 Numitron displays for the hours and minutes display. An analog dial panel display is employed for the seconds’ and is driven by a PWM signal. The absence of the RTC module was not obvious until we saw that the BOM includes a DCF77 receiver. For the uninitiated, DCF77 is a longwave time signal and standard-frequency radio station in Mainflingen, Germany. If you are anywhere within a 2000 km range of that location, you can pick up a 24-hr time signal for free which is excellent if you plan to make say… a radio clock.

The steam/smoke generator is a subproject of sorts. The custom machine is designed to have a separate oil reservoir and pump in addition to the actual generator so that the system does not run out of fuel as quickly. Clearly [Fuselage] did his homework which is explained in brief in his project logs. The final design has a brass tube as the main heating and also serves as the outlet chamber. The oil is pumped from under the heating filament in the brass tube, and excess fluid drains off back into the reservoir. A piece of nichrome wire serves as the filament that vaporizes the liquid to gaseous form. Sensors make sure of the oil levels in the reservoir as well as the steam tube. Servo motors and fans add the effect of the opening the exhaust rain cap, and a small LED helps illuminate the exhaust to complete the impression of real steam.

The project is a great example of a simple but effective implementation and for those who are wondering about Numitron Tubes, check out this tutorial on the subject. Of course, there is the Giant Electro-mechanical Clock for those looking at more sizable works of art.

Continue reading “Smell That? It’s Time.”

MicroPython Learns A New Trick – ISP For AVRs

One of the reasons why the Arduino became so popular was the ability to program it with ease. It meant the end of big parallel programmers that would cost an arm and a leg. The latest installment of CircuitPython from [Lady Ada] and the team over at Adafruit is a library for programming AVR microcontrollers without a dedicated PC.

For the uninitiated, in-system programming or ISP for AVR controllers employ the SPI bus to write the compiled binary to the flash memory of the controller. The discount on the number of pins used itself is a benefit though getting the timings right was a bit tricky in the good old days. Most dedicated ISPs handle this nicely, though they are normally slaves to a host PC where an ‘upload’ button initiates the process.

With CircuitPython (a derivative of MicroPython), programming microcontrollers does not require going through the code-compile-flash cycle. It can be run on a number of processors, however, AVRs are not among them so this neat little library offers the next best thing. Wire-up an Atmega328P or ATmega2560 to a board like the ESP8266 that does run CircuitPython, and you can write firmware on the fly.

There is a complete tutorial on the subject thanks to [Phillip Torrone] and [Lady Ada] which includes some demo files for testing out the functionality. This opens up a lot of possibilities where OTA firmware updates for an AVR co-processor. We expect to see some keychain AVR programmers in the near future taking a hint from the ESP8266 based Two-Factor Authentication featured previously.

Measuring HF Signal Speeds In A DIY Coaxial Collinear Antenna

Air Traffic Controllers use Automatic Dependent Surveillance-Broadcast (ADS-B) as an alternative to secondary radar to track aircraft. The ADS-B is transmitted by the aircraft and contains information such as GPS position, pressure, altitude, and callsign among other things at a 1090 MHz frequency, which can be decoded using any of a number of software tools.

[Mike Field] lives near an airport, and decided he wanted to peek into the tracking signals for fun. He turned to an RTL-based TV Dongle. Since the stock antenna was not cutting it, he decided to make one specifically for the 1090 MHz signal. His design is based on Coaxial Collinear Antenna for ADS-B Receiver by [Dusan Balara] which uses pieces of the coaxial cable cut to the right length. There are a number of calculations involved in determining the size of the cable, however, the hack in this design is the way he uses a USB based oscilloscope to measure the speed of RF waves inside the line in question.

We reached out to [Mike], and this is what he had to say. The idea is to use a cable of half the size of the wavelength which is calculated as

lambda = c/f

For the best reception, the sections of coax need to be half a wavelength long – but the wavelength of the signal inside the coax, which is shorter than the wavelength in free space. As this was a generic cable he had no idea of the dielectric that separates the core from the shield, so the ‘velocity factor’ could be anything depending on the exact composition.

To determine the speed of the signal in the cable, his approach omits the more expensive equipment. A length of coax acts as a stub – any energy that is sent into the cable reaches the far end of the transmission line and is then reflected back to the source. When the cable is 1/4th of the wavelength long, the reflected signal arrives back at the start of the signal 180 degrees out of phase – in a perfect world it would completely null out the input signal. Continue reading “Measuring HF Signal Speeds In A DIY Coaxial Collinear Antenna”

A Few Caps For A Faster Multimeter

We just love it when someone takes apart a bench instrument. There is something about voiding a warranty and then making modifications that hits the spot and in a series of simple modifications, [Jack Zimmermann] dives into the guts if an Aneng AN8008.

The multimeter in question, the AN8008, is a low-cost true-RMS instrument that takes a bit longer to settle on the correct voltage reading than [Jack] would have liked. While poking around, he found that the DC rail inside the meter was host to noise spikes. He theorized that these were being coupled back from an element and proceeded to verify the decoupling arrangement.

The first step was to replace a Rubycon 100 uF capacitor with a Panasonic FM 100 µF which has an ESR of 0.4 Ohms, an improvement on the 1.4 Ohms of stock capacitor. Next came the addition of 0.1 µF, 1 µF and a 10 µF 0805 capacitors and finally a huge 1000 uF 10 V capacity which helped cut down the noise from 30 mV p-p to 3.6 mV p-p. And finally he added decoupling capacitors to the voltage reference chip in accordance with the manufacturer’s datasheet.

These small modifications improved the settling time as well as the stability of the measurements. [Jack] verifies the accuracy against a voltage reference and a bench meter which is good news considering the calibration certificate went out the door anyway.

This is one of the many DMM hacks we have covered in the past such as the Fluke 12E+ hack that enables hidden features though there may be other models out there with possible upgrades.