← Circuits with Tinkercad

Chapter 5 · Book pp. 73–94

Learning and Playing with ICs: the 555

ตะลุยโครงงานอิเล็กทรอนิกส์เบื้องต้น : เรียนและเล่นไปกับไอซี

An IC (integrated circuit) packs many parts — transistors, diodes, resistors — onto one small piece of silicon, the chip, joined by tiny aluminium or gold wires. One IC may hold a few parts or millions of them, which is how modern devices stay so small. This chapter introduces ICs and then puts the famous 555 timer to work.

5.1 Types of IC ชนิดของไอซี

Early ICs were split into two kinds: analogue and digital. Today there are many specialist types instead: op-amps, timers, digital signal processors (DSP), analogue-to-digital and digital-to-analogue converters, bus and interface ICs, logic ICs, power-supply and power-management ICs, radio ICs and microcontrollers.

ICs are also graded by where they will be used: audio, cars, factories, medical equipment, security systems and even space.

5.2 IC packages ลักษณะรูปร่างของไอซี

An IC needs pins to connect to the outside, so it comes in a standard package. The best known is the DIP (Dual In-line Package): two rows of pins, from 4 pins upwards. Modern surface-mount (SMD) ICs come in many small packages, such as SOIC (Small-Outline IC), QFP (Quad Flat Package) and QFN (Quad Flat No-leads).

Fig 5-1Standard IC packages: DIP, SOIC, QFN, QFP/LQFP, TO-220, PLCC and SSOP

Each package marks pin 1 in its own way:

Fig 5-2Finding pin 1 and counting the pins: DIP, SOIC, TSSOP and SSOP (a dot or notch at the pin 1 end, counted anticlockwise from the top); LQFP and TQFP (a dot in one corner); QFN (a dot on top, pads underneath); PLCC (a dot in the middle of one side)

Next: the 555 timer →

5.3 Introducing the 555 แนะนำไอซี 555

  • Designed in 1971 by Hans Camenzind at Signetics; it quickly became one of the world’s best-known chips, and by 1972 more than 12 makers produced it.
  • It is a timer. Inside are 25 transistors, 2 diodes and 15 resistors in an 8-pin DIP.
  • Common uses: astable multivibrator (a continuous signal), monostable multivibrator (one pulse) and time-delay circuits.
  • The standard 555 runs from 4.5 to 16 V. The ICM7555 runs from 2 to 18 V, so it also works from two alkaline cells (3 V).

Inside (Fig 5-3) are two comparators built from op-amps and a chain of resistors that sets their reference levels: 2/3 Vcc (about 0.67 Vcc) for the threshold comparator and 1/3 Vcc for the trigger comparator. Their outputs set and reset an RS flip-flop, whose output is amplified to drive pin 3.

Fig 5-3Block diagram of the 555: discharge transistor, two comparators, RS flip-flop and output amplifier, with the pinout (1 GND, 2 TRIG, 3 OUT, 4 RESET, 5 CTRL, 6 THR, 7 DIS, 8 Vcc) and the 8-pin DIP package
PinNamePinName
1GND (ground)8Vcc (supply)
2TRIG (trigger input)7DIS (discharge)
3OUT (output)6THR (threshold input)
4RESET5CTRL (control)

The threshold input is connected to an outside resistor and capacitor — an RC timing circuit that sets the timing and frequency (Fig 5-4). As the capacitor charges to 2/3 Vcc, the comparator sets the flip-flop, the discharge transistor turns on, the capacitor discharges, and the output goes to “0”. When the voltage falls to 1/3 Vcc, the flip-flop resets, the discharge transistor turns off and the output goes back to “1”.

Fig 5-4The resistor and capacitor connected to the 555 set the timing and the output frequency

5.4 Using the 555 การใช้งานไอซี 555

