DIY Internet-Enabled Home Control System

Why shell out hundreds or thousands of dollars on various home control systems (HCS) when you have the skills and resources to build your own? You can design and implement sophisticated Internet-enabled systems with free tools and some careful planning.

John Breitenbach did just that. He used a microcontroller, free software, and a cloud-based data platform to construct a remote monitoring system for his home’s water heater. The innovative design can email or text status messages and emergency alerts to a smartphone. You can build a similar system to monitor any number of appliances, rooms, or buildings.

An abridged version of Breitenbach’s article, “Internet-Enabled Home Control” (Circuit Cellar 264, July 2012), appears below. (A link to the entire article and an access password are noted at the end of this post.) Breitenbach writes:

Moving from the Northeast to North Carolina, my wife and I were surprised to find that most homes don’t have basements. In the north, the frost line is 36˝–48 ˝ below the surface. To prevent frost heave, foundations must be dug at least that deep. So, digging down an extra few feet to create a basement makes sense. Because the frost line is only 15 ˝ in the Raleigh area, builders rarely excavate the additional 8’ to create basements.

The lack of basements means builders must find unique locations for a home’s mechanical systems including the furnace, AC unit, and water heater. I was shocked to find that my home’s water heater is located in the attic, right above one of the bedrooms (see Photo 1).

Photo 1: My home’s water heater is located in our attic. (Photo courtesy of Michael Thomas)

During my high school summers I worked for my uncle’s plumbing business (“Breitenbach Plumbing—We’re the Best, Don’t Call the Rest”) and saw firsthand the damage water can do to a home. Water heaters can cause some dramatic end-of-life plumbing failures, dumping 40 or more gallons of water at once followed by the steady flow of the supply line.

Having cleaned up the mess of a failed water heater in my own basement up north, I haven’t had a good night’s sleep since I discovered the water heater in my North Carolina attic. For peace of mind, especially when traveling, I instrumented my attic so I could be notified immediately if water started to leak. My goal was to use a microcontroller so I could receive push notifications via e-mails or text messages. In addition to emergency messages, status messages sent on a regular basis reassure me the system is running. I also wanted to use a web browser to check the current status at any time.


The attic monitor is based on Renesas Electronics’s YRDKRX62N demonstration kit, which features the RX62N 32-bit microcontroller (see Photo 2). Renesas has given away thousands of these boards to promote the RX, and the boards are also widely available through distributors. The YRDK board has a rich feature set including a graphics display, push buttons, and an SD-card slot, plus Ethernet, USB, and serial ports. An Analog Devices ADT7420 digital I2C temperature sensor also enables you to keep an eye on the attic temperature. I plan to use this for a future addition to the project that compares this temperature to the outside air temperature to control an attic fan.

Photo 2: The completed board, which is based on a Renesas Electronics YRDKRX62N demonstration kit. (Photo courtesy of Michael Thomas)


Commercial water-detection sensors are typically made from two exposed conductive surfaces in close proximity to each other on a nonconductive surface. Think of a single-sided PCB with no solder mask and tinned traces (see Photo 3).

Photo 3: A leak sensor (Photo courtesy of Michael Thomas)

These sensors rely on the water conductivity to close the circuit between the two conductors. I chose a sensor based on this type of design for its low cost. But, once I received the sensors, I realized I could have saved myself a few bucks by making my own sensor from a couple of wires or a piece of proto-board.

When standing water on the sensor shorts the two contacts, the resistance across the sensor drops to between 400 kΩ and 600 kΩ. The sensor is used as the bottom resistor in a voltage divider with a 1-MΩ resistor up top. The output of the divider is routed to the 12-bit analog inputs on the RX62N microcontroller. Figure 1 shows the sensor interface circuit. When the voltage read by the analog-to-digital converter (ADC) drops below 2 V, it’s time to start bailing. Two sensors are connected: one in the catch pan under the water heater, and a second one just outside the catch pan to detect failures in the small expansion tank.

Figure 1: The sensor interface to the YRDK RX62N board


One of my project goals was to push notifications to my cell phone because Murphy’s Law says water heaters are likely to fail while you’re away for the weekend. Because I wanted to keep the project costs low, I used my home’s broadband connection as the gateway for the attic monitor. The Renesas RX62N microcontroller includes a 100-Mbps Ethernet controller, so I simply plugged in the cable to connect the board to my home network. The open-source µIP stack supplied by Renesas with the YRDK provides the protocol engine needed to talk to the Internet.

There were a couple of complications with using my home network as the attic monitor’s gateway to the world. It is behind a firewall built into my router and, for security reasons, I don’t want to open up ports to the outside world.

My Internet service provider (ISP) occasionally changes the Internet protocol (IP) address associated with my cable modem. So I would never know what address to point my web browser. I needed a solution that would address both of these problems. Enter Exosite, a company that provides solutions for cloud-based, machine-to-machine (M2M) communications.


Exosite provides a number of software components and services that enable M2M communications via the cloud. This is a different philosophy from supervisory control and data acquisition (SCADA) systems I’ve used in the past. The control systems I’ve worked on over the years typically involve a local host polling the hundreds or thousands of connected sensors and actuators that make up a commercial SCADA system. These systems are generally designed to be monitored locally at a single location. In the case of the attic monitor, my goal was to access a limited number of data points from anywhere, and have the system notify me rather than having to continuously poll. Ideally, I’d only hear from the device when there was a problem.

Exosite is the perfect solution: the company publishes a set of simple application programming interfaces (APIs) using standard web protocols that enable smart devices to push data to their servers in the cloud in real time. Once the data is in the cloud, events, alerts, and scripts can be created to do different things with the data—in my case, to send me an e-mail and SMS text alert if there is anything wrong with my water heater. Connected devices can share data with each other or pull data from public data sources, such as public weather stations. Exosite has an industrial-strength platform for large-scale commercial applications. It provides free access to it for the open-source community. I can create a free account that enables me to connect one or two devices to the Exosite platform.

