Topik 6 - Converter
Topik 6 - Converter
AD/DA CONVERTER
              Together, they are often used in digital systems to provide complete interface
        with analog sensors and output devices for control systems such as those used in
        automotive engine controls:
   It is much easier to convert a digital signal into an analog signal than it is to do the
   reverse. Therefore, we will begin with DAC circuitry and then move to ADC circuitry.
                                                     1                               Prepared by:
                                                               NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                 ELECTRICAL ENGINEERING DEPARTMENT
                               POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                   SHAH
                                     06000 JITRA, KEDAH DARUL AMAN
                    A DAC, on the other hand, inputs a binary number and outputs an analog
                    voltage or current signal. In block diagram form, it looks like this:
Audio
           Most modern audio signals are stored in digital form (for example MP3s and CDs)
           and in order to be heard through speakers they must be converted into an analog
           signal. DACs are therefore found in CD players, digital music players, and PC sound
           cards.
           Specialist standalone DACs can also be found in high-end hi-fi systems. These
           normally take the digital output of a compatible CD player or dedicated transport
           (which is basically a CD player with no internal DAC) and convert the signal into an
           analog line-level output that can then be fed into an amplifier to drive speakers.
           Data transmission over the Internet is done digitally so in order for voice to be
           transmitted it must be converted to digital using an Analog-to-Digital Converter
           and be converted into analog again using a DAC so the voice it can be heard on the
           other end.
Video
                                                  2                               Prepared by:
                                                            NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                    ELECTRICAL ENGINEERING DEPARTMENT
                                  POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                      SHAH
                                        06000 JITRA, KEDAH DARUL AMAN
                                       D
                                       C
                                       B         DAC              VOUT             1V
                                       A          Resolusi
                                                   (1 V)
                                   clock                         0V
                                   mo                                                                  Bin
                                                                  0000     1001 ..
                       All resistors must be of equal value. If any of the input resistors were
                different, the input voltages would have different degrees of effect on the
                                                             3                                   Prepared by:
                                                                           NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                    ELECTRICAL ENGINEERING DEPARTMENT
                                  POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                      SHAH
                                        06000 JITRA, KEDAH DARUL AMAN
                output, and the output voltage would not be a true sum. Let's consider,
                however, intentionally setting the input resistors at different values. Suppose
                we were to set the input resistor values at multiple powers of two: R, 2R, and
                4R, instead of all the same value R:
                Starting from V1 and going through V3, this would give each input voltage
                exactly half the effect on the output as the voltage before it. In other words,
                input voltage V1 has a 1:1 effect on the output voltage (gain of 1), while input
                voltage V2 has half that much effect on the output (a gain of 1/2), and V3 half
                of that (a gain of 1/4). If we drive the inputs of this circuit with digital gates so
                that each input is either 0 volts or full supply voltage, the output voltage will be
                an analog representation of the binary value of these three bits.
                       If we chart the output voltages for all eight combinations of binary bits
                (000 through 111) input to this circuit, we will get the following progression of
                voltages (for VDD =10 volts):
                                                    4                               Prepared by:
                                                              NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                     ELECTRICAL ENGINEERING DEPARTMENT
                                   POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                       SHAH
                                         06000 JITRA, KEDAH DARUL AMAN
                | 001         | -1.25 V |
                | 010         | -2.50 V |
                | 011         | -3.75 V |
                | 100         | -5.00 V |
                | 101         | -6.25 V |
                | 110         | -7.50 V |
                | 111         | -8.75 V |
                        If we wish to expand the resolution of this DAC (add more bits to the
                input), all we need to do is add more input resistors, holding to the same
                power-of-two sequence of values:
D C B A
                        3V
                                        18.7K   37.5K   75K       150K
                                                                               RF
                                   R4       R     R      R
                                                                               20K
                                            3     2      1
                                                                          --
                                                              5                                  VVout
                                                                                               Prepared
                                                                                                   o
                                                                                                        by:
                                                                         NorjulianaBintiOthman/JKE/POLIMAS
                                                                          ++                     V
                                                                                                 ut
                                                                                                 VO
