DIY Dead Man’s Switch (No Microcontrollers)

A “dead man’s switch” (abbreviated here as DMS) is a very useful device for applications where the effect of forgetting to turn something off ranges from a mild annoyance to costly or dangerous consequences. We first learned about the DMS from a locomotive engineer, who explained vividly that an engineer is supposed to press a button every minute to keep the locomotive going, otherwise the machine stops. Less “dramatic” applications include turning off lights or other equipment after a period of time.

The ideal DMS provides several minutes of “on” time, requires no programming, external controls, additional power supplies and no modifications of the existing equipment. In effect, no changes should occur in the standard operating procedures of using the equipment. To reset the timer from “off” back to “on,” it is desirable to either use a button or just cycle the power.

Ironically, a multitude of electronic timers available online or at home improvement retail stores are highly over-engineered. These timers either require programming of specific date-times to be “ON” or have very long pre-sets, require changes in equipment wiring, etc.

DMS OPERATION

This article presents a DMS design that has been tested and currently in use in two different systems. One is controlling a UV source and another is controlling a hydrogen gas line valve. If someone forgets to turn off the UV source, the repairs are costly. When it comes to forgetting to turn off hydrogen, a violent explosion may happen!

The DMS works as follows. First, there are no microcontrollers—just plain physics. Capacitors C1 (bipolar, electrolytic) and C2 make a voltage divider (see Figure 1). Note this timer was originally designed for the European voltage; however, it is very simple to recalculate the capacitor divider for the US voltage.

Figure 1: This is the timer schematic. The Reset button S1 is optional.

Figure 1: This is the timer schematic. The Reset button S1 is optional.

The voltage is rectified by a bridge and smoothed by C3. The voltage on C3 is approximately 13 V. When the timer is powered on, both capacitors C4 and C5 are quickly charged each to a half of the supply voltage. FET is turned on and relay is engaged. At the same time, the charge begins a slowly redistribution between the capacitors, with C5 discharging via R3 and C4 further charging. Note that diode D1 is not conducting. When C5 is discharged enough, FET is turned off. This causes the relay to disengage. The timer will continue to be in this state as long as the power is provided, because C4 is effectively blocking any current flow. If the power is removed, D1 opens up to discharge C4 via R2. Remember: C5 is already discharged. Thus, the timer is reset to its initial condition. In addition, a manual reset switch S1 is added in case if it is more convenient to reset the timer by pushing a button rather than briefly disconnecting the mains power.

“ON” TIME

With the indicated components, the “on” time is for approximately 6 minutes. Changing C4 and C5 adjusts the “on” time. Our hydrogen valve control system uses capacitances of 30 µF each, resulting in approximately 25 minutes of “on” time. Note that the capacitances of C4 and C5 must be the same.

ABOUT THE AUTHORS

Dr. Alexander Pozhitkov has an MS in Chemistry and a PhD in Genetics from Albertus Magnus University in Cologne, Germany. For 12 years he has been involved with interdisciplinary research relating to molecular biology, physical chemistry, software, and electrical engineering. Currently, Dr. Pozhitkov is a researcher at the University of Washington, Seattle. His technical interests include hardware programming, vacuum tubes, and high-voltage electronics.

Hans-Joachim Hamann is a staffer at the Max Planck Institute for Evolutionary Biology.

 

Member Profile: Scott Weber

Scott Weber

Scott Weber

LOCATION:
Arlington, Texas, USA

MEMBER STATUS:
Scott said he started his Circuit Cellar subscription late in the last century. He chose the magazine because it had the right mix of MCU programming and electronics.

TECH INTERESTS:
He has always enjoyed mixing discrete electronic projects with MCUs. In the early 1980s, he built a MCU board based on an RCA CDP1802 with wirewrap and programmed it with eight switches and a load button.

Back in the 1990s, Scott purchased a Microchip Technology PICStart Plus. “I was thrilled at how powerful and comprehensive the chip and tools were compared to the i8085 and CDP1802 devices I tinkered with years before,” he said.

RECENT EMBEDDED TECH ACQUISITION:
Scott said he recently treated himself to a brand-new Fluke 77-IV multimeter.

CURRENT PROJECTS:
Scott is building devices that can communicate through USB to MS Windows programs. “I don’t have in mind any specific system to control, it is something to learn and have fun with,” he said. “This means learning not only an embedded USB software framework, but also Microsoft Windows device drivers.”