Embedded devices using Exosite are responsible for pushing data to the server and pulling data from it. Devices use simple HTTP requests to accomplish this. This works great in my home setup because the attic monitor can work through my firewall, even when my Internet provider occasionally changes the IP address of my cable modem. Figure 2 shows the network diagram.

Figure 2: The cloud-based network


Web-based dashboards hosted on Exosite’s servers can be built and configured to show real-time and historical data from connected devices. Controls, such as switches, can be added to the dashboards to push data back down to the device, enabling remote control of embedded devices. Because the user interface is “in the cloud,” there is no need to store all the user interface (UI) widgets and data in the embedded device, which greatly reduces the storage requirements. Photo 4 shows the dashboard for the attic monitor.

Photo 4: Exosite dashboard for the attic monitor

Events and alerts can be added to the dashboard. These are logical evaluations Exosite’s server performs on the incoming data. Events can be triggered based on simple comparisons (e.g., a data value is too high or too low) or complex combinations of a comparison plus a duration (e.g., a data value remains too high for a period of time). Setting up a leak event for one of the sensors is shown in Photo 5.

Photo 5: Creating an event in Exosite

In this case, the event is triggered when the reported ADC voltage is less than 2 V. An event can also be triggered if Exosite doesn’t receive an update from the device for a set period of time. This last feature can be used as a watchdog to ensure the device is still working.

When an event is triggered, an alert can optionally be sent via e-mail. This is the final link that enables an embedded device in my attic to contact me anywhere, anytime, to alert me to a problem. Though I have a smartphone that enables me to access my e-mail account, I can also route the alarm message to my wife’s simpler phone through her cellular provider’s e-mail-to-text-message gateway. Most cellular providers offer this service, which works by sending an e-mail to a special address containing the cell phone number. On the Verizon network, the e-mail address is <yourcellularnumber> Other providers have similar gateways.

The attic monitor periodically sends heartbeat messages to Exosite to let me know it’s still working. It also sends the status of the water sensors and the current temperature in the attic. I can log in to Exosite at any time to see my attic’s real-time status. I have also configured events and alarms that will notify me if a leak is detected or if the temperature gets too hot…

The complete article includes details such about the Internet engine, reading the cloud, tips for updating the design, and more.  You can read the entire article by typing netenabledcontrol to open the password-protected PDF.

Build a Microcontroller-Based Mail Client

Does the sheer amount of junk mail that fills your Inbox make you hate everything about e-mail? If so, it’s time to have a little fun with electronic mail by building a compact microcontroller-based mail client system. Alexander Mann designed a system that uses an Atmel ATmega32 and a Microchip Technology ENC28J60 Ethernet controller to check continuously for e-mail. When a message arrives, he can immediately read it on the system’s LCD and respond with a standard keyboard.

Mann writes:

My MiniEmail system is a compact microcontroller-based mail client (see Photo 1). The silent, easy-to-use system doesn’t require a lot of power and it is immune to mail worms. Another advantage is the system’s short start-up time. If you want to write a quick e-mail but your PC is off, you can simply switch on the miniature e-mail client and start writing without having to wait for your PC to boot up and load the necessary applications. All you need is an Ethernet connection and the MiniEmail system.

Photo 1: The complete MiniEmail system includes an LCD, a keyboard, and several connections. (A. Mann, Circuit Cellar 204)


The hardware for the MiniEmail system is inexpensive. It cost me about $50. The LCD is the most expensive part. To keep things simple, I left the system’s power supply, 5- to 3.3-V conversion crystals, and latch out of Figure 1.

Figure 1: This is a block diagram of MiniEmail’s hardware. The arrows indicate the directions of data flow between the devices. The rounded boxes indicate parts that do not sit on the circuit board.

The main components are an Atmel ATmega32 microcontroller and a Microchip Technology ENC28J60 Ethernet controller. Because a mail client is a piece of complex software, you need a fast microcontroller that has a considerable amount of program space. The MiniEmail system uses almost all of the ATmega32’s features, including the SPI, internal EEPROM and SRAM, counters, USART interface, sleep modes, all 32 I/O lines, and most of the 32 KB of program memory. The ENC28J60 is a stand-alone Ethernet controller that provides basic functionality for transmitting frames over an Ethernet connection. It has 8 KB of built-in SRAM, which can be divided into transmit and receive buffers as desired, and it provides several interrupt sources (e.g., when new packets have arrived). The ATmega32 also has 128 KB of external SRAM connected as well as an LCD, which is a standard module with a resolution of 128 × 64 pixels.

Take a look at the ATmega32’s pin connections in Figure 2. Ports A and C are used as 8-bit-wide general I/O ports, one of which is latched using an NXP Semiconductors 74HC573.

Figure 2: Here’s the complete schematic for the MiniEmail. The LF1S022 is the RJ-45 connector for the Ethernet connection.

The two ports provide data connections to the LCD and SRAM (U3). For the SRAM, you need three additional wires: write (*RAM_WR), read strobe (*RAM_RD), and the seventeenth bit of the address (ADDR16). The LCD connector (CON1) uses five additional wires (for the signals CS1, CS2, DI, EN, and RW). CS1 and CS2 are taken from the general I/O port A (DATA6 and DATA7) and determine which of the two halves of the LCD is selected (i.e., the two controllers on the LCD module you are talking to). RW (where you can use ADDR16 again) sets the direction of the LCD access (read or write). DI describes the type of instruction sent to the LCD. EN is the enable signal for read and write cycles. For the keyboard, you need only two pins: KEY_DATA and KEY_CLOCK. The clock signal must be connected to an external interrupt pin, INT1. One additional wire is needed to switch the latch (LE).