EE 301  Electronic Circuit
                                        ELECTRICAL ENGINEERING DEPARTMENT
                                      POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                          SHAH
                                            06000 JITRA, KEDAH DARUL AMAN
             Example:-
             Calculate the resistive value of R1, R2,R3 and R4 for 4 bit DAC circuit above and find
             out the Vout for 0001 and 0110 input.
             Resistive value:-
             R 1 =150K Bit 20 (LSB)
                    R1        150K
             R2 =
                     1
                               1
                                     = 75k,  Bit 21
                  2     2
                   R 150K 150K
             R 3  21  2          37.5k,  Bit 2 2
                   2    2      4
                   R 150K
             R 4  31      18.75k  Bit 2 3
                   2     8
                                                           6                               Prepared by:
                                                                     NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                    ELECTRICAL ENGINEERING DEPARTMENT
                                  POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                      SHAH
                                        06000 JITRA, KEDAH DARUL AMAN
                  1111) input to this circuit, we will get the following progression of voltages
                  (for VCC =6 volts): -
                          0           0         0            0            0            0
                          1           0         0            0            1           0.4
                          2           0         0            1            0           0.8
                          3           0         0            1            1           1.2
                          4           0         1            0            0           1.6
                          5           0         1            0            1           2.0
                          6           0         1            1            0           2.4
                          7           0         1            1            1           2.8
                          8           1         0            0            0           3.2
                          9           1         0            0            1           3.6
                          10          1         0            1            0           4.0
                          11          1         0            1            1           4.4
                          12          1         1            0            0           4.8
                          13          1         1            0            1           5.2
                          14          1         1            1            0           5.6
                          15          1         1            1            1           6.0
                       An alternative to the resistive divider is the R/2R DAC, which uses fewer
                unique resistor values. A disadvantage of the former DAC design was its
                requirement of several different precise input resistor values: one unique value
                per binary input bit. Manufacturing may be simplified if there are fewer
                different resistor values to purchase, stock, and sort prior to assembly. Of
                course, we modify it to use two resistance values, by connecting resistors
                together in series and it call R-2R ladder circuit.
                It uses resistors of only two different values, and their ratio is 2:1. An N-bit DAC
                requires 2N resistors, and they are quite easily trimmed.
                                                    7                                  Prepared by:
                                                                 NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                                 ELECTRICAL ENGINEERING DEPARTMENT
                                               POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                                   SHAH
                                                     06000 JITRA, KEDAH DARUL AMAN
                                                                                        Vref R f
           a) For input equal to 01 2 = 110, Vout =                                              , 3 circuit below show you the
                                                                                         4 R
                equivalent circuit
                              Vref
                                                    B
                                 A
                                     I1                          Rf                    I1 = Vref/2R, I2 = 0/2R = 0.
                         A                     B
                         2R                                                           I2 I3 = I1 + I2 = Vref/2R
                                                2R
                               I
                         2                3
                        Vth1 I
                         R (1+2)R
                                                        -
                                                         -                             Rth = 2R 2R = R, Vth1 = Vref/2
                        2R
                                                        +
                                          I2                                   VOUT
                        then,
                          2
                          R
                                                                               Rf            I4 = Vref/2R = 0/2R = 0.
                                                            I4
                                                            B                                I
                                                        2R                                   I5 = Vref/(2 X 2R) = Vref/(4R)
                                                                                             2
                              VREF/2
                                                         2R                                  Rth = 2R 2R = R, Vth2 = Vref/4
                                          I5    R       R Vth2
                                                                           -
                                                                           -
                                                                           + 8                                         Prepared by:
                                                                                      VOUT       NorjulianaBintiOthman/JKE/POLIMAS
                                                    2
                                                    R
EE 301  Electronic Circuit
                                                      ELECTRICAL ENGINEERING DEPARTMENT
                                                    POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                                        SHAH
                                                          06000 JITRA, KEDAH DARUL AMAN
then,
Rf
                                                                               IO
                                                                                                            I6 = Vref/4R = -Io
                                 I6
                             I
                                                       -
                                                        -                                                   VOUT (01) = Io X Rf = Vref/(4R) x Rf
                         VREF/4(1+2) R
                                                        +
                                                                            VOUT                                               Rf
                                               2R                                                               = (Vref/4)
                                                                                                                               R
