PROTEUS DESIGN SUITE Getting Started Guide
COPYRIGHT NOTICE © Labcenter Electronics Ltd 1990-2019. All Rights Reserved. The Proteus software programs (Proteus Capture, PROSPICE Simulation, Schematic Capture and PCB Layout) and their associated library files, data files and documentation are copyright © Labcenter Electronics Ltd. All rights reserved. You have bought a licence to use the software on one machine at any one time; you do not own the software.
LABCENTER ELECTRONICS LTD.
TABLE OF CONTENTS COPYRIGHT NOTICE .................................................................................................................. 1 © Labcenter Electronics Ltd 1990-2019. All Rights Reserved. ................................................ 1 WARNING ................................................................................................................................ 1 DISCLAIMER ...................................................................................................
Gateswap ................................................................................................................................. 42 Preparing for PCB Layout ........................................................................................................ 44 Packaging Considerations ........................................................................................................ 44 To view the package associated with a component: .......................................................
Displayed Layers Dialogue ...................................................................................................... 90 Component Placement ............................................................................................................. 92 Components and Packages ..................................................................................................... 92 The Board Edge .......................................................................................................
Schematic to PCB .................................................................................................................... 149 PCB to Schematic .................................................................................................................... 150 General Netlisting Rules ........................................................................................................... 150 Power Planes and Slots ............................................................................
Basic Debugging ...................................................................................................................... 194 Important Notes ........................................................................................................................ 197 The Watch Window .................................................................................................................. 197 Hardware Breakpoints ...........................................................................
SCHEMATIC CAPTURE TUTORIAL INTRODUCTION The aim of this tutorial is to take you through the process of entering a circuit of modest complexity in order to familiarise you with the techniques required to drive the schematic capture module in Proteus. The tutorial starts with the easiest topics such as placing and wiring up components, and then moves on to make use of the more sophisticated editing facilities, such as creating new library parts.
LABCENTER ELECTRONICS LTD. your own keyboard accelerators the shortcuts mentioned may not be valid. Information on configuring your own keyboard shortcuts can be found in the General Concepts section of the Documentation. Creating a New Project We shall assume at this point that you have installed the Proteus 8 software package. To start the software, click on the Start button and select Programs, Proteus 8 Professional and then the Proteus 8 application.
Schematic Capture Similarly, we need a layout so check the box at the top of the layout page and again choose the default template. The next screen allows us to define the layer stack for our PCB. Since we will be designing a simple two layer board there is no configuration necessary here. For multi-layer PCB's the stackup wizard button would be used to define the number of copper layers, cores and pre-preg's. This is discussed in more detail in the accompanying PCB tutorial.
LABCENTER ELECTRONICS LTD. The final screen in the PCB configuration is simply a preview of a PCB cross section that displays visually what has been set up in the previous screens.
Schematic Capture Click on the finish button to create the project. A schematic template can contain sheet size, colour scheme, company logo, header block and various other aesthetic presets. Further information can be found in the Templates chapter of the reference manual. A PCB template can contain board edge, mounting holes, design rules, layer stack and various other technology information. Refer to the Templates chapter in the PCB documentation for more information.
LABCENTER ELECTRONICS LTD. Guided Tour The largest area of the screen is called the Editing Window, and it acts as a window on the drawing - this is where you will place and wire-up components. The smaller area at the top left of the screen is called the Overview Window. In normal use the Overview Window displays, as its name suggests, an overview of the entire drawing - the blue box shows the edge of the current sheet and the green box the area of the sheet currently displayed in the Editing Window.
Schematic Capture Auto hide the Object Selector Device Mode Icon Navigation of the view displayed in the Editing Window takes two forms; adjusting the scale of the drawing (zooming) and adjusting the area of the drawing displayed (panning).
LABCENTER ELECTRONICS LTD. Panning As with zooming, there are a number of options for panning across the editing window. Click on the middle mouse button to enter track pan mode. This puts the schematic in a mode where the entire sheet is picked up and will move as you move the mouse. The track pan cursor will indicate when you have entered this mode. Left click the mouse again to exit track pan mode.
Schematic Capture Note that Proteus allows you to reposition all the icon toolbars as well as move/resize the Object Selector/Overview Window. Do be aware however, that this documentation refers to all the rebars and windows in their default locations.
LABCENTER ELECTRONICS LTD. Keyboard Mapping Dialogue Form While there are few limits on shortcuts, a few standard windows accelerators are restricted as they are global across the entire Proteus system (e.g. CTRL+S for save). Display Options Proteus is capable of harnessing the power of your computers graphics card to speed up operation and present a crisp and smooth display.
Schematic Capture Configuration of the screen display takes place from the Set Display Options on the System menu. Some of these options are specific to a particular hardware acceleration technology and will be disabled when a different mode is enabled. The Set Display Options Form for OpenGL and Direct2D The first section of the dialogue reports on whether your graphics card will support OpenGL and/or Direct2D hardware acceleration and, if so, allows you to switch between graphics mode.
LABCENTER ELECTRONICS LTD. display issues. We would suggest you being with multi-sampling off if you choose to work in OpenGL mode. Configuration of colours and styles in Proteus takes place from the Template Menu. This allows to change everything from paper, grid and highlight colours to the thickness and colour of all the object types used in a design. Please refer to the reference manual section on Templates for more information. Design Overview The circuit we are going to draw is shown below.
Schematic Capture Relative humidity A number of low cost silicon transducers with built-in signal conditioning or digital interfaces have been used for measurement. This reduces the number of components to the minimum required for dsPIC33 interfacing. All measurements get periodically stored into a non-volatile, low power memory in row binary format for later transfer to a host PC either by using a serial terminal or, more properly, a simple program (not supplied with the project).
LABCENTER ELECTRONICS LTD. Basic Schematic Entry We’ll start the tutorial by familiarizing ourselves with the basics of schematic design; picking components from the libraries, placing them on the schematic and wiring them together. The design in question is relatively large and there is therefore a reasonable amount of drawing involved.
Schematic Capture Either of these two methods will cause the Device Library Browser dialogue form to appear.
LABCENTER ELECTRONICS LTD. The 2N7002 in the Object Selector Given that we know the names of all the parts we want we could simply proceed by using this technique to bring in all the components we need. However, this may not always be the case and Proteus provides several methods for finding parts in the component libraries. One of the most intuitive is to use the library browser a little like an internet search engine, typing in descriptive keywords and then browsing the results to find a specific part.
Schematic Capture Picking a CHIPRES1K Resistor from the Pick Devices form You can customize the information displayed in the Library Browser’s results list by right clicking the mouse on the results list. The context menu provides you with options to display Categories, Sub-Categories, Manufacturer and Library alongside each result. It may be that we simply want to browse for a specific type of part and/or one available from a specific manufacturer.
LABCENTER ELECTRONICS LTD. methods to find and select the parts into your design. When you are finished you should have all of the required components in the Object Selector as shown in the following screenshot. A Full list of required components For example, if you wanted to search for a specific stockcode you would need to make sure that the stockcode column was enabled (right click on results list) and then type something like ‘digi ’ to locate the digikey stockcode.
Schematic Capture Placing Objects on the Schematic Having selected the parts we need the next thing is to actually place them on the drawing area – the Editing Window – and wire them together. You’ll notice from the screenshot that we have also split the contents of the schematic into logical blocks of circuitry. This is partly aesthetic but also reduces wiring clutter on the schematic and will allow us to cover the use of terminals to form connections as we work through the tutorial.
LABCENTER ELECTRONICS LTD. I2C circuit section Begin by placing the I2C memory device as follows: Select the 24CL64 device from the Object Selector. Left click on the schematic to enter placement mode. Move the mouse to the desired location for the part, then left click the mouse again to ‘drop’ the part and commit placement.
Schematic Capture Often we need to move parts or blocks of circuitry after placement and now is a good time to cover the different ways in which we can do that. The procedure for this should be familiar to most users; we need to select the object(s) we want to move, left depress the mouse, drag to the new location and finally release the mouse to drop. We can select an object in several ways as detailed below: Choose the Selection Icon and then left click on the object.
LABCENTER ELECTRONICS LTD. Now place the resistor above and to the left of the memory device in the same way as before. Then, simply left click again on the Editing Window to start placing the second 10K resistor just beside the first one. Next, select CHIPRES100R, rotate appropriately (see above) and place two to the left of the memory device in line with the SCK and SDA pins. You can also rotate parts 'live' when in placement mode.
Schematic Capture Components positioned correctly Similarly, you can clear a selection (or group of selections) either by left clicking in empty space or by right clicking in empty space and choosing the Clear Selection option from the resulting context menu Dragging components Remember that you can rotate while moving by using the '+' and '-' keys on the numeric keypad. Wiring Up Having placed all the requisite components we now need to wire them together.
LABCENTER ELECTRONICS LTD. Live Cursor Display The cursor will change as a visual indicator when wiring to show when a wire can be placed, when a wire can be terminated and when a wire is being placed. The basic procedure for placing a wire between two pins is given below, using the connection between the SCK pin of the memory device and the 100Ohm resistor as an example: Move the mouse over the SCK pin on the memory device - the cursor will change to a green pen.
Schematic Capture Armed with the above you should now be able to connect up all of the circuitry, so that your schematic now looks something like the following Schematic section with all parts / terminals placed Remember, Proteus provides visual indicators to help you. If the cursor turns green you can start/stop wire placement. Connectivity by Touch The following basic rules of thumb may be helpful: Iif you are placing the component you can attach to another component, wire or terminal directly.
LABCENTER ELECTRONICS LTD. Terminal connection Power, Ground and NC terminals are the exception to this rule, although there is no reason not to label them; an unlabeled power terminal is assigned to the VCC net and an unnamed ground terminal will be assigned to net GND. A pin connected to the NC terminal is NC and cannot then be connected on the layout.
Schematic Capture Schematic section completed Power Connections Proteus supports a powerful scheme for making power connections implicitly, thus vastly reducing the number of wires on the schematic. There are three main concepts involved that we will discuss in turn below. Hidden Power Pins Almost all relevant parts in Proteus have their power pins hidden (not visible on the schematic).
LABCENTER ELECTRONICS LTD. Managing power nets and power supplies is a very important concept so we’ll experiment a little to re-enforce the point. Exit the Power Rail Configuration dialogue form, right click on the I2C memory part and select Edit Properties from the resulting dialogue form. Next, click on the Hidden Pins button at the right hand side to view the hidden pins and their net assignments. Hidden Power pins in schematic components.
Schematic Capture Changing the Terminal name If we were doing this for real, we would now have to select the VSS/VDD power supply and then click the assign button to map our power net onto the correct supply. If we had simply removed the label from the power terminal (instead of renaming it), it would have been designated to the VCC net and again everything would be done for us. A final point worth noting is that new power supplies are created automatically when you label a terminal with a voltage.
LABCENTER ELECTRONICS LTD. Part Labels and Annotation You should see that all the parts you have placed have both a unique reference and a value. A unique and sequential annotation is assigned to components as you place them on the schematic, although you can re-annotate manually if you need to. You have full control over the position and visibility of part labels – you can change the values, move the position or hide information that you feel is unnecessary.
Schematic Capture This will cause netlist errors when working in the PCB module. If, however, you re-annotate using the new button on the edit component you are guaranteed a unique part reference. The 'New' button will automatically assign a new reference Similarly, the Global Annotator (discussed later in the tutorial) will always avoid duplication of part references. As well as the ability to hide part labels you can move them to a more convenient place.
LABCENTER ELECTRONICS LTD. Timesaving Techniques & Block Editing Armed with all of the basic techniques we can now look at the other blocks of circuitry on the front sheet of the design, practice what we have covered so far and introduce a couple of new timesaving techniques. Let’s start by drawing the dsPIC33 block as shown here: dsPIC33 Circuit section You should be able to tell which components go where by comparing the component names in the Object Selector to the parts labels on the screenshot above.
Schematic Capture Start by rotating and placing a couple of the terminals to the right of the processor. Terminals belonging to the dsPIC33 Now drag a box around the terminals and select the block copy command; this will allow you to quickly copy out three more sets of terminals ready for connection. Right click the mouse when you are finished to exit block copy mode Block copying Terminals Wire up the first connection from pin 4 (RB0) of the dsPIC to the terminal exactly as we discussed previously.
LABCENTER ELECTRONICS LTD. existing terminal label names is available as a drop down list from the Edit Terminal dialogue form (refer to the section on labeling terminals if you need a reminder). Drop down list of Terminals It is highly recommended that you use this where applicable as it avoids the potential to make typing errors. Remember that terminal names donate connections so care should be taken during labeling.
Schematic Capture Completed dsPIC33 circuit If you feel comfortable with the topics we have covered to date, you can skip some of the drawing and load a pre-supplied completed schematic later in the tutorial As a final point it is worth re-emphazing that you can re-arrange or move blocks of objects at any time by tagging a box around them and dragging them to the desired location.
LABCENTER ELECTRONICS LTD. Multi-Sheet Designs and Connectivity It is increasingly common in larger designs to split the schematic into multiple sheets. This serves both to reduce clutter on the schematic and also to organize the design into logical blocks. Proteus fully supports this methodology and we have arranged our tutorial design into two sheets in order to cover the relevant procedures.
Schematic Capture Naming, Ordering and Navigating Sheets Before we lay out the circuitry on this sheet we need to do a little housekeeping. While it’s not necessary it is often helpful to name the different sheets on the schematic and also to order them in some sensible fashion. We can do both of these things via the Edit Sheet Properties command on the Design Menu. The Edit Sheet Properties dialogue form The Sheet Title is what will be displayed and should therefore reflect the contents of the sheet.
LABCENTER ELECTRONICS LTD. Before exiting, your dialogue form should now look something like the following: Edit Sheet properties with the Annotator set For completeness we should also follow this process for the sheet we have just finished laying out. Before we can change the properties of a sheet we must first navigate to that sheet in the design and Proteus provides several ways to do this: From the Design Menu select Root Sheet 2 at the bottom of the menu.
Schematic Capture Use the PGUP and PGDOWN keyboard shortcuts to navigate between sheets. These cycle up and down the sheets respectively, although for a two sheet design they will seem to have the same function! The Design Explorer is also a powerful way to navigate the schematic – this is covered in the Design Verification section of the tutorial and in more depth in the reference manual.
LABCENTER ELECTRONICS LTD. This is what you should see in the Design menu Connectivity between Sheets Now that we have taken care of the naming, let’s navigate back to our blank sheet and lay out the analog circuitry. The following screenshot shows the circuit we need to draw.
Schematic Capture As we can see, there are three logical blocks of circuitry; a reference generator for the ADC module, an analog buffer for the pressure channel and a DC/DC converter to provide 5V from the 3V battery to the other two sections on each pressure sampling time. If you feel that you need more practice then you can use all of the techniques we have covered so far to complete the schematic.
LABCENTER ELECTRONICS LTD. Move the mouse along to the left and then left click the mouse once to place an ‘anchor’. Move the mouse up, left click to place an anchor, then right, left click to place an ‘anchor’ and finally down onto the wire between the op-amp output and resistor. This technique constrains the follow-me algorithm and provides greater control during wire placement. If at any time during placement you change your mind and wish to remove an anchor simple right click the mouse once.
Schematic Capture U4:A and U4:B Start by editing one of the LM358 gates (right click - edit properties) to bring up the Edit component dialogue form. Edit Component Dialogue form for an Op-Amp To swap the gates we are switching the element identifiers (A and B) on a single part (U4). The element field of the dialogue conveniently contains a combo box will all available gates so all we need do is change the element and hit OK to commit.
LABCENTER ELECTRONICS LTD. On schematic this switches the gates over according to the change specified in Edit component. Preparing for PCB Layout Now that we have completed the circuit we need to give some thought to PCB Layout and the information that we are going to provide from the schematic.
Schematic Capture The new package appears in the Edit Component Dialogue form You can also see what the default footprint is for a component at the time you select it from the libraries. At the bottom of the Pick Devices dialogue form a preview of the footprint is shown for the currently selected component. For convenience, components in the schematic often have packagings for more than one footprint.
LABCENTER ELECTRONICS LTD. Clear out the text from the keywords field and then use the filters on the left hand side to narrow down the selection. We will want to select the ‘Discrete Components’ category with type ‘Through Hole’ and Sub-Category ‘Resistors’. We can then select for example the ‘RES40’ footprint and click OK to commit. You should now see that the RES40 is listed as the PCB Package for the component in the schematic.
Schematic Capture You should now see a filtered list of all the resistors on the schematic in a grid view. We could filter further by entering a resistor value. To change the package, simply type in the field at the top and then, much like Excel, drag the value down the other entries in the column.
LABCENTER ELECTRONICS LTD. Hit Apply Changes to commit the change. Some caution is required with bulk editing like this because the software will accept your input without verification. It is however, extremely handy for changing passive footprints en-masse. Connectivity Considerations When we transfer our schematic to the PCB Layout software (netlist) all of the wires and connections are grouped into nets and passed through.
Schematic Capture Any net with a bus is assigned to the BUS net class. Any other net is assigned to the SIGNAL net class. This gives us quite a bit of flexibility during PCB layout as we can define different trace widths, via styles, clearances and so on for each net class. Sometimes, however, we will need a particular set of conditions for particular connections.
LABCENTER ELECTRONICS LTD. If you have completed drawing the schematic follow this procedure now to add the net class; this will already be in place if you have loaded our pre-supplied schematic. If you work through the PCB layout tutorial, you'll see how to configure routing styles and design rules for the net class. Design Verification It is always a good idea to spend a little time checking the schematic before we move through to PCB layout.
Schematic Capture Split programs in Proteus Alternatively, if you do prefer to work with tabs in a single frame you can quickly cycle between tabs using the standard Windows CTRL+TAB keyboard shortcut. Once launched and in its default mode, you should see a dialogue form that looks a little like Windows™ Explorer. The left hand pane displays the sheets and the right hand pane displays the contents of the currently selected sheet.
LABCENTER ELECTRONICS LTD. The Design Explorer The Design Explorer has two distinct modes; partlist mode and netlist mode. The former will show a physical representation of the sheets (the components on a sheet) whilst the latter will show how the design is organized into groups of connections (nets). You can switch between the two modes via the Design Explorer Icons. Design Explorer icon bar Since we are in partslist mode by default let’s look at what we can do from there.
Schematic Capture The Design Explorer's context menu This will zoom the schematic around the part and tag it for editing. Simply right click on the highlighted part and select Edit Properties in the normal way. We could follow the procedure that we discussed earlier to find a suitable footprint but in this case take it as a given that it is named LED and simply type in LED in the PCB Package field of the dialogue form.
LABCENTER ELECTRONICS LTD. We can also use the Design Explorer to investigate the connectivity of the schematic – for this we need to switch into netlist mode via the icon at the top left of the dialogue form. This will give us a view as shown below. The Netlist icon The first point to note is the net names which, as we discussed earlier, are either named according to terminal or label or simply assigned a number if the net consists only of wire connections.
Schematic Capture product variant. Start by creating the new variant from inside the Design Explorer and naming it budget. Notice that this gives us a new column in the component grid. Each entry currently has a tick which indicates that the part is fitted on the board for the variant. If we click on the entries for the budget column on U3 along with R5, R6 and R7 they will change to a cross. Clicking on the apply changes button at the top will then set these parts to be excluded from the BUDGET variant.
LABCENTER ELECTRONICS LTD. We could also have done this by individually editing the parts and checking the exclude from Active Variant box on the Edit component dialogue. You need to be very careful when working this way to ensure that you have first selected the variant you want from the combo-box at the top. Finally, you can quickly manage variants for a group of parts by first dragging a selection box around the parts and then showing selected in the search tab of the design explorer.
Schematic Capture The section at the top of the report is taken from the Design Properties Command, which you can find on the Design Menu, and modify accordingly. The Edit Design Properties dialogue form If your Active Variant is not the base design then the Assembly Variant will also be included in the header block: Bill of Materials categories control the grouping of parts in the report and work by comparing the reference prefix of the components.
LABCENTER ELECTRONICS LTD. Section for editing The Bill of Materials information Let's work through a couple of examples. First, we'll order all our parts from Digikey so let's specify a supplier in the BOM. To do this, we need a new field.
Schematic Capture BOM Fields Launch the BOM Field editor by clicking on the Add button underneath the Fields listing. The 'Add' button enters the Edit BOM Fields dialogue form If you are adding a field that you have previously defined then you select it from the drop down combo box at the top of the dialogue form. However, since we have not defined a SUPPLIER property before click on the new button to create a property definition.
LABCENTER ELECTRONICS LTD. Adding a New BOM field There are two non-editable fields that you can apply namely .placed and .name. The placed field will show whether the part is placed on the layout (component or solder side) while the name field simply populates with the component names. Property name is SUPPLIER, description can also be Supplier and Type is String.
Schematic Capture easier to use find/replace. Left click on the supplier column and then either use the CTRL+F shortcut or click on the find/replace icon. Find and Replace form Leave the find edit box blank (we are entering data into blank fields), type Digikey in the Replace edit box and make sure that the current column only checkbox is selected. Replacing blank fields with 'DigiKey' Hit the replace all button to enter the data.
LABCENTER ELECTRONICS LTD. The blue indicates that the changes have not yet been committed; if you have made a mistake the clear pending changes button will revert your edits. When you have reviewed your changes use the Apply Changes button at the top to commit. Applying BOM Changes If you switch back to the HTML View of the report you should now see the information you entered in the report.
Schematic Capture The BOM updates live with any changes in the schematic This process can of course be repeated as required with other properties such as RoHS, MoQ, Lead Time, etc. More practical examples and detail can be found in the Bill of Materials reference manual (accessed via the Help Menu in BOM Module). Note that property changes are applied locally to the schematic components and not to the library parts.
LABCENTER ELECTRONICS LTD. You can also export the schematic directly in PDF format from the Output Menu (no driver installation required). The current schematic is now ready for board layout so if you have purchased a Proteus PCB Design package you can move straight onto the accompanying tutorial booklet for PCB Layout.
Schematic Capture The Import Part dialogue with a part loaded. Technically, the import works with PADS Library V9.x files, meaning that the import will work with any supplier who can generate a fileset in this format. To import a library part 1) Download the part you want onto your computer. This will almost always be in a zip file. 2) If the part doesn't come from a vendor source that we directly support (see here) then you'll need to extract all the files from the zip into a folder of your choice.
LABCENTER ELECTRONICS LTD. 5) Choose the appropriate file to load. This will normally be a zip file if the vendor is selectable in the file selector or a .p file if you've had to extract the parts into a folder. 6) Review the parse log and the previews to make sure everything looks good. Use configuration settings if need be to fix problems. 7) Use Import Part and follow the wizards to bring first the footprint and then the component into Proteus.
Schematic Capture current project ready for placement. You should have an end parsed result that looks like the following: What you are actually doing at this last stage is running the Make Package tool to create the footprint and then running the Make Device tool to make the schematic component. The areas where input may be required from you are in the library choice and the description and categorization of the part. For most complex devices, you can also find a BSDL script from the manufacturer.
LABCENTER ELECTRONICS LTD. The MCP23008 Completed Let’s begin by placing the component body as follows: Select the 2D Graphics Square icon and make sure the component style is selected in the Object Selector. Left click once on an empty area of the schematic to begin placement.
Schematic Capture Move the mouse until the rectangle is around the size of the part that you want. It’s better to make this slightly larger than might be required as we can easily resize it later. Left click again to complete placement of the graphic. Proteus supports a powerful graphics style system of local and global styles and the ability of local styles to follow or track global styles that allows you to easily and flexibly customize the appearance of your schematic.
LABCENTER ELECTRONICS LTD. 1. Left click the mouse on the schematic to begin placement. The small cross at the end of the pin indicates the side of the pin that will be wired to so it is important that this is outward facing. 2. Move the mouse so that the other end of the pin touches the edge of the component graphic and left click again to place 3. A new pin is automatically primed for placement so simply move the mouse down slightly and left click to place again.
Schematic Capture 4. Repeat the process down the left hand side of the component graphic using the completed screenshot as a reference. Right click to finish placement. 5. Click on the X-Mirror icon to point the pin in the opposite direction ready for placement down the right hand side. 6. Repeat as of stage 3 to place the pins down the right hand side of the component. 7. Right click the mouse when you are finished to exit pin placement mode.
LABCENTER ELECTRONICS LTD. The body of the MCP23008 The actual positioning of the pins is of course somewhat aesthetic and you may prefer to have different groupings to those we have chosen. Now that we’ve placed the pins we may need to adjust the size of the component body. If you need to adjust the size of the component body to better fit.
Schematic Capture Type in the name of the pin (SCL), the default pin number (1) and the electrical type (INPUT). You can use the other options to control visibility but for our purposes the defaults are fine. Hit the Next button at the bottom to switch to the next pin in the list and repeat the process – the schematic will update to show which pin you are editing. If you are unfamiliar with this part and don’t therefore know the electrical type of the pin simply leave it as the default Passive type.
LABCENTER ELECTRONICS LTD. Hit the OK button when you are finished. You may have noticed that there is a significant omission from the schematic part as we have drawn it so far, namely that there are no physical power pins on the device. Since we do not need to wire power nets explicitly we do not need a physical pin for the component. We need only ensure that the power pins are handled correctly with respect to the physical PCB footprint and we’ll discuss this in more detail in the next section.
Schematic Capture This presents us with the Make Device dialogue form, where we can customize the part. All fields throughout this wizard have context sensitive help associated with them, accessed by clicking on the question at the top right and then on the field in question. However, the only items we need to deal with here are the Device Name and the Reference Prefix. The device name should be MCP23008 and the reference prefix should be ‘U’.
LABCENTER ELECTRONICS LTD. There are several points of note here. Firstly, the pads in the preview which are white are deemed to be mapped onto component pins. This has happened as we have correctly specified the default pin numbers when we edited the pins earlier on (pad name maps onto pin number when present). If we had chosen to leave the pin number fields blank we would have to map all of the pins in this dialogue form.
Schematic Capture terminals with the correct names. If you are in any doubt regarding power nets and connections please see the section earlier in the document on powering the circuit or consult the reference manual. Click on the Add Pin button underneath the grid, type VSS to name the pin and then repeat the process for the VDD pin. Remember that connections to these virtual pins are made according to their name so make sure that you name them correctly.
LABCENTER ELECTRONICS LTD. We should see that all the pads on the footprint are now highlighted, indicated that the part is fully packaged. Simply hit the ‘Assign Package’ button at the bottom of the Visual Packaging Tool to commit and return to the Make Device dialogue form. It is possible (and extremely useful) to have more than one packaging for a given component. We could, for example, follow the exact same procedure to add a DIL18 footprint to the component.
Schematic Capture Let’s assume we want to add a property for RoHS compliance. Start by clicking on the New button at the bottom left and then clicking on Blank Item. On the right hand side fill out the name as ‘ROHS’ and the description as ‘RoHS Compliant’ The next field is the data type which in our case is a simple Boolean (Yes/No) – select this from the drop down list. Change the Default value to be Yes and leave the visibility defaults as they are. If you want to add more properties (e.g.
LABCENTER ELECTRONICS LTD. Attaching a Datasheet This screen allows us to attach a datasheet to the part we are creating. To do this we would need to enter the filename for the datasheet and then configure the path as required. As we don’t have a datasheet handy we’ll ignore this step but the following screenshot shows an example of how we would set it up. Adding a datasheet to the component The main advantage of working through this step is to have the datasheet handy when you place the part.
Schematic Capture Indexing and Library Selection The final screen allows us to categorize our part and choose which library we will place it in. As we have seen earlier in the tutorial the part description and the categories are used as filters when finding and selecting parts from the library so it is worth giving some thought to your description. An example of what you might enter is shown in the following screenshot.
LABCENTER ELECTRONICS LTD. Edit Component for the MCP23008 It is also possible to create multi-element parts in Proteus. While beyond the scope of this tutorial these are covered in the reference manual.
PCB LAYOUT TUTORIAL Introduction The purpose of this tutorial is to familiarize you as quickly as possible with the main features of the PCB Layout, to the point that you can use the package for real work. Users with modest computer literacy should find it possible to learn the package and produce their first board within a day or two. The tutorial proceeds by taking you through worked examples involving all the important aspects of the package including: Basic techniques for placement and routing.
LABCENTER ELECTRONICS LTD. From the home page in Proteus click on the Open Sample button, filter to the tutorials category and then select the dsPIC33 Recorder (schematic only) sample. Opening a Tutorial sample design This will open the tutorial project with the completed schematic from the Schematic Capture tutorial. We can start the PCB layout module from the application module toolbar at the top of the Proteus application.
PCB Layout However, when a new object is selected from the Object Selector the Overview Window is used to preview the selected object – this is discussed later.
LABCENTER ELECTRONICS LTD. At the left hand side is the Selection Filter which allows you to configure both the layers and the objects that will be selected in the current operating mode. Typically, the default rules will suffice and this serves simply as a convenient override where you may wish finer granularity in selection at a given time. The Layer Selector combo box also determines the current layer or layer set and also applies to the placement of PCB objects.
PCB Layout The co-ordinates can be in imperial or metric units as set by the Metric (default key mapping 'M') command. You can also set a false origin using the Origin command (default key mapping 'O') in which case the co-ordinates change colour from black to magenta. The dot grid on the Editing Window can be toggled on and off using the Grid command, or via its keyboard shortcut (by default this is ‘G’). The spacing of the dots normally reflects the current snap setting, except when zoomed out.
LABCENTER ELECTRONICS LTD. Display Options Proteus is capable of harnessing the power of your computers graphics card to speed up operation and provide true layer transparency on the layout. However, as not all machines have sufficient graphics cards the software is also capable of using Windows to perform display and graphical operations. The three modes of operation are called: Windows GDI Mode. OpenGL Hardware Accelerated Mode.
PCB Layout When using hardware acceleration, Proteus places special significance on the current layer, giving it a higher opacity than other copper layers on the layout. This means that objects on the layer you are working are clearly visible and that objects on the other layers of the board are dimmed. You can control the relative opacity of both the current layer and the background layer(s) using the sliders on this section of the dialogue form.
LABCENTER ELECTRONICS LTD. The animation interval controls the frame rate of the animation and therefore the smoothness of the fade-in/fade-out effect. Normally, the default value for this is suitable. The attack rate specifies the speed at which an object will go from ‘fully off’ to ‘fully on’ whilst the release rate allows you to adjust the speed at which an object will return from ‘fully on’ to ‘fully off’. These options are only available in hardware accelerated modes.
PCB Layout Finally, if you are working in OpenGL or Direct2D mode, the Resist/Paste Mask Display options allow you turn on full display of these layers on the board, showing the resist and paste coverage around pads and vias. When enabled you can change the intensity of these layers by switching to the Thru-View settings tab and adjusting the appropriate slider controls.
LABCENTER ELECTRONICS LTD. Component Placement Proteus 8 works with a live netlist so the PCB Layout module already has much of the information we need to start the layout process. In particular, we have specified which footprints are associated with each schematic symbol and Layout module can therefore pre-select these for us ready for placement. This brings us to an important distinction in the software; the difference between a component and a package.
PCB Layout Package Mode When placing, routing and laying out a PCB based on a schematic (such as with this project) we will be working with components. The Board Edge Before we can place the components on the board we need to define what shape and size the board will be. For our project we need only a simple rectangular board edge but we do want to control the dimensions of the board (115mm wide and 40mm high).
LABCENTER ELECTRONICS LTD. 2D Box Icon Next, change the Layer Selector to the Board Edge Layer. Board Edge layer selected Move the mouse to the approximate starting point (e.g. top left) for the board edge. Now, hold the mouse still and press the ‘O’ key on the keyboard to set the origin of the co-ordinate system to the point under the mouse. This will be reflected in the co-ordinate display at the bottom right of the application. Left click to start placement and drag in the normal way.
PCB Layout Placed board edge which is always Yellow If you would like the board edge to be a specific size, edit the board edge graphic and set the dimensions to your requirements: Finally, restore the co-ordinate system to its global origin by pressing the ‘O’ button on the keyboard again. The colour of the co-ordinates will change from Magenta to black to indicate that the global origin is now in use.
LABCENTER ELECTRONICS LTD. Select Delete from the context menu Complex board edges can be directly imported onto the board edge layer using the Import DXF function on the File Menu. Layer Stackup and Drill Spans Before we begin layout, we need to define our layer stackup and specify which drill ranges are valid for vias. Start by launching the layer stackup dialogue from the Technology menu. We will be making a simple two-layer board with a single core between top copper and bottom copper.
PCB Layout Similarly, on the drill spans tab there are no additions required, since our target PCB is 2-layer only. However, to provide some context to the topic, the following are some screenshots from a 6-layer stackup. The most important thing to remember is that for multi-layer boards, configuration of this dialogue is really important. We'd encourage you to read through the dialogue level help and if you are unsure about anything, the topic is discussed in detail in the reference manual.
LABCENTER ELECTRONICS LTD. Work Area, Co-ordinates and Snap It is likely that your board edge covers a small portion of the Editing Window, which is less than ideal as all of the work will be taking place inside this area. We can of course zoom into the area (point the mouse and roll the middle mouse button or use the F6 key) but the default zoom level is designed to show the entire Work area. The Work area is the area inside the dark blue box at the edges of the Editing Window.
PCB Layout This is a very important technique worth mastering as it allows you to easily block select and then perform actions on (move, delete, etc.) groups of objects. Having centered our board edge in the Work area we can shrink the work area to a suitable size. From the Technology Menu, select the Board Properties command and then set to something like 175mm by 100mm, such that the resulting work area forms a reasonably boundary to the board.
LABCENTER ELECTRONICS LTD. 2) Move the mouse towards the bottom left of the board edge. Roll the middle mouse button as required to zoom in for more accurate placement. 3) Left click the mouse to commit placement. The co-ordinate display will now provide values relative to the position at the bottom left of the board by default, and relative to any specified temporary origin when set. Remember that you can also toggle metric or imperial units via the command on the View menu or the ‘M’ keyboard shortcut.
PCB Layout A useful trick once we have specified our origin is to use the Goto-XY command on the View Menu to move the mouse to the exact location we want to place position sensitive parts. This command will automatically switch between X-Y or RadiusTheta depending on whether you are in polar or cartesian co-ordinates. Proteus has a default grid and will snap objects onto the grid, making it easy to form connections and control board layout.
LABCENTER ELECTRONICS LTD. dsPIC33 board un-routed Placing a component in the Layout is very similar to that in the schematic. Start by selecting Component Mode from the left hand side icon set and then ensure that the layer selector is set to Component Side – we won’t be placing any solder side components in this project. Component mode and the Layer Selector The object selector by default will contain a list of all parts to be placed.
PCB Layout Components selected in Proteus and shown in the Layout - Component 'tagged' mode This allows you to select parts of your design in the schematic and then work on placement and routing of them in PCB Layout without the clutter of other components in the object selector. Our layout however is relatively simple so we will work globally (all of the components available in the object selector). Let’s get the AA battery holder down first on the right hand side of the board.
LABCENTER ELECTRONICS LTD. dsPIC33 board as you see it having placed all the components From the View Menu, select the Edit Layer Colours/Visibility command. The resulting dialogue form shows all the layers in the layout with colour and visibility configuration options. All we need do here is deselect the checkbox for the ‘Vectors and Ratsnest’ layer and exit the dialogue.
PCB Layout You may find that you need more control over the positioning in order to move connector J2 into position. Remember that objects are linked to a snap grid so all we need do is reduce the snap grid via the options on the View Menu, for example to 1mm snap.
LABCENTER ELECTRONICS LTD. J1 and J2 placed with the CRC showing 1 connection missing A missing connection is essentially a wire connection on the schematic that has not been routed on the layout. It follows that when the board is completed the connectivity status should report no missings. We'll look at this is more detail when we discuss routing later in the tutorial.
PCB Layout If you are placing components in a high density area where routing space is at a premium you can hide the part reference via the edit component dialogue form (right click on the part and select edit properties from the resulting dialogue form). Generally speaking you have two options for placement of the board.
LABCENTER ELECTRONICS LTD. The middle mouse will zoom you in and out as you place components (as will keyboard shortcuts F6 and F7) Right clicking on a component once placed will present a context menu option, allowing you to move, rotate or delete the part. Changing the snap settings to a finer grid will allow more accurate positioning at the expense of more precision being required to select the part. If you place a part in an illegal position (e.g.
PCB Layout The nomenclature of pads in the PCB Layout is designed for easy reading and tends to follow the following format: - - Units are in imperial unless prefixed with an ‘M’ so for example a C-40-15 is a circular pad with a 40th diameter and a 15th hole and a C-200-M3 is a circular pad with a 0.2in diameter and a 3mm hole. Our spec requires a pad with a 0.18in diameter and a 3mm hole, which we can see does not exist in the pre-supplied set.
LABCENTER ELECTRONICS LTD. 4) The diameter of the pad is 180th or 0.18in.The drill mark is the size of the mark output in a drill plot, 30th would be fine. The drill hole needs to be 3mm and the guard gap should be th enlarged to 20 . The guard gap (or solder mask expansion) is the amount by which the pad diameter is expanded on the resist plot.
PCB Layout Moving a selection of circuitry Remember that you can resize the selection box to include or exclude items using the drag handles if you don’t get the right size the first time. Once you’ve cleared some space, go to the circular PTH pad icon again, select theC-180-M3 Pad style and place two at the top and the bottom left of the board. Mounting holes placed We want to position the third mounting hole above the battery and in a reasonably accurate position.
LABCENTER ELECTRONICS LTD. the mouse up and right from the bottom of the board edge until the co-ordinate display reads correctly (you may need to switch into Metric units using the ‘M’ shortcut key toggle). If required, we can move the DC/DC converter circuitry as before, then switch back to pad mode and place the final mounting hole at the correct co-ordinates.
PCB Layout Opening a sample project Design Rules and Net Classes Now that we have a placed board we need to configure the software to obey any design constraints or electrical considerations relevant to the layout. We can do this largely from a single dialogue form called the Design Rule Manager. Start by launching this dialogue form now from the Technology Menu in the Layout module.
LABCENTER ELECTRONICS LTD. Design Rules The first tab of this dialogue form allows us to configure constraints and minimum clearances for the layout. We have a DEFAULT rule loaded which must apply to all layers and all net classes, providing a set of clearances between objects equivalent to manufacturing guidelines. The Design Rule Manager This rule and these clearances are created automatically for each layout in order to provide a minimum set of constraints for a board.
PCB Layout Default clearance settings in the DRC manager The graphics and edge clearances are fine at the default values. Note that the edge/slot clearance field defines the clearance for power planes against the board edge. In addition to these clearances there is a board global rule for Resist-Trace clearance. This rule enforces a clearance between the solder mask and copper and is intended to prevent exposed slivers of copper on the manufactured PCB.
LABCENTER ELECTRONICS LTD. Net Classes This is the place where we configure trace and via styles and control which layers we route on when auto-routing the board. The selector at the top allows us to switch between different net classes and configure each separately. Let’s start with the POWER Net class, which should be the default selection.
PCB Layout Our board is not likely to be complex enough that this will be an issue but we'll set the neck style to 15th so that we can practice. Given that we don’t really have current constraints the choice of vias is a tradeoff between the higher manufacturing costs of smaller vias and the decreased routing quality of large vias. For the current this circuit is dealing with and for a standard 1.6mm FR-4 support plated with 35um copper, vias with the standard 0.4mm hole are a good compromise.
LABCENTER ELECTRONICS LTD. Let’s move on to the next net class in the selector; the ANSW class. You may remember that we specifically named this net class in the Proteus Getting Started Guide in order that the 5V switched power supply for the analog circuitry (the output of the DC/DC converter) could be handled separately in the layout.
PCB Layout Keepout Areas We can also introduce tracking constraints by limiting areas in which tracks can be placed. A good example of this is the crystal towards the bottom left of the layout where we do not want tracks under this area. To form a keepout area, start by selecting the 2D Box graphic icon and changing the layer selector to be keepout.
LABCENTER ELECTRONICS LTD. First DRC warning Checking the box on the dialogue form will prevent it from appearing in the future. If you left click the mouse on the DRC section of the status bar a small window will appear providing information on the errors. You should see that they are of type PAD-EDGE as the pads of the th crystal are closer to the keepout graphic than the 15 specified in the Design Rules. Displaying DRC errors We have two options here: 1) Ignore the DRC errors.
PCB Layout Correctly placed Keepout The default for the keepout is that it applies to all layers. However, after placing the graphic on the keepout layer, you can right click change it to apply only to a specific copper layer from the resulting context menu. This can be very useful on more complex or densely packed board. We have a similar problem around the temperature/humidity sensor (U3).
LABCENTER ELECTRONICS LTD. 2) Place a rectangle around the bottom half of the IC as shown below. U3 with a Keepout This time we cannot move the keepout to remove the DRC errors as the positioning is sensitive. Instead we can manually override the errors by launching the DRC dialogue, right clicking and selecting the Ignore option from the resulting context menu. Ignoring DRC errors Design Rooms Alternatively, we can designate this area of the board to have different design rules from everywhere else.
PCB Layout Setting up a Design Rule Room Now that we have the room set up we need to change the design rules inside it. Go back to the design rule manager and find the room definition. You'll notice when you select the room in the tree that the right hand side shows you that the default rule but shaded in a light grey. This indicates that the default rule applies in the area but was defined at a higher level.
LABCENTER ELECTRONICS LTD. Routing the Board Having configured the board constraints we can now move on to actually making connections and routing the board. Teardrops Teardrop functionality is included in the Advanced Feature Set and requires a license for PCB Design Level 2 or higher. Placing teardrops at the connection point between track and pad is often useful in preventing drill breakout during board manufacture. We can configure teardrops from the Set Teardropping command on the Technology Menu.
PCB Layout Note that the creation of a teardrop connection is dependent on the design rules. If making a teardrop connection would violate one of the design rules then it will simply not be created. Once configured teardrops connections will be made dynamically as we complete routes in the sections below. Placing a Route Manually Before we start, we will want the ratsnest lines turned back on.
LABCENTER ELECTRONICS LTD. mounting hole and then track into the small SMT pad. Instead, we will route this down and across the bottom of the board to a more convenient ground connection. The Layout module features a sophisticated 'follow me' routing algorithm for manual routing in which the route being placed will follow the path of the mouse as best it can while still obeying all of the design rules for the board that we set up previously.
PCB Layout Connecting to JP2 Pin 1 Once we are underneath the jumper we can change direction and move upwards towards the destination pin Connecting the trace to the pin Finally, we can click left over the pin to finish placing the route. This will both commit the route and remove the ratsnest line corresponding to this connection.
LABCENTER ELECTRONICS LTD. Finished route from J2 pin 4 to JP2 pin 1 Note that we did not need to select the width of track to route with as we configured this in the previous chapter. The PCB Layout recognizes that we are routing a track on the GND net, th applied the rules for the POWER net class and selected the specified 25 track style for us. Manual routing is probably the most common action you will perform with the software and it is vital that you understand how it works.
PCB Layout Panning and Zooming While placing a track you can use the middle mouse wheel (or F6 & F7 keys) to zoom in and out during routing. Panning will happen seamlessly when the mouse is at the edge of the Editing window during routing. Placing Anchors The follow me routing algorithm will move the track being placed according to the way you move the mouse. If you want a track to follow a particular path then you need to help by left clicking whenever you change direction.
LABCENTER ELECTRONICS LTD. Object Hugging Since the design rules are all live during placement it is quite easy to hug a track to another track or to wrap a track around an object. If the mouse is over an object where the route being placed cannot travel then the route will follow the mouse path as closely as it legally can, essentially hugging the barrier object. Abandoning a Route - If you want to abandon the route at the last committed (solid) segment then right click the mouse.
PCB Layout Deleting a Route Once the route has been completed we can delete either the full route or a specific part of the route if we are not happy with the placement. Let’s assume that we were not happy with our placement of the last piece of track (upwards to pad 1 of JP2). Start by right clicking on the track over this segment of track. This will highlight the entire track and the Delete Route option near the top would then remove the complete trace from the board.
LABCENTER ELECTRONICS LTD. Next, right click on the highlighted segment and select the Delete Route command; this will delete only this segment of the route. Deleting a trace via the context menu Finally, zoom in, change the snap settings if need be and replace the route from the existing track to the terminating pad.
PCB Layout Editing a Route It is often the case that routes need to be nudged or moved into position after placement and we definitely don’t want to be deleting and replacing routes or parts of routes all the time. To take an example, let’s move our track lower down the board a little, towards the bottom board edge. Start by right clicking on the horizontal section (segment) of the track; this is the section we want to move.
LABCENTER ELECTRONICS LTD. Selecting the Bottom Copper layer The processor is some distance from the connector and the easiest path would seem to be down and along the bottom of the board. Begin placing the track by left clicking on pin 1 on the connector and then moving the mouse downwards Routing on Bottom Copper When we get near the bottom of the board, left click the mouse to place anchors and guide the mouse to the left.
PCB Layout Routing to the left of the right hand pads of the Processor We now need to place a via before we can connect to the SMT pad on top copper. As described above you can either double click the mouse at the point you wish to place the via or you can press the spacebar to float a via and then guide the placement point with the mouse before left clicking to commit.
LABCENTER ELECTRONICS LTD. In order to make the connection, we can then route vertically underneath the pads and make a short 45 degree track before double clicking to place the via and complete the connection. Routing a 45 degree angle Of course there are many ways we can route the board and personal preference also plays a part.
PCB Layout Select the Autorouter from the Tools menu The resulting dialogue form is reasonably complex but all fields have context sensitive help associated with them. You can also find additional information about the various type of routing pass in the reference manual. For our purposes (and indeed for most boards of small/medium complexity) the defaults are more than adequate.
LABCENTER ELECTRONICS LTD. Everything will happen quite quickly from this point onwards but you should see routing progress on the status bar as the engine works towards completion. Once the board is complete there are two immediate points of note: The auto-router has preserved those tracks that we placed manually and has not ripped and replaced them whilst working on the rest of the board. Once the autorouter has completed a final pass is made to corner the tracks.
PCB Layout Selecting two tracks for length matching Next, right click on one of the tracks and select the match route lengths command from the context menu. If successful you will see track segments added in a serpentine pattern to the shorter route in order to match its length with the longer route. Matched lengths Full configuration of the added length can be found on the Configure Length Tuning command on the Technology Menu or from the context menu.
LABCENTER ELECTRONICS LTD. Configuring Length Matching Options. Other points to note about length matching. You can match multiple tracks at the same time (e.g a bus). The length of a track is shown on the status bar when it is selected. If a track is part of a group that has been length matched the target length is also shown in the status bar when you select the track. The pre-production check will test all matched tracks against their target length and warn you if their length has changed.
PCB Layout When toggled on the selection applies only to the layer specified in the layer selector The other buttons represent different object types (tracks, components, graphics, etc.) and determine whether those object types are selectable. Hover the mouse over an icon for a tooltip description.
LABCENTER ELECTRONICS LTD. Select the entire board Next, deselect those objects that we do not want to delete, namely everything apart from tracks and vias. The tagged items will update automatically to provide visual confirmation of what is selected.
PCB Layout Notice that Only the traces on Top Copper are Selected Finally, use the icon at the far right of the selection filter to deselect items that are only partially inside the tagbox; in our case this will deselect the track we manually placed from J2, pin 4. Tag box toggle We can now simply hit the delete button on the keyboard or right click inside the tagbox and select Block Delete icon to remove all the top copper tracks.
LABCENTER ELECTRONICS LTD. Start by invoking the autorouter dialogue form (Tools Menu), switching to Interactive mode and then selecting the Begin Routing button. Entering the router interactively A command window will open at the bottom of the Editing Window, which will allow us to direct the routing progress interactively. The PCB Layout provides a rich command set to control routing, including such things as bend radius for mitering tracks and fanout length and direction from SMT pads.
PCB Layout Next, let’s assume that we want to route all the VCC connections. Select the VCC/VDD=POWER net in the Object Selector and click on the small ‘T’ button above the Object Selector to highlight all the connections on that net. Finally type in ‘route 5’ to route these connections. Clicking anywhere in the Editing Window will deselect the currently tagged items. When the focus is in the Editing Window you can also use the middle mouse (or keyboard shortcuts) to zoom in and out in the normal way.
LABCENTER ELECTRONICS LTD. completing routing. You can do this by left clicking on an empty area of the Editing Window to clear the selection. Typing route 25, followed by clean 2 should see the board completed Finally, we can reduce trace length by typing recorner diagonal as a finishing touch. Do note that there is much more flexibility in the command set than that shown in this tutorial, both in the number of commands and in the parameters that control the command actions.
PCB Layout Live Netlisting First, let’s delete the J2 connector on the schematic. Switch to the Proteus tab, right click and select delete object from the resulting context menu. Deleting a component in Proteus Now switch back to the PCB tab. Note that the J2 part has been dimmed to show that it is not present on the schematic and that the connectivity status shows that we have pending changes (we are out of sync).
LABCENTER ELECTRONICS LTD. Undo and Redo icons If you click on undo while in the PCB Layout tab but the undo action applies to the schematic you will be prompted to confirm the operation. In our case, we do want to bring back the connector so accept the prompt to return the PCB to the original state. This is a simple example of a change which affects objects already placed on the layout.
PCB Layout Having turned live netlisting off, let's repeat the same procedure to see the difference. Switch to the schematic tab, delete the connector and then switch back to the PCB tab. This time the connector on the PCB remains present and the connectivity status reports that the layout is locked and out of sync. Status bar messages when 'out of sync' This means that we have not loaded the changed netlist and cannot work on the layout until we bring the netlist across.
LABCENTER ELECTRONICS LTD. PCB to Schematic You can re-annotate the board either manually (editing the part reference labels) or globally from the automatic annotator command on the PCB Layout tools menu. Launching the Automatic Annotator When live netlisting is on, this will automatically reflect to the schematic. With live netlisting off, the schematic will update and the layout will then lock as the netlist has changed and needs to be manually passed through to the layout.
PCB Layout Power Planes and Slots If you switch back to the layout tab we will continue the layout phase of the project. To minimize track impedance we are going to place a power plane covering the entire board. Placing Power Planes This is actually the easiest type of power plane to place and is available in all levels of the professional software.
LABCENTER ELECTRONICS LTD. Power Plane Generator Dialogue form After you exit the dialogue form you should see that the power plane is generated across the entire board. Power Plane has flooded the entire layer The clearance from the zone to the board edge is defined by the Edge/Slot design rule. We can change this via the Design Rule Manager on the Technology and the zone will re-generate to the new clearance when we have finished.
PCB Layout Since you can set a new design rule per layer it is possible to have different clearance rules for power planes on different layers Stitching Zones In Proteus you can auto stitch / shield a power plane. This is done by right clicking on the edge of a power plane and select the relevant option: Nesting and Islands There are several additional configuration options available to us now that we have placed the zone.
LABCENTER ELECTRONICS LTD. Zone icon in the Selection Filter Next, zoom in and move the mouse over the edge of the zone, right clicking the mouse when the zone is shown as active under the mouse. Select the Edit Properties from the resulting context menu.
PCB Layout Suppress Islands An island is defined in the PCB Layout as a block of copper or zone area in which no valid connections can be made. When checked, the layout will remove all such blocks from the board, leaving only areas of copper with connections. Allow Nesting It is quite common, particularly with larger boards, that the flow of a zone will encounter an obstacle through which it cannot pass. When checked, the zone will jump over the obstacle and continue flowing across the board.
LABCENTER ELECTRONICS LTD. removing the keepout. You’ll need to either switch to Selection Mode or to change the selection filter such that you can select 2D Graphics Deleting a Keepout area While we are here, we might as well move across and repeat the process by deleting with the other keepout around the crystal. Returning to U3, we now need to outline the cutout region.
PCB Layout Right click on any line and select Edit Properties from the resulting context menu. Uncheck the Follow Global checkbox, change the width to be 20th and then apply to all tagged graphics. Changing multiple objects at once We will cover how to specify MECH1 as the slotting later in the documentation in the section on manufacturing outputs.
LABCENTER ELECTRONICS LTD. Basic Navigation The first thing we can do is view the board from different preset angles. Five preset views are supplied: top view, front view, back view, left view and right view and these are accessible via any of the following methods: Menu options on the View menu in the 3D Viewer From the navigation toolbar at the bottom of the 3D Viewer From keyboard shortcuts F8 through F12 whilst in the 3D Viewer.
PCB Layout Board properties dialogue form Custom Views The next logical step is to be able to customise the view. This works conceptually by ‘attaching’ the mouse to the camera such that as you move the mouse the camera moves to the area of the board that you are interested in. You can invoke the Navigation mode either from the View menu, the crosshairs icon on the Navigation toolbar or simply by clicking the left mouse button.
LABCENTER ELECTRONICS LTD. mouse button the camera will follow the mouse around the current view of the board as normal. Try this now, experimenting with different views of components on the board. Remember that, if you are struggling to get the view you want you can use the keyboard shortcuts or navigation toolbar to return to one of the preset views. You should find however, that with only a little practice you become quite proficient at navigation. To summarise: Left click enters navigation mode.
PCB Layout 4) Type the name of the STEP file and then the rotation and offset required to align the STEP file with the pads on the board. For geometric models, the difference is basically that you describe the part in terms of size and shape via a simple scripting language. This is covered in the reference manual. Live Update Like any other module in Proteus, the 3D Viewer will update live as changes are made to the PCB layout module.
LABCENTER ELECTRONICS LTD. Board Output Options Last, but by no means least, we come to the crucial business of reproducing the pretty on screen graphics on paper or film. Under Windows, most hard copy devices are supported through the normal Windows printer drivers. Additionally, we supply our own drivers for penplotters, Gerber photoplotters and Excellon NC drill machines.
PCB Layout Output for Manufacture The PCB Layout module provides two main output options for board manufacture: Traditional Gerber/Excellon (available in all professional versions). ODB++ Manufacturing Output (available in Advanced Feature Set only). From a user interface perspective both options are very similar but from a manufacturing perspective, the ODB++ option provides far more information than the older Gerber formats.
LABCENTER ELECTRONICS LTD. The Gerber / Excellon Output dialogue form The options in the top section of the dialogue form are self-explanatory but there are some points of note regarding the rest of the configuration options. The software attempts to populate the layer set with those layers used on the layout but this should always be verified. One of the most common problems with manufacture occurs when the manufacturer is not supplied with the full board information.
PCB Layout Select the required slotting layer The Bitmap/Font Rasterizer option controls the thickness of trace used to render bitmaps and, more importantly, power planes. The higher the resolution the better tonality of the resulting bitmaps but the larger the files. It is also possible that some manufacturers have a minimum width requirement and in such cases it may be necessary to reduce the DPI settings to conform with this. Generally speaking however, the default settings are fine.
LABCENTER ELECTRONICS LTD. APPENDIX: Creating New Packages Library Importer Proteus comes pre-supplied with a large quantity of footprints, and we have seen previously how to select and place these parts on to a layout. However, it may be necessary at times to create your own custom footprints or symbols – also a simple task with Proteus – and this process is detailed below.
PCB Layout Start by selecting rectangular SMT mode. We want a pad 0.5mm by 1.8mm that should already exist as M0.5x1.8. The Pad used in the M0.5x1.8 If the pad style does not exist you can easily create it as discussed earlier in the tutorial (Click on the ‘C’ button above the Object Selector). Make sure that the Layer Selector is on Top Copper and place one of the pads in the usual way. Right click to cancel placement immediately after placing a single pad and then left click on the pad to highlight it.
LABCENTER ELECTRONICS LTD. Replicate Dialogue Note that you need to include the units of either millimetres (mm) or Thou (th) when entering values in to the X/Y-step fields. This will give us a single row of pads of the correct pitch (zoom in, change the snap settings and measure if you would like to confirm). The next step is to duplicate this row of pads to form the bottom of the footprint. Start by right dragging a tagbox around the entire row of pads and then go to the Edit menu and select replicate.
PCB Layout Move the mouse and drag the copy to a free area, left clicking to place and then right clicking to exit copy mode. Now, drag a tagbox around the row, right click and select the Block Rotate option, specifying a 90 degree rotation to align the pads correctly. Block rotation of 90 degrees In order to position this row of pads correctly it’s best to first set place a marker on the location we want to move the row of pads to.
LABCENTER ELECTRONICS LTD. Type in –2mm in both the X and the Y co-ordinate fields (i.e. down and left) and make sure that the offset is relative to the current origin. Select OK and click the mouse twice to place the marker at this location. OK will take the mouse to the specified location The marker we have placed will serve for now as the location we want to centre the top most pad of our third row.
PCB Layout Moving the centre of a pad on to the marker Having placed the row of pads right click on the marker and delete it – we’ll come back to marker placement later on. The final stage of pad placement is to replicate the newly placed row of pads onto the right hand side. As before, draw a selection box around the row of pads and use the replicate command with an X offset of 12mm to duplicate the row. Adding the silkscreen graphics is now straightforward.
LABCENTER ELECTRONICS LTD. Placing the Top Silk area The next job we have is to number the pads. Start by invoking the Auto Name Generator from the Tools Menu. We don’t need to enter anything in the string field here; simply leave the defaults and click on the pads consecutively to number them, Number 1 is the top pad on the left hand row.
PCB Layout Remember to hit the escape key on your keyboard when you have finished numbering pin 44 to exit assignment mode. It’s common to place a small dot beside pin one and you can do this via the 2D Graphics circle icon. Make sure that the Layer Selector is on Top Silk and turn the snap setting down to minimum (CTRL+F1) to achieve finer control over the size.
LABCENTER ELECTRONICS LTD. Reference marker placed Having completed the layout of the footprint, we can now move on to the (far simpler) process of packaging the part into the libraries. Circular Pad Placement The replicate command is dynamic based on whether you are in cartesian co-ordinates or polar co-ordinates (View Menu Toggle).
PCB Layout Select Polar mode (View Menu). Place a False Origin ('O' shortcut key). Orient your first pad and place at radius distance from (false) origin.
LABCENTER ELECTRONICS LTD. Right click on the pad, select replicate command and specify angle (e.g. 20) and number (e.g. 17) to complete the circle. Packaging the Footprint Drag a selection box around the entire footprint and then select the Make Package command from the Library Menu. Launch 'Make Package' from the Library menu The first screen is fairly self-explanatory and similar to that we’ve seen in the schematic capture.
PCB Layout The Make Package dialogue form You can create your own libraries via the Library Manager – please see the reference manual for details. You should not make your own parts into the other pre-supplied libraries as Labcenter may overwrite these libraries during upgrade installs. When this is filled out, switch tabs to the 3D Visualisation tab (do not hit the OK button at this stage – we still have some work to do).
LABCENTER ELECTRONICS LTD. 3) Rotate and offset such that the part is aligned correctly on the 2D courtyard. Note that you can zoom in and out on the preview with the middle mouse wheel (or buttons) and the flip command will mirror the board at its current position. Fortunately, this job is greatly aided by the number of STEP files available on the internet (e.g. www.3dcontentcentral.com) and a 3D preview on the dialogue form to help with alignment.
VSM TUTORIAL (Interactive) Introduction – Interactive Simulation The purpose of this tutorial is to show you how to conduct an interactive simulation with a microcontroller using Proteus VSM and the VSM Studio IDE. The emphasis will be on practical usage of the simulator and IDE, with more detailed coverage of each topic being available in the reference manuals.
LABCENTER ELECTRONICS LTD. Requirements To work through this tutorial you will need: An installed copy of the Proteus Software at Version 8.0 or later. A demonstration copy of the software can be downloaded free of charge from the Labcenter website if you do not have a professional copy. An installed copy of the Hi-Tech PIC16 compiler at Version 9.8 or later.
Proteus VSM After project import you should see two tabs in the application, the schematic capture module with the F1 Evaluation Board design and the VSM Studio IDE containing the standard Microchip source code for driving the hardware. The first thing we need to do is compile the source code and produce some firmware that we can test in simulation.
LABCENTER ELECTRONICS LTD. Hi-Tech compiler we need requires download from Microchip's website so if you don't have this compiler installed you will have to: 1) Click on the goto website button beside the compiler. 2) Download and install the compiler. 3) Click on the Check All button at the bottom of the dialogue form to configure the compiler to work with Proteus. You should notice after running this command that the Hi-Tech compiler row on the dialogue form is marked as installed.
Proteus VSM Output from the compiler is written to the bottom pane of the IDE and you should get a compiled successfully message on completion. The next step is to run the simulation and test our compiled code on the virtual hardware. VSM Studio automatically configures common compiler options to correctly build your programs for simulation in Proteus. If you need to tweak settings (e.g. link to external library) you can do so via Project Settings on the Build Menu.
LABCENTER ELECTRONICS LTD. The Microchip demonstration code for the F1 Evaluation Board has three modes, one for time, one for temperature and a third which gives an ADC reading from the POT. You can interact with the simulation and cycle through the modes of operation by pressing the control button on the schematic. When in temperature mode you can adjust the temperature on the MCP9800 temperature sensor by clicking on the increment or decrement buttons.
Proteus VSM When in voltage mode you can adjust the value of the POT. The voltage reading is converted by the processor and then displayed on the LCD panel. The PIC microcontroller has a 10-bit LCD so our displayed value range is 0 to 1023 over the 0 to 3.3V range. When you are finished press the stop button on the animation control panel to stop the simulation.
LABCENTER ELECTRONICS LTD. Important Notes Quite a lot is happening when we run a simulation in Proteus that might not be immediately apparent. Firstly, the micro-controller on the schematic is executing the compiled firmware file in exactly the same way as a physical PIC would execute its programmed firmware. Working with the VSM Studio IDE simply automates the 'programming' step by sending the output file to the schematic after a successful compile.
Proteus VSM Writing Firmware Now that we have completed the workflow through simulation let's add some functionality to the program. We know that pressing the button switches between time display, temperature and POT display so we can easily add another mode of operation here. Start by switching to the VSM Studio IDE tab and opening up the main.c file (double click on the item in the project tree).
LABCENTER ELECTRONICS LTD. Almost the first hit is the one we are looking for, namely a switch statement on button release that cycles through the setting of the display modes. All we need do here is add our new mode. Note that you need to change the display mode on the previous case statement as well. Just below this in the code there is another switch statement which actions the current display mode. Again, we need to our case here and call our function.
Proteus VSM The last step is to write a function that does something when we enter our mode of operation. We'll add this at the bottom of the file. You can experiment and add anything you like here but we'll do something simple, writing a value to the display and adding a little binary counter on the LED's. Since we are using PORTE to write the LED's here we also need to configure the port pins. We'll set up ANSELE in the peripheral config section at the top of the main function.
LABCENTER ELECTRONICS LTD. error will navigate to the problem. In our case we have missed a semi-colon from the end of the line. Some errors - such as linker errors - will obviously not be navigable. In these cases you may need to change the options/includes via the project settings command. When we run the simulation this time we can use the button to cycle through the modes of operation until our own is reached (time -> temperature -> test).
Proteus VSM 2) Start at the top left and drag a box around it. 3) You should see a blue dashed line around the area when you are finished. If you make a mistake you can right click on the dashed line and delete. Similarly, if your positioning is wrong, you can right click on the dashed line and drag. Other likely candidates for active popups are the mode selection button, the POT and the display itself so we can repeat the process above, dragging additional boxes around these items.
LABCENTER ELECTRONICS LTD. Since we have specified active popups the assumption is that we will be working (debugging) inside VSM Studio. If you press the play button to run the simulation now you should find that you switch to the VSM Studio tab and that the active popups appear docked on the right hand side of the IDE.
Proteus VSM The source and variables areas of the tab will display a simulation running message at this point as we are freely executing code. We'll cover debugging in the next section of the tutorial. Active popups are clever not only because they bring areas of the schematic into the debugging environment but because you can interact with them.
LABCENTER ELECTRONICS LTD. You can switch back to the schematic tab and you will see exactly the same status as in the active popups. When you stop the simulation (from the animation control panel) the active popups will disappear and VSM Studio will switch from its 'debugging layout' to its 'design layout' where you can once again edit and compile your source code. You can only create or adjust active popups on the schematic when the simulation is stopped.
Proteus VSM At this stage the simulation has 'booted' and a stable operating point has been found but no instructions have executed and no real time has elapsed. No source code is shown as there is no source line at the current program counter value You can select any of the program source files from the combo box at the top of the window but we will start with the main.c file which contains the principle program control loop.
LABCENTER ELECTRONICS LTD. To take a simple example, let’s set a breakpoint in the main event loop when a button is released. The easiest way to set/toggle a breakpoint is to double click on the line of code that you wish to break on. The breakpoint indicator should appear at the left of the source window beside the line of code in question. If you set a breakpoint by mistake then you can remove it or toggle it off by double clicking again on the line (or from the right hand context menu).
Proteus VSM If you really need to examine behaviour in detail you can even step the code at assembly level. Right click on the source menu and select 'disassembly' from the resulting context menu and then use the same step commands as before. Right click and select disassembly again to return to high level source code stepping You may notice during step debugging that the active popup for the display does not show a full legible output. This is correct and a consequence of the display being multiplexed.
LABCENTER ELECTRONICS LTD. Start the simulation using the play button at the bottom of Proteus and then launch the watch window from the debug menu in VSM Studio. You should see it appear as a docked tab at the bottom of the IDE. Next, right click on the watch window and select 'Add items by name' from the context menu. We want to add the ADC registers ADRESH and ADRESL which you can do by double clicking on an entry.
Proteus VSM You can change the display format of the items to binary if you find it easier to understand the results. You would do this by right clicking on each item in the watch window and changing the display format to binary. Since this is 10-bit ADC we would expect the maximum value to be 1023 or 0x03FF and we should see this value when the POT is fully ramped up. Now let’s assume that we needed to catch the midpoint on the way back down.
LABCENTER ELECTRONICS LTD. Note that you need to separately configure ADRESH and ADRESL. The watch window display should look like the following when you are finished. Having set up the watch conditions all we need do now is adjust the POT back down until the breakpoint kicks in when the conditions are met. As before you can do this either via the POT active popup inside VSM Studio or by switching to the schematic tab.
Proteus VSM Hardware Breakpoints So far, we have looked at how to break into the simulation based on software conditions (watchpoints and breakpoints). It is also possible to use hardware breakpoint objects in order to check the code when a hardware condition occurs. As an example, if we wanted to catch the beginning of activity on the I2C bus we could set up a hardware breakpoint on the I2C line as follows.
LABCENTER ELECTRONICS LTD. Hit OK and then press play to run the simulation. You should find that the simulation will pause almost immediately and the source window in VSM Studio will show that we have just executed a command to set SDA low. This breakpoint is actually taking place inside the initialization routine. If we wanted to skip this and activate only when we enter I2C mode we need to set and arm time on the breakpoint.
Proteus VSM This time when we run the simulation the breakpoint will not trigger until we press the mode selection button to enter temperature mode (where temperature is transmitted on the I2C bus). You should find that you end up inside one of the I2C routines in the source code. You can follow the code path from here using the stepping and debugging described in previous sections. Stop the simulation again when you are finished.
LABCENTER ELECTRONICS LTD. Click on the I2C analyser in the parts bin to select it and then place it on the schematic in the usual way. For ease of wiring, you'll want to drop it underneath the temperature sensor. Next, we need to wire up the pins. Note that the cursor turns green on both a starting and stopping point for a wire.
Proteus VSM Once we have wired up the analyser we can start the simulation. You should see straight away that there is an additional window for the I2C debugger and what seems to be some initialization/identification traffic. To view normal transmission we need to press the button on the schematic to switch into temperature mode display. Since the code is constantly polling you should then pause the simulation from the animation control panel so that we can take some time to analyse the traffic.
LABCENTER ELECTRONICS LTD. If you are working within a single frame the VSM Studio tab will come to the foreground when the simulation is paused as it is assumed you are interested in the source code pending execution. The analyser will however remain on top. If you want to see both the schematic and the source at the same time you can either use Active popups or drag the VSM Studio tab onto some free space to separate it. The syntax used in the protocol analyser is standard and should be familiar.
Proteus VSM Do note that with constantly polling firmware such as this there is considerable overhead in terms of performance as we are constantly writing textual data to the display. However, in most cases you are using the instrument for testing or debugging, at which point the simulation speed is secondary to problem solving. As with all debugging windows you can close the debugger when not in use and then re-open it from the Debug Menu in either VSM Studio or Proteus.
LABCENTER ELECTRONICS LTD. Now select the graph icon and then the digital graph from the parts bin. Left click the mouse at the top left of where you want the graph to be and then move the mouse down and to the right. Left click again to commit placement. Note that the graph on the schematic doesn't need to be particularly large. We will maximise it later when we want to analyse the simulation results. Having added the graph we now need to tell it which wires we want to trace.
Proteus VSM If you need to make some room for the probes, right click on the terminal at the end of the wire, right click and select drag object from the context menu and move to the left to make room for the probe. You can use the middle mouse button or the F6/F7 keys to zoom in and out around the mouse position if you need to get in closer. The F8 key will return to the default view of the schematic. By default, the voltage probes will pick up the name of the terminal.
LABCENTER ELECTRONICS LTD. By default, a graph based simulation will run from time zero to one second of simulation time. In our case, it would make much more sense to run from one second to two seconds, thus skipping the initialization traffic. We can do this by editing the graph (right click and edit properties) and changing the start and stop time. Left clicking on an empty area of the schematic will de-select any currently selected objects.
Proteus VSM Now edit the generator in the usual way (right click - edit properties). Select single pulse from the digital generator types and change the pulse polarity to be negative so that the pulse signal represents a button push. Since we are simulating from 1s to 2s set the start time to 1.25s and the pulse width to something like 50ms.
LABCENTER ELECTRONICS LTD. We can now run the simulation. Unlike an interactive simulation the animation control panel is now used (we are simulating for a fixed time which does not necessarily start at time zero). Instead, use the 'Simulate Graph' command on the graph menu. You should then see results which look like those below. Aside from the fact that the traffic didn't start until around 1.25s (as specified by the pulse) we can't see much information here.
Proteus VSM When the graph tab is in the foreground the menu's and icons change to show things we can do with the graph. In particular, notice the new graph toolbar at the top of the application The zoom commands can be found here and probably the most useful of these is the 'zoom to area' icon. Click on this icon and then drag around a small area to localise the display. If you repeat this you will soon be able to zoom in on a single I2C sequence.
LABCENTER ELECTRONICS LTD. Further Reading All of the general placement and editing techniques discussed briefly here are covered in far more detail in the Proteus tutorial documentation. More information on Graphing is provided later in this documentation and a full discussion of generators, probes and graph based simulation can be found in the Proteus VSM reference manual. Diagnostic Messaging Another - often overlooked - tool provided in Proteus is diagnostic messaging.
Proteus VSM Expand the entry for the display panel, click on the entry and then change the trace information level to full trace. Now expand the PIC16 and scroll down to the LCD module entry, again changing the trace information level to 'full trace'.
LABCENTER ELECTRONICS LTD. Start an interactive simulation from the animation control panel and then click on the simulation advisor to view the diagnostic messages. This will switch Proteus to the VSM Studio tab and the simulation advisor will appear as a docked window at the bottom of the frame. If you pause the simulation note that the LCD messages contain PC values which you can click on to locate the instruction in your source code that caused the condition.
Proteus VSM Navigation to source code is only possible when the simulation is paused. Finally, stop the simulation and turn off diagnostics in the same as they were enabled, except change the trace information levels back to warnings only. Diagnostic messages are particularly useful in a problem situation where you need to gather information before deciding where to hunt for the bug.
LABCENTER ELECTRONICS LTD.
VSM TUTORIAL (Graphs) The purpose of this tutorial is to show you, by use of a simple amplifier circuit, how to perform a graph based simulation using Proteus VSM. It takes you, in a step-by-step fashion, through: Placing graphs, probes and generators. Performing the actual simulation. Using graphs to display results and take measurements. A survey of the some of the analysis types that are available.
LABCENTER ELECTRONICS LTD. If you want, you can draw the circuit yourself, or you can load a ready made design file by File Menu ->Open Sample -> Tutorials -> Analogue Simulation Tutorial (Part 1) within your Proteus installation. Whatever you choose, at this point ensure you have Proteus running and the circuit drawn Generators To test the circuit, we need to provide it with a suitable input. We shall use a voltage source with a square wave output for our test signal.
Proteus VSM Generator objects are like most other objects in Proteus; the same procedures for previewing and orienting the generator before placement and editing, moving, re-orienting or deleting the object after placement apply (see Generators and Probes in the reference manual). As well as being dropped onto an existing wire, as we just did, generators may be placed on the sheet, and wired up in the normal manner.
LABCENTER ELECTRONICS LTD. Select the OK button to accept the changes. For this circuit only one generator is needed, but there is no limit on the number which may be placed. Probes Having defined the input to our circuit using a generator, we must now place probes at the points we wish to monitor. We are obviously interested in the output, and the input after it has been biased is also a useful point to probe. If needs be, more probes can always be added at key points and the simulation repeated.
Proteus VSM Probe objects are like generators and most other objects in Proteus; the same procedures for previewing and orienting the probe before placement, and editing, moving, re-orienting or deleting the probe after placement apply (refer to the section on Probes in the reference manual for more information). Probes may be edited in order to change their reference labels.
LABCENTER ELECTRONICS LTD. We now need to add our generator and probes on to the graph. Each generator has a probe associated with it, so there is no need to place probes directly on generators to see the input wave forms. There are three ways of adding probes and generators to graphs: The first method is to tag a probe/generator and drag it over the graph and release it - exactly as if we were repositioning the object, repeat for each probe/generator.
Proteus VSM We will Quick Add our probes and the generator to the graph. Either tag the probes and generators individually, or, more quickly, drag a tag box around the entire circuit - the Quick Add feature will ignore all tagged objects other than probes and generators. Select the Add Trace option from the Graph menu and answer Yes to the prompt. The traces will appear on the graph (because there is only one graph, and it was the last used, it is deemed to be the current graph).
LABCENTER ELECTRONICS LTD. There is one final piece of setting-up to be done before we start the simulation, and this is to set the simulation run time. Proteus will simulate the circuit according to the end time on the x-scale of the graph, and for a new graph, this defaults to one second. For our purposes, we want the input square wave to be of fairly high audio frequency, say about 10kHz. This needs a total period of 100ms.
Proteus VSM Simulation To simulate the circuit, all you need do is invoke the Simulate command on the Graph menu (or use its keyboard short-cut: the space bar). The Simulate command causes the circuit to be simulated and the current graph (the one marked on the Graph menu) to be updated with the simulation results. Do this now. The status bar indicates how far the simulation process has reached. When the simulation is complete, the graph is redrawn with the new data.
LABCENTER ELECTRONICS LTD. So the first simulation is complete. Looking at the traces on the graph, it’s hard to see any detail. To check that the circuit is working as expected, we need to take some measurements. Taking Measurements A graph sitting on the schematic, alongside a circuit, is referred to as being minimised. To take timing measurements we must first maximise the graph. To do this, right click on the graph and select the maximise option from the resulting context menu.
Proteus VSM We shall measure two quantities: The voltage gain of the circuit. The approximate fall time of the output. These measurements are taken using the Cursors. Each graph has two cursors, referred to as the Reference and Primary cursors. The reference cursor is displayed in red, and the primary in green. A cursor is always 'locked' to a trace, the trace a cursor is locked to being indicated by a small 'X' which 'rides' the waveform.
LABCENTER ELECTRONICS LTD. on the x-axis. The title on the status bar is removed, and will now display the cursor time (in red, at the left) and the cursor voltage along with the name of the trace in question (at the right). It is the U1(POS IP) trace that we want. You can move a cursor in the X direction using the left and right cursor keys, and you can lock a cursor to the previous or next trace using the up and down cursor keys.
Proteus VSM cursor should be at the corner at the start of the falling edge. You should find that the falling edge is a little under 10m. Using Current Probes Now that we have finished with our measurements, we can return to the circuit – just close the maximised graph for the cross at the right of the tab. We shall now use a current probe to examine the current flow around the feedback path, by measuring the current into R4.
LABCENTER ELECTRONICS LTD. At the moment no trace is drawn for the current probe. Press the space bar to re-simulate the graph, and the trace appears. Even from the minimised graph, we can see that the current in the feedback loop follows closely the wave form at the output, as you would expect for an op-amp. The current changes between 10mA and 0 at the high and low parts of the trace respectively. If you wish, the graph may be maximised to examine the trace more closely.
Proteus VSM Now to add the probes. We shall add both the voltage probes, OUT and U1(POS IP). In a frequency graph, the two y-axes (left and right) have special meanings. The left y-axis is used to display the magnitude of the probed signal, and the right y-axis the phase. In order to see both, we must add the probes to both sides of the graph. Tag and drag the OUT probe onto the left of the graph, then again drag the robe onto the right.
LABCENTER ELECTRONICS LTD. There is no need to edit the graph properties, as the frequency range chosen by default is fine for our purposes. However, if you do so (right click on the graph and select Edit properties), you will see that the Edit Frequency Graph dialogue form is slightly different from the transient case. There is no need to label the axes, as their purpose is fixed, and there is a check box which enables the display of magnitude plots in dB or normal units.
Proteus VSM Now start the simulation by right clicking on the graph and selecting the simulate option from the context menu. When it has finished, maximise the graph by opening it in a new tab as before (right click context menu). Considering first the OUT magnitude trace, we can see the pass-band gain is just over 20dB (as expected), and the useable frequency range is about 50Hz to 20kHz. The cursors work in exactly the same manner as before - you may like to use the cursors to verify the above statement.
LABCENTER ELECTRONICS LTD. The OUT phase trace shows the expected phase distortion at the extremes of the response, dropping to -90° just off the right of the graph, at the unity gain frequency. The high-pass filter effect of the input bias circuitry can be clearly seen if the U1(POS IP) magnitude trace is examined. Notice that the x-axis scale is logarithmic, and to read values from the axis it is best to use the cursors.
Proteus VSM To begin with place a DC Sweep graph on an unused space on the schematic. Then tag the U1(POS IP) probe and drag it onto the left of the graph. We need to set the sweep value, and this is done by editing the graph (right click - edit properties). The Edit DC Sweep Graph dialogue form includes fields to set the swept variable name, its start and ending values, and the number of steps taken in the sweep.
LABCENTER ELECTRONICS LTD. Now you can simulate the graph by right clicking on it and selecting the simulate option. Then, by maximising the graph, you can see that the bias level reduces as the resistance of the bias chain increases. By 5MW it is significantly altered. Of course, altering these resistors will also have an effect on the frequency response. We could have done an AC Sweep analysis at say 50Hz in order to see the effect on low frequencies.
Proteus VSM schematic. It is really only output noise we are interested in, so tag the OUT voltage probe and drag it onto the graph. As before, the default values for the simulation are fine for our needs, but you need to set the input reference to the input generator IN. The Edit Noise Graph dialogue form has the check box for displaying the results in dBs. If you use this option, then be aware that 0dB is considered to be 1 volt r.m.s. Click on Cancel to close the dialogue form.
LABCENTER ELECTRONICS LTD. This lists the individual noise contributions (across the entire frequency range) of each circuit element that produces noise. Most of the elements are in fact inside the op-amp, and are prefixed with U1_. If you select the Log Spectral Contributions option on the Edit Noise Graph dialogue form, then you will get even more log data, showing the contribution of each component at each spot frequency.
Proteus VSM 241
Labcenter Electronics LTD. 21 Hardy Grange, Grassington, Skipton, N. Yorks, BD23 5AJ, UK Tel: +44 (0) 1756 753 440, E-mail: info@labcenter.com Web: www.labcenter.