You are left with eight I/O pins on the ATmega32’s ports B and D. RXD and TXD are connected to a MAX232, an RS-232 level converter that also provides the negative supply voltage needed for the LCD (LCD_VOUT in Figure 2). The ATmega32’s USART functionality is used as a debugging interface. It isn’t needed for normal operation.


The firmware for this project is posted on the Circuit Cellar FTP site. I wrote the firmware in C language with a few small parts of inline assembler. I used the open-source software suite WinAVR, which includes the GNU GCC compiler with special libraries for AVR devices and avrdude, a tool for the in-system programming of AVR microcontrollers…


The user interface consists of three control elements: menus, edit fields, and an elaborate text editor. A special screen (the Mail Menu) enables you to quickly browse through your mailbox. After power-up, the system displays a greeting message. After a short while, the Main menu appears (see Photo 2).

Photo 2: This is a screenshot of MiniEmail’s main menu. In the upper-right corner, a clock shows the current time, which is retrieved from the Internet. An arrow to the left of the menu items indicates the selected item. (A. Mann, Circuit Cellar 204)

The Compose Mail, Check Mailbox, and Configuration submenus form a hierarchical menu structure. When the other items listed beneath the respective menu titles in the diagram are activated (e.g., start the text editor), they enable you to input data, such as a username and password, or retrieve mail from the mail server. “Standby” is the only action that is accessible directly from the main menu. All other actions are grouped by function in the submenus.


With respect to the firmware, sending mail is much easier than reading it, so let’s first focus on the Compose Mail menu. The first item in the menu starts the text editor so you can enter the body of your letter. You then enter the recipient’s mailing address and the subject of your e-mail, just like you would do when sending e-mail from your PC. Additional fields, such as CC or BCC are not included, but since this requires only one more line in the header of the mail, it is not difficult. Your e-mail also needs a reply address, so the recipient knows who sent the mail. The reply address is normally the same for all of the messages you write. The text you enter in this edit field is stored in the ATmega32’s EEPROM, so you don’t have to type it every time you write a letter. After you select the last menu item, “Send” initiates the dispatch of the mail and displays a message that indicates whether or not it was successful.


What makes this part more sophisticated is the ability to handle not only one e-mail at a time, but also fetch mail from the server. The system can determine which messages are new and which messages have been read. It can also extract data such as the sender, subject, or sent date from the header of the mail and then display the information.

The amount of mail the firmware can handle is limited by the size of the external SRAM. The maximum number of e-mails is currently 1,024. (If you’ve got more mail, you will be so busy answering it that you won’t have time to build your own MiniEmail client—or you should delete some old mail). Note that 1,024 is the number of unique identifiers that the system can remember. The server assigns a unique identifier to each piece of mail. The system uses the identifiers to keep track of which letters are new on the server, which have already been read, and which have been marked for deletion.

All of the header data for all of the 1,024 messages cannot be held in SRAM at once; only the most recent (about 50) mail headers are held. When you want to browse through older e-mails, the firmware automatically reconnects to the server and fetches the headers of the next 50 e-mails.

When you select Check Mailbox in the main menu, you get to a submenu where you can retrieve and read mail. Before you can collect your mail, you must enter your username and password, which can be stored in EEPROM for your convenience. The firmware then retrieves the headers and displays the Mail Menu, where you can browse through your e-mail. Apart from the size and the date, the first 42 characters of the subject and the mail sender are shown. In the first row, additional icons indicate (from left to right) whether a message is new, has been marked for deletion, or has been read. You can view the content of the selected message by pressing Return. When the mail is fetched from the server, it is prepared for viewing. The header and HTML tags, as well as long runs of the same character, are stripped from the mail and base64 decoding (used to encode 8-bit characters) is performed, so the content of the message is as readable as plain text. Binary attachments (e.g., images) can’t be handled. Following this, the mail is viewed in the text editor (with editing disabled).

A similar action is performed when you press “r” in the Mail Menu. In that case, you can edit the text so you can add your reply. Leaving the text editor will bring you back to the Send Mail menu, where the reply address and subject will be filled in so your mail will be clear for take-off. To delete a message, simply press D to mark it for deletion….


I hadn’t imagined how many details would need to be considered when I started this project more than a year ago. It has been a very interesting and challenging project. It has also been a lot of fun.

The MiniEmail system provides all of the basics for communicating via email, but such a project is never really finished. There are still dozens of items on my to-do list. Fortunately, the ATmega32 can be replaced with a new member of the AVR family, the Atmel ATmega644, which is pin-compatible to the ATmega32 and has twice the flash memory (and internal SRAM). That will provide enough space for many of my new ideas. I want to get rid of the static IP address, add CC and BCC fields, use a bigger display or a smaller (variable-width) font, improve the filtering and display of mail content and attachments, and add an address book (it would be best in combination with an additional external EEPROM with an SPI, such as the AT25256).

This project proves, rather impressively, that the ATmega32 and the ENC28J60 are a powerful combination. They can be used for many useful Internet applications. My e-mail client system is surely one of the most exciting. I can think of many other interesting possibilities. At the moment, my MiniEmail assembly serves as an online thermometer so I can check my room’s temperature from anywhere in the world…

Mann’s entire article appears in Circuit Cellar 204, 2007. Type “miniemailopen”  to access the password-protected article.

DIY Solar-Powered, Gas-Detecting Mobile Robot

German engineer Jens Altenburg’s solar-powered hidden observing vehicle system (SOPHECLES) is an innovative gas-detecting mobile robot. When the Texas Instruments MSP430-based mobile robot detects noxious gas, it transmits a notification alert to a PC, Altenburg explains in his article, “SOPHOCLES: A Solar-Powered MSP430 Robot.”  The MCU controls an on-board CMOS camera and can wirelessly transmit images to the “Robot Control Center” user interface.