A Vref
                                      B
                                                                                          Vref
                                                                                                                                                 Rf
                                               Rf                                                  B
                         I1                                                                                Rf
               AI                                                                        I4                                        I6
               2R         2R                                                              B                              I                            IO
                                                                                         2R                              VREF/2
              2 I 2R
                    2
                                                                  0                                                      2
                                                                                                                                  I(1+   R   -
                                                                                                                                             -
              Vth1 I
                          3
                                          -
                                           -                                             2R                                                  +
              R (1+R                      +                           I5   R        I(1+R Vt           -
                                                                                                       -
                                                                                                                                  2)                  VOUT
              2R
                         I2                           VOUT
                                                                                                       +                                2
                2
                    2)                                                                        h2                  VOUT                  R
                                                                               2
                                                                                    2)
                                                                                                                          I6 = Vref/2R = -Io
                R
                                                                               R                                          VOUT (10) = Io X Rf = Vref/(2R)
             I1 = Vref/2R= I2 = 0/2R I4 = Vref/2R.                                                                        x Rf
             = 0.                      I5 = 0                                                                                     = (Vref/2)
             I3 = I1 + I2 = Vref/2R R = R, V = V /2
                                         th          th2    ref
             =0                     DAC circuit for R/2R for 102 bit input
             Rth =2R 2R = R, Vth1 =
           c) For 112, the circuit shown below.
             0
                                                 3Vref R f
              When input is 112 = 310, Vout =
                                                   4 R
                                                                                         9                                            Prepared by:
                                                                                                                NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                               ELECTRICAL ENGINEERING DEPARTMENT
                                             POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                                 SHAH
                                                   06000 JITRA, KEDAH DARUL AMAN
                      A
                                             Vref
                                         B
                                                                                                 Vref                                       Rf
                                                    Rf
                               I1                                                                       B
                     AI                                                                     I4
                                                                                                            Rf
                                                                                                                                                 IO
                    2R              2R                                                    B                          I      I7
                                                                                        2R                         3VREF/4              -
                                                                                                                                        -
                    2 2 I                                                                                                  I(1+    R
                    Vth1 I 2R                                                                                                           +
                                3
                    R (1+R
                                              -
                                               -                   Vref/2
                                                                                          2
                                                                                                                     2
                    2R
                                              +
                                                                            I5   R
                                                                                               -
                                                                                               -
                                                                                      I(1RRVth +                              2)
                                                                                                                                   2
                                                                                                                                                 VOUT
                               I2                           VOUT
                     2
                          2)
                                                                                                 2               VOUT              R
                                                                                      +2)
                     R                                                        2
                                                                      I4 = VrefR/2R.                                    I7 = 3Vref/4R = -Io
                   I1 = Vref/2R, I2 = 0                               I5 = Vref/4R,                                     VOUT (11) = Io X Rf
                   I3 = I1 + I2 =                                     I6 = I4 + I5 =                                               = 3Vref/(4R) x Rf
                   Vref/2R                                            3Vref/4R
                                                                                                                                   = (3Vref/4)
                   Rth = 2R//2R = R,                                  Rth = 2R//2R = R,
                    Vth1 = Vref/2                                     Vth2 = 3V
                                                                              DAC
                                                                                ref
                                                                                   /4circuit for R/2R for 10 bit input
                                                                                                            2
                    Most of the digital to analog converters are available in the form of Integrated
                    circuit (IC). It is important that you know some features or specifications of the
                    manufacturer to apply on any circuit. There are five specifications for the DAC,
                    which we discuss.
           Figure 6.1.3 shows the DAC receives digital input from mode counter 16. 4-bit DAC has a
           resolution of 1 V and maximum output voltage or full-scale voltage of 15 V. Now let us
           examine the specifications for digital to analog converter.
Resolution
           Defined as the smallest change achieved in the analog output as a result of changes in
           digital input.
                                                                                 10                                           Prepared by:
                                                                                                        NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                  ELECTRICAL ENGINEERING DEPARTMENT
                                POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                    SHAH
                                      06000 JITRA, KEDAH DARUL AMAN
           Manufacturers often refer to the resolution of the DAC is in the number of bits. For
           example, 10-bit DAC has a resolution of 10 bits. 10-bit DAC has a resolution smaller than
           8-bit DAC.
           Resolution can be expressed in two cases, either the Voltage or Ampere and percent.
           Resolution in the voltage or Ampere is also known as the step size. You can see in Figure
           6.1.3 above, the output waveform versus the digital input is shaped into a staircase has
           15 stairs and 16 step. 15 stairs is known as the number of steps. So the step size or
           resolution for digital to analog converter in this figure is 1 V. To your knowledge is often
           the resolution is equal to the value of the product when the first digital input of 0001 2.
           Percentage Resolution can be expressed as the amount of it is also useful to express it as
           a percentage of the full-scale output.
           Example
           Digital to analog converter 10-bit with step size 10 mV. Search for full-scale voltage and
           the percent resolution.
           Solution
           Number of bits = 10
           The total step size = 210-1 = 1023 steps
           Thus, the full-scale output voltage = 10mV x 1023 = 10.23 V
                                  stepsize               10mV
           % Resolution = fullscalevoltage  100 =          100  0.1%
                                                   10.23 V
                                    1                 1
           or % resolution = totalstep  100 =            100  0.1%
                                                    1023
                                                    11                                Prepared by:
                                                                NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                  ELECTRICAL ENGINEERING DEPARTMENT
                                POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                    SHAH
                                      06000 JITRA, KEDAH DARUL AMAN
