The Celtic Engineer is a weekly newsletter produced by Celtic Engineering Solutions.  We hope you enjoy it.  If you have any suggestions for topics, would like to give feedback or want your email added to the distribution list please send an email to[email protected].
That voltage is over my head
A common situation in analog electronics is the need for level translation.  A simple example of this is if one part of the circuit (or perhaps the input from another circuit) is sending information that has an upper voltage level of 5 volts and a lower level of ground, but it needs to be sampled by an A to D that has a 0 to 1.8V input.  Now that may be too easy of an example.  Or is it? I want to examine this idea in more depth and also discuss a more complex example where a signal is riding on a high DC voltage.
This feels so ‘draining,’ maybe I need a buffer
The first solution that comes to mind for the above situation, is a simple voltage divider set to have 1.8V output when the input is 5V.  Does the driving electronics have the ability to power the divider?  If the driving electronics is a bit gutless, or if sampling it will change the operation of the circuit, you might need a buffer.
Even if the circuit can power the divider, the device may be running off batteries where a constant drain on the batteries will shorten the usable life of the product.  To reduce current draw you increase the overall resistance of the divider to a few hundred kilohms.  And even with a constant voltage on the driving circuit the sampled voltage is all over the place when you look at the A to D.  What is going on?
The problem is not all A to D’s are created equal.  They all boast a different input impedance.  If the current draw of the A to D is large enough, it can affect your high impedance divider.  In that case, you are back to needing another buffer.
This is not a bad situation.  Many engineers will forget about the Nyquist criteria when dealing with an A to D and noise often has a much higher frequency than your sample rate.  Since you have a buffer sitting right in front of the A to D input you might as well take advantage of it and put some filtering on it.  I think we should devote a whole newsletter to Nyquist and filtering.

Hey what is that signal way up there?
A more interesting situation is when you have a digital signal represented as a current on a high DC voltage.  I worked on a project where the customer not only wanted to decode the digital signal but wanted to know the current being drawn by the device on the end of the line, you know, the one sending the digital signal.  Now there are more ways to solve this than there are engineers to solve it, as with any problem. I will provide just one possibility.
Since they wanted to know the current drawn on the high voltage line (somewhere between 20 and 60 volts) I started there.  A high side current monitor converts the current being drawn through a sense resistor placed in line with the high voltage supply to a voltage.
Since the device at the end of the line was a slave device, only responding to requests made by the MCU, the one sampling the current, there was plenty of time to sample the current of the device with no noisy digital signal.  When the digital signal was present it was additive, higher than the original current and therefor a voltage above that of the voltage representing the DC current. It was a digital signal with dc bias.
An open collector comparator with the reference input above the signal input would allow the signal to be removed from the dc voltage it rode on, and the open collector would allow level shifting to the required input voltage of the MCU. Not really a complicated circuit, but a puzzle never the less.

Wow that is so complicated!
Non-Electrical Engineers will often marvel at how complicated a circuit is and wonder how we know how to design anything like that.  The truth we all know is that it is like eating an elephant.  You take it one ‘byte’ at a time.  Each portion of the overall circuit does a fairly simple task.  And when it is all put together is performs a very useful task.
There are so many situations where level shifting is required.  Each one brings interesting challenges.  Do you have a story about an interesting puzzle you solved?  I would love to hear about it.  Post it under this newsletter on LinkedIn, or send me an email.

Final thoughts
This newsletter is sponsored by Celtic Engineering Solutions LLC, a design engineering firm based out of West Jordan, Utah, which can be found on the web  You can find the newsletter on the company blog, LinkedIn or by subscribing.  Send your emails to The Celtic Engineer at[email protected].