# How connected devices work

Sensors, chips, radios, power and software, explained from the ground up by Dharanova. No brand is recommended here, and each fact links to its source.

Page: https://dharanova.com/learn/ · Data last checked 7 October 2026

## One device, end to end

- **Physical world**: Temperature, force, light, sound and motion. None of these arrive as numbers.
  - Data: Everything starts as a physical quantity, and it comes with its own noise.
- **Sensor**: Turns a physical quantity into an electrical signal.
  - Data: Output is an analog voltage, current, resistance or capacitance change, a pulse train, or already a digital reading.
  - Buses: Digital sensors usually connect over I²C or SPI (sometimes I3C, UART, 1-Wire, or PDM/I²S for microphones); analog ones go through conditioning and an ADC.
  - Power: Some sensors need continuous excitation; switching them off between readings saves energy.
  - Attack surface: A sensor can be fooled physically (heated, shaken, blinded) without touching any electronics.
- **Conditioning**: Amplifies, filters and shifts the signal into the range the ADC measures best.
  - Data: Gain boosts a millivolt signal to fill the ADC's input range. A low-pass filter weakens frequencies above half the sampling rate, which would otherwise show up as false signals; because real filters cut off gradually, designers sample well above twice the highest frequency they need.
  - Power: Precision amplifiers draw continuous current; low-power designs switch them off between readings.
- **ADC**: Samples the analog voltage at fixed intervals and outputs numbers.
  - Data: Resolution sets the step size; the sampling rate must exceed twice the highest frequency in the signal to capture it without aliasing.
  - Buses: Often built into the microcontroller; external ADCs connect over SPI or I²C.
- **Microcontroller**: Runs the firmware: reads the samples, decides what they mean, and acts or reports.
  - Data: Filters, averages or runs a small model, so only meaningful results leave the device.
  - Buses: Connects to other chips over I²C, SPI and UART, and drives simpler parts directly through GPIO and PWM pins.
  - Power: Spends most of its life asleep; average current is set by its sleep current plus how often, and for how long, it wakes.
  - Attack surface: Firmware can be read out or replaced through an unlocked debug port, a serial bootloader left enabled, or unsigned updates.
- **Secure element**: Optional separate chip that holds long-term private keys so they never sit in the main processor's memory. Some microcontrollers build a similar key store in.
  - Buses: Usually connected over I²C or SPI.
  - Attack surface: The device's identity key cannot be copied out even if the main firmware is hacked, though hacked firmware could still ask the chip to use it.
- **Radio**: Sends and receives packets over the air: Bluetooth LE, Thread, Zigbee, Wi-Fi or LoRa. (Cellular goes through a mobile operator and the internet, so it bypasses the home hub.)
  - Data: Battery devices send small packets, and not often. Every byte sent costs energy. Wi-Fi devices skip the hub's radio and join the home Wi-Fi directly.
  - Buses: Integrated in wireless MCUs; otherwise a separate chip or module on SPI or UART, or SDIO for faster Wi-Fi. Cellular modules are usually driven over UART with AT commands, or USB when the host runs Linux.
  - Power: Usually the largest consumer among the electronics when active, especially Wi-Fi and cellular transmit; time spent listening costs energy too. Motors, relays and heated sensors can draw more.
  - Attack surface: Anything in range can listen or transmit; links need encryption and authenticated pairing.
- **Battery**: Stores the energy; its chemistry sets the voltage range the rest of the device must tolerate.
  - Power: Usable capacity depends on load current, temperature and the cut-off voltage of the circuit.
- **Regulator**: Converts the battery or supply voltage into the stable rails each chip needs.
  - Power: Its own quiescent current is spent all the time, including while everything else sleeps.
- **Debug port**: JTAG or SWD pins used in development to program and inspect the chip.
  - Buses: JTAG or Arm SWD; a probe connects it to a debugger on a computer.
  - Attack surface: If left open on a shipped product, it gives full control of the chip. Lock it before shipping. On many chips, someone with the board in hand can still defeat the lock by glitching the power supply, so keep long-term secrets in a secure element.
- **Actuator**: Turns a decision back into a physical effect: a relay, motor, valve, LED or speaker.
  - Data: The return path: a command from the device, the gateway or the user becomes movement, light or sound.
  - Power: Motors and relays draw far more current than the logic driving them. They need a driver stage, usually fed straight from the battery or supply rather than the logic rail.