Advantages
                                              Disadvantages
                          Resistive Divider                        R/2R
                    Hard to match resistors         More parts
              An analog signal is a signal that may assume any value within a continuous
        range. Examples of analog signals commonly encountered every day are sound, light,
        temperature, and pressure, all of which may be represented electrically by an analog
        voltage or current. A device that is used to convert an analog signal into an analog
        voltage or current is known as a transducer. An analog-to-digital converter is used to
                                                   12                               Prepared by:
                                                              NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                      ELECTRICAL ENGINEERING DEPARTMENT
                                    POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                        SHAH
                                          06000 JITRA, KEDAH DARUL AMAN
        further translate this analog voltage or current into digital codes that consist of 1's
        and 0's.
                                                                               MSB
                                                                                         D
                              Clock
                                                           ADC                           C
                   Input
                                    0                                                   B
                   Voltage                                                      LSB
                   Aanalog          3V                                                   A
                A typical ADC, therefore, has an analog input and a digital output, which may
        either be 'serial' (consisting of just one output pin that delivers the output code one
        bit at a time) or 'parallel' (consisting of several output pins that deliver all the bits of
        the output code at the same time).
                                                                                          Q0
                              Clock =                                                     Q1     Output
                                 A                             CK                                digital
                                                                                          Q2
                               START
                                            B                  Counter                    Q3
                                                               Mod 16
                    Input      VA                              reset
                    analog
                              VA   +       Voltage
                                    -       Comparator                                    DAC
                                           VA > VA = 1
                                           VA < VA = 0                                      Prepared by:
                                                          13
                                                                       NorjulianaBintiOthman/JKE/POLIMAS
                                                                                                VOUT
                                          Figure : 4-Bit Digital Ramp Circuit
EE 301  Electronic Circuit
                                     ELECTRICAL ENGINEERING DEPARTMENT
                                   POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                       SHAH
                                         06000 JITRA, KEDAH DARUL AMAN
             1. A positive pulse 'Start' is supplied, a count restored to zero. AND gate output is low,
                so there is no receive any triggered counter bell-shaped.
             2. When the zero count, VA '= 0, so the comparator output is high voltage. When the
                pulse returns low and triggered at the output of the AND gate will be high (because
                all entries are in a logic high) and allows the counter count.
             3. Output DAC, VA 'increase in the voltage step (step voltage) corresponding to the
                step size or resolution.
             4. This process will continue until the VA ' VA. Comparator output will be low; the
                counter will stop on the count represented by the VA. The conversion process is
                complete; the conversion at the output of the comparator from high to low the
                conversion process is complete (EOC - End Of Conversion).
         Example
         Now let's see an example of the conversion of analog inputs, VA = 0.75 V using a
         converter 4-bit digital ramp with a step size 0.2V.
                  Table 4: Example for ADC with Input Analog 0.75V and 0.33 V digital Ramp 4-bit
            Cycle     Row          Device                Input Condition            Output
                       1         Comparator        VA = 0.75V, VA = 0V, VA > VA              1
                       2                                 A = clock, B = 1             1 Pulse
                                                                                          st
                                                         14                                   Prepared by:
                                                                        NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                      ELECTRICAL ENGINEERING DEPARTMENT
                                    POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                        SHAH
                                          06000 JITRA, KEDAH DARUL AMAN
                                                          15                                    Prepared by:
                                                                          NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                  ELECTRICAL ENGINEERING DEPARTMENT
                                POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                    SHAH
                                      06000 JITRA, KEDAH DARUL AMAN
             Resolution and accuracy of the analog to digital converter is the same as the resolution
             and accuracy for the digital to analog converter
             Conversion time is the time taken to convert the analog input digital exit. For the
             digital ramp converters, counters count from 0 to VA ' VA. Time to complete the
             conversion process, depending on the value of analog input, VA. The greater the value
             of the VA, then more steps and longer time of conversion. We will now see the
             expression for the exchange of digital ramp converter.
             Example
             Digital ramp ADC has the following values:
             Bell-shaped frequency = 1 MHz, the VT (voltage 'threshold sensitivity' = (VA '- VA) = 0.1
             mV, filled with Scale voltage 10-bit DAC = 10.23V. Find the following values;
             a) If VA = 3568 V, what is the equivalent output.
             b) conversion time.
             c) The resolution of the converter in volts and percent.
