Actuators & Control · Study deck

Visual and Audio Actuators: Displays and Buzzers

An OLED can show rich detail but uses memory and a shared bus.

Motor Max is your guide for this deck.

visualaudio
Motor Max, the module guide, in a scene from this chapter.
iotclass.org

After studying this chapter

Learning objectives

You will be able to:

  • Explain: A 2 kHz passive-buzzer alert has a period of 1 / 2000 = 0.0005 s, or 500 microseconds; a 50% square wave is high for about 250 microseconds and low for about 250 microseconds.
  • Explain: If a small OLED draws 20 mA from a 3.3 V rail while lit, the display load is 3.3 V x 0.020 A = 0.066 W.
  • Explain: The first pixel reads its color instruction, then passes the rest of the message down the chain -- like a game of telephone, but it actually works perfectly!".
iotclass.org

Major section

Musical Note Frequency Reference

Active buzzers have built-in oscillators, so the controller supplies an on/off command rather than an audio-frequency waveform.

  • Applying rated power starts its internal oscillator and fixed tone; firmware controls timing and pattern, while a passive buzzer is required when pitch itself must carry information.
A round piezo buzzer component with two wire leads
A round piezo buzzer component with two wire leads
iotclass.org

Major section

Bedside Feedback Actuators

Scenario: A team is designing bedside monitors for a clinical ward.

  • Each monitor tracks several patient readings and must draw staff attention to urgent conditions while avoiding constant, low-value beeping.
  • A local high-visibility LED or strobe is simpler to verify.
  • That separation keeps urgent states noticeable while reducing unnecessary sound.
iotclass.org

Major section

For Kids: Meet the Actuator Crew!

"Time for the Output Show!" announced the LED, glowing all the colors of the rainbow. "We're the actuators that you can SEE and HEAR!".

  • She started dim, then slowly grew brighter and brighter. "Max controls my brightness with PWM -- the same trick he uses for motors!
  • Even though there are 30 of us, Max only needs ONE wire to talk to all of us.
  • I can even play songs!".
iotclass.org

Major section

For Kids: Meet the Actuator Crew! (continued)

The first pixel reads its color instruction, then passes the rest of the message down the chain -- like a game of telephone, but it actually works perfectly!".

  • "And I'm the screen!" said OLED Olivia, displaying a smiley face. "I can show Sammy's temperature readings, draw pictures, and even make progress bars.
  • I use tiny organic light-emitting dots -- each pixel makes its own light, so I'm super bright and clear!".
  • the battery whispered, "Just remember, all those pretty lights use MY energy.
iotclass.org

Major section

Deep Dive: Feedback Loads, Perception, and Timed LEDs

The panel encodes several user-facing states, while the companion circuit exposes the GPIO, resistor, LED, and return path that make each indication electrically safe.

  • The panel decides what a person can distinguish; the resistor and return path decide whether the controller can drive the chosen LED safely.
  • Displays need the same budget discipline.

Numbers to remember

1.3 Vthe resistor must drop 1.3 V

Why it matters

If the value changes only occasionally, e-paper is often a better human interface because it can keep an image visible between refreshes without continuous display power.

Status indicator LED array with a current-limited GPIO LED circuit
Status indicator LED array with a current-limited GPIO LED circuit
iotclass.org

Major section

Deep Dive: Feedback Loads, Perception, and Timed LEDs (continued)

That pairing connects perception, timing, and electrical load rather than treating feedback as decoration.

  • LEDs, displays, and buzzers are simple only at the user interface.
  • Electrically, each one still has a load path and a control signal.
  • Choosing 150 ohms gives I = 1.3 / 150 = 0.0087 A, or 8.7 mA.
iotclass.org

Major section

Deep Dive: Feedback Loads, Perception, and Timed LEDs (continued)

A buzzer interrupts attention, but repeated audio becomes annoying and may be masked by the environment.

  • The resistor dissipates 1.3 V x 0.0087 A = 0.011 W, so a small signal resistor has margin.
  • The design decision is not only electrical.
  • Feedback actuators differ in noticeability, power, and information density.
iotclass.org

Major section

Deep Dive: Feedback Loads, Perception, and Timed LEDs (continued)

Left on for 24 hours, that is 0.066 W x 24 h = 1.58 Wh before regulator losses.

  • At 25% PWM duty cycle, the average LED current is about 8.7 mA x 0.25 = 2.2 mA.
  • A single green LED is excellent for a healthy status, but poor for a fault that must be noticed across a room.
  • On a small battery device, that can dominate the energy budget.
iotclass.org

Major section

Deep Dive: Feedback Loads, Perception, and Timed LEDs (continued)

Strong products combine channels: quiet visual status for normal operation, stronger visual patterns for warnings, and audio only when the state needs immediate attention.

  • If a small OLED draws 20 mA from a 3.3 V rail while lit, the display load is 3.3 V x 0.020 A = 0.066 W.
  • Buzzers split into two kinds that are often confused.
  • That timing issue is separate from the power issue.
iotclass.org

Major section

Deep Dive: Feedback Loads, Perception, and Timed LEDs (continued)

A lower 500 Hz warning tone has a period of 1 / 500 = 0.002 s, or 2 ms.

  • An active buzzer has an internal oscillator and produces one fixed tone when powered.
  • A passive piezo or magnetic buzzer needs the controller to supply an audio-frequency waveform.
  • The controller changes pitch by changing the period, not by changing the supply voltage.
iotclass.org

Major section

Deep Dive: Feedback Loads, Perception, and Timed LEDs (continued)

