Friday, January 18, 2019

How To View Layer Sets Quickly - Altium

Each layout software is slightly different in how you view sets of layers during the routing process. If you made the transition from Orcad PCB Editor to Altium like I did, then you're familiar with what were called 'Views.'

These views are a way to group layers for quickly jumping back and forth between layer sets. Altium has a similar thing which it calls 'Layer Sets.' For those familiar with Orcad PCB Editor, the video below should seem normal.

The next video shows how to define layer sets for quickly switching between groups of available layers.

The key to quickly viewing groups of layers is to put these layer sets on hotkeys so that you can quickly swap during routing. What I do in the video below is click on the Manager Layer Sets menu 'LS' and then Ctrl-Click on the Top Layer layer set. This brings up the Edit Command window for assigning a hotkey such as one of the Num Pad numbers. I usually start with Num1 for Top Layer, Num2 for Bottom Layer, etc.


Now that you've got layer sets defined in Altium and you know how to assign hotkeys to them, you'll be able to quickly switch between groups of layers. This concept is extremely useful in reducing the amount of clutter on the screen, and it allows you to have go to layer sets for views such as Assembly Drawings, Top and Bottom Views, Component Outlines, Etc.

I hope you find this useful. Comment below on how you use layer sets and let me know if you have Altium questions I can help with.

Saturday, January 12, 2019

Using Component Classes in Altium with Rooms

When doing layouts in Altium, it is useful to bundle components into Component Classes for organizing into rooms and applying design rules. To do this, I highlight the all the components in the schematic that I want to group (making sure to enable Tools -> Cross Select Mode).

Once this is done, I go to the PCB document where the components have already been imported and I arrange them into a rectangle on part of the PCB (Tools -> Component Placement -> Arrange Within Rectangle). You should get something like the picture below.


Now that you can see all the components you're interested in, you want to draw a Room around the group of components (Design -> Rooms -> Place Rectangular Room). You can press tab and get the dialog shown below. Once you have this dialog up, you can change the name of the room. Here I typed in EthernetRoom and then pressed Ok.

If we double click on the room just created, we'll see 'Component Class 2' was created and all the components we drew in the room selection have been added as members. You can check the defined classes to verify (see below). I'm going to rename this to EthernetClass and then edit the room definition by double clicking on the room rectangle.


Here I'm editing the drop down boxes so that EthernetRoom contains objects that match everything in the EthernetClass Component Class.


Now we've got a room with assigned components in it that can be used for easier component placement. Dragging this room around will move components as well as visible polygons, traces, etc. In addition to placement, rules can be assigned in the Design Rules to Component Classes. Rooms can also be used for Channel designs that have the same schematic and layout repeated multiple times.


Hope you found this one useful and interesting. If you have questions, or other topics in Altium you need help with, comment below and I'll be more than happy to help.


Tuesday, March 14, 2017

What I've learned... ~3 years after school

Roughly three years ago, I started my current job as an electrical engineer fresh out of school. I had accepted a position as a power electronics engineer. However, if you asked me in my junior or senior year of school what discipline I wanted to go into, power electronics would have been at the bottom of the list. This is a short story describing many of the things I've learned any my experiences on my journey from school to industry.

Friday, October 3, 2014

Understanding Linear Regulator Design Parameters

Understanding Linear Regulator Design Parameters
by Michael Delany

Introduction

All electrical systems need to have one or more power rails to power components or use as references. Depending on the application, some characteristics can be more desirable than others. It is common that one wishes to take some voltage level and regulate it down to a lower level and filter the signal to have clean DC output. One way to accomplish this is to use a linear voltage regulator. This segment will discuss when to use and when not to use a linear voltage regulator. In the same manner this segment will also explain what characteristics will be more important in one linear regulator versus another.

Why Use A Linear Voltage Regulator?

The linear voltage regulator is a device which uses output feedback to correct its output and makes it as stable as possible to the reference. This is done with a differential amplifier and a transistor to regulate the output (in this case a FET). In this segment, we’re going to use a low-dropout (LDO) linear regulator. In this device a FET is used rather than a BJT to minimize losses when the BJT is in the active region.

So why would we consider using a linear regulator? Why not just put a battery into a system and use the output of the battery? Well, it turns out that a battery’s voltage drops linearly as time goes on.

In addition, one would would also like to remove the effect of load transients on the output of the regulator.  That is, when the device loading the regulator suddenly needs more current, this has only a small affect on the output voltage. Another reason includes the rejection of noise and voltage ripple at the input. The linear regulator is not the only type of regulator either. The other most common voltage regulation techniques are switch-mode regulators and switch capacitor regulators.

So in which applications would it be preferrable to use a linear regulator? Considering a linear regulator requires very few external components, it is very simple to set up. In addition, they are usually much cheaper than another type of regulator like a switch-mode power supply.

The linear regulator is most suited for an application where the regulated output will be very close to the input voltage. The reason being because of better efficiency, something that’ll also be discussed. Also, unlike a switch mode power supply, there is considerably less noise since the regulator isn’t constantly switching.

Modeling An LDO

The following is how one can model a linear voltage regulator along with some of its internal characteristics.

is the load resistance
is the load capacitance
is the equivalent series resistance of the capacitor
is the bypass capacitor placed across the regulator’s output terminals
is the capacitance of the PMOS pass transistor
is the output resistance of the error amplifier
is the gain of the error amplifier

For output feedback the output voltage is scaled for comparison against a reference via a voltage divider. A typical reference voltage for a TI part for example is = 1.192 [V]. First, let’s define a parameter β known as the feedback gain of the system as the ratio of the output voltage is scaled by for the controller (op amp).

    β =

The following is an approximation when the open loop gain is much greater than 1 and we can solve this equation for β using the code below: (Note is the gain of the error amplifier in V/V)

    