5.4.1 The 555 as an astable (continuous signal)

  • RESET (pin 4) is tied to +Vcc. If it were grounded, the 555 would be disabled.
  • C2 on the control pin (pin 5) stops noise causing false triggering.
  • While the discharge transistor is off, C1 charges through RA and RB: t₁ = (RA + RB) × C1 seconds.
  • At 2/3 Vcc the flip-flop changes state, the discharge transistor turns on and C1 discharges through RB: t₂ = RB × C1 seconds.
  • At 1/3 Vcc it changes back, and the cycle repeats. The output keeps switching between “0” and “1”.
Fig 5-5An astable multivibrator using the 555 (RA, RB, C1, C2)
Fig 5-6Timing diagram: the voltage on C1 rises and falls between 1/3 Vcc and 2/3 Vcc while the output Vout switches high and low

Because charging goes through two resistors but discharging through only RB, the high and low parts are not equal. The ratio is the duty cycle, from 50% to 100% for this circuit:

D = (RA + RB) ÷ (RA + 2RB) × 100%

f = 1.44 ÷ ((RA + 2RB) × C1)

The book prints this as 1 ÷ ((RA + 2RB) × C1); the projects below use the full form with 1.44.

If RB is much bigger than RA, D is close to 50%. If RA is much bigger than RB, D is well above 50%.

5.4.2 The 555 as a monostable (one pulse)

A monostable gives one pulse each time it is triggered. The trigger input (pin 2) is normally held near Vcc. When it drops below 1/3 Vcc, the flip-flop resets, the discharge transistor turns off and C1 charges through R1. At 2/3 Vcc the flip-flop changes again, the transistor discharges C1, and the output returns to “0”. Further triggers during the pulse are ignored.

Fig 5-7A monostable multivibrator using the 555, with the trigger input on pin 2

tm = 1.1 × R1 × C1 seconds

Example: R1 = 10 kΩ, C1 = 0.01 µF → tm = 1.1 × 10 × 10³ × 0.01 × 10⁻⁶ = 0.11 ms

🧮 Try it: 555 calculator

Astable uses RA, RB and C; monostable uses RA as R1 and C.

5.5 Putting the 555 on a breadboard ติดตั้งไอซีบนเบรดบอร์ด

A new IC’s pins splay outwards. Before you push it into the breadboard, bend them in so they stand straight down — press each row gently against the table, or use an IC tool. The same goes for any other DIP IC.

Fig 5-8Fitting a 555 into a breadboard: bend the splayed pins so they are straight, then it is ready to plug in. This works for any DIP IC

Next: Projects 7 and 8 →

Project 9 · Adjustable time-delay circuit

P9.1 How it works

This 555 monostable sets a delay from about 1 to 3 seconds with the variable resistor VR1 (100 kΩ down to 0 Ω). C1 and C2 are in parallel, giving 20 µF.

Tmax = 1.1 × (100k + 47k) × (10 µF + 10 µF) = 1.1 × 147 × 10³ × 20 × 10⁻⁶ ≈ 3.2 s

Tmin = 1.1 × (0 + 47k) × (10 µF + 10 µF) = 1.1 × 47 × 10³ × 20 × 10⁻⁶ ≈ 1 s

  • RESET is tied to the supply so the timer only resets at power-on.
  • The trigger (pin 2) needs a falling edge, so R1 pulls it up to keep it High. Pressing S1 (START) pulls pin 2 low and starts the timer.
  • The supply voltage is not in the equation, so the timing is about the same at 4.5 V or 6 V.
Fig P9-1An adjustable time delay using the 555, drawn in KiCad (R1 10k, VR1 100k, R2 47k, C1 and C2 10 µF, S1 START, R3 220, LED1)
Fig P9-2The adjustable timer on Tinkercad, ready to simulate
Fig P9-3The adjustable timer built with real parts on a breadboard. Scan the QR code for the demo video

🛠️ Lab 5.1 · Time it

  1. Simulate Project 9 in Tinkercad. Turn VR1 to one end, press START and time how long LED1 stays on.
  2. Turn VR1 to the other end and time it again. Compare with Tmin ≈ 1 s and Tmax ≈ 3.2 s.
  3. Remove C2 (leaving 10 µF). Predict the new times, then measure.

Next: the music IC →

5.6 The melody IC ไอซีเสียงเพลง