Solution:-
                                                 V        10.23
                     size step = resolution = totalstep  1023  10mV
                                                   FS
                                                  16                               Prepared by:
                                                             NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                  ELECTRICAL ENGINEERING DEPARTMENT
                                POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                    SHAH
                                      06000 JITRA, KEDAH DARUL AMAN
                    3.5681
                            356.81  357 step  [Remember! These formulas are similar to the
                    10mV
                    DAC
                    output divided by the number of steps, before we know the number of steps =
                    full-scale voltage / step size]
                    When completed the process of conversion, the output of the counter is 35 710 =
                    01,011,001,012, a digital output when VA = 3.568V.
             b)     From a) above we know that the 357 steps required to get products
                    01011001012. Then 357 clock cycles occur at a rate of 1  s. So this will give time
                    for the conversion of 357  s.
                                                                          1
             c)     Resolution = DAC step size = 10 mv,% resolution =        x 100  0.1%
                                                                        1023
                                                  17                               Prepared by:
                                                             NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                          ELECTRICAL ENGINEERING DEPARTMENT
                                        POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                            SHAH
                                              06000 JITRA, KEDAH DARUL AMAN
                   Initially all bits of SAR are set to 0. Then, beginning with the most
           significant bit, each bit is set to 1 sequentially. If the DAC output does not exceed
           the input signal voltage, the bit is left as a 1. Otherwise it is set back to 0. It is kind
           of a binary search. For an n-bit ADC, n steps are required.
             Masukan VA
             analog
                    VA
                              +
                              -
                                  jam          Successive-approximation
                                                    register (SAR)                 DR (Data ready end-of-
                                                                                        conversion)
                                              MSB                  LSB
                              START
                                                                                Q7
                                                                                   Cp
                                                                                Q6  Keluaran
                                                                    Output register
                                                                                Q5  digital
                                                                                Q4
                              Vref =                                            Q3
                                                8-Bit D/A
                              10V
           Explanation of analog toVout
                                     digital Converter
                                             process(DAC)
                                                        for SAC :-              Q2
                                         Block diagram of 8-Bit SAR             Q
           1. SAC has a shorter conversion   time and fixed (not dependent1 on the analog input
                                                                                Q0
           value).
           2. SAC circuit using the register circuit to provide input to the DAC block where logic
           controllers ("control logic") to change the contents of the register-to-bit bit up in the
           registry data with an analog input, VA (within the resolution of the converter). Figure 7.5
           is a block diagram of the successive approximation converter.
                                                          18                                    Prepared by:
                                                                          NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                     ELECTRICAL ENGINEERING DEPARTMENT
                                   POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                       SHAH
                                         06000 JITRA, KEDAH DARUL AMAN
           1. Control logic (in block list of tools SAC) Recharge the registrar to the logic high MSB
              and other bits to logic low. This produces a value VA 'on the weight of the DAC output
              with the MSB last. If the VA '> VA, the comparator output will be' low 'and this will
              cause the control logic will be reset to low MSB. If the VA '<VA MSB still' high '.
           2. Recharge control logic of the next bit to '1 '. This results in the VA 'a new one. If this
              value is greater than the VA, the comparator output will be 'low' and the control logic
              will be reset that bit to 0. Otherwise, the left bit ' 1 '.
           3. This process continues for each bit in the registry. This process requires a bell-
              shaped per bit. After all bits have been tested registrar will store the digital
              equivalent of the VA.
                Example
                SAC 4-bit converter with 1V step size was used to change the input values, VA =
                9.9 V. Show each step of the conversion.
               Reset bit to 2 and set next to. ,VA >       1010          10        9.9           0
               VA
               Reset bit to 3 and set LSB ,VA < VA          1001           9        9.9           1
                                                       19                           Prepared by:
                                                              NorjulianaBintiOthman/JKE/POLIMAS
EE 301  Electronic Circuit
                                   ELECTRICAL ENGINEERING DEPARTMENT
                                 POLITEKNIK SULTAN ABDUL HALIM MUADZAM
                                                     SHAH
                                       06000 JITRA, KEDAH DARUL AMAN
                                                   20                               Prepared by:
                                                              NorjulianaBintiOthman/JKE/POLIMAS