LOGBOOK

HELP

1 / 104
time's up — finish this card
Other keys: show • Space: good • 1-4: rate • 0: skip • 5: flag
Topic IoT Boards, Sensors and Development Tools

Question

What is the difference between through-hole (PTH) and surface-mount (SMD) resistors?

Answer

Through-hole resistors have wire leads that go through holes, fit into a breadboard and use colour bands; surface-mount resistors are tiny blocks soldered onto pads on the surface of a PCB and use a printed number code.

Through-hole (PTH) Surface-mount (SMD)
Mounting Leads pushed through holes and soldered on the other side, or into a breadboard Soldered onto pads on top of the PCB
Size Several millimetres, easy to handle Down to fractions of a millimetre
Value marking Colour bands Printed numeric code, e.g. 472 = 47 × 10² = 4.7 kΩ
Where you meet it Prototyping, breadboards, hobby kits Almost every mass-produced board, including the ESP32 dev board

The split mirrors the IoT development path. You prototype with through-hole parts on a breadboard because you can plug them in and swap them. The product is then made with SMD parts because they are smaller, cheaper and can be placed by machine.

Resistors also come as resistor packs (several in one package) and variable resistors such as the potentiometer, whose resistance changes when you turn the knob.

Tip: the SMD code uses the same idea as the colour bands: two digits then the number of zeros.

Go deeper:

or press any other key
Topic Real-Time Operating Systems and Task Scheduling

Question

What is a real-time operating system, and what does "real-time" actually mean?

Answer

An RTOS manages the hardware of an embedded system with precise, predictable timing and high reliability. "Real-time" means every response is guaranteed within a known deadline, not that it is fast.

A general-purpose OS such as Windows or desktop Linux is designed to keep the whole machine busy and be fair to every program. It will usually respond quickly, but it makes no promise: a background update or a page fault can delay your code by an unpredictable amount.

An RTOS makes the opposite trade. It is intended to serve applications that process data as it comes in, and its key goal is that the timing is predictable: the worst-case time to respond to an event is known and bounded. The six properties it is built around are:

  1. Multi-tasking — several tasks share the processor.
  2. Small latency — the delay before a task gets the processor is bounded.
  3. Preemption — a more important task can interrupt a less important one.
  4. Predictability — you know how long tasks take.
  5. Determinism — the same inputs lead to the same timing, so deadlines can be proven.
  6. Responsiveness — inputs and events are handled within a defined short period.

A car's airbag controller is the classic example. Deploying in 15 ms every time is correct; deploying in 1 ms usually and 200 ms occasionally is a failure, even though its average is faster.

Tip: real-time = on time, every time. A late correct answer is a wrong answer.

Go deeper:

or press any other key