- **Home hub**: A local, always-on device that connects low-power radios to the home network, and makes decisions without the internet.
  - Data: Collects readings from every device, decides what to do and keeps the history, all without an internet connection.
  - Buses: Bluetooth LE, Thread, Zigbee or LoRa on one side; Ethernet or Wi-Fi to the home network on the other.
  - Power: Mains-powered and always on, so it can listen for battery devices that wake only briefly.
  - Attack surface: It holds credentials for every device behind it, so if it is hacked, the whole site is exposed.
- **Local broker**: Passes messages between devices and apps. It runs on the hub, so nothing has to leave the building.
  - Data: Devices and apps do not need to know about each other; each one just sends and receives messages.
  - Buses: MQTT over TCP, ideally with TLS even inside the home.
  - Attack surface: Needs per-device credentials and topic permissions, or any device can publish as any other.
- **Remote server**: Optional. Remote access from outside the home, an off-site backup, and delivery of software updates.
  - Data: Only what needs the outside world goes here. In a local-first design, the home keeps working when it cannot be reached.
  - Attack surface: The update service, through the hub, can push code to every device. The firmware signing key is the most valuable secret in the system; keep it offline or in a hardware security module, not on the server. A stolen account or exposed remote access reaches the hub the same way.
- **App or dashboard**: Where a person sees results and sends commands, from a phone or screen on the home network.
  - Data: Commands travel back the same way: app, broker, hub, radio, device, actuator.

## The map

### Sense

How does a device measure the physical world?