THOUGHTS ON THE FUTURE OF EMBEDDED TECH:
“Embedded devices are popping up everywhere—in places most people don’t even realize they are being used. It’s fun discovering where they are being applied. It is so much easier to change the microcode of an MCU or FPGA as the unit is coming off the assembly line than it is to rewire a complex circuit design,” Scott said.

“I also like Member Profile Joe Pfeiffer’s final comment in Circuit Cellar 276: Surface-mount and ASIC devices are making a ‘barrier to entry’ for the hobbyist. You can’t breadboard those things! I gotta learn a good way to make my own PCBs!”

Web-Based Remote I/O Control

The RIO-2010 is a web-based remote I/O control module. The Ethernet-ready module is equipped with eight relays, 16 photo-isolated digital inputs, and a 1-Wire interface for digital temperature sensor connection. The RIO-2010’s built-in web server enables you to access the I/O and use a standard web browser to remotely control the RIO-2010’s relay.

The RIO-2010 can be easily integrated into supervisory control and data acquisition (SCADA) and industrial automation systems using the standard Modbus TCP protocol. The I/O module also comes with RS-485 serial interface for applications requiring Modbus RTU/ASCII. Its built-in web server enables you to use standard web-editing tools and Ajax dynamic page technology to customize your webpage.

Contact Artila for pricing.

Artila Electronics Co., Ltd.
www.artila.com

Low-Cost, High-Performance 32-bit Microcontrollers

The PIC32MX3/4 32-bit microcontrollers are available in 64/16-, 256/64-, and 512/128-KB flash/RAM configurations. The microcontrollers are coupled with Microchip Technology’s software and tools for designs in connectivity, graphics, digital audio, and general-purpose embedded control.

The microcontrollers offer high RAM memory options and high peripheral integration at a low cost. They feature 28 10-bit ADCs, five UARTS, 105-DMIPS performance, serial peripherals, a graphic display, capacitive touch, connectivity, and digital audio support.
The PIC32MX3/4 microcontrollers are supported with general software development tools, including Microchip Technology’s MPLAB X integrated development environment (IDE) and the MPLAB XC32 C/C++ compiler.

Application-specific tools include the Microchip Graphics Display Designer X and the Microchip Graphics Library, which provide a visual design tool that enables quick and easy creation of graphical user interface (GUI) screens for applications. The microcontrollers are also supported with a set of Microchip’s protocol stacks including TCP/IP, USB Device and Host, Bluetooth, and Wi-Fi. For digital audio applications, Microchip provides software for tasks such as sample rate conversion (SRC), audio codecs—including MP3 and Advanced Audio Coding (AAC), and software to connect smartphones and other personal electronic devices.

The PIC32MX3/4 family is supported by Microchip’s PIC32 USB Starter Kit III, which costs $59.99 and the PIC32MX450 100-pin USB plug-in module, which costs $25 for the modular Explorer 16 development system. Pricing for the PIC32MX3/4 microcontrollers starts at $2.50 each in 10,000-unit quantities.

Microchip Technology, Inc.
www.microchip.com

MCU-Based Prosthetic Arm with Kinect

James Kim—a biomedical student at Ryerson University in Toronto, Canada—recently submitted an update on the status of an interesting prosthetic arm design project. The design features a Freescale 9S12 microcontroller and a Microsoft Kinect, which tracks arm movements that are then reproduced on the prosthetic arm.

He also submitted a block diagram.

Overview of the prosthetic arm system (Source: J. Kim)

Kim explains:

The 9S12 microcontroller board we use is Arduino form-factor compatible and was coded in C using Codewarrior.  The Kinect was coded in C# using Visual Studio using the latest version of Microsoft Kinect SDK 1.5.  In the article, I plan to discuss how the microcontroller was set up to do deterministic control of the motors (including the timer setup and the PID code used), how the control was implemented to compensate for gravitational effects on the arm, and how we interfaced the microcontroller to the PC.  This last part will involve a discussion of data logging as well as interfacing with the Kinect.

The Kinect tracks a user’s movement and the prosthetic arm replicates it. (Source: J. Kim, YouTube)

The system includes:

Circuit Cellar intends to publish an article about the project in an upcoming issue.