Dr. Dobb's is part of the Informa Tech Division of Informa PLC

This site is operated by a business or businesses owned by Informa PLC and all copyright resides with them. Informa PLC's registered office is 5 Howick Place, London SW1P 1WG. Registered in England and Wales. Number 8860726.


Channels ▼
RSS

Embedded Systems

Logic 101: Part 1 - Assertion-Level Logic


Editors Note: This is the first in a four-part mini-series on different ways of looking at logical representations. This is abstracted from the book Bebop to the Boolean Boogie (An Unconventional Guide to Electronics) with the kind permission of the publisher. The topics in this mini-series are as follows:

Part 1 – Assertion–Level Logic
Part 2 – Positive vs Negative Logic
Part 3 – Reed Muller Logic
Part 4 – Gray Codes


Beware – here be dragons!
In a moment we're going to start throwing terms around such as active-high and active-low. Sad to relate, the definitions of active-high and active-low are subject to confusion. Some academics (and even text books) define an active-low signal as one whose asserted (True or logic 1) state is at a lower voltage level than its unasserted (False or logic 0) state. However, this definition serves only to cause confusion when combined with negative logic implementations (see also Part 2 in this mini-series).

Engineers in the trenches generally take the position that an active-high state is one whose active state is considered to be True or logic 1, while an active-low state is one whose active state is considered to be False or logic 0. These definitions allow all forms of logic – including the assertion-level logic introduced in this article – to be represented without any confusion, regardless of whether positive or negative logic implementations are employed.

The bottom line, however, is that when using the terms active-high and active-low in discussions with other folks, you are strongly advised to make sure that you all understand them to mean the same thing before you find yourself up to your ears in alligators.

Assertion-level logic
The purpose of a circuit diagram is to convey the maximum amount of information in the most efficient fashion. One aspect of this is assigning meaningful names to wires; for example, naming a wire system-reset conveys substantially more information than calling it something like big-boy. Another consideration is that the signals carried by the wires may be active-high or active-low (see the discussions in the topic above).

For example, consider a portion of a circuit containing a tri-state buffer with an active-low control input called ~enable (Fig 1).


1. Naming active-low signals.

In order to convey as much information as possible, it is preferable to indicate the nature of an active-low signal in its name. One method of achieving this is to prefix the name with a tilde (pronounced "til-duh")character "~"; hence, ~enable. When both the enable-A and enable-B signals are set to their active-high states, the ~enable signal is driven to its active-low state and the tri-state buffer is enabled.

It is important to note that the active-low nature of the ~enable signal is not decided by the NAND per se. The only thing that determines whether a signal is active-high or active-low is the way in which it is used by any target gates, such as the tri-state buffer in this example. Thus, active-low signals can be generated by ANDs and ORs as easily as NANDs and NORs.

The problem with the standard symbols for BUF, NOT, AND, NAND, OR, and NOR is that they are tailored to reflect operations based on active-high signals being presented to their inputs. To address this problem, special assertion-level logic symbols can be used to more precisely indicate the function of gates with active-low inputs. As a simple example of this, consider how we might represent a NOT gate used to invert an active-low ~enable signal into its active-high enable counterpart (Fig 2).


2. Standard versus assertion-level NOT symbols.

Both symbols indicate an inversion, but the assertion-level symbol is more intuitive in the case of this example because it reflects the fact that an active-low input is being transformed into an active-high output. In both cases, the small circles known as bobbles (or bubbles) on the symbols indicate the act of inversion. One way to visualize this is that the symbol for a NOT has been pushed into a symbol for a BUF until only its bobble remains visible (Fig 3).


3. One way to visualize standard versus assertion-level NOT symbols.

In the real world, both standard and assertion-level symbols are implemented using identical logic gates. Assertion-level logic does not affect the final implementation, but simply offers an alternative way of viewing things. Visualizing bobbles as representing inverters is a useful technique for handling more complex functions. Consider a variation on our original circuit, in which the ~enable-A and ~enable-B signals are active-low and the tri-state buffer has an active-high enable input (Fig 4).


4. Standard NAND versus assertion-level OR symbols.

The purpose of this circuit is to set the enable signal to its active-high state if either of the ~enable-A or ~enable-B signals are in their active-low states. Remember that both of these circuit representations are functionally identical (you can easily prove this by drawing out their truth tables). Once again, however, the assertion-level representation is the more intuitive, especially for someone who is unfamiliar with the function of the circuit. This is because the assertion-level symbol unambiguously indicates that enable will be set to logic 1 if either of the ~enable-A OR ~enable-B signals are presented with logic 0s.

Any standard primitive gate symbol can be transformed into its assertion-level equivalent by inverting all of its inputs, exchanging any & (AND) operators for | (OR) operators (and vice versa), and also inverting its output. In fact, a little thought reveals that these steps are identical to those used in a DeMorgan Transformation. Thus, assertion-level symbols may also be referred to as DeMorgan equivalent symbols. The most commonly used assertion-level symbols are those for BUF, NOT, AND, NAND, OR, and NOR (Fig 5).


5. Commonly used assertion-level symbols.

Note that any tilde characters in the illustration above are part of the signal names and are used to indicate active-low signals. By comparison, the exclamation mark "!" characters (also known as "shriek" or "bang" characters) are used to indicate actual negation operations in the equations.

Clive "Max" Maxfield is president of TechBites Interactive, a marketing consultancy firm specializing in high technology. Max is the author and co-author of a number of books, including Bebop to the Boolean Boogie (An Unconventional Guide to Electronics), The Design Warrior's Guide to FPGAs (Devices, Tools, and Flows), and How Computers Do Math featuring the pedagogical and phantasmagorical virtual DIY Calculator.

Widely regarded as being an expert in all aspects of computing and electronics (at least by his mother), Max was once referred to as "an industry notable" and a "semiconductor design expert" by someone famous who wasn't prompted, coerced, or remunerated in any way. Max can be reached at [email protected].


Related Reading


More Insights






Currently we allow the following HTML tags in comments:

Single tags

These tags can be used alone and don't need an ending tag.

<br> Defines a single line break

<hr> Defines a horizontal line

Matching tags

These require an ending tag - e.g. <i>italic text</i>

<a> Defines an anchor

<b> Defines bold text

<big> Defines big text

<blockquote> Defines a long quotation

<caption> Defines a table caption

<cite> Defines a citation

<code> Defines computer code text

<em> Defines emphasized text

<fieldset> Defines a border around elements in a form

<h1> This is heading 1

<h2> This is heading 2

<h3> This is heading 3

<h4> This is heading 4

<h5> This is heading 5

<h6> This is heading 6

<i> Defines italic text

<p> Defines a paragraph

<pre> Defines preformatted text

<q> Defines a short quotation

<samp> Defines sample computer code text

<small> Defines small text

<span> Defines a section in a document

<s> Defines strikethrough text

<strike> Defines strikethrough text

<strong> Defines strong text

<sub> Defines subscripted text

<sup> Defines superscripted text

<u> Defines underlined text

Dr. Dobb's encourages readers to engage in spirited, healthy debate, including taking us to task. However, Dr. Dobb's moderates all comments posted to our site, and reserves the right to modify or remove any content that it determines to be derogatory, offensive, inflammatory, vulgar, irrelevant/off-topic, racist or obvious marketing or spam. Dr. Dobb's further reserves the right to disable the profile of any commenter participating in said activities.

 
Disqus Tips To upload an avatar photo, first complete your Disqus profile. | View the list of supported HTML tags you can use to style comments. | Please read our commenting policy.