Comparators, FETS, & Logic Other Useful Devices. Winter 2012 UCSD: Physics 121; 2012 2 Comparators It is very often useful to generate a strong electrical.

Slides:



Advertisements
Similar presentations
CT455: Computer Organization Logic gate
Advertisements

TTL (Transistor Transistor Logic).  Transistor Transistor logic or just TTL, logic gates are built around only transistors.  TTL was developed in 1965.
Ch 11 Bipolar Transistors and Digital Circuits
Introduction to Digital Systems By Dr. John Abraham UT-Panam.
Instructor Name: (Your Name)
From analog to digital circuits A phenomenological overview Bogdan Roman.
Justin Chow Jacob Huang Daniel Soledad ME 4447/6405 Student Lecture.
Field Effect Transistors and their applications. There are Junction FETs (JFET) and Insulated gate FETs (IGFET) There are many types of IGFET. Most common.
Transistors These are three terminal devices, where the current or voltage at one terminal, the input terminal, controls the flow of current between the.
MOSFETs Monday 19 th September. MOSFETs Monday 19 th September In this presentation we will look at the following: State the main differences between.
Voltage Transfer Characteristic for TTL
CMPE 118 MECHATRONICS Digital I/O Transistors and Mosfets.
Experiment 6 -- Digital Switching
Transistor. BJT Transistors: NPN Transistor PNP Transistor Sandwiching a P-type layer between two n- type layers. Sandwiching a N-type layer between.
EE365 Adv. Digital Circuit Design Clarkson University Lecture #4
Chapter 4 Gates and Circuits.
EE365 Adv. Digital Circuit Design Clarkson University Lecture #5
Informationsteknologi Friday, October 19, 2007Computer Architecture I - Class 81 Today’s class Digital Logic.
Digital logic families
Physics 124: Lecture 5 Binary, Hexadecimal, and Logic.
Logic Manipulation Transistors Digital Logic Computers.
Semiconductor circuit elements and dependent sources
Principles & Applications
Unit 7, Chapter 24 CPO Science Foundations of Physics.
CSET 4650 Field Programmable Logic Devices
1 Electronic Circuits TRANSISTOR PRINCIPLES & APPLICATIONS.
ECE 331 – Digital System Design Transistor Technologies, and Realizing Logic Gates using CMOS Circuits (Lecture #23)
09/16/2010© 2010 NTUST Today Course overview and information.
Black Box Electronics An Introduction to Applied Electronics for Physicists 2. Analog Electronics: BJTs to opamps University of Toronto Quantum Optics.
Chapter 5: Field–Effect Transistors
CHAPTER 7 Junction Field-Effect Transistors. OBJECTIVES Describe and Analyze: JFET theory JFETS vs. Bipolars JFET Characteristics JFET Biasing JFET Circuits.
Principles & Applications
Transistor.
Chapter 4 Gates and Circuits. 4–2 Chapter Goals Identify the basic gates and describe the behavior of each Describe how gates are implemented using transistors.
Chapter 4 Gates and Circuits.
Ch 10 MOSFETs and MOS Digital Circuits
Electronic Troubleshooting Chapter 10 Digital Circuits.
Digital Design: Principles and Practices
Electrical Characteristics of Logic Gates Dr. Ashraf Armoush © 2010 Dr. Ashraf Armoush.
Field Effect Transistors Next to the bipolar device that has been studied thus far the Field Effect Transistor is very common in electronic circuitry,
Chapter 2: Fundamentals of Digital Electronics Dr Mohamed Menacer Taibah University
General Licensing Class Oscillators & Components Your organization and dates here.
© 2013 The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill 5-1 Electronics Principles & Applications Eighth Edition Chapter 5 Transistors.
School of Computer Science G51CSA 1 Computer Systems Architecture Fundamentals Of Digital Logic.
Concepts of Engineering and Technology Copyright © Texas Education Agency, All rights reserved.
BJTs. Transistor The transistor is the main building block “element” of electronics. A transistor is a semiconductor device used to amplify and switch.
PHY 202 (Blum)1 Analog-to-Digital Converter and Multi-vibrators.
Chapter 4 Logic Families.
Chapter 1 Combinational CMOS Logic Circuits Lecture # 4 Pass Transistors and Transmission Gates.
IC Logic Families Wen-Hung Liao, Ph.D.
Transistor.
CMOS Logic.  The CMOS Logic uses a combination of p-type and n-type Metal-Oxide-Semiconductor Field Effect Transistors (MOSFETs) to implement logic gates.
McGraw-Hill 5-1 © 2013 The McGraw-Hill Companies, Inc. All rights reserved. Electronics Principles & Applications Eighth Edition Chapter 5 Transistors.
Transistors, Logic Gates and Karnaugh Maps References: Lecture 4 from last.
Electronic. Analog Vs. Digital Analog –Continuous –Can take on any values in a given range –Very susceptible to noise Digital –Discrete –Can only take.
Introduction to Computing Systems and Programming Digital Logic Structures.
CMOS Logic Gates. NMOS transistor acts as a switch 2 When gate voltage is 0 V No channel is formed current does not flow easily “open switch” When gate.
EE Electronics Circuit Design Digital Logic Gates 14.2nMOS Logic Families 14.3Dynamic MOS Logic Families 14.4CMOS Logic Families 14.5TTL Logic.
Electrical Characteristics of Logic Gates Gate Characteristics Last Mod: January 2008  Paul R. Godin.
 A transistor is the basic building block of electronic components.  The average computer may have millions of them within its circuits.  Essentially,
Logic Gates Unit 16.
Transistor.
Binary, Hexadecimal, and Logic
Digital Signals Digital Signals have two basic states:
Basic Digital Logic Basic Gates
Lesson 9: Digital Input-Output Signal Interfacing
CS105 Introduction to Computer Concepts GATES and CIRCUITS
Fundamentals of Computer Science Part i2
SOLIDS AND SEMICONDUCTOR DEVICES - IV
SOLIDS AND SEMICONDUCTOR DEVICES - IV
Presentation transcript:

Comparators, FETS, & Logic Other Useful Devices

Winter 2012 UCSD: Physics 121; Comparators It is very often useful to generate a strong electrical signal associated with some eventIt is very often useful to generate a strong electrical signal associated with some event If we frame the “event” in terms of a voltage threshold, then we use a comparator to tell us when the threshold is exceededIf we frame the “event” in terms of a voltage threshold, then we use a comparator to tell us when the threshold is exceeded –could be at a certain temperature, light level, etc.: anything that can be turned into a voltage Could use an op-amp without feedbackCould use an op-amp without feedback –set inverting input at threshold –feed test signal into non-inverting output –op-amp will rail (negative rail if test reference) But op-amps have relatively slow “slew rate”But op-amps have relatively slow “slew rate” –15 V/  s means 2  s to go rail-to-rail if powered  15 V

Winter 2012 UCSD: Physics 121; Enter the comparator When V in < V ref, V out is pulled high (through the pull-up resistor— usually 1 k  or more)When V in < V ref, V out is pulled high (through the pull-up resistor— usually 1 k  or more) –this arrangement is called “open collector” output: the output is basically the collector of an npn transistor: in saturation it will be pulled toward the emitter (ground), but if the transistor is not driven (no base current), the collector will float up to the pull-up voltage The output is a “digital” version of the signalThe output is a “digital” version of the signal –with settable low and high values (here ground and 5V) Comparators also good at turning a slow edge into a fast oneComparators also good at turning a slow edge into a fast one –for better timing precision +  V ref V in V out +5 V R 5 V V ref V out V in time V

Winter 2012 UCSD: Physics 121; Relays Relays provide a way to switch on/off an AC line with a logic signalRelays provide a way to switch on/off an AC line with a logic signal Simple: 5 volts in  AC switch flipped onSimple: 5 volts in  AC switch flipped on Often will phase to AC line so it turns on at zero- crossing, so-as not to jar electronicsOften will phase to AC line so it turns on at zero- crossing, so-as not to jar electronics +5 V external circuit/load

Winter 2012 UCSD: Physics 121; Opto-isolators Optoisolators provide a means of connecting signals without copper (so can isolate grounds, noise, etc.)Optoisolators provide a means of connecting signals without copper (so can isolate grounds, noise, etc.) –LED shines light on a phototransistor, bringing it into saturation –in the above circuit, the output is pulled up to 5 V when the input is inactive, and drops near ground when the input sees a voltage 5 V V out V in

Winter 2012 UCSD: Physics 121; Logic Families TTL: transistor-transistor logic: BJT basedTTL: transistor-transistor logic: BJT based –chips have L, LS, F, AS, ALS, or H designation –output: logic high has V OH > 3.3 V; logic low has V OL < 0.35 V –input: logic high has V IH > 2.0 V; logic low has V IL < 0.8 V –dead zone between 0.8V and 2.0 V nominal threshold: V T = 1.5 V CMOS: complimentary MOSFETCMOS: complimentary MOSFET –chips have HC or AC designation –output: logic high has V OH > 4.7 V; logic low has V OL < 0.2 V –input: logic high has V IH > 3.7 V; logic low has V IL < 1.3 V –dead zone between 1.3V and 3.7 V nominal threshold: V T = 2.5 V –chips with HCT are CMOS with TTL-compatible thresholds

Winter 2012 UCSD: Physics 121; Logic Family Levels CMOS is closer to the “ideal” that logic low is zero volts and logic high is 5 voltsCMOS is closer to the “ideal” that logic low is zero volts and logic high is 5 volts –and has a bigger dead zone The ?CT line accommodates both the TTL/CMOS levelsThe ?CT line accommodates both the TTL/CMOS levels Example: A TTL device must:Example: A TTL device must: –interpret any input below 0.8 V as logic low –interpret any input above 2.0 V as logic high –put out at least 3.3 V for logic high –put out less than 0.35 V for logic low The differing input/output thresholds lead to noise immunityThe differing input/output thresholds lead to noise immunity

Winter 2012 UCSD: Physics 121; Field-Effect Transistors The “standard” npn and pnp transistors use base- current to control the transistor currentThe “standard” npn and pnp transistors use base- current to control the transistor current FETs use a field (voltage) to control currentFETs use a field (voltage) to control current Result is no current flows into the control “gate”Result is no current flows into the control “gate” FETs are used almost exclusively as switchesFETs are used almost exclusively as switches –pop a few volts on the control gate, and the effective resistance is nearly zero 2N7000 FET

Winter 2012 UCSD: Physics 121; FET Generalities Every FET has at least three connections: –source (S) akin to emitter (E) on BJT –drain (D) akin to collector (C) on BJT –gate (G) akin to base (B) on BJT Some have a body connection too –though often tied to source FET BJT note pinout correspondence

Winter 2012 UCSD: Physics 121; FET Types Two flavors: n and pTwo flavors: n and p Two types: JFET, MOSFETTwo types: JFET, MOSFET MOSFETs more commonMOSFETs more common JFETs conduct “by default”JFETs conduct “by default” –when V gate = V source MOSFETs are “open” by defaultMOSFETs are “open” by default –must turn on deliberately JFETs have a p-n junction at the gate, so must not forward bias more than 0.6 VJFETs have a p-n junction at the gate, so must not forward bias more than 0.6 V MOSFETs have total isolation: do what you wantMOSFETs have total isolation: do what you want 0 24 22 44 log current V gate  V source p-channel MOSFET n-channel MOSFET n-channel JFET p-channel JFET

Winter 2012 UCSD: Physics 121; MOSFET Switches MOSFETs, as applied to logic designs, act as voltage- controlled switchesMOSFETs, as applied to logic designs, act as voltage- controlled switches –n-channel MOSFET is closed (conducts) when positive voltage (+5 V) is applied, open when zero voltage –p-channel MOSFET is open when positive voltage (+5 V) is applied, closed (conducts) when zero voltage (MOSFET means metal-oxide semiconductor field effect transistor) source drain gate source gate drain 5 V 0 V 5 V0 V + voltage 0 V5 V < 5 V n-channel MOSFET p-channel MOSFET “body” connection often tied to “source”

Winter 2012 UCSD: Physics 121; Data manipulation All data manipulation is based on logicAll data manipulation is based on logic Logic follows well defined rules, producing predictable digital output from certain inputLogic follows well defined rules, producing predictable digital output from certain input Examples:Examples: A B C AND A B C OR A B C XOR A B C NAND A B C NOR ABAB ABAB ABAB ABAB ABAB C bubbles mean inverted (e.g., NOT AND  NAND) A A C NOT

Winter 2012 UCSD: Physics 121; An inverter (NOT) from MOSFETS: 5 V 0 V inputoutput 5 V 0 V 5 V 0 V 0 V input turns OFF lower (n-channel) FET, turns ON upper (p-channel), so output is connected to +5 V0 V input turns OFF lower (n-channel) FET, turns ON upper (p-channel), so output is connected to +5 V 5 V input turns ON lower (n-channel) FET, turns OFF upper (p-channel), so output is connected to 0 V5 V input turns ON lower (n-channel) FET, turns OFF upper (p-channel), so output is connected to 0 V –Net effect is logic inversion: 0  5; 5  0 Complementary MOSFET pairs  CMOSComplementary MOSFET pairs  CMOS A A C NOT

Winter 2012 UCSD: Physics 121; A NAND gate from scratch: 5 V 0 V IN A IN B OUT C Both inputs at zero: –lower two FETs OFF, upper two ON –result is output HI Both inputs at 5 V: –lower two FETs ON, upper two OFF –result is output LOW IN A at 5V, IN B at 0 V: –upper left OFF, lowest ON –upper right ON, middle OFF –result is output HI IN A at 0 V, IN B at 5 V: –opposite of previous entry –result is output HI A B C NAND ABAB 0 V C

Winter 2012 UCSD: Physics 121; A NOR gate from scratch: 5 V 0 V IN A IN B OUT C Both inputs at zero: –lower two FETs OFF, upper two ON –result is output HI Both inputs at 5 V: –lower two FETs ON, upper two OFF –result is output LOW IN A at 5V, IN B at 0 V: –lower left OFF, lower right ON –upper ON, middle OFF –result is output LOW IN A at 0 V, IN B at 5 V: –opposite of previous entry –result is output LOW A B C NOR 5 V ABAB C just a NAND flipped upside-down…

Winter 2012 UCSD: Physics 121; All Logic from NANDs Alone A B C NAND ABAB A C NOT A B C AND A B C OR A B C NOR invert output (invert NAND) invert both inputs invert inputs and output (invert OR)

Winter 2012 UCSD: Physics 121; One last type: XOR XOR = (A NAND B) AND (A OR B)XOR = (A NAND B) AND (A OR B) And this you already know you can make from composite NAND gates (though requiring 6 total)And this you already know you can make from composite NAND gates (though requiring 6 total) Then, obviously, XNOR is the inverse of XORThen, obviously, XNOR is the inverse of XOR –so just stick an inverter on the output of XOR ABAB C

Winter 2012 UCSD: Physics 121; Rule the World Now you know how to build ALL logic gates out of n-channel and p-channel MOSFETsNow you know how to build ALL logic gates out of n-channel and p-channel MOSFETs –because you can build a NAND from 4 MOSFETs –and all gates from NANDs That means you can build computersThat means you can build computers So now you can rule the world!So now you can rule the world!

Winter 2012 UCSD: Physics 121; Arithmetic Example Let’s add two binary numbers:Let’s add two binary numbers: = = = 123 How did we do this? We have rules:How did we do this? We have rules: = 0; = = 1; = 10 (2): (0, carry 1); (carried 1) = 11 (3): (1, carry 1) Rules can be represented by gatesRules can be represented by gates –If two input digits are A & B, output digit looks like XOR operation (but need to account for carry operation) A B C XOR ABAB

Winter 2012 UCSD: Physics 121; Can make rule table: C in A B D C out Digits A & B are added, possibly accompanied by carry instruction from previous stageDigits A & B are added, possibly accompanied by carry instruction from previous stage Output is new digit, D, along with carry valueOutput is new digit, D, along with carry value –D looks like XOR of A & B when C in is 0 –D looks like XNOR of A & B when C in is 1 –C out is 1 if two or more of A, B, C in are 1

Winter 2012 UCSD: Physics 121; Binary Arithmetic in Gates A B C in D C out F E H G A B C in E F H G D C out Input Intermediate Output Each digit requires 6 gates Each gate has ~6 transistors ~36 transistors per digit + A B C in D C out “Integrated” Chip

Winter 2012 UCSD: Physics 121; bit binary arithmetic (cascaded) = = = MSB LSB = Least Significant Bit Carry-out tied to carry-in of next digit. “Magically” adds two binary numbers Up to ~300 transistors for this basic function. Also need –, , , & lots more. Integrated one-digit binary arithmetic unit (prev. slide)

Winter 2012 UCSD: Physics 121; Computer technology built up from pieces The foregoing example illustrates the way in which computer technology is builtThe foregoing example illustrates the way in which computer technology is built –start with little pieces (transistors acting as switches) –combine pieces into functional blocks (gates) –combine these blocks into higher-level function (e.g., addition) –combine these new blocks into cascade (e.g., 8-bit addition) –blocks get increasingly complex, more capable Nobody on earth understands Pentium chip inside-outNobody on earth understands Pentium chip inside-out –Grab previously developed blocks and run –Let a computer design the gate arrangements (eyes closed!)

Winter 2012 UCSD: Physics 121; Reading As before, The Art of Electronics by Horowitz and Hill, and the Student Manual accompaniment by Hayes and Horowitz are valuable resourcesAs before, The Art of Electronics by Horowitz and Hill, and the Student Manual accompaniment by Hayes and Horowitz are valuable resources Text reading:Text reading: –p. 432 (p. 461 in 3 rd ed.) on comparators –6.2.5 on relays (esp. solid state) –pp. 461–462 (490–491 in 3 rd ) paragraph on opto-isolators – on logic families –p. 410 (p. 449 in 3 rd ) on FETs –6.6.1, 6.6.2, 6.6.3, on digital logic –6.6.7 on DACs, ADCs