1 of 46

Lecture 3:

Integrated Circuits

2 of 46

OPS Member of the Week: Chandra Suresh

2

  1. What are your hobbies?
    1. “I like watching TV shows and movies and stuff”
    2. “and ping pong and smash”
  2. What other clubs are you in?
    • IEEE, ACM Cyber, ACM AI
  3. What is your favorite meme?

3 of 46

Recap of Project 2

  • Some common errors that need to be debugged:
    • Continuity Errors
      • i.e. two nodes are accidentally connected
    • Backwards Polarity
      • check LEDs, JST connectors, etc.

3

4 of 46

Project 2

555 LED Blinker

4

5 of 46

So, say we want to blink an LED on and off. We need a particular circuit to carry out this task. Let’s see the schematic for it:

Except, this circuit is extremely complicated! How would it even fit on a breadboard?

5

555 Timer

6 of 46

Integrated Circuits (ICs)

  • Instead of building out complex circuits, we can use integrated circuits!
    • Entire circuit on a tiny semiconductor (usually silicon)
  • Benefits:
    • Small
    • Cheap
    • Easy to Replace
    • Mass produced

6

7 of 46

Integrated Circuits - How to Use

  • Each IC usually has some specified function
    • Ex: Timers, Logic Circuits, Operational Amplifiers
  • Pins numbered counter clockwise
  • Use dot to align

7

Top Left

8 of 46

Black Box

  • The idea of “the Black Box” is that the internal behavior of the IC is unimportant…
  • What matters are the inputs and outputs
  • That way, we don’t have to think about nasty, complicated circuits!

8

Internal behavior of the IC is unknown (and unimportant)

9 of 46

Make LED blink using 555 timer!

9

10 of 46

The 555 Timer

Uses

  • Timing applications such as blinking LED
  • Outputs oscillating square wave repeatedly
  • Called 555 timer because of three internal 5k ohm resistors

10

11 of 46

Definitions you will need to know:

Capacitor

  • Stores electrical charge
  • Charges/Discharges over time
  • Voltage across it increases as it charges
  • Voltage across it decreases as it discharges
  • Can be polarized/non-polarized

11

*Voltage across a capacitor changes slowly!

12 of 46

Definitions you will need to know:

Polarized Capacitor

  • Negative lead is on the grayish stripe with a minus(-) sign

12

13 of 46

555 Timer Pins

  • Pin 1: Ground (GND)
  • Pin 8: Power (VCC)
  • Pin 4: Reset (RST)
    • Restarts the timer when at LOW voltage
    • In this circuit, will it ever do this?

The timer IC is powered by the potential difference between Pin 1 and Pin 8!

13

Battery

14 of 46

555 Timer Pins

  • Pins 2 and 6 are connected (they’re a node!)
  • Pin 2: Trigger (TRIG)
    • Monitors voltage across CAP (C2)
    • Turns on/controls the output when the vMoltage supplied to it drops below 1/3 of Vcc
  • Pin 6: Threshold (THRS)
    • Monitors voltage across CAP (C2)
    • Turns off the output when the voltage supplied to it reaches above 2/3 Vcc

14

15 of 46

555 Timer Pins

  • Pin 3: Digital Output (OUT)
    • Outputs only HIGH/LOW voltage, no in between
    • Duration controlled by rest of circuit
    • Connect your output elements to this pin! (LED)
  • Pin 5: Control Voltage (CV)
    • Connects to GND with small CAP (C1) to remove fluctuations in supply voltage
  • Pin 7: Discharge (DIS)
    • Starts to discharge the CAP (C2) when it is fully charged

15

16 of 46

What is going on???

If these pins are confusing, no worries!

The only ones that have special functionality are:

16

Pin 3(Output)

Pin 6(Threshold)

Active HIGH

Pin 3(Output)

Pin 2(Trigger)

Active LOW

1/3V

2/3V

17 of 46

How does the 555 timer make the LED blink?

  1. Pin 6: Threshold (THRS), Pin 2: Trigger (TRIG), and C2 have the same voltage (same node)
  2. At the beginning of an off/on cycle, Pin 6, Pin2, and C2 are at a LOW voltage
    • When Pin 2(Trigger) is LOW
      • Pin 3(Output) is HIGH and LED is on
      • Pin 7(Discharge) is OFF
        • Current can then flow through R1 and R2 to charge C2

17

18 of 46

How does the 555 timer make the LED blink?

  • Once C2 charges to ⅔ of Vcc:
    • Pin 6(Threshold) turns OFF the output (LED)
  • Output is OFF, the discharge pin switches ON
    • Allows charge accumulated on C2 to discharge
    • Once voltage across C2 reaches ⅓ of Vcc, Pin 2(Trigger) turns off Pin 6(Discharge) so that C2 can start charging again

18

19 of 46