Take a look at the complete SOPHOCLES design. The CMOS camera is located on top of the robot. Radio modem is hidden behind the camera so only the antenna is visible. A flexible cable connects the camera with the MSP430 microcontroller.

Altenburg writes:

The MSP430 microcontroller controls SOPHOCLES. Why did I need an MSP430? There are lots of other micros, some of which have more power than the MSP430, but the word “power” shows you the right way. SOPHOCLES is the first robot (with the exception of space robots like Sojourner and Lunakhod) that I know of that’s powered by a single lithium battery and a solar cell for long missions.

The SOPHOCLES includes a transceiver, sensors, power supply, motor
drivers, and an MSP430. Some block functions (i.e., the motor driver or radio modems) are represented by software modules.

How is this possible? The magic mantra is, “Save power, save power, save power.” In this case, the most important feature of the MSP430 is its low power consumption. It needs less than 1 mA in Operating mode and even less in Sleep mode because the main function of the robot is sleeping (my main function, too). From time to time the robot wakes up, checks the sensor, takes pictures of its surroundings, and then falls back to sleep. Nice job, not only for robots, I think.

The power for the active time comes from the solar cell. High-efficiency cells provide electric energy for a minimum of approximately two minutes of active time per hour. Good lighting conditions (e.g., direct sunlight or a light beam from a lamp) activate the robot permanently. The robot needs only about 25 mA for actions such as driving its wheel, communicating via radio, or takes pictures with its built in camera. Isn’t that impossible? No! …

The robot has two power sources. One source is a 3-V lithium battery with a 600-mAh capacity. The battery supplies the CPU in Sleep mode, during which all other loads are turned off. The other source of power comes from a solar cell. The solar cell charges a special 2.2-F capacitor. A step-up converter changes the unregulated input voltage into 5-V main power. The LTC3401 changes the voltage with an efficiency of about 96% …

Because of the changing light conditions, a step-up voltage converter is needed for generating stabilized VCC voltage. The LTC3401 is a high-efficiency converter that starts up from an input voltage as low as 1 V.

If the input voltage increases to about 3.5 V (at the capacitor), the robot will wake up, changing into Standby mode. Now the robot can work.

The approximate lifetime with a full-charged capacitor depends on its tasks. With maximum activity, the charging is used after one or two minutes and then the robot goes into Sleep mode. Under poor conditions (e.g., low light for a long time), the robot has an Emergency mode, during which the robot charges the capacitor from its lithium cell. Therefore, the robot has a chance to leave the bad area or contact the PC…

The control software runs on a normal PC, and all you need is a small radio box to get the signals from the robot.

The Robot Control Center serves as an interface to control the robot. Its main feature is to display the transmitted pictures and measurement values of the sensors.

Various buttons and throttles give you full control of the robot when power is available or sunlight hits the solar cells. In addition, it’s easy to make short slide shows from the pictures captured by the robot. Each session can be saved on a disk and played in the Robot Control Center…

The entire article appears in Circuit Cellar 147 2002. Type “solarrobot”  to access the password-protected article.

Q&A: Dave Jones (Engineer, EEVBlog)

Are you an electrical engineer, hacker, or maker looking for a steady dose of reliable product reviews, technical insight, and EE musings? If so, Dave Jones is your man. The Sydney, Australia-based engineer’s video blog (EEVblog) and podcast (The Amp Hour, which he co-hosts with Chris Gammell) are quickly becoming must-subscribe feeds for plugged-in inquisitive electronics enthusiasts around the world.

Dave Jones: engineer, video blogger, and podcaster

The April issue of Circuit Cellar features an interview with Jones, who describes his passion for electronics, reviewing various technologies, and his unscripted approach to video blogging and podcasting. Below is an abridged version of the interview.

David L. Jones is a risk taker. In addition to jumping off cliffs in the name of product testing, the long-time engineer recently switched to full-time blogging. In February 2012, Dave and I discussed his passion for electronics, his product review process, and what it means to be a full-time video blogger.—Nan Price, Associate Editor

NAN: When did you first start working with electronics?

DAVE: The video story can be found at “EEVblog #54 – Electronics – When I was a boy…” I was very young, maybe six or so, when I was taking apart stuff to see how it worked, so my parents got me a 50-in-1Tandy (RadioShack) electronics kit and that was it, I was hooked, electronics became my life. And indeed, this seems to be fairly typical of how many engineers of the era got started.

By the time I was eight, I already had my own lab and was working on my own projects. All my pocket money went into tools, parts, and magazines.

The electronics magazine industry was everything back then before the Internet and communications revolution. I would eagerly await every issue of the Australian electronics magazines like Electronics Australia, Electronics Today International (ETI), Applied and Australian Electronics Monthly (AEM), Talking Electronics, and later Silicon Chip.

NAN: Tell us about some of your early projects.

DAVE: Given that it was over 30 years ago, it’s hard to recall I’m afraid. Unfortunately, I just didn’t think to use a (film) camera back then to record stuff, it just wasn’t something that you did as a kid. The family camera only came out on special occasions. So those projects have been lost in the annals of time.