- [What a sensor actually is](https://dharanova.com/learn/what-is-a-sensor.md) (Foundation): A sensor responds to something physical, like heat or force, in a way a circuit can measure. Every reading depends on how well it does that.
- [Analog-to-digital conversion](https://dharanova.com/learn/adc-basics.md) (Foundation): How a voltage becomes a number: resolution, reference voltage, sampling rate and the Nyquist limit.
- [Accuracy, precision and resolution](https://dharanova.com/learn/accuracy-precision-resolution.md) (Foundation): Accuracy, precision and resolution mean different things, and datasheets often blur them. Mixing them up gives readings that look precise but are wrong.
- [Signal conditioning](https://dharanova.com/learn/signal-conditioning.md) (Core): Raw sensor signals are often tiny or noisy. Conditioning amplifies and filters them so the ADC can measure them well.
- [The common sensor families](https://dharanova.com/learn/sensor-families.md) (Core): How common sensors for temperature, motion and sound work, and what limits each one.

### Think

What kind of chip does the computing, and why that kind?

- [Microcontroller or microprocessor?](https://dharanova.com/learn/mcu-vs-mpu.md) (Foundation): A microcontroller is a small computer on one chip. A microprocessor usually needs separate memory chips, but can run a full operating system like Linux.
- [Instruction sets: Arm, RISC-V, x86 and others](https://dharanova.com/learn/isa-landscape.md) (Foundation): The instruction set is the language a processor understands. Who owns it, and who can build chips with it, shapes everything around it.
- [Chip, module, SoM, dev board, SBC](https://dharanova.com/learn/chip-som-board.md) (Foundation): The same processor is sold as a bare chip, a module or a ready-made board. Their prices are not comparable, and mixing them up is a common mistake.
- [Anatomy of an application-processor system](https://dharanova.com/learn/anatomy-of-an-mpu-system.md) (Core): What sits around the processor on a Linux board, and how it starts up, from power-on to a login prompt.
- [Application cores and microcontroller cores on one chip](https://dharanova.com/learn/heterogeneous-socs.md) (Core): Many processors that run Linux also include a small microcontroller core, which handles time-critical work while Linux does the rest.
- [GPUs, DSPs, ISPs, NPUs and what TOPS means](https://dharanova.com/learn/accelerators-and-tops.md) (Core): Accelerators do one kind of work far more efficiently than a CPU. TOPS is the headline number, and it is hard to compare between chips.
- [Choosing a microcontroller or processor](https://dharanova.com/learn/choosing-a-processor.md) (Core): Answer six questions to find the kind of chip that fits your project, from small microcontrollers to Linux-class processors. You get a class, not a brand.

### Talk

How do chips, devices and servers exchange data?

- [UART, I²C and SPI](https://dharanova.com/learn/uart-i2c-spi.md) (Foundation): The three buses that connect most sensors, displays and radio chips to a microcontroller, and how to choose between them.
- [Bluetooth LE, Wi-Fi and 802.15.4](https://dharanova.com/learn/short-range-radio.md) (Foundation): Common radios in home and wearable devices, and how each one trades range, speed and battery life.
- [CAN, RS-485 and Ethernet in the field](https://dharanova.com/learn/field-buses.md) (Core): Buses built for long cables and electrical noise, used in vehicles, factories and buildings.
- [LoRa, LoRaWAN, NB-IoT and LTE-M](https://dharanova.com/learn/long-range-radio.md) (Core): Low-power wide-area networks trade data rate for range and battery life. They suit small, infrequent messages from devices that sleep most of the time.
- [MQTT, CoAP and HTTP](https://dharanova.com/learn/iot-protocols.md) (Core): Once a device is on a network, it needs a way to send its data. MQTT, CoAP and HTTP each suit different kinds of device.
- [Matter, Thread and Zigbee](https://dharanova.com/learn/smart-home-standards.md) (Deep dive): How smart-home devices from different brands are meant to work together, and which part of the job each standard covers.

### Power

Where does the energy go, and how long will it last?

- [Writing a power budget](https://dharanova.com/learn/power-budget.md) (Foundation): Battery life comes down to arithmetic: how much current each state draws, for how long, and how often. Work it out before choosing a battery.
- [Batteries for small devices](https://dharanova.com/learn/batteries.md) (Foundation): Coin cells, Li-ion and LiFePO4: their voltages, their capacity, and when the capacity on the label actually holds.
- [LDOs, buck converters and PMICs](https://dharanova.com/learn/regulators.md) (Core): How a battery or adapter is turned into the steady voltages a chip needs, and why the choice of regulator matters for battery life.
- [Sleep modes and waking up](https://dharanova.com/learn/low-power-modes.md) (Core): A battery device spends most of its time asleep. What stays on, what wakes it up, and what is lost while it sleeps.
- [Designing for power that cuts out](https://dharanova.com/learn/unreliable-power.md) (Deep dive): Power cuts and voltage dips are common in many places. A device should handle them safely and recover on its own.

### Run

What software runs on the chip, and how does it start?

- [Bare metal: the super-loop and interrupts](https://dharanova.com/learn/bare-metal.md) (Foundation): The simplest firmware is a main loop and a few interrupt handlers, with no operating system. It handles more than you might expect.
- [Real-time operating systems](https://dharanova.com/learn/rtos.md) (Core): An RTOS adds tasks, priorities and predictable scheduling to a microcontroller, so deadlines can be met. Real-time means predictable timing, not raw speed.
- [Embedded Linux](https://dharanova.com/learn/embedded-linux.md) (Core): Running Linux on a device usually means building or adapting your own small Linux system, and keeping it updated for as long as the product is in use.
- [Debug probes and bench instruments](https://dharanova.com/learn/debugging-hardware.md) (Core): Tools for seeing inside a running chip and on the wires around it: JTAG, SWD, GDB, logic analysers and oscilloscopes.

### Secure

How does a device stay trustworthy after it ships?

- [Secure boot and the root of trust](https://dharanova.com/learn/secure-boot.md) (Core): At start-up, each piece of software checks the signature of the next one before running it, starting from code that cannot be changed.
- [Over-the-air updates](https://dharanova.com/learn/ota-updates.md) (Core): Devices need software updates after they ship, and a failed update must not break the device. A/B slots and rollback handle both.
- [Security baselines and the law](https://dharanova.com/learn/iot-security-rules.md) (Deep dive): Several countries now have security rules for connected products. The basic requirements are short and specific.

### Infer

How does a small device run machine learning itself?

- [On the device or in the cloud?](https://dharanova.com/learn/on-device-vs-cloud.md) (Foundation): Where a model runs affects speed, privacy, cost, and what happens when the network is down.
- [Machine learning on a microcontroller](https://dharanova.com/learn/tinyml.md) (Core): Small machine-learning models can run on microcontrollers, with no operating system and very little memory.
- [Quantisation: making models fit](https://dharanova.com/learn/quantisation.md) (Deep dive): Storing weights as 8-bit integers instead of 32-bit floats makes a model about four times smaller. Quantising the activations too lets integer-only NPUs run it.
