Week 10: Output Devices
This week focused on power management for outputs, emphasizing current consumption and load requirements.
Before starting
Output devices are components that allow a system to interact with the physical world by transforming electrical signals into visible, mechanical, thermal, or audible actions. In embedded systems and digital fabrication environments, these devices receive instructions from a microcontroller (such as an ESP32 or XIAO) and execute actions like turning on a light, moving a motor, activating a relay, or generating sound. Unlike input devices (sensors), which collect data, output devices act upon that data, closing the loop between measurement and action.These devices operate by receiving control signals either digital (ON/OFF) or analog (variable levels) from a controller. Depending on the signal type, the output device interprets the instruction and produces a corresponding physical response.
| Communication Type | How It Works |
|---|---|
| GPIO (Digital Output) | Uses HIGH/LOW signals (ON/OFF) directly from microcontroller pins. |
| PWM (Pulse Width Modulation) | Modulates signal duty cycle to simulate analog output. |
| Analog Output (DAC) | Generates variable voltage levels instead of discrete signals. |
| I²C (Inter-Integrated Circuit) | Two-wire communication (SDA, SCL) with multiple addressable devices. |
| SPI (Serial Peripheral Interface) | High-speed communication using multiple lines (MOSI, MISO, SCK, CS). |
| UART (Serial Communication) | Asynchronous communication using TX/RX lines. |
Regarding electrical characteristics, output devices typically require higher current and sometimes higher voltages than what a microcontroller can safely provide. For instance, a GPIO pin usually supplies around 3.3V or 5V with a limited current (often 10–20 mA max), which is sufficient for small LEDs but not for motors or high-power loads. Therefore, external components such as transistors, MOSFETs, relays, or motor drivers are used to handle larger currents and protect the control circuitry.
Power consumption is a key factor when working with output devices. The basic electrical relationships used to analyze and design these systems include:
P = V × I This equation calculates power consumption, where P is power (watts), V is voltage (volts), and I is current (amperes). It is essential for determining how much energy an output device will consume.
I = V / R Derived from Ohm’s Law, this formula is used to calculate the current flowing through a device such as an LED, allowing proper resistor selection to avoid damage.
P = I² × R This form is useful for calculating power dissipation in resistive elements, such as current limiting resistors, ensuring they can handle the thermal load safely.
For further information about this topic, please consult this week’s group page.
Examples
Results
In XIAO and PLC
On the left, an example of the XIAO’s output is shown, controlling the NeoPixels and the DC motor. On the right, a test carried out with the PLC is presented, since due to confidentiality reasons, the rest of the system cannot be disclosed.Download files
For download 3D and others files, just click on the dancing shrimp.