EESchema
Headings:
A schematic can be represented on a single sheet, but it will mostly require several sheets.
A schematic represented on several sheets is then called hierarchical, and all these sheets (each one represented by its own file) constitutes for EESchema a project.
A project consists of a main schematic, called the root schematic, and sub-sheets constituting a hierarchy.
In order to find every file of the project, you will have to follow drawing rules which will be described hereafter.
In the following, when we talk about project, we will be refering to both single sheet and hierarchical multi sheets.
An additional special chapter develops the use of the hierarchy and its characteristics.
A schematic designed with EESchema is more than a simple graphic representation of an electronic device.
It is normally the entry point of a development chain which allows :
The control of the electrical rules (control E.RC.) that allows the detection of errors or omissions in the schematic.
The automatic generation of the bill of material.
The netlist generation for simulation software such as Pspice.
The netlist generation for printed circuits board design (PCBNEW). The consistency check between the schematic and the printed circuit board is then automatic and instantaneous.
In order to benefit from these possibilities, you will have to respect certain constraints and conventions, to avoid nasty surprises and errors.
A schematic mainly consists of components, wires, labels, junctions, buses and power ports.
For clearness in the schematic, you can place purely graphical elements like bus entries, comments, and dotted lines to draw frames.
The schematic software uses component libraries.
In addition to the schematic design file, the netlist file is particularly important because it is used by the other design softwares.
A netlist file gives the list of the components and connections resulting from the schematic.
There is (unfortunately for the user) a great number of netlist formats, some are more known. It is the case of the Spice format for example.
To load a component,
use the tool
To place a new component, click at the place you want to draw it.
A dialog box allows you to type the name of the module to load.
The dialog box displays the last two elements loaded.
If you type *, or if you select the button “list all”, EESchema will display the libraries list, and then the available components.
If you type the symbol “=“ followed by key words, EESchema will then display a list of components according to all the key words.
You can also list a selection : for example if you enter LM2 *, all the component's names starting with LM2 will be listed
The selected component will appear on the screen, in placement mode.
Before placement in the desired position (with a left click), you can rotate the component 90 degrees by 90 degrees, have a mirror view according to axis X or Y, or select its representation via the fast edit pop-up menu.
This can also easily be done after placement.
If the desired component does not exist, remember that you can often load a similar component and modify it : if a 54LS00 is wanted, you can obviously load a 74LS00 and change the name 74LS00 to 54LS00.
Here is a component during placement:
A power port symbol is a component (the symbols are grouped in the “power” library).
So you can use the previous command.
But as these
placements are frequent, the
tool is available.
This tool is similar to the preceeding one, except that the search is done directly in the “power library”, saving time.
Editions / modifications are of two kinds.
Modification of the component itself (position, orientation, part selection of a multi-part component).
Modification of one of the fields (Reference, value, or others) of the component.
When a component has just been placed, you may have to modify its value (particularly for resistors, capacitors…), but it is useless to assign it a reference number immediately, or to select the part of a multi-part component (like a 7400).
This can automatically be done by the annotation function.
To do this position the cursor mouse on the component (not to position on a field). One can then:
Double-click on the component to open the full editing dialog box.
Right-click to open the Pop Up menu, and use one of the displayed commands (Move, Orientation, Edit, Delete).
You can modify the reference, value, position, orientation, size and the visibility of the fields.
For simple editing:
Double-click on the text field to modify it.
Right-click and use one of the displayed commands (Move, Rotate, Edit, Delete) in the Pop Up menu.
For more complete editing, or in order to create fields, double-click on the component; this will open the “component properties” dialog box :
Every field can then be edited:
Each field can be visible, displayed horizontally or vertically.
The displayed (and changeable) position is always indicated for a normally displayed component (no rotation or mirror) and relates to the anchoring point of the component.
All these drawing elements can also be placed with the tools on the vertical right toolbar.
These elements are:
Wires for usual connections.
Buses (which use is only to connect bus labels, for esthetic considerations of the drawing)
Dotted lines, for graphic presentation.
Junctions, to force connections between crossing wires or buses.
Bus entries of Wire to Bus or Bus to Bus connections, for esthetic considerations of the drawing.
Labels for usual connections.
Global labels, for connections between sheets.
Texts of comment.
“NoConnection” symbols.
Hierarchy sheets, and their connection pins.
There are two ways to establish connection:
Pin to pin wires.
Labels.
The following figure shows the two methods :
Notice 1:
The point of “contact” (or anchoring) of a label is the lower left corner of the first letter of the label.
This point must thus be in contact with a wire, or be superimposed at the point of contact of a pin so that this label is taken into account.
Notice 2:
To establish a connection, a segment of wire must be connected by its ends to an another segment or to a pin.
If there is overlapping (if a wire passes over a pin, but without being connected to the pin's end), there is no connection.
However, a label will be connected to a wire whatever the position of the anchoring point of the label on this wire.
Notice 3:
If a wire must be connected to another wire, otherwise than by their ends, it will be necessary to place a junction symbol at the crossing point.
The previous figure (wires connected to DB25FEMALE pins 22, 21, 20, 19) shows such a case of connection using a junction symbol.
Notice 4:
If two different labels are placed on the same wire, they are connected together and become equivalent: all the other elements connected to one or the other label are then connected to all of them.
Let us consider the following schematic:
Many pins (particularly component U1 and BUS1) are connected to buses.
From the schematic point of view, a bus is a collection of signals, starting with a common prefix, and ending by a number.
This concept is not exactly the one which is used for a microprocessor bus. Each signal is a member of the bus.
PCA0, PCA1, PCA2, are thus members of PCA bus.
The complete bus is named PCA [N. .m], where N and m are the first and the last wire number of this bus.
Thus if PCA has 20 members from 0 to 19, the complete bus is noted PCA [0..19].
But a collection of signals like PCA0, PCA1, PCA2, WRITE, READ cannot be contained in a bus.
Pins connected between the same members of a bus must be connected by labels.
Indeed, directly connecting a pin to a bus is a non-sense, because a bus is a collection of signals, and this connection will remain ignored by EESchema.
In the example above, connections are made by the labels placed on wires connected to the pins.
Connections via bus entries (wire segments at 45 degrees) to bus wires have only an esthetic value, and are not necessary on the purely schematic level.
In fact, due to the repetition command (Insert key), connections can be very quickly made in the following way, if component pins are aligned in increasing order (a common case in practice on components such as memories, microprocessors…):
Place the first label (for example PCA0)
Use the repetition command as much as needed to place members. EESchema will automatically create the next labels (PCA1, PCA2…) vertically aligned, theorycally on the position of the other pins.
Draw the wire under the first label. Then use the repetition command to place the other wires under the labels.
If needed, place the bus entries by the same way (Place the first entry, then use the repetition command).
Note:
In the Preferences/Options menu, you can set the parameters of repetition:
Vertical step.
Horizontal step.
Label increment (which can thus be incremented by 2, 3. or decremented).
You may need connections between buses, in order to link two buses having different names, or in the case of a hierarchy, to create connections between different sheets.
You can make these connections in the following way.
Buses PCA [0..15], ADR [0..7] and BUS [5..10] are connected together (note the junction here because the vertical bus wire joins the middle of the horizontal bus segment).
More precisely, the corresponding members are connected together : PCA0, ADR0 are connected, (as same as PCA1 and ADR1… PCA7 and ADR7).
Furthermore, PCA5, BUS5 and ADR5 are connected (just as PCA6, BUS6 and ADR6 like PCA7, BUS7 and ADR7).
PCA8 and BUS8 are also connected (just as PCA9 and BUS9, PCA10 and BUS10)
On the other hand you cannot connect members of different weights in this way.
If you want to connect members of different weights from different buses, you will have to do that member by member like two usual labels, placing them on the same wire.
When the power pins of the components are visible, they must be connected, as for any other signal.
The difficulty comes from components (such as gates and flip-flops) for which the power pins are normally invisible (invisible power pins).
The difficulty is double because :
- You cannot connect wires, because of their invisibility.
- You don't know their name.
And moreover, it would be a bad idea to make them visible and to connect them like the other pins, because the schematic would become unreadable and not in accordance with usual conventions.
Note:
If you want to enforce
the display of these invisible power pins, you must check the option
"Show invisible power pins" in the Option dialog box of the
main menu, or the icon
of the left toolbar ( options toolbar)
EESchema connects automatically the invisible power pins :
All the invisible power pins of the same name are automatically connected between them without other notice.
However these automatic connections must be supplemented:
- By connections to the other visible pins, connected to this power port.
- Possibly by connections between groups of invisible pins of different names (for example, the ground pins are usually called “GND” in TTL components and “VSS” in MOS, and they must be connected together).
For these connections, you must use power ports symbols (components especially designed for this use, that you can create and modify with the library editor).
These symbols consist of an invisible power pin associated with the desired drawing.
Don't use labels, which have only a “local” connection ability, and which would not connect the invisible power pins. (See hierarchy concepts for more details).
The figure below shows an example of power ports connections.
In this example, ground (GND) is connected to power port VSS, and power port VCC is connected to VDD.
Two PWR_FLAG symbols are visible. They indicate that the two power ports VCC and GND are really connected to a power source.
Without these two flags, the ERC tool would diagnose : Warning: power port not powered.
All these symbols are components of the schematic library "power".
These symbols are very useful for E.R.C. to avoid undesired warnings. (The electric rules check ensures that no connection has been unopportunely left unconnected).
If pins must really
remain unconnected, it is necessary to place a NoConnection symbol
(tool
)
on these pins.
These symbols however do not have any influence on the generated netlists.
It can be usefull (for a good comprehension of the schematic) to place indications such as text fields, frames.
Text fields
(tool
)
and dotted lines (tool
)
are intended for this use, contrary to labels and wires, which are
connection elements.
Example of frame :
The title block is
edited with the tool
:
The complete title block is then:
The date and the sheet number (Sheet X/Y) are automatically updated:
Date : when you modify the schematic.
Sheet number (useful in hierarchy) : by the annotation function.
A hierarchical representation is generally a good solution for projects bigger than a few sheets. If you want to manage this kind of project, it will be necessary to :
- Use large sheets, which results in printing and handling problems.
- Use several sheets, which leads you to a hierarchy structure.
The complete schematic then consists in a main schematic sheet, called root sheet, and sub-sheets constituting the hierarchy.
Moreover, a skilful subdividing of the design into separate sheets often improves on its legibility.
From the root sheet, you must be able to find all sub-sheets.
Hierarchical
schematics management is very easy with EESchema, thanks to an
integrated “hierarchy navigator” (button
of the upper and right toolbar, further detailed).
In fact, there are two types of hierarchy (that can exist simultaneously):
The first one has just been evoked and is of general use.
The second consists in creating components in the library that appear like traditional components in the schematic, but which actually correspond to a schematic which describes their internal structure.
This second type is rather used to develop integrated circuits, because in this case you have to use function libraries in the schematic you are drawing.
EESchema currently does't treat this second case.
The creation of a hierarchical schematic is easy, the whole hierarchy is handled starting from the root schematic, as if it were only one schematic.
The two points to be known are :
How to create a sub-sheet.
How to build electric connections between sub-sheets.
It is very easy thanks
to the navigator (tool
of the horizontal toolbar) shown here :
Each sheet is reachable, clicking its name.
Fast navigation:
Right click on a sheet name, and choose enter sheet.
You can also quickly
reach the root sheet, or a sub-sheet thanks to the tool
of the right vertical toolbar.
After tool selection :
Click on a sheet name to selection this sheet.
Click elsewhere to select the main sheet.
You have to :
Place in the root sheet a hierarchy symbol called “sheet symbol”.
Enter into the new schematic (sub-sheet) with the navigator and draw it, like any other schematic.
Draw the electric connections between the two schematics by placing Global Labels (Glabels) in the new schematic (sub-sheet), and labels having the same name in the root sheet, known as SheetLabels. These SheetLabels will be connected to the sheet symbol of the root sheet to the other elements of the schematic like standard component pins.
Draw a rectangle defined by two diagonal points symbolizing the sub-sheet.
The size of this rectangle must allow you to place later particular labels, hierarchy pins, corresponding to the global labels (Glabels) in the sub-sheet .
These labels are similar to usual component pins.
Select the tool
.
Click to place the upper left corner of the rectangle. Click again to place the lower right corner, having a large enough rectangle.
Example :
You will then be prompted to type a filename and a sheet name for this sub-sheet (in order to reach the corresponding schematic, using the hierarchy navigator).
You must give at least a file name. If there is no sheet name, the filename will be used as sheet name (usual way to do that).
You will create here points of connection (Hierarchy pins) for the symbol which has been just created.
These points of connection are similar to normal component pins, with however the possibility to connect a complete bus with only one point of connection.
There are two ways to do this:
Place the different pins before drawing the sub-sheet (manual placement).
Place the different pins after drawing the sub-sheet, and the global labels (semi-automatic placement).
The second solution is quite preferable, as much as possible.
Manual placement:
- To select the
tool
.
- Click on the hierarchy symbol where you want to place this pin.
See below an example of the creation of the hierarchical pin called “CONNEXION”.
You can then define its graphical attributes, size ( Right click and select Edit in the PopUp menu) :
Various pin symbols are available :
- Input
- Output
- BiDir
- TriState
- NotSpecified
These pin symbols are only graphic enhancements, and have no other role.
Automatic placement:
Select the tool
.
Click on the hierarchy symbol from where you want to import the pins corresponding to global labels placed in the corresponding shematic. A hierarchical pin appears, if a new global label exists, i.e. not corresponding to an already placed pin.
Click where you want to place this pin.
All necessary pins can thus be placed quickly and without error. Their aspect is in accordance with corresponding global labels.
Each pin of the sheet symbol just created, must correspond to a label called global Label or GLabel in the sub-sheet.
Glabels are similar to labels, but they provide connections between sub-sheet and root sheet.
The graphical representation of the two complementary labels (pin and GLabel) is similar.
GLabel creation is
made with the tool
.
See below a root sheet example :
Notice pins TRANSF1 and TRANSF2, connected to connector JP3.
Here are the corresponding connections in the sub-sheet :
You find again, the two corresponding Glabels, providing connection between the two hierarchical sheets.
Note:
You can use GLabels and Hierarchy pins to connect two buses, according to the syntax (Bus [N. .m]) previously described.
Here are some comments on various ways to provide connections, others than wire connections.
The simple labels have a local capacity of connection, i.e. limited to the schematic sheet where it is placed.
This is due to the fact that :
Each sheet has a sheet number.
This sheet number is associated to the Label.
Thus, if you place the label “TOTO” in sheet n° 3, in fact the true label is “TOTO_3“.
If you also place a label “TOTO” in sheet n° 1 ( root sheet) you place in fact a label called “TOTO_1“, different from “TOTO_3“.
This is always true, even if there is only one sheet.
What is said for the simple labels is also true for global labels or GLabels.
Thus in the same sheet, a GLabel “TOTO” is considered to be connected to a local label “TOTO”, but not connected to a GLabel or label called “TOTO” in another sheet.
However a GLabel is regarded as to be connected to the corresponding SheetLabel symbol in the hierarchical symbol placed in the root sheet.
It was seen that they were connected together if they had the same name.
Thus all the power pins declared “Invisible Power Pins“ and named VCC are connected and form the equipotential VCC, whatever the sheet they are placed on.
This explains that if you place a VCC label in a sub-sheet, it will not be connected to VCC pins, because this label is actually VCC_n, where n is the sheet number.
If you want this label VCC to be really connected to the equipotential VCC, it will have to be explicitly connected to an invisible power pin, thanks to a VCC power port.
Schematic
creation / editing Page 5 -