When is the LED on/off with respect to C2?

  • As C2 is charging
    • Output: LED is ON
  • As C2 is discharging
    • Output: LED is OFF
  • Oscillation continues forever until power source removed
  • Capacitor acts as this “timer”
    • Voltage across a capacitor changes slowly
  • Output is a square wave!

19

ON

OFF

THRESHOLD

TRIGGER

20 of 46

555 Timer Pins- TL;DR

  • Basically, how it works:
    1. Capacitor C2 alternates between charging/discharging, depending on the resistance/capacitance values
    2. Pin 6 (THRS) monitors the alternating voltage of the cap.
    3. Since Pin 2 (TRIG) is connected to Pin 6, it alternates between setting Pin 3 (OUT) to HIGH and LOW
    4. Blinky LED!

20

21 of 46

555 LED Blinker Schematic

  • The first part of your project is to build this circuit on your breadboard!

21

Think back to Project 1. What value should this resistor be?

22 of 46

Circuit on the Breadboard

22

3.7V

+ -

+ -

C1

R1

R2

C2

R3

23 of 46

Adjusting the Blink Timing

RC Time Constants

  • Increasing the values of either C2 or R1 will increase both the time the output stays on and the time it stays off
  • Increasing the value of R2 will only increase the time the output stays on

23

C2

C2

C2

C2

R1

24 of 46

Adjusting the Blink Timing

24

What happens if we change this value? Use 68 µF for this project.

25 of 46

Project 3

Part 2: 555 Piano using speaker

25

26 of 46

Project 3: 555 Pulse Instantiated Astable Nerdy Organ (PIANO)

26

  • More advanced version of Project 2
  • Use resistors and push buttons to make different sounds on a speaker!

Push Buttons

27 of 46

How can we use the 555 timer to play noise on a speaker?

  • Last project, the LED was the output
  • Speaker is the output in this case, so what pin should it be connected to?

27

?

?

28 of 46

How can we use the 555 timer to play noise on a speaker?

How can we change the pitch (output) of the speaker?

28

29 of 46

Recall

  • Remember the output of the 555 timer is a square wave connected to Pin3
  • We need to change this output somehow!

29

ON

ON

OFF

. . .

30 of 46

What if the frequency was higher or lower?

Higher frequency = higher pitch

30

Lower frequency = lower pitch

31 of 46

Using different resistor values to change duty cycle

  • The resistance between Pin 6 and Pin 7 determines the “on” and “off” time of the output
  • Just change the resistance!
  • Lower resistance = less on/off time = higher frequency = higher pitch
  • Higher resistance = more on/off time = lower frequency = lower pitch

31

R?

32 of 46

Pushbuttons

To choose a certain resistor value

32

33 of 46

How are push buttons connected internally?

33

  • A push button internally is a switch
  • Completes the circuit when pressed
  • Disconnects circuit when not pressed
  • Two sides to a push button
    • On each side
      • Two pins connected to each other

34 of 46

Push Buttons: Ambiguity

  • We’re not always sure how the button is connected inside...
  • Assuming the wrong orientation can mess up your circuit!
  • Let’s look at an example of what could go wrong

34

or...

35 of 46

Push Buttons: Ambiguity

  • What is wrong with this circuit?

35

36 of 46

Push Buttons: Ambiguity

  • What is wrong with this circuit?

36

Two terminals are already connected and the circuit is connected, so the push button is useless :0

37 of 46

Push Buttons: Ambiguity

  • Solution: Connect your two leads diagonally, so it is compatible with either orientation!

37

38 of 46

Now you know about pushbuttons, so let’s apply it to the 555!

39 of 46

Schematic

39

2.7k

Resistors to change output pitch/frequency

40 of 46

Schematic

40

2.7k

What if we close S1?

R3

Resistance between pin 6 and 7 is only R3!

current

41 of 46

Schematic

41

2.7k

R3

Resistance between pin 6 and 7 is R3+R4!

current

What if we close S2?

42 of 46

Schematic

42

2.7k

R3

Resistance between pin 6 and 7 is R3+R4+R5!

current

What if we close S3?

43 of 46

Soldering Tips

  • Do NOT solder your 555 timer in directly
    • IT WILL FRY
    • Also you need it later
  • Use 8-pin dip socket instead!
  • CLEAN UP AFTER YOURSELF!

43

44 of 46

Dates!

  • 555 LED Blink (Breadboard and Solder): 6pm Monday, Nov 11
  • 555 Piano (Breadboard and Solder): 6pm Friday, Nov 15
  • GB Infosession: 6pm Thursday, Nov 14
  • Next Lecture: Arduino Lecture and Workshop on Nov 19th and Nov 20th 6-7pm
    • Sign up for one of the slots Here! (First come first serve)

44

45 of 46

Kahoot time!

45

Take out your phone/laptop, go on kahoot.it, and enter the code on the screen!

46 of 46

Thank you!

Questions?

46