Presentation is loading. Please wait.

Presentation is loading. Please wait.

Dept. of Electrical and Computer Eng., NCTU 1 Lab 4. BCD Adder Presenter: Chun-Hsien Ko Contributors: Chung-Ting Jiang and Lin-Kai Chiu.

Similar presentations


Presentation on theme: "Dept. of Electrical and Computer Eng., NCTU 1 Lab 4. BCD Adder Presenter: Chun-Hsien Ko Contributors: Chung-Ting Jiang and Lin-Kai Chiu."— Presentation transcript:

1 Dept. of Electrical and Computer Eng., NCTU 1 Lab 4. BCD Adder Presenter: Chun-Hsien Ko Contributors: Chung-Ting Jiang and Lin-Kai Chiu

2 Logic DesignLab 4. BCD AdderChun-Hsien Ko Dept. of Electrical and Computer Eng., NCTU 2 Outlines Binary and Decimal BCD Adder and Decoder 4-bit Binary Full Adder (7483) BCD Adder Combinational Logic of BCD Decoder 7-segment Decoder BCD-to-7-Segment Decoders (7447) 7-Segment LED LAB 4: BCD Adder

3 Logic DesignLab 4. BCD AdderChun-Hsien Ko Binary 4-bit binary digits can represent 16 different numbers (0~15) Easy to compute in digital circuit 0x00, 0x01, …, 0x09, 0x0A, 0x0B, …,0x0F Binary-Coded Decimal (BCD) A decimal digit can represent 10 different numbers (0~9) Using 4-bit binary digits to represent a decimal digit Familiar to most people Only use 0x00 ~ 0x09 in 4-bit digits Dept. of Electrical and Computer Eng., NCTU 3

4 Logic DesignLab 4. BCD AdderChun-Hsien Ko Two 4-bit binary inputs: A (A4;A3;A2;A1) and B (B4;B3;B2;B1) Input 0 ≦ A, B ≦ 9 → Output 0 ≦ A+B ≦ 18 If A+B = 0~9 Output Carry = 0,Sum = A+B If A+B = 10~18 Output Carry = 1, Sum = A+B+6 Why? 0x0A = (1010) 2 = (10) 10 (10000) 2 – (01010) 2 = (00110) 2 Dept. of Electrical and Computer Eng., NCTU 4

5 Logic DesignLab 4. BCD AdderChun-Hsien Ko Dept. of Electrical and Computer Eng., NCTU 5

6 Logic DesignLab 4. BCD AdderChun-Hsien Ko Dept. of Electrical and Computer Eng., NCTU 6 4-bit Binary Full Adder BCD Adder Combinational logic BCD-to-7- Segment Decoders

7 Logic DesignLab 4. BCD AdderChun-Hsien Ko 4-bit Adder: 74LS83 Dept. of Electrical and Computer Eng., NCTU 7 No C0 in this Lab Pin 13 connect to GND

8 Logic DesignLab 4. BCD AdderChun-Hsien Ko Combinational Logic of BCD Decoder Dept. of Electrical and Computer Eng., NCTU 8 T 8 T 4 + T 8 T 2 + K Add 6 or not (0110)

9 Logic DesignLab 4. BCD AdderChun-Hsien Ko 7-segment LED Display Common anode pin ‘A’ and ‘k’ connect to VCC LED illuminate when its input pin is low Therefore, we need to decode the number for display with the 7-segment display For example, if we want to show ‘1’, we need to input [1 0 0 1 1 1 1 1] in term of [a b c d e f g dp] Reference https://en.wikipedia.org/wiki/Seven-segment_display Dept. of Electrical and Computer Eng., NCTU 9

10 Logic DesignLab 4. BCD AdderChun-Hsien Ko BCD-to-7-Segment Decoders (7447) Dept. of Electrical and Computer Eng., NCTU 10 Don’t care N = 8*A+4*B+2*C+D = (A;B;C;D) 2

11 Logic DesignLab 4. BCD AdderChun-Hsien Ko 7-segment LED Display Dept. of Electrical and Computer Eng., NCTU 11 330Ω( 橘橘棕 )

12 Logic DesignLab 4. BCD AdderChun-Hsien Ko Dept. of Electrical and Computer Eng., NCTU 12 https://en.wikipedia.org/wiki/Elec tronic_color_code

13 Logic DesignLab 4. BCD AdderChun-Hsien Ko Dept. of Electrical and Computer Eng., NCTU 13 Lab 4: BCD Adder


Download ppt "Dept. of Electrical and Computer Eng., NCTU 1 Lab 4. BCD Adder Presenter: Chun-Hsien Ko Contributors: Chung-Ting Jiang and Lin-Kai Chiu."

Similar presentations


Ads by Google