<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Engineersphere.com &#187; Basic Computer Engineering Concepts</title>
	<atom:link href="http://engineersphere.com/category/basic-computer-concepts/feed" rel="self" type="application/rss+xml" />
	<link>http://engineersphere.com</link>
	<description>doesn&#039;t have to make sense to you, but it&#039;s probably great for your health.</description>
	<lastBuildDate>Fri, 28 Oct 2011 03:05:49 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>Circular Buffers</title>
		<link>http://engineersphere.com/basic-computer-concepts/circular-buffers.html</link>
		<comments>http://engineersphere.com/basic-computer-concepts/circular-buffers.html#comments</comments>
		<pubDate>Sat, 16 Oct 2010 06:04:24 +0000</pubDate>
		<dc:creator>Jeff</dc:creator>
				<category><![CDATA[Basic Computer Engineering Concepts]]></category>
		<category><![CDATA[Microcontrollers]]></category>
		<category><![CDATA[circular buffers]]></category>
		<category><![CDATA[data transmission]]></category>
		<category><![CDATA[subroutines]]></category>

		<guid isPermaLink="false">http://engineersphere.com/?p=1935</guid>
		<description><![CDATA[TweetTweetSoftware circular buffers are data structures used to pass data from one section of code to another, where the code sections usually have no other interaction with each other. One situation that dictates that a “buffer” be used is when it is possible that a burst of data to occur that exceeds the “processing” codes [...]]]></description>
			<content:encoded><![CDATA[<div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/circular-buffers.html&via=EngineerSphere&text=Circular Buffers&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/circular-buffers.html&via=EngineerSphere&text=Circular Buffers&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><p>Software circular buffers are data structures used to pass data from one section of code to another, where the code sections usually have no other interaction with each other. One situation that dictates that a “buffer” be used is when it is possible that a burst of data to occur that exceeds the “processing” codes ability to keep up on an item by item basis. Then a separate section of code to buffer (accept from the external source and insert it into a circular buffer) is necessary.</p>
<p>On average, the processing must keep up, or no amount of buffering will prevent an eventual overrun and loss of data. Another situation where you might use a “buffer” is to compartmentalize the functions of your code. For example, if you are using a keypad on a project, you may choose to write one section of code that detects that a key has been pressed, determines what it is, and places the ASCII code for it in a circular buffer.</p>
<p>A completely separate section of code could then process the “stream” of key-presses for the purpose at hand, say a combination lock code. Partitioning the code in this fashion not only makes each section easier to write (each is smaller and you get to focus on a simpler task), but also makes each section more reusable. The combination decoding could easily be used virtually unchanged with the code sequence coming from the SCI instead. The proper view of data in a circular buffer is a “stream” of sequential data items, often characters.</p>
<p>The section of code that sends data to another section inserts each new datum item into the buffer. In general, that code inserts data as fast as it becomes available. The section of code that receives the data removes each item from the buffer.  The receiver almost always has some processing task to perform on the received data items, and often processes at a slower instantaneous rate than the insertion code. It is often the case that several circular buffers will exist within a program. It is also often the case that the sending and/or receiving code sections are in interrupt handler routines. A possible point of confusion is that any receiving ISR routine (say an SCI receive ISR) will probably play the role of sender via the circular buffer. Virtually the only SCI receiver ISR I have ever written was to have it read the incoming characters and place them in a circular buffer, and nothing more.</p>
<h3>How Do Circular Buffers Work?</h3>
<p>A circular buffer is really a linear sequential buffer that is used from beginning to end, over and over. Unlike a STACK which operates as a first-in-last-out (FILO) buffer and naturally keeps reusing memory as items are popped on and later pulled off of the stack, with a circular buffer one must work at reusing memory. This is accomplished by having code to wrap around to the beginning of the buffer whenever the next location gets past the end of the buffer. Picture the buffer as a consecutive set of memory locations that has its last location adjacent to its first location (in effect a circle).<a href="http://engineersphere.com/wp-content/uploads/2010/10/circular-buffer.png"><img class="alignright size-full wp-image-1936" title="circular-buffer" src="http://engineersphere.com/wp-content/uploads/2010/10/circular-buffer.png" alt="circular-buffer" width="423" height="338" /></a><span id="more-1935"></span></p>
<p>This circular buffer forms an endless queue. The queue functions as an endless first-in-first-out (FIFO) buffer. It is indeed endless as long as the process receiving the data never gets a complete buffer length behind the one sending the data. An evaluation of how far behind the receiver may get is the only way to determine the size one needs for the buffer. If it never gets more than one data value behind then a 2-long buffer is sufficient. If it gets up to 99 behind then a 100 element buffer is needed, and so on. In addition to the memory for the buffer itself, essentially an array of data, a circular buffer requires two markers, one to tell where to insert the next datum and one to tell from where to extract the next datum. Note that a stack required only one marker (called the Stack Pointer). The two markers can take either of two forms –<strong> indices or pointers</strong>.</p>
<p>Either type tells the next available location to place new data into the buffer and the next location containing data to be taken out of the buffer. If the buffer is four bytes long, an index would have a value from 0 to 3, whereas, a pointer would contain the address from buffer to buffer+3. The out marker chases the in marker around the buffer. Whenever it catches up it means the code receiving data has caught up with the code sending data and so the buffer is empty (has no more data to process at the moment). There is never a conflict between the two code sections in updating the markers as in marker is only updated (incremented) by the code inserting the buffered data, and out marker is only updated (incremented) by the code extracting the data.</p>
<h3>Common Uses for Circular Buffers</h3>
<p>Probably the most common use of a circular buffer is for storing characters received from an input device. The interrupt handler for the device simply reads the device (usually whenever an interrupt occurs indicating new data has been received), places it in a circular buffer, and exits (returns from the interrupt). There are numerous other uses for circular buffers and no assembly language programmer or high-level language programmer (especially one working with real-time or event-driven systems) should be without this powerful software tool. To implement a circular buffer in any language you need four distinct code sections. First, you must declare the buffer and the two pointer variables that will be used with it. In HCS08 assembler that section will look like this:</p>
<p><a href="http://engineersphere.com/wp-content/uploads/2010/10/declare-circular-buffer.png"><img class="alignleft size-full wp-image-1937" title="declare-circular-buffer" src="http://engineersphere.com/wp-content/uploads/2010/10/declare-circular-buffer.png" alt="declare-circular-buffer" width="590" height="84" /></a></p>
<p style="text-align: left;">There also needs to be an initialization section that is executed before the buffer can be used and must be executed only once in your program. This should exist with the code that is executed almost immediately after reset on any embedded system that uses such buffers. In HC11 assembler it could be:</p>
<p><a href="http://engineersphere.com/wp-content/uploads/2010/10/initialize-circular-buffer.png"><img class="alignleft size-full wp-image-1938" title="initialize-circular-buffer" src="http://engineersphere.com/wp-content/uploads/2010/10/initialize-circular-buffer.png" alt="initialize-circular-buffer" width="494" height="57" /></a></p>
<p style="text-align: left;">So if we are using our circular buffers to move data between a sender and a receiver we will need to make a few<strong> subroutines</strong> to implement our buffers.  The next two sections of code are in (or are in a subroutine called by) the sender or receiver, respectively. I will first show example code for buffers containing single byte data values. (The previous examples are independent of data item size.) The examples are in subroutine form.</p>
<p><a href="http://engineersphere.com/wp-content/uploads/2010/10/add-byte-subroutine.png"><img class="alignleft size-full wp-image-1939" title="add-byte-subroutine" src="http://engineersphere.com/wp-content/uploads/2010/10/add-byte-subroutine.png" alt="add-byte-subroutine" width="551" height="138" /></a></p>
<p><a href="http://engineersphere.com/wp-content/uploads/2010/10/get-byte-subroutine1.png"><img class="alignleft size-full wp-image-1940" title="get-byte-subroutine1" src="http://engineersphere.com/wp-content/uploads/2010/10/get-byte-subroutine1.png" alt="get-byte-subroutine1" width="500" height="92" /></a></p>
<p><a href="http://engineersphere.com/wp-content/uploads/2010/10/get-byte-subroutine2.png"><img class="alignleft size-full wp-image-1941" title="get-byte-subroutine2" src="http://engineersphere.com/wp-content/uploads/2010/10/get-byte-subroutine2.png" alt="get-byte-subroutine2" width="500" height="110" /></a></p>
<p>If the data items are more than one byte then something more than an sta or lda is needed to add or retrieve them, and more than a single increment is needed to advance the pointer in the buffer. Those are the only two changes.</p>
<p>I hope you enjoyed learning about circular buffers! They are truly wonderful.</p>
]]></content:encoded>
			<wfw:commentRss>http://engineersphere.com/basic-computer-concepts/circular-buffers.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>History of Computer Technology</title>
		<link>http://engineersphere.com/basic-computer-concepts/history-of-computer-technology.html</link>
		<comments>http://engineersphere.com/basic-computer-concepts/history-of-computer-technology.html#comments</comments>
		<pubDate>Thu, 26 Aug 2010 03:33:06 +0000</pubDate>
		<dc:creator>Jeff</dc:creator>
				<category><![CDATA[Basic Computer Engineering Concepts]]></category>
		<category><![CDATA[Microcontrollers]]></category>
		<category><![CDATA[Arithmetic Operations]]></category>
		<category><![CDATA[Big Endian]]></category>
		<category><![CDATA[Bit]]></category>
		<category><![CDATA[Branch Instruction]]></category>
		<category><![CDATA[Byte]]></category>
		<category><![CDATA[Byte Conventions]]></category>
		<category><![CDATA[Computer History]]></category>
		<category><![CDATA[Computer Technology]]></category>
		<category><![CDATA[Conditional Branching]]></category>
		<category><![CDATA[HCS08]]></category>
		<category><![CDATA[I/O Devices]]></category>
		<category><![CDATA[IAS]]></category>
		<category><![CDATA[IAS Computer]]></category>
		<category><![CDATA[John Von Neumann]]></category>
		<category><![CDATA[Little Endian]]></category>

		<guid isPermaLink="false">http://engineersphere.com/?p=1582</guid>
		<description><![CDATA[TweetTweetSo this post is a little out of the ordinary, however I figured this nice rant about the history of computer technology may be useful to some readers out there. The History of Computer Technology The first computer built in America was the IAS computer. It was developed at the Institute for Advanced Study at [...]]]></description>
			<content:encoded><![CDATA[<div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/history-of-computer-technology.html&via=EngineerSphere&text=History of Computer Technology&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/history-of-computer-technology.html&via=EngineerSphere&text=History of Computer Technology&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><p>So this post is a little out of the ordinary, however I figured this nice rant about <strong><span style="text-decoration: underline;">the history of computer technology</span></strong> may be useful to some readers out there.</p>
<h3>The History of Computer Technology</h3>
<p>The first computer built in America was the <strong>IAS computer</strong>. It was developed at the Institute for Advanced Study at Princeton under the direction of John Von Neumann between 1946-1950.</p>
<p>This obsolete machine’s architecture is presented not just for its historical significance, though that would be reason enough. Details about it are presented because many (most) modern computers (including the <strong>HCS08</strong>) trace their ancestry to the <strong>IAS machine</strong>. Those that do are referred to as von Neumann (or Princeton) architecture machines. The <strong>IAS architecture</strong> is relatively simple and is a convenient starting point for assembly language programming. An assembly language program for the IAS (though programs for it were written in machine language) would not look very different from modern load/store style machines. Also, a sense of the relative importance of concepts results from learning the IAS architecture. Programs written in a carefully selected subset of the HCS08 instruction set would look almost identical to an IAS assembly program (were we to create an assembler for that machine). We will then see how the complete HCS08 instruction set improves on the IAS instruction set and addressing scheme. The general design of the IAS machine is given below. The HCS08 is almost identical to it.</p>
<p style="text-align: center;"><a href="http://engineersphere.com/wp-content/uploads/2010/08/iasmachine.png"><img class="aligncenter size-full wp-image-1583" title="ias-machine-architecture" src="http://engineersphere.com/wp-content/uploads/2010/08/iasmachine.png" alt="ias-machine-architecture" width="458" height="206" /></a>As originally designed (to cut costs the machine was built with less memory), the memory consisted of 4096 40-bit words. The number of words in <strong>computer memory systems</strong> (at least the maximum memory) always consists of a power of two. This is because the specific word in memory to be accessed at any given time is specified by a set of binary valued wires or lines called the address bus. The number of different locations in memory such a bus can specify is simply all the possible combinations of the two values possible on each of the lines. For an n-bit bus, that value is 2n. The address bus size for the <strong>IAS memory</strong> was therefore 12 providing for 212 = 4096 unique memory locations. The number of bits per word is up to the computer designer. Memory word sizes of 4, 8, 12, 16, 18, 24, 32, 36, 40, 48, 60, and 64 have all existed for some computer. Almost all computers made today use 8-bit memory words, although they all support data types that use several consecutive memory words together as a single value. Most desktop (or larger) computer systems support 8-bit, 16-bit, 32-bit, and 64-bit values. Some even support 128-bit values. Note, all of these sizes are multiples (in fact powers of 2 multiples) of the basic 8-bit word size so these values use 1, 2, 4, and 8 (some even 16) words, respectively. Whatever the memory size, anyone with some programming experience taking their first look at the memory system in a computer design, should think of the memory as an array with 2n elements. The address bus carries the value of an n-bit unsigned index into the memory array. The data bus returns (or supplies if a write instead of a read is issued) the m-bit memory word value of the specified element, where m is the word size (in bits) of the memory system.</p>
<p>The REGS component of the general design represents the register set used by the CPU (Central Processor Unit). Registers are fast special-purpose memory separate from the main memory. They support the fetching and execution of instructions stored in memory. The registers in the IAS design are given below:</p>
<p style="text-align: center;"><a href="http://engineersphere.com/wp-content/uploads/2010/08/iasdesign.png"><img class="aligncenter size-full wp-image-1584" title="ias-design" src="http://engineersphere.com/wp-content/uploads/2010/08/iasdesign.png" alt="ias-design" width="587" height="139" /></a></p>
<h3>IAS Instructions and Data</h3>
<p>The <strong>IAS computer</strong> embodied the concept of a <span style="text-decoration: underline;"><strong>stored-program computer</strong></span>. The main memory contained two main categories of information – instructions and data. It is the ability to place different sequences of instructions in the memory that makes the computer so useful – it is what makes it a general-purpose computing device rather than a special-purpose or single-function computer. Instead of being constrained to building computers that perform only predefined single tasks (or small set of tasks), we can build a computer that does different tasks at different times. Such a computer can be reconfigured (reprogrammed) at any time to perform a new or different task. Often an important task is not even conceived of at the time the computer is designed. For the IAS machine, it was important that the programs and data shared the same memory. That way the instructions themselves could be processed as other data values. Self-modifying programs were the only scheme that the <strong>IAS designers</strong> thought of for performing loops that worked on different array elements each time through the loop. Between iterations of the loop, the instructions that accessed the array element were loaded into the AC and a value added to them to change the address portion of the instruction to the next array element to be processed. The modified instruction was then stored back in its memory location for execution the next time through the loop. Computer designers have since come up with several methods of accomplishing this type of operation without modifying the instructions themselves. Today, self-modifying code is considered taboo, as it is prone to logic errors that are hard to discover, cannot be executed out of <span style="text-decoration: underline;"><strong>Read-Only Memory (ROM)</strong></span>, and other deficiencies that are beyond this article.</p>
<h3>IAS Instruction Sets</h3>
<p>The IAS instructions consisted of 20 bits – a 12-bit address and an 8-bit operation code (opcode). The operation code part specified both an operation and a register. The instruction’s 12-bit address part usually specified an operand by giving the memory address of the memory word involved in the operation. Basic operations like load (copy a value from a memory word to the implied register), store (copy a value from the implied register to a memory word), add (add the value in a memory word to the value in the AC replacing the AC value with the sum) are referred to as memory-reference instructions and form the core instructions for both the IAS machine and the HCS08 microcontroller. When an instruction contains the actual full address of the operand, as the IAS memory-reference instructions did, the value is usually referred to as a direct address and those instructions are said to use the direct addressing mode. Unfortunately, Freescale’s terminology for the HCS08 refers to such instructions as extended addressing mode instructions, and uses direct addressing mode to mean something else. The IAS instruction set had only one other class of instructions which were called register-reference instructions. Such instructions were said to use the inherent addressing mode. The HCS08 also has many such instructions and also refers to them as inherent addressing mode instructions. It is almost an oxymoron to say these instructions have an addressing mode as they use no memory address at all. Such operations involved only the registers. An example of such an instruction for the IAS machine was to add the value in the MQ to the value in the AC replacing the value in the AC with the sum. At this point we should note that descriptions of computer instructions usually shorten the phrase “the value in the Register-name” to just “Register-name”. Thus we describe the above addition as adding MQ to AC. It is implied that we mean the value in or content of the registers, and that by adding “to” we are replacing the original value after it is used in the operation with the result of the operation. An example of a similar instruction in the HCS08 instruction set is the “mul” instruction. It means multiply X times A, where X and A are HCS08 registers, replacing the value in the X:A pair with the 16-bit product.</p>
<p>Normally, instructions are executed in the sequence they appear in memory with the instruction in Memory[i+1] being executed immediately following the execution of the instruction in Memory[i]. The <strong>CPU register</strong> that keeps track of where the next instruction is located is the PC. Its name come from the fact that it is an index into the Program and that its normal mode of being modified is to be incremented (so it Counts) after each instruction. On the IAS machine each instruction occupied only half a word so the PC was incremented after every other instruction. There was an additional Register bit that told whether the current instruction was in the first or last half of the word referenced by the PC. On the HCS08 instructions take from one to four memory words, so its PC may be incremented several times per instruction.</p>
<h3>Branch (jump) Instruction</h3>
<p>A different type of instruction from those that manipulate data is the branch (or jump) instruction. They are so named because they cause the CPU to deviate from the normal sequence of instructions. Instructions in this class change the value of the PC from its normal incrementing sequence by loading a new value into it in much the same way that the loading of other registers work. A big difference, however, is that branch and jump instructions usually come in both unconditional and conditional varieties. The unconditional ones always change the course of execution from the normal sequential order, the conditional ones, however, may change it or they may let the normal order continue. Which program path occurs usually depends on the outcome of some previous operation such as subtracting one value from another. The IAS’s conditional branch would change the normal sequence if the result of the most recent arithmetic operation were positive, otherwise it would let the normal sequence continue. Conditional branching is the feature that gives computers the power to perform complex algorithms. Without it they would only be able to perform simple formula-based calculations! The HCS08 has a rich assortment of conditional branch instructions. <strong><em>Conditional branching is the feature that gives computers the power to perform complex <span style="text-decoration: underline;">algorithms</span>.</em></strong> Without it they would only be able to perform simple formula-based calculations! The HCS08 has a rich assortment of conditional branch instructions.</p>
<h3>Arithmetic Instructions</h3>
<p>Data values in the IAS machine consisted of signed binary fixed-point numbers 40 bits in size. The sign used one bit so 39 bits remained to hold the magnitude of the value. The 39 bits are equivalent to about 12 decimal digits. As is true today, these fixed-point numbers could be considered to be integers or to contain fractional parts depending on where the binary point was considered to be. The hardware that performs calculations on the data works for a wide variety of conventions. Addition and subtraction require only that both operands are considered to have the binary point in the same position, there is no restriction on where it is considered to be. Multiply and divide don’t have even that restriction, but one must understand where the binary point of the results must be considered to be. Experimentation with decimal numbers with varying number of digits following the decimal point will allow one to understand the outcomes, and formulate the rules for properly placing binary points for the various computer operations. It should be made perfectly clear that no bits are used to indicate where the binary point is located; its position only exists in the way the programmer intends to interpret the value represented by the bits in the data word. Addition and subtraction instructions in the HCS08 support 8-bit unsigned and 2’s complement (signed) values. The multiply supports only 8-bit by 8-bit unsigned values – producing a 16-bit unsigned result. The divide instruction supports only a 16-bit by 8-bit unsigned divide, that produces an 8-bit quotient and a 8-bit remainder. By dividing the remainder by the original dividend, the quotient’s precision can be extended another 8 bits. This process can be repeated to any desired precision.</p>
<h3>Indirect Addressing</h3>
<p>The first architectural improvement in computers that eliminated the need to have self-modifying code was <strong><span style="text-decoration: underline;">indirect addressing</span></strong>. This addressing mode makes use of a pointer data type. A pointer is a word (or multiple words if a word is too small) that has a value used as an address to another word in the memory. To specify an address indirectly, the indirect addressing mode instruction contains the address of a pointer instead of the data. The CPU knows that for such instructions there must be two memory areas accessed. The first reads the pointer and then uses its value as the address to access (read or write) the actual operand. To change the memory location accessed by such an instruction, the instruction itself need not be modified, only the value of the pointer variable. Few computers still use this form of indirect addressing, but rather its cousin, register addressing or a variation of it. In <strong><span style="text-decoration: underline;">register addressing</span></strong>, the pointer value must be loaded into an address register with one instruction, and then that address used with another instruction. Again, to modify the actual data location a register addressing mode instruction accesses, one need only modify the value in the address register. The HCS08 has two such address registers, H:X and SP, although the SP main use is as a stack pointer. A variety of addressing modes based on those two registers are available.</p>
<p>Modern desktop computers now have many registers that can be used as accumulators and/or address registers. It is not uncommon for a computer to have 32 32-bit general- purpose registers that can be used for either. The HCS08 has only a microprocessor as its computing core, so it has only a single 8-bit accumulator and a pair of 16-bit index (address) registers – no general-purpose registers. In order to program in <span style="text-decoration: underline;"><strong>machine language</strong><strong> assembly language</strong></span> or you must first learn the architecture of the computer you plan to program. The architecture of a computer specifies the registers in the CPU, the main memory size, and the instruction set (including not only the operations it can perform, but also all the addressing modes supported).</p>
<p>We are ready to study the architecture of the HCS08 microcontroller’s microprocessor core. The general design is given below. It is only a slight modification of the IAS one shown earlier. The only difference is that the Input/Output (I/O) devices are <strong><span style="text-decoration: underline;">memory-mapped devices</span></strong>. That is, you access them as though they were normal memory, with load and store instructions within the main memory address space.</p>
<p style="text-align: center;"><a href="http://engineersphere.com/wp-content/uploads/2010/08/HCS08architecture.png"><img class="aligncenter size-full wp-image-1585" title="HCS08-architecture" src="http://engineersphere.com/wp-content/uploads/2010/08/HCS08architecture.png" alt="HCS08-architecture" width="423" height="193" /></a>There are big differences with the details of the design. The register set is different, the memory size and shape are different, and the instruction set contains many more instructions. However, the basic functioning of the machines is very much the same. They both have the same load/store nature where most ALU operations must be performed on values in the CPU’s registers. They are both single address machines in that at most one of the operands of binary (two operand) operations (such as add) can come from main memory. (Actually the HCS08 has a very limited set of “move” instructions that transfer data from one memory location to another without going through a register.) The main memory can contain both instructions and data at virtually any location (even intermixed – although we will try not to do that). The CPU can operate on instructions as though they were data.</p>
<h3>Memory Comparisons</h3>
<p>Let’s check out the differences. The main memory of the IAS held 4096 40-bit values. The memory space of the HCS08 provides for 65536 8-bit values. Thus the HCS08 memory system uses a 16-bit address bus (216 = 65536) and an 8-bit data bus. The address bus carries information only one direction, to the memory system, but the data bus can carry information either to or from the memory (thus the double arrowheads on the data bus above). Not shown in the above diagram are control signals that tell the memory such things as whether a read or write is being performed. Each of the 65536 memory locations should be thought of as having an address and a contents (or value). The address is a 16-bit (4-hexadecimal-digit) number, while the contents is an 8-bit (2-hexadecimal digit) number. When we look at the instruction format we will find it is convenient that the value of an address can be stored exactly in two words of memory. In truth, that ability is the cause of the memory space being the size that it is.</p>
<p>At the risk of being too remedial, I will emphasize a possibly painfully obvious, but extremely important, concept. We often show the content of a section of memory by listing the memory address in one column and its content in another. Consider the example below. The left pair are in binary and the right in hexadecimal.</p>
<p><a href="http://engineersphere.com/wp-content/uploads/2010/08/memoryaddress.png"><img class="alignleft size-full wp-image-1586" title="memory-addressing" src="http://engineersphere.com/wp-content/uploads/2010/08/memoryaddress.png" alt="memory-addressing" width="521" height="134" /></a></p>
<p>First, note how much more compact the hexadecimal (we’ll shorten that name as well, and start calling it hex) notation is. From this point on we will use mostly hex notation for address and values.</p>
<p>The key point I want to make is that only the value part is stored anywhere. The address is a fleeting number generated one at a time as needed and then its value disappears. When a program is being executed the Program Counter (PC) provides that value for instruction fetch. After each use of the PC it is incremented so the previous address value does not exist anywhere any more. The new value will exist only while it is being used to read the next word of the program.<br />
Because the addresses are consecutive over an area of interest we often will show only the lowest address with a set of data values. By convention know that each successive memory content value is at an address that is one greater than the previous content. Thus the above set of memory values could be given as:<br />
020D: 5B D8 74 06 31<br />
A colon is often used to separate the address from a sequence of data values for added clarity. Here is my last restatement of the (hopefully blatantly obvious) address/data relationship – whenever the contents of locations 020D-0211 are given, the address part can never change, only the content can.</p>
<h3>Byte Conventions</h3>
<p>The HCS08 instruction set supports one 16-bit load operation. As 16-bit values require 2 words of memory, and the instructions specify only a single address, a convention must be established as to which of the two memory addresses that contain the 16-bit value will be specified in the instruction. It must also be decided whether the most-significant byte (MSB) or the least-significant byte (LSB) should be stored in the lower-numbered address of the pair. For me, this last question has an obviously best answer. Place the MSB at lower-numbered addresses. This convention is known as <span style="text-decoration: underline;"><strong>big-endian</strong></span> memory organization. When consecutive address values are written horizontally, the MSB will be to the left. This follows the standard convention for decimal numbers where more-significant digits appear to the left of less-significant digits. This convention, that more-significant bytes of multi-byte value be stored at lower address values, will never be violated in this course. In every situation that the HCS08 hardware dictates how they will appear, that convention is adhered to. In every situation where the programmer must decide, I will require that this rule be followed as well. Some machine designs even specify that two-byte values must start on an even address. Such requirements are referred to as memory alignment restrictions, but the HCS08 has no such restriction. The HCS08 always uses the address of the MSB, which is the lower of the pair. We will adopt that same convention, using the lowest address as the “handle”, for any program-defined groups of bytes for any size group that we create.</p>
<h3>Registers to know</h3>
<p>The Registers that you may need to know the most about are the ones in the Programmer’s Model as shown on Page 86 of the MC9S08QG Data Sheet for HCS08 Microcontrollers that is available in pdf form on the web and distributed in booklet form in class compliments of Freescale. The A register is an 8-bit accumulator used primarily for 8-bit arithmetic and load/store style moving of data. The H:X and SP register are used primarily for addressing. They are 16-bit registers so can point to any location in the memory space. The stack pointer (SP) exists primarily to support stack operations built into the hardware – we will learn all about these operations later. It is a 16-bit register as the stack utilizes main memory, and a 16-bit value allows the stack data to be placed anywhere in the memory space. The program counter (PC) tells where in the memory the next instruction to be executed is located. It is a 16-bit register so that instructions can exist and be executed out of any location in the memory space. The condition code register (CCR) keeps machine state information – our main programming use of it will be to guide conditional branch execution along the two paths that such instructions can direct a program. It is an 8-bit register.</p>
<p>This was wordy and didn&#8217;t necessarily wrap up completely but we have learned a lot of new information!  I hope you enjoyed this article about the history of computer technology and how this introduces you to how a simple computer called a <span style="text-decoration: underline;"><strong>microcontroller </strong></span>works.</p>
]]></content:encoded>
			<wfw:commentRss>http://engineersphere.com/basic-computer-concepts/history-of-computer-technology.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Karnaugh Maps</title>
		<link>http://engineersphere.com/basic-computer-concepts/karnaugh-maps.html</link>
		<comments>http://engineersphere.com/basic-computer-concepts/karnaugh-maps.html#comments</comments>
		<pubDate>Tue, 29 Sep 2009 17:07:25 +0000</pubDate>
		<dc:creator>chrislego88</dc:creator>
				<category><![CDATA[Basic Computer Engineering Concepts]]></category>
		<category><![CDATA[Binary]]></category>
		<category><![CDATA[Boolean expressions]]></category>
		<category><![CDATA[K Maps]]></category>
		<category><![CDATA[Karnaugh Maps]]></category>
		<category><![CDATA[Truth Tables]]></category>

		<guid isPermaLink="false">http://engineersphere.com/?p=828</guid>
		<description><![CDATA[TweetTweetWhat are Karnaugh Maps used for? Karnaugh maps or K-maps for short are used for simplifying Boolean expressions. K-maps are constructed depending on the number of variables, or bits, in the expression. For example if the expression is f(A,B,C,D) = A + D, there are 4 bits to consider. Before starting to construct the K-Map you [...]]]></description>
			<content:encoded><![CDATA[<div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/karnaugh-maps.html&via=EngineerSphere&text=Karnaugh Maps&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/karnaugh-maps.html&via=EngineerSphere&text=Karnaugh Maps&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><h3>What are Karnaugh Maps used for?</h3>
<p>Karnaugh maps or K-maps for short are used for simplifying Boolean expressions. <strong>K-maps</strong> are constructed depending on the number of variables, or bits, in the expression. For example if the expression is f(A,B,C,D) = A<img src='http://s.wordpress.com/latex.php?latex=%5Cscriptstyle%20%5Coverline%7BC%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\scriptstyle \overline{C} ' title='\scriptstyle \overline{C} ' class='latex' />  + D<img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BB%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{B} ' title='\overline{B} ' class='latex' />, there are 4 bits to consider. Before starting to construct the K-Map you should first create the truth table for the function you are implementing. After this is done it is time to make the K-Map. First thing to do is to draw the box for the K-Map.</p>
<p><a href="http://upload.wikimedia.org/wikipedia/commons/6/62/K-map_4x4_empty.svg"><img title="empty-karnaugh-map" src="http://upload.wikimedia.org/wikipedia/commons/thumb/6/62/K-map_4x4_empty.svg/275px-K-map_4x4_empty.svg.png" alt="empty-karnaugh-map" width="275" height="275" /></a></p>
<p>Notice that the most significant bit (A) is on top followed by B and so on.On the top bar 00 stand for AB, 01 stand for A<img src='http://s.wordpress.com/latex.php?latex=%5Cscriptstyle%20%5Coverline%7BB%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\scriptstyle \overline{B} ' title='\scriptstyle \overline{B} ' class='latex' />, and so on. Also the order of the bits is not the standard binary counting order. The order is created in such a way that only one bit at a time is changed.</p>
<h3>Filling out a Karnaugh Map</h3>
<p>Once the table has been created it is time to take the data from the truth table to the K-Map. Copy all the outputs from the truth table onto the K-Map according to what the inputs are. For example, if<br />
ABCD | F<br />
0000  | 0<br />
0001  | 1<br />
0010  | 0<br />
etc.</p>
<p>Remember that the 3rd row is flipped with the 4th, so change the outputs accordingly.</p>
<p>After the K-Map has been filled in it is time to try to simplify the boolean expression. There are two ways to do this, either SOP (Sum of Products) or POS( Products of Sum). The difference between the two is what you group together. In SOP you would group all the 1&#8242;s in the K-Map together, and in POS you group the 0&#8242;s. In the examples, I will be using SOP.</p>
<p>What does grouping mean? Grouping means that if there 1&#8242;s which are next to each other than you can circle them together to create a simpler boolean expression in the end. The trick is that you can only circle an even number of 1&#8242;s. So if three 1&#8242;s are next to each other you can only circle them as groups of 2. It is possible to group 1&#8242;s at 0000 and 1000; 1000 and 1010; and so on.</p>
<h3>A Karnaugh Map example</h3>
<p>For example<br />
CD<br />
AB    <span style="text-decoration: underline;">00   01    11      10</span><br />
00  |<span style="text-decoration: underline;"> 1 </span>| <span style="text-decoration: underline;"> 1   |   1   |   1   |</span><br />
01   | <span style="text-decoration: underline;"> 0 </span>|<span style="text-decoration: underline;"> 0   |   0   |   0  | </span><br />
11    | <span style="text-decoration: underline;"> 0 </span>|<span style="text-decoration: underline;"> 0  |   0   |   1   |</span><br />
10   | <span style="text-decoration: underline;"> 1 </span>|<span style="text-decoration: underline;"> 1  |   0   |   1   |</span></p>
<p><span>To simply this expression, you should group:</span></p>
<p><span>1.  all the 1&#8242;s in AB = 00<br />
2.  1&#8242;s from AB = 10 and C = 0<br />
3.  1&#8242;s from CD = 10 and A = 1</span></p>
<p><span>The way to simply the expression is you note the changes in bits in the groupings.<br />
<strong>In grouping 1:</strong> The only bits to stay the same are bits AB which stay at 00. So the simplified expression would be  <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BA%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{A}' title='\overline{A}' class='latex' /> * <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BB%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{B}' title='\overline{B}' class='latex' /><br />
<strong>In grouping 2 : </strong>The only bit to change is D. So the expression becomes A * <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BB%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{B}' title='\overline{B}' class='latex' /> * <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BC%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{C}' title='\overline{C}' class='latex' /><br />
<strong>In grouping 3:</strong> The only bit to change is B. So the expression becomes A* C * <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BD%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{D}' title='\overline{D}' class='latex' /></span></p>
<p><span>So the final expression would turn into F(A,B,C,D) = <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BA%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{A}' title='\overline{A}' class='latex' /> * <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BB%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{B}' title='\overline{B}' class='latex' /> + A * <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BB%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{B}' title='\overline{B}' class='latex' /> * <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BC%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{C}' title='\overline{C}' class='latex' /> + A* C * <img src='http://s.wordpress.com/latex.php?latex=%5Coverline%7BD%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\overline{D}' title='\overline{D}' class='latex' /></span></p>
<p>Note: This expression is not hazard free. To make hazard free group all possible 1&#8242;s together.</p>
]]></content:encoded>
			<wfw:commentRss>http://engineersphere.com/basic-computer-concepts/karnaugh-maps.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Finite State Machines</title>
		<link>http://engineersphere.com/basic-computer-concepts/finite-state-machines.html</link>
		<comments>http://engineersphere.com/basic-computer-concepts/finite-state-machines.html#comments</comments>
		<pubDate>Thu, 10 Sep 2009 04:01:00 +0000</pubDate>
		<dc:creator>Kyle</dc:creator>
				<category><![CDATA[Basic Computer Engineering Concepts]]></category>
		<category><![CDATA[Control Systems]]></category>
		<category><![CDATA[Electromagnetic Theory]]></category>
		<category><![CDATA[Finite state machines]]></category>
		<category><![CDATA[mealy machines]]></category>
		<category><![CDATA[moore machines]]></category>
		<category><![CDATA[state machines]]></category>

		<guid isPermaLink="false">http://engineersphere.com/?p=808</guid>
		<description><![CDATA[TweetTweetA Finite State Machine (FSM), or just state machine, is a model of behavior composed of a finite number of states. We use these in computer engineering to model a &#8220;machine&#8221; with primitive memory. Based on the signals  we recieve, we go to a certain state where information is processed, and then we wait for [...]]]></description>
			<content:encoded><![CDATA[<div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/finite-state-machines.html&via=EngineerSphere&text=Finite State Machines&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/finite-state-machines.html&via=EngineerSphere&text=Finite State Machines&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><p>A Finite State Machine (FSM), or just state machine, is a model of behavior composed of a finite number of states. We use these in computer engineering to model a &#8220;machine&#8221; with primitive memory. Based on the signals  we recieve, we go to a certain state where information is processed, and then we wait for the signal that indicates we move to the next state.  There are two types of FSMs we will talk about: Moore machines and Mealy machines.</p>
<h3>Moore Machines</h3>
<p>Moore machines are state machines where the output is determined by only the current state, not the inputs. For example, if we  had designed a system where the state table looks like this:</p>
<table style="border-collapse: collapse; width: 207pt;" border="0" cellspacing="0" cellpadding="0" width="276">
<col style="width: 88pt;" width="117"></col>
<col style="width: 71pt;" width="95"></col>
<col style="width: 48pt;" width="64"></col>
<tbody>
<tr style="height: 18.75pt;" height="25">
<td style="height: 18.75pt; width: 88pt;" width="117" height="25">Current   State</td>
<td style="width: 71pt;" width="95">Next State</td>
<td style="width: 48pt;" width="64">Input</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">00</td>
<td>01</td>
<td>XX</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">01</td>
<td>10</td>
<td>XX</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">10</td>
<td>11</td>
<td>XX</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">11</td>
<td>00</td>
<td>XX</td>
</tr>
</tbody>
</table>
<p><tt></tt></p>
<p>we can see that it doesn&#8217;t even matter what the input and outputs are, the next state only depends on the current state. A typical example of Moore style state machines is a synchronous circuit composed of flip-flops connected to a clock. The state can only change when the clock pulses, and for flip-flops, the output(next state) is a function of the input(current state).</p>
<h3>Mealy Machines</h3>
<p>By contrast there are FSMs called Mealy machines where the next state is a function of both the current state, and the input.</p>
<p>Consider the truth table we discussed earler. In our Moore state machine design, we didn&#8217;t care what the input was. Now, however, we have decided that if the current state is 00 and the input is 0 , the next state is 01 .</p>
<table style="border-collapse: collapse; width: 207pt;" border="0" cellspacing="0" cellpadding="0" width="276">
<col style="width: 88pt;" width="117"></col>
<col style="width: 71pt;" width="95"></col>
<col style="width: 48pt;" width="64"></col>
<tbody>
<tr style="height: 18.75pt;" height="25">
<td style="height: 18.75pt; width: 88pt;" width="117" height="25">Current   State</td>
<td style="width: 71pt;" width="95">Next State</td>
<td style="width: 48pt;" width="64">Input</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">00</td>
<td>01</td>
<td>0</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">00</td>
<td>01</td>
<td>1</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">01</td>
<td>10</td>
<td>0</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">01</td>
<td>10</td>
<td>1</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">10</td>
<td>11</td>
<td>0</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">10</td>
<td>11</td>
<td>1</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">11</td>
<td>00</td>
<td>0</td>
</tr>
<tr style="height: 15pt;" height="20">
<td style="height: 15pt;" height="20">11</td>
<td>00</td>
<td>1</td>
</tr>
</tbody>
</table>
<p>We can see above that the next state is a function of the current state, and the input. A real world example of a  Mealy machine is a mathematical cypher machine.</p>
<p>Mealy machines are typically sequential logic, whereas Moore machines are combinatorial logic.</p>
]]></content:encoded>
			<wfw:commentRss>http://engineersphere.com/basic-computer-concepts/finite-state-machines.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ABEL Logic Simplified</title>
		<link>http://engineersphere.com/basic-computer-concepts/abel-logic-simplified.html</link>
		<comments>http://engineersphere.com/basic-computer-concepts/abel-logic-simplified.html#comments</comments>
		<pubDate>Mon, 27 Jul 2009 09:48:36 +0000</pubDate>
		<dc:creator>Eli</dc:creator>
				<category><![CDATA[Basic Computer Engineering Concepts]]></category>
		<category><![CDATA[ABEL]]></category>
		<category><![CDATA[ABEL Logic]]></category>
		<category><![CDATA[ABEL Logic Simplified]]></category>
		<category><![CDATA[Digital Logic]]></category>

		<guid isPermaLink="false">http://engineersphere.com/?p=499</guid>
		<description><![CDATA[TweetTweetABEL Logic is the simplest way to turn an idea in your brain to a working digital circuit.  It is very easy to understand, works like english and functions like a digital circuit so you can easily turn any idea into a working PLD chip that&#8217;ll do exactly what you want.  To get started writing [...]]]></description>
			<content:encoded><![CDATA[<div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/abel-logic-simplified.html&via=EngineerSphere&text=ABEL Logic Simplified&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-computer-concepts/abel-logic-simplified.html&via=EngineerSphere&text=ABEL Logic Simplified&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><p>ABEL Logic is the simplest way to turn an idea in your brain to a working digital circuit.  It is very easy to understand, works like english and functions like a digital circuit so you can easily turn any idea into a working PLD chip that&#8217;ll do exactly what you want.  To get started writing your first ABEL powered device you just need to know your inputs, your outputs and what you want your outputs to do based on your inputs.  This is much simpler than it sounds.</p>
<p>Let&#8217;s say you have two buttons and a light bulb.  You want to turn on the light anytime one of the buttons is pushed. We&#8217;ll first give the buttons names and call them our inputs.  Button one will be called <img src='http://s.wordpress.com/latex.php?latex=B_%7B1%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{1} ' title='B_{1} ' class='latex' /> and button two will be <img src='http://s.wordpress.com/latex.php?latex=B_%7B2%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{2} ' title='B_{2} ' class='latex' />.  We&#8217;ll call the light bulb L.  Since ABEL is a digital circuit that means for every input and output we only have two combinations 1 or 0, on or off.  We use this to represent if they produce power or not.  In the language we use the exclamation point to represent off <strong>!</strong>.</p>
<p><strong>First we check if button one is on:</strong><br />
<img src='http://s.wordpress.com/latex.php?latex=B_%7B1%7D%20%3D%20L%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{1} = L ' title='B_{1} = L ' class='latex' /><br />
This says if button 1 is on then light is on.  If we wanted to say button 1 is off then the light is on we would write that as <strong>!</strong><img src='http://s.wordpress.com/latex.php?latex=B_%7B1%7D%20%3D%20L%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{1} = L ' title='B_{1} = L ' class='latex' />.  That would cause it so every time the button isn&#8217;t pressed the light would come on, and the light would turn off when it is pressed.  This is known as an inverter.</p>
<p>Next we check if button two is on:<br />
<img src='http://s.wordpress.com/latex.php?latex=B_%7B2%7D%20%3D%20L%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{2} = L ' title='B_{2} = L ' class='latex' /><br />
This does the same thing for button two.  The problem here is we can&#8217;t use both because then if only one button is pressed then the light gets both an on and an off signal, which is called a &#8220;Data contention error.&#8221;  Which can cause problems for our little bulb buddy when the circuit sends the wrong amperage with the same voltage.  So we have to combine them into one single statement using the english word OR.</p>
<p><img src='http://s.wordpress.com/latex.php?latex=B_%7B1%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{1} ' title='B_{1} ' class='latex' /> OR <img src='http://s.wordpress.com/latex.php?latex=B_%7B2%7D%20%3D%20L%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{2} = L ' title='B_{2} = L ' class='latex' /><strong><br />
</strong></p>
<p>This means if button 1 OR button 2 is pressed then light is ON. In ABEL we simplify the OR statement by using the character +.  So it becomes</p>
<p><img src='http://s.wordpress.com/latex.php?latex=B_%7B1%7D%20%2B%20B_%7B2%7D%20%3D%20L%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{1} + B_{2} = L ' title='B_{1} + B_{2} = L ' class='latex' /></p>
<p>If Mr. Bossman comes to use later and says whoah there!  I want it so the light only comes on if button 2 is pressed and button one is not then we would use our inverter character (the <strong>!</strong>) to change the circuit to:</p>
<p><strong>!</strong><img src='http://s.wordpress.com/latex.php?latex=B_%7B1%7D%20B_%7B2%7D%20%3DL%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{1} B_{2} =L ' title='B_{1} B_{2} =L ' class='latex' /></p>
<p>This literally translates to NOT button1 AND button 2 turns light on.  Everything else keeps the light off.  We can use the OR make other combinations the boss might specify such as if button 1 is not pressed but button 2 is pressed or if both buttons are pressed at the same time.  The OR is represented by the addition symbol +.  The AND symbol is represented by the multiplication.  Which is literally what they mean in standard mathematics.</p>
<p><strong>!</strong><img src='http://s.wordpress.com/latex.php?latex=B_%7B1%7D%20B_%7B2%7D%20%2B%20B_%7B1%7D%20B_%7B2%7D%20%3D%20L%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='B_{1} B_{2} + B_{1} B_{2} = L ' title='B_{1} B_{2} + B_{1} B_{2} = L ' class='latex' /></p>
<p>This means the light comes on if NOT button1 AND button 2 is pressed or if button 1 and button 2 are pressed.</p>
<h3>Building A Garage Door Opener Using ABEL</h3>
<p>Using our knowledge we just learned we can build just about anything by putting it into ABEL.  Let&#8217;s pretend Mr. Bossman tells us he wants us to build him a microchip that will control a garage door opener.  If the opener has power then it will open the door, if it doesn&#8217;t then it will shut the door.  There are two buttons and a safety laser.  One button is on the inside of the garage and the other on the outside.  There is a safety laser that is always on and if something blocks it will send a voltage to the circuit at which time we need to open the door immediately to make sure we don&#8217;t continue to shut it on a Fluffins the mildly braindamaged neighborhood cat.</p>
<p>While taking notes on what Mr. Bossman is telling us he wants we write:  Open door if Inside Button is on AND Laser is off OR open door if outside button is on AND Laser off OR open door if Laser is on.  In ABEL logic this gets written exactly as it is spoken, and we will use IB as inside button and OB as outside button and L as the laser and finally the door opener as the output of O.</p>
<p><strong>IB!L+OB!L + !L = O</strong></p>
<p>It really is that simple!  We can put that equation into an ABEL enabled PLD software and get a chip that when plugged into the correct inputs and outputs gives us a functioning garage door opener.  There are other commands and syntaxes to help you get really advanced with it.  Here is a great list of them: <a href="http://mazsola.iit.uni-miskolc.hu/cae/docs/xabel.html">List of ABEL HDL commands</a>.</p>
<p><strong>Question for the comments!</strong></p>
<p>How would you use ABEL to design a street light traffic system?  You have two total sensor pads, one at each street crossing.  When a car stops on the sensor pads the sensor sends voltage to the controller.  You have two outputs, a green light and a red light.  When the light has voltage the red light is ON and the green is OFF.  When it is at a logic 0 (off) it flips the red light off and the green light on.  See if you can figure it out!</p>
]]></content:encoded>
			<wfw:commentRss>http://engineersphere.com/basic-computer-concepts/abel-logic-simplified.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Count In Binary</title>
		<link>http://engineersphere.com/math/how-to-count-in-binary.html</link>
		<comments>http://engineersphere.com/math/how-to-count-in-binary.html#comments</comments>
		<pubDate>Mon, 27 Jul 2009 08:43:15 +0000</pubDate>
		<dc:creator>Eli</dc:creator>
				<category><![CDATA[Basic Computer Engineering Concepts]]></category>
		<category><![CDATA[Math]]></category>
		<category><![CDATA[Binary]]></category>
		<category><![CDATA[counting in binary]]></category>

		<guid isPermaLink="false">http://engineersphere.com/?p=492</guid>
		<description><![CDATA[TweetTweetHow do binary numbers work? Binary numbers work exactly like our decimal system. It&#8217;s called Decimal because it has 10 total combinations per digit. For instance we count 0-1-2-3-4-5-6-7-8-9 which gives us 10 total numbers we can use in a single digit. When we run out of digits we add one to the leading digit [...]]]></description>
			<content:encoded><![CDATA[<div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/math/how-to-count-in-binary.html&via=EngineerSphere&text=How To Count In Binary&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/math/how-to-count-in-binary.html&via=EngineerSphere&text=How To Count In Binary&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><h3>How do binary numbers work?</h3>
<p>Binary numbers work exactly like our decimal system. It&#8217;s called Decimal because it has 10 total combinations per digit. For instance we count 0-1-2-3-4-5-6-7-8-9 which gives us 10 total numbers we can use in a single digit. When we run out of digits we add one to the leading digit and switch the current digit to the first combination. For instance when we count in decimal and we get to 19 we add 1 to the first digit making it a 2 and turn the current digit to our first combination,a zero, making a 20. Whenever there is no digit in front we assume its a zero so when we count to 10 and we&#8217;re at 9 we add one to the first digit turning it from a zero to a one. Then we turn our current digit, the nine, to a zero making 10. It works infinitely so we can be at 999,999 and our next number would be 1,000,000.</p>
<p>Binary counting is exactly the same only even simpler because it only has two combinations, 0-1. The only combinations in digits you have available to you is zero or one. So you start your count with 0. Then you add one to bring you to <strong>1</strong>. Then when you add another, since you&#8217;re at your max combinations for that single digit you need to add one to the leading digit and turn your current digit to zero. So the decimal #2 becomes 10 in binary. That may look like a 10 in decimal but in binary since you only have two combinations per digit it translate to the number 2. You&#8217;re next number would be done the same way. You add one to your current digit which in the 10 would become <strong>11</strong>. This becomes the number 3 in decimal. Once again to add one you need to add one to the leading digit which would be the <strong><span style="text-decoration: underline;">1</span>1</strong> and turn your current digit to zero making it <strong>100</strong> for the count of four. Much like learning to count it gets much simpler the more you practice.</p>
<p><strong>Try figuring out what the next number would be in this sequence:</strong><br />
0000=0<br />
0001=1<br />
0010=2<br />
0011=3<br />
0100=4<br />
0101=5<br />
0110=6<br />
0111=7<br />
1000=8<br />
1001=9<br />
1010=10<br />
1011=11<br />
____=12</p>
<p><em>Answer: 1100</em></p>
<h3>Figuring Out Long Numbers In Binary</h3>
<p>As mentioned binary works exactly like our decimal system only it has two combinations per digit instead of ten. When you&#8217;re brain is trying to figure out how large a decimal number is it looks at all the placements of the digits and their values. For instance the number 321 is <img src='http://s.wordpress.com/latex.php?latex=3%20x%2010%5E2%20%2B%202%20x%2010%5E1%20%2B%201%20x%2010%5E0%20%3D%20321%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='3 x 10^2 + 2 x 10^1 + 1 x 10^0 = 321 ' title='3 x 10^2 + 2 x 10^1 + 1 x 10^0 = 321 ' class='latex' />. The 10 base number is because there is 10 combinations per digit. The power is the placement of that digit and the number being multiplied by it is the number in that position. So to get the number 400 it is <img src='http://s.wordpress.com/latex.php?latex=4%20x%2010%5E2%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='4 x 10^2 ' title='4 x 10^2 ' class='latex' />. In reality this is done for every digit so 50 would actually be <img src='http://s.wordpress.com/latex.php?latex=5%20x%2010%5E1%20%2B%200%20x%2010%5E0%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='5 x 10^1 + 0 x 10^0 ' title='5 x 10^1 + 0 x 10^0 ' class='latex' />. Since anything multiplied by zero is zero we tend to ignore those as to not confuse ourselves when doing large numbers. Binary is done the same way except since there is only ones and zeros you only need to concern yourself with the ones. So the binary number 0100 would be <img src='http://s.wordpress.com/latex.php?latex=1%20x%202%5E2%20%3D%204&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='1 x 2^2 = 4' title='1 x 2^2 = 4' class='latex' /> Therefore 1010 would be <img src='http://s.wordpress.com/latex.php?latex=1%20x%202%5E3%20%2B%201%20x%202%5E1%20%3D%2010%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='1 x 2^3 + 1 x 2^1 = 10 ' title='1 x 2^3 + 1 x 2^1 = 10 ' class='latex' />. This makes it easy to figure out really long binary numbers such as 00110111 because logically on paper that would be <img src='http://s.wordpress.com/latex.php?latex=1%20x%202%5E5%20%2B%201%20x%202%5E4%20%2B%201%20x%202%5E2%20%2B%201%20x%202%5E1%20%2B%201%20x%202%5E0%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='1 x 2^5 + 1 x 2^4 + 1 x 2^2 + 1 x 2^1 + 1 x 2^0 ' title='1 x 2^5 + 1 x 2^4 + 1 x 2^2 + 1 x 2^1 + 1 x 2^0 ' class='latex' /> for a decimal answer of 55.</p>
<p><strong>Using What You&#8217;ve Learned Try To Figure Out The Decimal Equivilant of This Binary Number:</strong><br />
10110111</p>
<p><em>Answer: 183</em></p>
<h3>Bits And Bytes</h3>
<p>When people talk about bits and bytes of binary they&#8217;re referring to how many assumed leading zeros are in the number. So a 4 bit binary number of two would be 0010. An 8bit version of the number 2 would be 00000010. As with decimal the zeros are always there they just aren&#8217;t shown unless you need to specify a maximum amount that you want. So if you said you want a 8 bit binary representation of the number 85 you would get 01010101. A byte is simply 8 bits. So if you said you wanted a 2 byte representation of the number 85 you would get 0000000001010101 for a total of 16 bits.</p>
<p><strong>Good luck and happy counting!</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://engineersphere.com/math/how-to-count-in-binary.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Complex Numbers</title>
		<link>http://engineersphere.com/basic-electrical-concepts/complex-numbers.html</link>
		<comments>http://engineersphere.com/basic-electrical-concepts/complex-numbers.html#comments</comments>
		<pubDate>Sat, 25 Jul 2009 21:46:10 +0000</pubDate>
		<dc:creator>Luke</dc:creator>
				<category><![CDATA[Basic Computer Engineering Concepts]]></category>
		<category><![CDATA[Basic Electrical Engineering Concepts]]></category>
		<category><![CDATA[Complex Number]]></category>
		<category><![CDATA[Complex Numbers]]></category>

		<guid isPermaLink="false">http://engineersphere.com/?p=226</guid>
		<description><![CDATA[TweetTweetA complex number can be represented graphically in the complex plane. This point can be described in several different ways: Note that the third relationship is derived when substituting these trigonometric functions into the first relationship: Also: Addition/Subtraction of Complex Numbers: Rectangular: Polar: There is no simple way of doing this. The best method would [...]]]></description>
			<content:encoded><![CDATA[<div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-electrical-concepts/complex-numbers.html&via=EngineerSphere&text=Complex Numbers&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><div style="float: right; margin-left: 10px;"><a href="http://twitter.com/share?url=http://engineersphere.com/basic-electrical-concepts/complex-numbers.html&via=EngineerSphere&text=Complex Numbers&related=EngineerSphere:&lang=en&count=none" class="twitter-share-button">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><p>A complex number can be represented graphically in the complex plane.</p>
<p>This point can be described in several different ways:</p>
<p style="text-align: center;"><img src='http://s.wordpress.com/latex.php?latex=x%2Bjy%20%3D%20r%20e%5E%7B%5Cj%20%5Ctheta%7D%20%3D%20r%20cos%5Ctheta%20%2B%20r%20j%20sin%5Ctheta%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='x+jy = r e^{\j \theta} = r cos\theta + r j sin\theta ' title='x+jy = r e^{\j \theta} = r cos\theta + r j sin\theta ' class='latex' /></p>
<p>Note that the third relationship is derived when substituting these trigonometric functions into the first relationship:</p>
<p style="text-align: center;"><img src='http://s.wordpress.com/latex.php?latex=x%20%3D%20r%20cos%5Ctheta%20%5Cquad%20%5C%26%20%5Cquad%20y%20%3D%20r%20sin%5Ctheta%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='x = r cos\theta \quad \&amp; \quad y = r sin\theta ' title='x = r cos\theta \quad \&amp; \quad y = r sin\theta ' class='latex' /></p>
<p>Also:</p>
<p style="text-align: center;"><img src='http://s.wordpress.com/latex.php?latex=%28x%20%5E%20%7B2%7D%20%2B%20y%20%5E%7B2%7D%29%20%5E%20%7B%20%5Cfrac%7B1%7D%7B2%7D%7D%20%3D%20r%20%5Cquad%20%5C%26%20%5Cquad%20%5Ctheta%20%3D%20tan%20%5E%20%7B-1%7D%28%20%5Cfrac%7By%7D%7Bx%7D%29%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='(x ^ {2} + y ^{2}) ^ { \frac{1}{2}} = r \quad \&amp; \quad \theta = tan ^ {-1}( \frac{y}{x}) ' title='(x ^ {2} + y ^{2}) ^ { \frac{1}{2}} = r \quad \&amp; \quad \theta = tan ^ {-1}( \frac{y}{x}) ' class='latex' /></p>
<h3 style="text-align: left;">Addition/Subtraction of Complex Numbers:</h3>
<p style="text-align: left;"><strong>Rectangular:</strong> <img src='http://s.wordpress.com/latex.php?latex=z_%7B1%7D%20%3D%20x_%7B1%7D%20%2B%20j%20y_%7B1%7D%20%5Cquad%20%5C%26%20%5Cquad%20z_%7B2%7D%20%3D%20x_%7B2%7D%20%2B%20jy_%7B2%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='z_{1} = x_{1} + j y_{1} \quad \&amp; \quad z_{2} = x_{2} + jy_{2} ' title='z_{1} = x_{1} + j y_{1} \quad \&amp; \quad z_{2} = x_{2} + jy_{2} ' class='latex' /></p>
<p style="text-align: left;"><img src='http://s.wordpress.com/latex.php?latex=z_%7B1%7D%20%2B%20z_%7B2%7D%20%3D%20%28x_%7B1%7D%20%2B%20x_%7B2%7D%29%20%2B%20j%28%20y_%7B1%7D%20%2B%20y_%7B2%7D%29%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='z_{1} + z_{2} = (x_{1} + x_{2}) + j( y_{1} + y_{2}) ' title='z_{1} + z_{2} = (x_{1} + x_{2}) + j( y_{1} + y_{2}) ' class='latex' /></p>
<p style="text-align: left;"><img src='http://s.wordpress.com/latex.php?latex=z_%7B1%7D%20-%20z_%7B2%7D%20%3D%20%28x_%7B1%7D%20-%20x_%7B2%7D%29%20%2B%20j%28%20y_%7B1%7D%20-%20y_%7B2%7D%29%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='z_{1} - z_{2} = (x_{1} - x_{2}) + j( y_{1} - y_{2}) ' title='z_{1} - z_{2} = (x_{1} - x_{2}) + j( y_{1} - y_{2}) ' class='latex' /></p>
<p style="text-align: left;"><strong>Polar:</strong> There is no simple way of doing this. The best method would be to convert to rectangular form using the formula: <img src='http://s.wordpress.com/latex.php?latex=r%20cos%5Ctheta%20%2B%20r%20j%20sin%5Ctheta%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='r cos\theta + r j sin\theta ' title='r cos\theta + r j sin\theta ' class='latex' /></p>
<h3 style="text-align: left;">Multiplication/Division of Complex Numbers:</h3>
<p style="text-align: left;"><strong>Rectangular: </strong><img src='http://s.wordpress.com/latex.php?latex=z_%7B1%7D%20%3D%20x_%7B1%7D%20%2B%20j%20y_%7B1%7D%20%5Cquad%20%5C%26%20%5Cquad%20z_%7B2%7D%20%3D%20x_%7B2%7D%20%2B%20jy_%7B2%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='z_{1} = x_{1} + j y_{1} \quad \&amp; \quad z_{2} = x_{2} + jy_{2} ' title='z_{1} = x_{1} + j y_{1} \quad \&amp; \quad z_{2} = x_{2} + jy_{2} ' class='latex' /></p>
<p style="text-align: left;"><img src='http://s.wordpress.com/latex.php?latex=z_%7B1%7D%20%5Ccdot%20z_%7B2%7D%20%3D%20%28x_%7B1%7D%20%2B%20j%20y_%7B1%7D%29%28x_%7B2%7D%20%2B%20j%20y_%7B2%7D%29%20%3D%20x_%7B1%7Dx_%7B2%7D%20%2B%20j%28x_%7B2%7Dy_%7B1%7D%20%2B%20x_%7B1%7Dy_%7B2%7D%29%20-%20y_%7B1%7Dy_%7B2%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='z_{1} \cdot z_{2} = (x_{1} + j y_{1})(x_{2} + j y_{2}) = x_{1}x_{2} + j(x_{2}y_{1} + x_{1}y_{2}) - y_{1}y_{2}' title='z_{1} \cdot z_{2} = (x_{1} + j y_{1})(x_{2} + j y_{2}) = x_{1}x_{2} + j(x_{2}y_{1} + x_{1}y_{2}) - y_{1}y_{2}' class='latex' /></p>
<p style="text-align: left;"><img src='http://s.wordpress.com/latex.php?latex=%5Cfrac%7Bz_%7B1%7D%7D%7Bz_%7B2%7D%7D%20%3D%20%5Cfrac%7Bx_%7B1%7D%20%2B%20j%20y_%7B1%7D%7D%7Bx_%7B2%7D%20%2B%20jy_%7B2%7D%7D%28%5Cfrac%7Bx_%7B2%7D%20-%20j%20y_%7B2%7D%7D%7Bx_%7B2%7D%20-%20jy_%7B2%7D%7D%29%20%3D%20%5Cfrac%7Bx_%7B1%7Dx_%7B2%7D%20%2B%20j%28x_%7B2%7Dy_%7B1%7D%20-%20x_%7B1%7Dy_%7B2%7D%29%20%2B%20y_%7B1%7Dy_%7B2%7D%7D%7Bx_%7B2%7D%5E%7B2%7D%2By_%7B2%7D%5E%7B2%7D%7D&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\frac{z_{1}}{z_{2}} = \frac{x_{1} + j y_{1}}{x_{2} + jy_{2}}(\frac{x_{2} - j y_{2}}{x_{2} - jy_{2}}) = \frac{x_{1}x_{2} + j(x_{2}y_{1} - x_{1}y_{2}) + y_{1}y_{2}}{x_{2}^{2}+y_{2}^{2}}' title='\frac{z_{1}}{z_{2}} = \frac{x_{1} + j y_{1}}{x_{2} + jy_{2}}(\frac{x_{2} - j y_{2}}{x_{2} - jy_{2}}) = \frac{x_{1}x_{2} + j(x_{2}y_{1} - x_{1}y_{2}) + y_{1}y_{2}}{x_{2}^{2}+y_{2}^{2}}' class='latex' /></p>
<p>When multiplying two complex numbers in rectangular form, the FOIL method must be used. When dividing complex numbers in rectangular form, multiply the numerator and denominator by the complex conjugate of the denominator.</p>
<p style="text-align: left;"><strong>Polar: </strong><img src='http://s.wordpress.com/latex.php?latex=z_%7B1%7D%20%3D%20c_%7B1%7D%20e%20%5E%20%7Bj%20%5Ctheta_%7B1%7D%7D%20%5Cquad%20%5C%26%20%5Cquad%20z_%7B2%7D%20%3D%20c_%7B2%7D%20e%20%5E%20%7Bj%20%5Ctheta_%7B2%7D%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='z_{1} = c_{1} e ^ {j \theta_{1}} \quad \&amp; \quad z_{2} = c_{2} e ^ {j \theta_{2}} ' title='z_{1} = c_{1} e ^ {j \theta_{1}} \quad \&amp; \quad z_{2} = c_{2} e ^ {j \theta_{2}} ' class='latex' /></p>
<p><img src='http://s.wordpress.com/latex.php?latex=z_%7B1%7D%20%5Ccdot%20z_%7B2%7D%20%3D%20%28c_%7B1%7D%20e%20%5E%20%7Bj%20%5Ctheta_%7B1%7D%7D%29%28c_%7B2%7D%20e%20%5E%20%7Bj%20%5Ctheta_%7B2%7D%7D%29%20%3D%20c_%7B1%7D%20c_%7B2%7D%20e%20%5E%20%7Bj%28%5Ctheta_%7B1%7D%20%2B%20%5Ctheta_%7B2%7D%29%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='z_{1} \cdot z_{2} = (c_{1} e ^ {j \theta_{1}})(c_{2} e ^ {j \theta_{2}}) = c_{1} c_{2} e ^ {j(\theta_{1} + \theta_{2})} ' title='z_{1} \cdot z_{2} = (c_{1} e ^ {j \theta_{1}})(c_{2} e ^ {j \theta_{2}}) = c_{1} c_{2} e ^ {j(\theta_{1} + \theta_{2})} ' class='latex' /></p>
<p><img src='http://s.wordpress.com/latex.php?latex=%5Cfrac%7Bz_%7B1%7D%7D%7Bz_%7B2%7D%7D%20%3D%20%28%5Cfrac%7Bc_%7B1%7D%7D%7Bc_%7B2%7D%7D%29%20e%20%5E%20%7Bj%28%5Ctheta_%7B1%7D%20-%20%5Ctheta_%7B2%7D%29%7D%20&#038;bg=efe5d9&#038;fg=000000&#038;s=0' alt='\frac{z_{1}}{z_{2}} = (\frac{c_{1}}{c_{2}}) e ^ {j(\theta_{1} - \theta_{2})} ' title='\frac{z_{1}}{z_{2}} = (\frac{c_{1}}{c_{2}}) e ^ {j(\theta_{1} - \theta_{2})} ' class='latex' /></p>
<p><span style="color: #000000;"><br />
</span></p>
]]></content:encoded>
			<wfw:commentRss>http://engineersphere.com/basic-electrical-concepts/complex-numbers.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