My first big published magazine project was a digital storage oscilloscope (DSO) adapter for PCs, in a 1993 issue of Electronics Australia. I originally designed this in the late 1980s. (See “,

NAN: You have many interests and talents. What made you choose engineering as your full-time gig?

DAVE: There was no choice, electronics has been my main hobby since I can remember, so electronics engineering was all I ever wanted to do to. I’ve branched out into a few other hobbies over the years, but electronics has always remained what I’ve wanted to do.

NAN: The Electronics Engineering Video Blog—EEVBlog—is touted as “an off-the-cuff video blog for electronics engineers, hobbyists, hackers, and makers.” Tell us about EEVBlog and what inspired you to begin it.

DAVE: I’ve always been into sharing my electronics, either through magazines, via my website, or on newsgroups, so I guess it’s natural that I’d end up doing something like this.

In early 2009 I saw that (WordPress-type) blogs were really taking off for all sorts of topics and some people were even doing “video blogs” on YouTube. I wondered if there were any blogs for electronics, and after a search I found a lot of text-based blogs, but it seemed like no one was doing a video blog about electronics, like a weekly show that people could watch … So I thought it’d be fun to do an electronics video blog and blaze a new trail and see what happened.

Being fairly impulsive, I didn’t think about it much; I just dusted off a horrible old 320 × 240 webcam, sat down in front of my computer, and recorded 10 minutes (the YouTube limit back then) of whatever came into my head. I figured a product review, a book review, a chip review, and some industry news was a good mix … I’ve had constant linear growth since then, and now have a regular weekly audience of over 10,000 viewers and over 4 million views on YouTube. Not to mention that it’s now my full-time job.

The complete April issue of Circuit Cellar is now available. For more information about Dave Jones, his video blog, and podcast, visit and

Renesas RL78 Green Energy Challenge

Up for an international design challenge? It’s time for the Renesas RL78 Green Energy Challenge! Renesas has partnered with IAR Systems to deliver engineers a power-house combo of low-power devices and high-quality software. They’re steering a great, green revolution and are challenging you to transform how the world experiences energy efficiency by developing a unique, low-power application using the RL78 MCU and IAR toolchain. Succeed and win a share of $17,500 in Grand Prizes from Renesas! * The Renesas Grand Prize winner will also win a free trip to Renesas DevCon in October where winners will be announced.

But that’s not all. Earn additional prizes like developments tools, Pmods, Wi-Fi modules, embedded systems books, and more from Contest Partners through weekly prize drawings. Follow Renesas on Twitter and Facebook for weekly challenge questions from official Contest Partners. Weekly Partner Challenges, and the respective winners, will be announced every Monday throughout the competition.

So, do you have a great idea for a remote device that monitors pollution? What about a box collecting data on home power usage or an energy harvesting biometric design? Perhaps your grand plan is for a low power controller scavenging heat from an oven or furnace, a meter reading biomass parameters, or a braking system for a wind turbine? It’s up to you! Send us your best RL78 based ideas to help make the world a better place.

The Challenge starts March 26, 2012 and ends on August 31, 2012. Winners will be announced in October at Renesas’ DevCon 2012.

Hundreds of free RL78/G13 development kits (“RDK”s), loaded with IAR’s Kickstart edition, are being distributed to those who qualify. Click here to see if you qualify for a complimentary RDK!

*Prizes in U.S. dollars.

Circuit Cellar, Inc. and Elektor International Media is the Contest Administrator.


Build a CNC Panel Cutter Controller

Want a CNC panel cutter and controller for your lab, hackspace, or workspace? James Koehler of Canada built an NXP Semiconductors mbed-based system to control a three-axis milling machine, which he uses to cut panels for electronic equipment. You can customize one yourself.

Panel Cutter Controller (Source: James Koehler)

According to Koehler:

Modern electronic equipment often requires front panels with large cut-outs for LCD’s, for meters and, in general, openings more complicated than can be made with a drill. It is tedious to do this by hand and difficult to achieve a nice finished appearance. This controller allows it to be done simply, quickly and to be replicated exactly.

Koehler’s design is an interesting alternative to a PC program. The self-contained controller enables him to run a milling machine either manually or automatically (following a script) without having to clutter his workspace with a PC. It’s both effective and space-saving!

The Controller Setup (Source: James Koehler)

How does it work? The design controls three stepping motors.

The Complete System (Source: James Koehler)

Inside the controller are a power supply and a PCB, which carries the NXP mbed module plus the necessary interface circuitry and a socket for an SD card.

The Controller (Source: James Koehler)

Koehler explains:

In use, a piece of material for the panel is clamped onto the milling machine table and the cutting tool is moved to a starting position using the rotary encoders. Then the controller is switched to its ‘automatic’ mode and a script on the SD card is then followed to cut the panel. A very simple ‘language’ is used for the script; to go to any particular (x, y) position, to lift the cutting tool, to lower the cutting tool, to cut a rectangle of any dimension and to cut a circle of any dimension, etc. More complex instructions sequences such as those needed to cut the rectangular opening plus four mounting holes for a LCD are just combinations, called macros, of those simple instructions; every new device (meter mounting holes, LCD mounts, etc.) will have its own macro. The complete script for a particular panel can be any combination of simple commands plus macros. The milling machine, a Taig ‘micro mill’, with stepping motors is shown in Figure 2. In its ‘manual’ mode, the system can be used as a conventional three axis mill controlled via the rotary encoders. The absolute position of the cutting tool is displayed in units of either inches, mm or thousandths of an inch.

Click here to read Koehler’s project abstract. Click here to read his complete documentation PDF, which includes block diagrams, schematics, and more.

This project won Third Place in the 2010 NXP mbed Design Challenge and is posted as per the terms of the Challenge.



Fundamental Amplifier Techniques with Electron Tubes

Want tips on designing electron tube amplifiers? Fundamental Amplifier Techniques with Electron Tubes might be the book for you. The author, Rudolf Moers carefully details the science of hollow-state design as applied to amplifiers and power supplies.

The book is an Elektor group publication. So, I asked tube amp aficionado Richard Honeycutt to provide an unbiased review the book. (I asked him to do this prior to taking him on as a columnist for audioXpress magazine.) He agreed, and here’s the review, which is also available in audioXpress April 2012:

Back in the 1950s and 1960s, if you wanted to learn about vacuum tube amplifiers, you could read the Radiotron Designer’s Handbook, a 1,500-page behemoth that covered all kinds of vacuum tube circuits that were known at the time, and also included abundant information on passive components as well. Or you could use the introductory material and example schematics in the RCA Receiving Tube Manual—much shorter and less expensive, and also far less comprehensive. Of course, it did include data on most tubes then being manufactured by RCA. If you just wanted to build your own amplifiers, but were not interested in designing, there was the Mullard  Circuits for Audio Amplifiers. For a more scholarly approach, you could check out an electrical engineering textbook such as Analysis and Design of Electronic Circuits by Paul Chirlian.

Now, however, things are different. Although some of these references can be found on the Internet, they are no longer up-to-date. Happily, however, Elektor recently published Fundamental Amplifier Techniques with Electron Tubes by Rudolf Moers, which presents a 21st-century perspective on the science of hollow-state design as applied to amplifiers and power supplies. Beginning with the principles of electron emission, the book progresses through standard vacuum tube varieties: diodes, triodes, tetrodes, and pentodes, after which it covers such general principles as frequency dependent behavior, non-linear distortion, noise, and negative feedback. The book concludes with a chapter on the construction of electron tube amplifiers. Unlike many of the earlier authors of books on electron tubes, Moers is not constrained by a need to cover such specialized tubes as pentagrid converters, or circuits specifically used in radio and TV receivers. Instead, he uses his 800 pages to discuss the physics underlying electron tube operation far more comprehensively than did any of his predecessors. He does this in a way that maximizes presentation of principles while minimizing unnecessary mathematics. In many cases, the physical explanations can be skipped over by those whose only interest is design methods. For the reader who does take advantage of the physical explanations, Moers’s inclusion of an eight-page listing/definition of mathematical symbols makes the explanations easy to follow.

The focus is by no means primarily on physics, however. None of the classic texts provides anything like so comprehensive coverage of the design and operation of half- and full-wave rectifier/filter circuits, or vacuum tube phase shifters, to mention a couple of examples.

Moers’s book assumes that the reader is familiar with basic DC and AC circuit theory, and therefore does not undertake the task of educating those who lack this understanding. The book is written from a scientific perspective in that, while mentioning the disconnect between measured and perceptual performance of an amplifier, the author makes no dogmatic claims about the relationship between the two, other than to opine that most of the “tube sound” results from harmonic distortion components that some people find pleasing to the ear. (Having followed this discussion for about four decades, your reviewer partially concurs, but believes that there are other elements involved as well.) The author lightheartedly introduces the quantity “cm2 of gooseskin/watt” as an example of a measurement of perceptual phenomena.

A consequence of Moers’ scientific approach is that specific catch phrases found in many amateur-oriented publications on tube technology are conspicuously absent. For example, it is difficult to read much about tube power amplifiers without noticing mention of the “Williamson amplifier.” This circuit was developed by D. T. N. Williamson and described in articles in Wireless World in April and May, 1947. It was unique in that it applied negative feedback around the entire amplifier, including the output transformer, thus reducing nonlinear distortion. Doing this required very careful design to ensure stability, including the elimination of interstage transformers such as the phase splitter transformer used in many prior designs.

Moers does not mention the Williamson amplifier by name, but the vacuum tube phase splitter design Williamson used is discussed in detail in the book, as is the method of designing a negative feedback loop encompassing the entire amplifier. Moers also gives a unique explanation of another pivotal power amplifier circuit: the ultralinear circuit invented in 1951 by Hafler and Keroes. It’s a case of content versus jargon.

In his otherwise excellent discussion of damping factor, Moers unfortunately makes the all-too-common error of ignoring the effects of voice coil  and lead wire resistance. He gives the common equation for damping factor: DF = (loudspeaker impedance)/(amplifier output impedance). Since the amplifier (modeled as an AC generator or Thevenin source), voice coil resistance, lead wire resistance, voice coil inductance, and reflected mechanical impedance form a series circuit whose actual damping is influenced by all elements, the lead wire resistance and voice coil resistance cannot be ignored. In fact, they can easily swamp the effects of the amplifier output impedance, at least for a pentode stage using negative feedback. However, Moers does not make the further error of insisting that the damping factor be a minimum of 100 as have some earlier authors. Using an 8-Ω speaker having about  6-Ω DC resistance, the effect of a combined output impedance and lead wire resistance less than 0.5 Ω is negligible.

Two shortcomings of Fundamental Amplifier Techniques with Electron Tubes are more or less linguistic. English may well be the only Germanic language in which the verb in a sentence is not at the end of the sentence required to come. Thus syntactical intrusions from the author’s native language sometimes make the text difficult for native English speakers. Also, Moers has chosen to use terminology that is probably not standard in English (at least American English) books on electronics. For example, he uses the term “ anode static steepness” to denote “transconductance” (also commonly called “mutual conductance.”) A common-cathode (or “grounded-cathode”) amplifier stage is called a “basic cathode” stage in Moers’ book.

These three small complaints pale in the face of the outstanding job the author has done in bringing together the theory, design, and practice of vacuum tube amplifiers in a single volume. Anyone who wants to go beyond the Heathkit level of tube amplifier understanding owes it to him/herself to buy and study this excellent volume.

If you’re interested purchasing the book or learning more about it, click here to visit the book’s webpage in the CC Webshop.

Fundamental Amplifier Techniques (by Rudolf Moers), audioXpress, and are Elektor group publications.


Weekly Elektor Wrap Up: Laser, Digital Peak Level Meter, & “Wolverine” MCU

It’s Friday, so it’s time for a review of Elektor news and content. Among the numerous interesting things Elektor covered this week were a laser project, a digital peak level meter for audio engineering enthusiasts, and an exciting new ultra-low-power MCU.

Are you an embedded designer who wants to start a laser project? Read about “the world’s smallest laser”:

What is the biggest constraint in creating tiny lasers? Pump power. Yes sir, all lasers require a certain amount of pump power from an outside source to begin emitting a coherent beam of light and the smaller a laser is, the greater the pump power needed to reach this state. The laser cavity consists of a tiny metal rod enclosed by a ring of metal-coated, quantum wells of semiconductor material. A team of researchers from the University of California has developed a technique that uses quantum electrodynamic effects in coaxial nanocavities to lower the amount of pump power needed. This allowed them to build the world’s smallest room-temperature, continuous wave laser. The whole device is only half a micron in diameter (human hair has on average a thickness of 50 micron).

The nanolaser design appears to be scalable – meaning that they could be shrunk to even smaller sizes – an important feature that would make it possible to harvest laser light from even smaller structures. Applications for such lasers could include tiny biochemical sensors or high-resolution displays, but the researchers are still working out the theory behind how these tiny lasers operate. They would also like to find a way to pump the lasers electrically instead of optically.

Be sure to check out Elektor’s laser projection project.

In other news, Elektor reached out to audio engineering-minded audio enthusiasts and presented an interesting project:

Are you an audio amateur hobbyist or professional? Do you try to avoid clipping in your recordings? To help you get your audio levels right, in January 2012 Elektor published a professional-quality peak level meter featuring 2x 40 LEDs, controlled by a powerful digital signal processor (DSP). As part of the eight-lesson course on Audio DSP, all the theory behind the meter was explained, and the accompanying source code was made available as a free download.

The DSP Board has been available for a while, and now we are proud to announce that the Digital Peak Level Meter is available as an Elektor quality kit for you to build. Although the meter was designed as an extension module for the Audio DSP board, it can be used with any microcontroller capable of providing SPI-compatible signals. So get your Peak Level Meter now and add a professional touch to your recording studio!

And lastly, on the MCU front, Elektor ran interesting piece about the Texas Instruments “Wolverine,” which should be available for sampling in June 2012:

Codenamed “Wolverine” for its aggressive power-saving technology, the improved ultra-low-power MSP430 microcontroller platform from Texas Instruments offers at least 50 % less power consumption than any other microcontroller in the industry: 360 nA real-time clock mode and less than 100 µA/MHz active power consumption. Typical battery powered applications spend as much as 99.9 % of their time in standby mode; Wolverine-based devices can consume as little as 360 nA in standby mode, more than doubling battery life.

Wolverine’s low power performance is made possible by using one unified ferromagnetic RAM (FRAM) for code and data instead of traditional Flash and SRAM memories, allowing them to consume 250 times less energy per bit compared to Flash- and EEPROM-based microcontrollers. Power consumption is further reduced thanks to an ultra low leakage  process technology that offers a 10x improvement in leakage and optimized mixed signal capabilities.

MSP430FR58xx microcontrollers based on the Wolverine technology platform will be available for sampling in June 2012.

Circuit Cellar and are part of the Elektor group.


DIY Cap-Touch Amp for Mobile Audio

Why buy an amp for your iPod or MP3 player when you can build your own? With the proper parts and a proven plan of action, you can craft a custom personal audio amp to suit your needs. Plus, hitting the workbench with some chips and PCB is much more exciting than ordering an amp online.

In the April 2012 issue of Circuit Cellar, Coleton Denninger and Jeremy Lichtenfeld write about a capacitive-touch, gain-controlled amplifier while studying at Camosun College in Canada. The design features a Cypress Semiconductor CY8C29466-24PXI PSoC, a Microchip Technology mTouch microcontroller, and a Texas Instruments TPA1517.

Denninger and Lichtenfeld write:

Since every kid and his dog owns an iPod, an MP3 player, or some other type of personal audio device, it made sense to build a personal audio amplifier (see Photo 1). The tough choices were how we were going to make it stand out enough to attract kids who already own high-end electronics and how we were going to do it with a budget of around $40…

The capacitive-touch stage of the personal audio amp (Source: C. Denninger & J. Lichtenfeld)

Our first concern was how we were going to mix and amplify the low-power audio input signals from iPods, microphones, and electric guitars. We decided to have a couple of different inputs, and we wanted stereo and mono outputs. After doing some extensive research, we chose to use the Cypress Semiconductors CY8C29466-24PXI programmable system-on-chip (PSoC). This enabled us to digitally mix and vary the low-power amplification using the programmable gain amplifiers and switched capacitor blocks. It also came in a convenient 28-pin DIP package that followed our design guidelines. Not only was it perfect for our design, but the product and developer online support forums for all of Cypress’s products were very helpful.
Let’s face it: mechanical switches and pots are fast becoming obsolete in the world of consumer electronics (not to mention costly when compared to other alternatives). This is why we decided to use capacitive-touch sensing to control the low-power gain. Why turn a potentiometer or push a switch when your finger comes pre-equipped with conductive electrolytes? We accomplished this capacitive touch using Microchip Technology’s mTouch Sensing Solutions series of 8-bit microcontrollers. …


The audio mixer flowchart

Who doesn’t like a little bit of a light show? We used the same aforementioned PIC, but implemented it as a voltage unit meter. This meter averaged out our output signal level and indicated via LEDs the peaks in the music played. Essentially, while you listen to your favorite beats, the amplifier will beat with you! …
This amp needed to have a bit of kick when it came to the output. We’re not talking about eardrum-bursting power, but we wanted to have decent quality with enough power to fill an average-sized room with sound. We decided to go with a Class AB audio amplifier—the TPA1517 from Texas Instruments (TI) to be exact. The TPA1517 is a stereo audio-power amplifier that contains two identical amplifiers capable of delivering 6 W per channel of continuous average power into a 4-Ω load. This quality chip is easy to implement. And at only a couple of bucks, it’s an affordable choice!


The power amplification stage of the personal audio amp (Souce: C. Denninger & J. Lichtenfeld)

The complete article—with a schematic, diagrams, and code—will appear in Circuit Cellar 261 (April 2012).








Aerial Robot Demonstration Wows at TEDTalk

In a TEDTalk Thursday, engineer Vijay Kumar presented an exciting innovation in the field of unmanned aerial vehicle (UAV) technology. He detailed how a team of UPenn engineers retrofitted compact aerial robots with embedded technologies that enable them to swarm and operate as a team to take on a variety of remarkable tasks. A swarm can complete construction projects, orchestrate a nine-instrument piece of music, and much more.

The 0.1-lb aerial robot Kumar presented on stage—built by UPenn students Alex Kushleyev and Daniel Mellinger—consumed approximately 15 W, he said. The 8-inch design—which can operate outdoors or indoors without GPS—featured onboard accelerometers, gyros, and processors.

“An on-board processor essentially looks at what motions need to be executed, and combines these motions, and figures out what commands to send to the motors 600 times a second,” Kumar said.

Watch the video for the entire talk and demonstration. Nine aerial robots play six instruments at the 14:49 minute mark.

Zero-Power Sensor (ZPS) Network

Recently, we featured two notable projects featuring Echelon’s Pyxos Pyxos technology: one about solid-state lighting solutions and one about a radiant floor heating zone controller. Here we present another innovative project: a zero-power sensor (ZPS) network on polymer.

The Zero Power Switch (Source: Wolfgang Richter, Faranak M.Zadeh)

The ZPS system—which was developed by Wolfgang Richter and Faranak M. Zadeh of Ident Technology AG— doesn’t require battery or RF energy for operation. The sensors, developed on polymer foils, are fed by an electrical alternating field with a 200-kHz frequency. A Pyxos network enables you to transmit of wireless sensor data to various devices.

In their documentation, Wolfgang Richter and Faranak M. Zadeh write:

“The developed wireless Zero power sensors (ZPS) do not need power, battery or radio frequency energy (RF) in order to operate. The system is realized on polymer foils in a printing process and/or additional silicon and is very eco-friendly in production and use. The sensors are fed by an electrical alternating field with the frequency of 200 KHz and up to 5m distance. The ZPS sensors can be mounted anywhere that they are needed, e.g. on the body, in a room, a machine or a car. One ZPS server can work for a number of ZPS-sensor clients and can be connected to any net to communicate with network intelligence and other servers. By modulating the electric field the ZPS-sensors can transmit a type of “sensor=o.k. signal” command. Also ZPS sensors can be carried by humans (or animals) for the vital signs monitoring. So they are ideal for wireless monitoring systems (e.g. “aging at home”). The ZPS system is wireless, powerless and cordless system and works simultaneously, so it is a self organized system …

The wireless Skinplex zero power sensor network is a very simply structured but surely functioning multiple sensor system that combines classical physics as taught by Kirchhoff with the latest advances in (smart) sensor technology. It works with a virtually unlimited number of sensor nodes in inertial space, without a protocol, and without batteries, cables and connectors. A chip not bigger than a particle of dust will be fabricated this year with the assistance of Cottbus University and Prof. Wegner. The system is ideal to communicate via PYXOS/Echelon to other instances and servers.

Pyxos networks helps to bring wireless ZPS sensor data over distances to external instances, nets and servers. With the advanced ECHELON technology even AC Power Line (PL) can be used.

As most of a ZPS server is realized in software it can be easily programmed into a Pyxos networks device, a very cost saving effect! Applications start from machine controls, smart office solutions, smart home up to Homes of elderly and medical facilities as everywhere else where Power line (PL) exists.”

Inside the ZPS project (Source: Wolfgang Richter, Faranak M.Zadeh)

For more information about Pyxos technology, visit

This project, as well as others, was promoted by Circuit Cellar based on a 2007 agreement with Echelon.

Radiant Floor Heating Zone Controller Project

Even if you aren’t interested in designing a radiant floor zoned heating system, you can study this innovative project and apply what you learn to any number of building control and automation applications. Dalibor Zaric’s Radiant Floor Heating Zone Controller is built around an NXP Semiconductors LPC2134 ARM processor that’s connected to an Echelon Pyxos chip. The project won Second Place in Echelon’s 2007 “Control Without Limits” design competition.

The heat zone controller system (Source: Echelon & Dalibor Zaric)

Zaric provides the following details in his project documentation:

“• Power supply to unit is 24VAC and controller has switching power supply to provide 24VDC for Pyxos network as well 5V for logic, there is 3.3V linear regulator as well.

• There are four relay with 24VAC output to power up thermoelectric zone valve on radiant floor heating manifold. These outputs are protected with 1.85A self resetting fuse to prevent overloading. This block has as well 24VAC/DC dry contact to provide a call for heat to boiler or optional zones pump.

• Pyxos power supply filter and Pyxos chip provides Pyxos network connection for future sensors and thermostats. Pyxos thermostat will be more cost effective than regular LONWorks sensors/thermostats.

• RS-485 driver will provide future Modbus connection for local touch screens or smart home systems with Modbus connections. There is end of line resistors enabled with the dip switches beside connector.

• 3150 Neuron board with 64K flash provides LONWorks connection to the controller.”


The heat zone controller diagram (Source: Echelon & Dalibor Zaric)

For more information about Pyxos technology, visit

This winning project, as well as others, was promoted by Circuit Cellar based on a 2007 agreement with Echelon.