Electronics & Circuits · Study deck
Electronics: Controller Design and Review
A fan controller joins sensing, such as reading temperature, with code and drive current, the electrical current supplied to its motor.
Voltage Vera is your guide for this deck.

After studying this chapter
Learning objectives
You will be able to:
- Explain: The caption's 10 mV per degree Celsius links that output to the ADC calculation, while pin identification and thermal placement warn that the transistor-like package is not self-explanatory.
- Explain: Its purpose is to reveal the LM35 in this fan controller is a three-lead analog sensor: supply, ground, and a voltage output that changes by 10 mV per degree Celsius.
- Explain: Your Challenge: Design a circuit that automatically turns on a 12V DC fan (300mA) when temperature exceeds 30°C, using an ESP32 and LM35 temperature sensor.
- Explain: Diode Choice: 1N5819 Schottky is better.
Major section
Smart Fan Controller Design
Your Challenge: Design a circuit that automatically turns on a 12V DC fan (300mA) when temperature exceeds 30°C, using an ESP32 and LM35 temperature sensor.
- Its purpose is to reveal the LM35 in this fan controller is a three-lead analog sensor: supply, ground, and a voltage output that changes by 10 mV per degree Celsius.

Major section
Smart Fan Controller Design (continued)
The component list below is the evidence set for those linked decisions, not a menu of interchangeable parts.
- Photo: Nevit Dilmen, CC BY-SA 3.0 before a design claim is accepted.
- Hint: LM35 max output is 1.5V @ 150°C.
- Step 1 Solution: Sensor Interface: LM35 can connect directly to ESP32 ADC.
Major section
Circuit note: Why the fan circuit needs the math
The mathematical gist: A GPIO is a command, not a motor supply.
- For this chapter's 300 mA fan, a 12 mA pin would be overloaded by 25.0 times.
Major section
Three paths in the fan controller
"Welcome to Electronics School!" announced the microcontroller. "Today I'm going to teach you how I was born -- from tiny pieces of silicon!".
LM35 output → ESP32 measurement; ESP32 GPIO → transistor control; 12 V supply → fan → transistor → return. The GPIO does not carry motor current.
Major section
BJT vs MOSFET Resistors
The Error: A developer uses a 10k ohm resistor from GPIO to the base/gate for both a BJT and a MOSFET.
- The BJT circuit barely turns on, while the MOSFET works perfectly.
- MOSFETs are voltage-controlled -- with essentially zero DC gate current, the gate resistor does not set steady-state gate voltage.
- The MOSFET is suitable only if its datasheet gives low Rds(on) at the available GPIO voltage.
Deck summary
Key takeaways
Your Challenge: Design a circuit that automatically turns on a 12V DC fan (300mA) when temperature exceeds 30°C, using an ESP32 and LM35 temperature sensor.
- The component list below is the evidence set for those linked decisions, not a menu of interchangeable parts.
- The caption's 10 mV per degree Celsius links that output to the ADC calculation, while pin identification and thermal placement warn that the transistor-like package is not self-explanatory.
- The mathematical gist: A GPIO is a command, not a motor supply.
Retrieval practice
Recall check 1 of 4

Voltage Vera says: answer from memory, then check your reasoning.
Q1You need to switch a 12V motor whose worst-case current is 1.5A from an ESP32 GPIO (3.3V output, max 12mA), including PWM speed control. Which component is MOST appropriate after checking its 3.3V gate-drive rating?
Show answer
Answer: C see answers page
Retrieval practice
Recall check 2 of 4

Voltage Vera says: answer from memory, then check your reasoning.
Q2An ESP32 GPIO pin outputs 3.3V and can source a maximum of 12 mA. A designer connects it directly to a 12V relay coil that requires 80 mA. What will happen, and what is the correct interface approach?
Show answer
Answer: B The GPIO cannot provide the coil's rated 12V and 80mA.
Retrieval practice
Recall check 3 of 4

Voltage Vera says: answer from memory, then check your reasoning.
Q3Two resistors measured at 10k ohms each divide an ideal 3.3V source to 1.65V at a high-impedance ADC input. Replacing that source with a 3.3V sensor whose output impedance is 1k ohm makes the measured divider output about 1.57V. What caused the discrepancy?
Show answer
Answer: C The sensor's 1k ohm output impedance adds to the upper 10k ohm arm.
Retrieval practice
Recall check 4 of 4

Voltage Vera says: answer from memory, then check your reasoning.
Q4Q4: material to rated load pathWhat semiconductor junction conducts forward current while blocking reverse current within ratings?
Show answer
Answer: A The junction conducts forward current and blocks reverse current within rated limits.
Q5Q5: GPIO load decision helperComplete the GPIO-to-load safety helper for an electronics overview:
Show answer
Answer: A A GPIO pin is a signal source, not a power supply.
Print reference
Answers
Answer key.
- C · Logic-level N-channel MOSFET is the best choice for several reasons: (1) it can handle 1.5A with margin, (2) low Rds(on) keeps conduction loss low, (3) gate current is essentially zero in steady state versus several milliamps for a BJT, and (4) it can be driven directly from a microcontroller only if the datasheet supports low Rds(on) at the available gate voltage. Always check Rds(on) at your actual gate voltage, not just the 10V headline spec.
- B · The GPIO cannot provide the coil's rated 12V and 80mA.
- C · The sensor's 1k ohm output impedance adds to the upper 10k ohm arm.
- A · The junction conducts forward current and blocks reverse current within rated limits.
- A · A GPIO pin is a signal source, not a power supply.