The above value 0.134921 corresponds to the gain in the feedback loop and above we can see the ratio of resistors needed.

Note: In Mathematica, (the computational package I’m using) one can use subscripted variables by holding ctrl and pressing - . However, if the subscript name is the same as another variable defined, Mathematica will try and expand the subscript to its evaluated form. The following are variables that are used to model the low-dropout regulator, including the poles and zeros needed to model the open-loop transfer function.

[s] above is the open loop transfer function. So to get the closed loop transfer function we just compute . It’s also a good exercise to plot the open loop transfer function versus the closed loop transfer function. When doing this one notices there is a tradeoff. The gain of the system will decrease, but the overall bandwidth increases when we switch to the closed loop gain.

Also another thing we could do if we like is calculate the gain and phase margins for the open-loop transfer function.

There is infinite gain margin in this case with None corresponding to the frequency and ∞ being the gain. Next the unity gain happens at 43,062.6 radians/sec and the phase margin is 1.07188 radians or 61.4142 degrees. According to the criteria of stability, this is a stable system.

Typical datasheet parameters

Included in this section are some of the most basic parameters noted in a typical datasheet:

Quiescent current is an undesirable parasitic of any linear regulator, and is defined as the difference in the output and input current. The components in the regulator are not ideal and therefore they require some bias current. For example, the current draw by the op amp, gate drive current for the pass transistor, and feedback resistors.

One thing to check for when looking for an LDO is to see if the efficiency will work for your application. To compute the efficiency of an LDO, the following equation can be used:

    η = * 100%
    
where is the output current, is the output voltage, is the input voltage and is the quiescent current. There are some applications where linear regulators won’t work well for efficiency. If for rough calculations, one assumes the quiescent current is relatively low, then the efficiency is approximately:

    η ≈
    
So if one were doing voltage regulation with a 12V input going to 3.3V output, the efficiency would be approximately 27.5%... Not so great.

One of the other parameters for designing a system with an LDO is knowing the line regulation. Or in other words, how much the output changes versus a step change in input. Line regulation is a steady-state parameter which is independent of frequency contributions, unlike Power Supply Ripple Rejection (PSRR) noted later in this text.

Line regulation is defined the following way:

    line regulation =

Another design parameter is the load regulation. The load regulation is the amount that the output voltage will change for a given output current change. Just like line regulation, load regulation is a stead state parameter so this should be taken into account during design.

    load regulation =

The following is the gain plot for the Power Supply Ripple Rejection (PSRR). PSRR is very similar to line regulation except it takes into account the entire frequency spectrum. It is worth while to note that this model for PSRR doesn’t take into consideration the load of the power supply. The higher the load, the more exaggerated the PSRR and vice versa.

Output Voltage Noise

Next, we’ll go over the noise at the output of the regulator and what causes it and how we can try and minimize its impact. One of the reasons there is noise at the output of the regulator is because the reference voltage inherently will have some noise which is amplified. This noise can be minimized greatly by using something known as a feedforward capacitor. This feedforward capacitor is placed between the output and feedback pin on the regulator.

The use of the feedforward capacitor will divert the noise across the reisistor such that the reference noise is not amplified. There is a parameter called the RMS noise which is typically in units of and this value is dependent on the value of . As can be seen below, the RMS noise is also dependent on the output voltage and is computed as an average over a frequency range:

This is not the only way to reduce noise due to the reference voltage. Looking at the schematic above, we can see that a capacitor can be added to the NR (noise reduction) pin to filter out reference voltage noise.

Conclusion

The linear regulator isn’t just a three pin device where the input is connected and voila there is an output. It’s more delicate than that and deserves some real thought (even the models I’ve used are simplified versions of the real models). When selecting components, it makes sense to be sure the component you’re choosing now will work well for for your application under its operating conditions.This isn’t an all encompassing text of linear regulators either. There are other topics that can be explored such as transient response and accuracy, which I encourage you to look at. This was hopefully a bit of an insight to remind you as an engineer to be meticulous with component selection and your particular application.



Download:

Sources

1.    Lee, Bang. “Understanding the Terms and Definitions of LDO Voltage Regulators.” Texas Instruments Application Report. 1 Oct. 1999. Web. 19 Sept. 2014. <http://www.ti.com/lit/an/slva079/slva079.pdf>.

2.    Rogers, Everett. “Stability Analysis of Low-dropout Linear Regulators with a PMOS Pass Element.” Texas Instruments Power Management. 1 Aug. 1999. Web. 19 Sept. 2014. <http://www.ti.com/lit/an/slyt194/slyt194.pdf>.

3.    Teel, John. “Understanding Power Supply Ripple Rejection in Linear Regulators.” Texas Instruments Power Management. 1 Apr. 2005. Web. 19 Sept. 2014. <http://www.tij.co.jp/jp/lit/an/slyt202/slyt202.pdf>.

4.    Nogawa, Masashi. “LDO Noise Examined in Detail.” Texas Instruments Power Management. 1 Oct. 2012. Web. 19 Sept. 2014. <http://www.ti.com/lit/an/slyt489/slyt489.pdf>.

5.    Antunes Fernandes, Pedro Miguel. “High PSRR Low Drop-out Voltage Regulator (LDO).” Universidade Technica De Lisboa. 1 Apr. 2009. Web. 19 Sept. 2014.     <https://fenix.tecnico.ulisboa.pt/downloadFile/395138344001/LDO.pdf>.

6.    Zhang, Henry. “Basic Concepts of Linear Regulator and Switching Mode Power Supplies.” Linear Technology Application Note. 1 Oct. 2013. Web. 19 Sept. 2014.     <http://cds.linear.com/docs/en/application-note/AN140fa.pdf>.