A melody IC plays a tune, for fun projects or as an alert in appliances. The best known is the UM66, first made by UTC (Unisonic Tech), with one song built in. Many compatible versions now exist, such as the BJ1552, which can replace a UM66 directly.

Fig 5-9Inside the UM66 / BJ1552: oscillator, tone generator, ROMs for the notes and rhythm, beat and tempo control and an output driver — and its pins: GND, Vcc and OUT
  • A 64-note memory.
  • A built-in oscillator; it can drive a piezo directly, or through an amplifier for more volume.
  • Supply 1.3–4.5 V (3 V recommended); it uses very little current — 2 mA at most.
  • A 3-pin TO-92 package.

Project 10 · Using the melody IC

P10.1 How it works

The UM66 or BJ1552 needs only 3 connections. Its output (pin 3) drives the piezo directly.

Fig P10-1A first circuit with the UM66 melody IC: 4.5 V supply, IC1 and a piezo speaker

P10.2 Building it

⚠️ Not simulatable

Tinkercad has no UM66, so it cannot play the tune. Use Fig P10-2 as a wiring guide for the real breadboard.

Fig P10-2Wiring the UM66 / BJ1552 on a breadboard: the piezo speaker, and the IC’s ground, sound output and supply pins
Fig P10-3Project 10 built with real parts. Scan the QR code for the demo video

Project 11 · Music box

This builds on Project 10 by adding a transistor amplifier, so the music is louder. Use it as a music box, or connect it to a microcontroller to play a tune when something happens.

P11.1 How it works

The UM66 output passes through R1 (1 kΩ) to the base of Q1, which drives the piezo louder.

Fig P11-1A music box: the UM66 / BJ1552 with a transistor amplifier (R1 1k, Q1 BC547) driving the piezo

P11.2 Building it

Like Project 10, Tinkercad cannot simulate it. Build it with real parts using Figs P11-2 and P11-3, then power it up.

Fig P11-2Wiring the music box on a breadboard. It cannot be simulated because Tinkercad has no UM66
Fig P11-3The music box built with real parts. Scan the QR code for the demo video

Next: review →

Formulas from this chapter

CircuitFormulaBook’s example
Astable frequencyf = 1.44 ÷ ((RA + 2RB) × C)10k, 10k, 0.047 µF → 1.023 kHz
Astable duty cycleD = (RA + RB) ÷ (RA + 2RB) × 100%10k, 10k → 66.7%
Monostable pulsetm = 1.1 × R × C10k, 0.01 µF → 0.11 ms
Project 7 flasher1.44 ÷ ((R1 + 2(R2 + VR1)) × C1)0.68–12 Hz
Project 9 timer1.1 × (VR1 + R2) × (C1 + C2)1–3.2 s

🛠️ Activity · Work it out, then test it

Use the calculator on the 555 tab to check your answers, then try them in Tinkercad.

  1. Project 7 with C1 changed to 4.7 µF: what are the slowest and fastest blink rates?
  2. Project 8: choose a new C1 so the tone is about 500 Hz. Simulate it — does it sound lower?
  3. Project 8: which C1 gives about 2 kHz?
  4. Project 9: which R2 would make the shortest delay 2 s with the same 20 µF?
  5. A monostable with R1 = 100 kΩ and C1 = 10 µF: how long is the pulse?

Check yourself

Chapter 5 of the book has worked calculations but no exercises, so these questions are my own, based on its pages.

1. On a DIP IC, how do you find pin 1?
2. At what fractions of Vcc do the 555’s two comparators switch?
3. Which 555 pin is the output?
4. Why does a basic 555 astable always have a duty cycle above 50%?
5. A 555 monostable has R1 = 10 kΩ and C1 = 0.01 µF. How long is its output pulse?
6. In Project 7, what happens to the blink rate as you turn VR1 up to 100 kΩ?
7. In Project 8, why is the frequency set to about 1 kHz?
8. In Project 9, why are two 10 µF capacitors placed in parallel?
9. How many pins does the UM66 melody IC have?
10. Why does Project 11 add a BC547 transistor to the melody circuit?