EDITOR’S NOTE: I am introducing you to LTspice now because I plan to bring blog posts in the future in which you will be able to leverage LTspice to your advantage. Please download it and find various YouTube tutorials on its use. LTspice is free.
Many amateurs are electronic enthusiasts and routinely design and build electronic devices to complement their amateur radio activities. But what does this entail? Many have thought about the time they could save if they could first do a computer simulation of their design before committing to the time to build hardware. In this blog post we will consider how incredibly sophisticated (but free) software can be put to use by the Saturday electronics enthusiast.
Let us consider one of our own, an amateur radio operator who knows something of electronics (he’s an electronics technician perhaps trained in the Army or Navy) and routinely comes up with ideas to enhance his amateur radio activities.
One day an idea comes to his mind while at a restaurant while dining with his wife or maybe even other licensed amateur radio operators. Our very knowledgeable amateur may likely make a sketch on a napkin of an electronic circuit while the idea is still fresh in his mind.
Later he may refine the concept from the restaurant napkin solving for parameter values and make a more detailed sketch on notebook paper. Likely he or she will realize that something in the design will not work and develop a solution or think of a simplification or some other change that is needed or would prove beneficial to its operation.
In time our amateur radio operator decides it is time to breadboard his design so that he can test the idea out and discover new refinements that are needed or that would prove beneficial to the design’s objective. He may not have all of the parts on hand so he orders what is needed and eventually a day arrives when he can spend a Saturday afternoon breadboarding the design and apply power to validate the design on his electronics workbench. Building a breadboard is relatively quick and typically reveals problems that must be solved. If the breadboarding suggests a solid design, the next step would to build a functional device he can deploy for his actual benefit both now and in the years to come.
But let us recognize that our friendly FCC licensed amateur radio operator and skilled electronics technician discovers that his Saturday afternoon breadboard project does not work at all! Yikes!!! Let us further suppose that he realizes from this breadboarding that he has failed to properly interface something but still thinks the design idea is solid. What does he do? He goes back to the drawing board to “enhance” his design idea in preparation for another Saturday afternoon breadboarding experiment. Some of the parts he special ordered may no longer be needed. Maybe another special order with shipping fees may be required.
But suppose our friendly amateur had first tried analog computer circuit simulation to validate his idea? Suppose that computer simulation revealed his simple mistake. Having found the oversight he does not order the needless parts making him wait a week.
Please consider the free (but very sophisticated) LTspice application. LTspice® is a high performance SPICE simulation software, schematic capture and waveform viewer with enhancements and models for easing the simulation of analog circuits. Included in the download of LTspice are macromodels for a majority of Analog Devices switching regulators, amplifiers, as well as a library of devices for general circuit simulation.
Don’t be fooled by the “free” aspect of LTspice. It is not a toy or rudimentary application in need of maturity. Let’s take a quick peek at where LTspice came from.
SPICE (Simulation Program with Integrated Circuit Emphasis) was originally developed by UC Berkely in the late 1970s and released into the public domain. In that day it was only available for mainframe use (the PC had not yet been invented) and billed to a subscriber by the CPU seconds it took a given simulation to run in batch mode. It was still written in assembly code.
By the early 1980s the PC had been invented and a capital venture developed a version of SPICE for the PC–Pspice. The only problem was that the DOS PC could only address 0.64MB of RAM and Pspice required 5MB of RAM. RAM extension boards could be purchased to bring a given machine’s resources up to par but in those days RAM cost roughly $1,000 per MB. The PC itself (having a 20MHz clock) was on the order of $5,000 so Pspice will still not available to the consumer. Let me see… didn’t T. Rex still roam the earth in those days?
While Pspice remained out of reach for the consumer, industry wildly adapted it. Other SPICE knock-offs materialized as well as venture capital funded new analog simulation software, even more sophisticated) developed from the ground up such as Saber and Simplorer. Typical 1980s prices ranged from $40,000 to $100,000 and required workstations with as much as 32MB of RAM (that’s 0.032GB of RAM, folks) at $1,000 per MB.
But technology advanced and by about 2005 Linear Technologies (a maker of integrated circuits and discrete devices) released its own version of SPICE called LTspice available for no fee. LTspice would run on the typical home desktop or laptop computer finally bringing analog circuit computer simulation to the consumer or at least the electronic enthusiast/hobbyist.
But using LTspice does take some knowhow. Its algorithms used to solve problems have limitations. After all, computers are incredibly dumb. You have to tell them everything. Knowledge that we take for granted, computers don’t even have a clue. For example, LTspice hates discontinuities.
Consider the example at right. To us this looks perfectly simple. The signal transitions from 1 Volts to -1 Volts with a periodicity. But to the computer it sees something else. The computer sees a conundrum. At the point of transition the computer thinks the signal is supposed to be both +1V and -1V at the same time which, of course, is impossible.
But maybe the problem is actually ours as humans. In the real world any rectangular or square wave such as that shown may have the appearance of instantaneous rise and fall times but that is only an illusion. The signal will ALWAYS have rise and fall times. LTspice merely thinks that it is operating in the real world. Therefore, you must accommodate LTspice and make sure that there is some rise and fall time included in the model, even if it is small enough that as humans it is irrelevant. It’s called “the real world.”
So, I invite you to download and practice using LTspice. While I will be pointing to it for various techniques, I will not be presenting training on its use. There are lots and lots of tutorials on that.