There are many times when developing code for some for instrument we only need a simple and quick way to filter raw ADC data captured by the micro-controller. In most cases this filtering is done to eliminate noise from the captured signal using a low-pass function and in other cases to block DC offsets from the signal using a high-pass filter function.
Although there are many filtering schemes and topologies available many of these require intensive amounts of number crunching, data memory and execution speed perhaps not available in a small 8- or 16-bit micro-controller. If your filtering requirement are not rigorous a simple single-pole filter may just fit the bill. Whether in the analog or digital world we find using these types of filters quite often. Over the years I have successfully used these types of simple signal filtering. There are numerous amounts of information and material on the web regarding this theme that you can easily google and get the answers. So, I will add one more source to such resources. I have included here a simple and brief description to the single pole low-pass filter function and its application. I have also included a download for an Excel file that I created that allows you to simulate both High-Pass and Low-Pass single pole recursive filter responses.
The above description does not get into the details of the High-Pass filter function, but it is almost identical except that it is the inverse function of the Low-Pass type.
The algorithm or time discrete recursive equation for the High-Pass filter function is shown below.
y(n) = a * y(n-1) + ( a * ( x(n) – x(n-1) ) )
Where y(n) is the present calculated output value, x(n) the present sample value, x(n-1) the previous sample value and y(n-1) the previous output value.
The need for a simple low cost tool for ESD troubleshooting
During the early 90’s most of my engineering development efforts always included the additional work required to get the product submitted to the new CE (European Conformity) standards. Although I was already well versed in agency submittals to places like UL, CSA, FCC and FM, the CE requirement were pretty much new to me. The newly introduced CE requirements included the various tests for IEC 61000-4-2 compliance which deal with ESD (Electro-Static Discharge) events. At the time testing for ESD susceptibility could only be done with an ESD gun, and back in those days this would set you back anywhere from $3000 to $4000 to purchase, or you could rent one for approximately $1000 per month. Either way that is a very expensive tool for something that is seldom used. Unfortunately, when it comes to IEC 61000-4-2 compliance testing there is no other way but to use a qualified ESD gun. Other methods will not apply. When we deal with real world ESD events in everyday life we are mainly dealing with human to machine ESD air type discharges; most commonly, triboelectric effect type charges similar to the ones that we all experience during very dry days while walking on a carpet and then touching any metallic objects that somehow have an electrical path to earth. Although annoying to some, this type of event has been known to cause malfunctions, or even permanent damage in electronic equipment. Thus, this is the foundation for the above testing requirements.
Given the above test requirement, one could say that a simple method to test for ESD susceptibility could easily be done by various methods. You could somehow generate an electrical charge and just do a discharge on to the surface of whatever device you are testing. To do this we could use a few cheap tools like a low-cost spark generator or a grill spark igniter.
The best candidate I found is a grill igniter. It is not only the absolute cheapest device, but it also meets most requirements. it is an air discharge source, and most can produce both positive and negative type discharges in a single discharge cycle and above all do not need any kind of power source or electronics. Of course, I was not the first to discover this as there were plenty of others in the WWW with postings and articles about this. One of the first things you typically do while doing ESD testing on any kind of electronics is to do some discharges in very close proximity and observe for any effects or failures. If that part of the test passes, the next is to do ESD discharges onto the actual surfaces of the device under test and, once again, take notice of any anomalies or failures. This type of testing is pretty much a debug or investigative type of approach. In most cases, if you find any failures at this point you will definitely find it during the real IEC 61000-4-2 compliance testing while you are paying an outside lab a couple of thousand $$ a day for that. So, for preliminary ESD compliance testing you do NOT need a sophisticated expensive tool. All you need is a simple tool that can give you an HV air discharge that will allow you to find ESD failure issues.
My first homebuilt ESD gun was a modified piezo-ceramic igniter whose piezo material just happened to have a capacity characteristic of 120 pF, very close to the required capacity described by IEC 61000-4-2 human body model which is 150 pF. In case you want to know the Human Body Model comprises a storage capacity of 150 pF and a series resistance of 300 ohms. Once I modified the above home-made ESD test gun by including a 330 resistor between the piezo element and the tip, I had just about the perfect tool for everyday preliminary ESD testing. This became such a nice tool that many had asked me to build one for them. Eventually, I purchased 600 pieces of these piezo-igniters from a company in Czechoslovakia and began building them at home and selling it as a product that I called ESD800 (see above photo) and sold over the internet back in the late 90’s. Unfortunately, that igniter company went out of business sometime in 2008 and I had sold every one of them. It took me quite a while to find something compatible. In 2009 I came up with a new model called the ESD1000 which is shaped closer to the appearance of an actual ESD gun. Over the years I have sold over two thousand of these and although I don’t bother advertising, they continue to sell.
Just like the ESD test gun, I have created many different pieces of test equipment over the years ranging from precision signal generators, calibration sources and various other types of instrumentation. However, nowadays, with the infusion of cheap test equipment coming from China and other Eastern Bloc countries, it no longer pays off to roll your own test equipment. Some of the test equipment like oscilloscopes, generators and many other types coming from China are excellent equipment with very impressive specifications at incredibly affordable prices. So, unless you need something that is very unique or specific that is not available through eBay or Amazon, then rolling your own may be the best bet.