A 2 kHz passive-buzzer alert has a period of 1 / 2000 = 0.0005 s, or 500 microseconds; a 50% square wave is high for about 250 microseconds and low for about 250 microseconds.

  • Each pixel contains a driver chip, reads the first 24 bits as its green, red, and blue values, and forwards the rest downstream.
  • A 30-pixel strip therefore needs 30 pixels x 24 bits = 720 bits, or 720 x 1.25 = 900 microseconds, plus the reset interval.
  • An interrupt that pauses the GPIO waveform halfway through a bit can corrupt the data seen by every later pixel.
iotclass.org

Major section

4. Active Buzzer and Passive Buzzer Confusion

Active buzzers contain an internal oscillator and produce a fixed tone when voltage is applied (just connect VCC and GND).

  • Passive buzzers require an external oscillating signal.
  • They look identical externally and share the same package styles.
  • Testing with a DC supply: active buzzers beep immediately; passive buzzers are silent.
iotclass.org

Deck summary

Key takeaways

Active buzzers have built-in oscillators, so the controller supplies an on/off command rather than an audio-frequency waveform.

  • Scenario: A team is designing bedside monitors for a clinical ward.
  • "Time for the Output Show!" announced the LED, glowing all the colors of the rainbow. "We're the actuators that you can SEE and HEAR!".
  • The first pixel reads its color instruction, then passes the rest of the message down the chain -- like a game of telephone, but it actually works perfectly!".
  • That pairing connects perception, timing, and electrical load rather than treating feedback as decoration.
iotclass.org

Retrieval practice

Recall check 1 of 6

Motor Max says: answer from memory, then check your reasoning.

Q1What is the key difference between an active buzzer and a passive buzzer?

AAn active buzzer needs PWM, while a passive buzzer only needs DC power
BAn active buzzer makes its own tone; a passive buzzer needs a frequency signal
CAn active buzzer plays melodies; a passive buzzer is fixed to one pitch
DAn active buzzer is always lower power; a passive buzzer always uses more current
Show answer

Answer: B An active buzzer contains an oscillator and produces a fixed tone when powered.

iotclass.org

Retrieval practice

Recall check 2 of 6

Motor Max says: answer from memory, then check your reasoning.

Q2How do addressable LED strips (NeoPixels/WS2812B) differ from regular RGB LEDs?

AThey need a separate PWM pin for each red, green, and blue channel
BEach pixel has a driver, so one data wire can set independent colors down the chain
CThey contain no drivers, so every pixel must share the same RGB value
DThey use analog voltage levels instead of timed digital color data
Show answer

Answer: B Each addressable pixel contains a small driver.

iotclass.org

Retrieval practice

Recall check 3 of 6

Motor Max says: answer from memory, then check your reasoning.

Q3An IoT factory safety system needs to alert workers of a chemical leak. The alert must be perceivable in a noisy 95 dB environment where workers wear hearing protection. Which combination of actuators is most effective?

AA loud buzzer alone, chosen to sit slightly above the measured noise level
BA phone notification, assuming workers will feel or hear their own devices
CHigh-intensity strobes paired with a low-frequency siren pattern
DA small status LED mounted only on the nearest IoT gateway
Show answer

Answer: C Critical alerts in noisy industrial spaces should not depend on one sensory channel.

iotclass.org

Retrieval practice

Recall check 4 of 6

Motor Max says: answer from memory, then check your reasoning.

Q4A smart home uses RGB LED strips for ambient lighting. The system creates "sunrise" by gradually transitioning from dim red to bright white over 30 minutes. Using PWM with 8-bit resolution (256 levels), users report visible "steps" in brightness during the dim red phase. What causes this?

AHuman brightness perception is logarithmic
BThe PWM frequency is too low, causing visible flicker during transitions
CThe LED color temperature changes at low duty cycles, creating the appearance of steps
D8-bit resolution is insufficient for any LED dimming application
Show answer

Answer: A Human brightness perception follows a logarithmic (Weber-Fechner) law.

iotclass.org

Retrieval practice

Recall check 5 of 6

Motor Max says: answer from memory, then check your reasoning.

Q5Complete the code to play a tone on a piezo buzzer:

Abuzzer = PWM(Pin(4))
Bbuzzer = Pin(4, Pin.OUT)
Cbuzzer = ADC(Pin(4))
Dbuzzer = Pin(4, Pin.IN)
Show answer

Answer: A A piezo buzzer uses PWM where freq() sets the tone pitch and duty(512) provides 50% duty cycle for maximum volume.

iotclass.org

Retrieval practice

Recall check 6 of 6

Motor Max says: answer from memory, then check your reasoning.

Q6A chain of WS2812 addressable LEDs shows the first few pixels correctly but garbles colors further down the strip. What is the most likely cause?

AA data-timing error corrupts the forwarded bit stream
BA large series resistor dims the far pixels
CA missing clock wire makes each pixel guess randomly
DMissing gamma correction rewrites color bits
Show answer

Answer: A WS2812 pixels use a clockless single-wire protocol that encodes bits by pulse width.

iotclass.org

Print reference

Answers 1 of 2

Answer key.

  1. B · An active buzzer contains an oscillator and produces a fixed tone when powered.
  2. B · Each addressable pixel contains a small driver.
  3. C · Critical alerts in noisy industrial spaces should not depend on one sensory channel.
  4. A · Human brightness perception follows a logarithmic (Weber-Fechner) law.
  5. A · A piezo buzzer uses PWM where freq() sets the tone pitch and duty(512) provides 50% duty cycle for maximum volume.
iotclass.org

Print reference

Answers 2 of 2

Answer key.

  1. A · WS2812 pixels use a clockless single-wire protocol that encodes bits by pulse width.
iotclass.org