📚 Input and Output Devices: Working Principles and Classification | 输入输出设备的工作原理与分类
Input and output (I/O) devices form the essential interface between a computer system and the outside world. This article explores their classification, underlying mechanical and electronic principles, and typical applications, aligned with the CIE A-Level Computer Science syllabus.
输入与输出(I/O)设备是计算机系统与外部世界之间的关键接口。本文将结合 CIE A-Level 计算机科学考纲,深入探讨它们的分类、底层机械与电子工作原理,以及典型应用。
1. Classification of Input Devices | 输入设备的分类
Input devices can be broadly classified by the form of data they accept. Manual input devices require human action, such as a keyboard or mouse, while automatic input devices capture data without direct human intervention, such as barcode readers and sensors.
输入设备可按其接受的数据形式大致分类。手动输入设备需要人工操作,例如键盘或鼠标;而自动输入设备无需直接人工干预即可采集数据,例如条形码阅读器和传感器。
- Manual input: keyboard, mouse, touchscreen, microphone.
- Automatic input: optical mark recognition (OMR), magnetic ink character recognition (MICR), sensors.
- Direct input: data goes straight into the CPU without intermediate storage.
- Indirect input: data is first stored on a medium (e.g., USB drive) then read.
- 手动输入:键盘、鼠标、触摸屏、麦克风。
- 自动输入:光学标记识别(OMR)、磁墨水字符识别(MICR)、传感器。
- 直接输入:数据无需中间存储,直接进入 CPU。
- 间接输入:数据先存储在介质(如 U 盘)上,再被读取。
2. Keyboard: Membrane and Mechanical | 键盘:薄膜与机械式
A keyboard converts physical key presses into electrical signals. In a membrane keyboard, pressing a key pushes a conductive pad through a hole to complete a circuit between two membrane layers. Each key position has a unique row–column address, and the keyboard controller scans this matrix to identify the pressed key.
键盘将物理按键转换为电信号。在薄膜键盘中,按下按键时,导电垫穿过小孔使两层薄膜之间的电路闭合。每个键位具有唯一的行–列地址,键盘控制器扫描该矩阵以识别被按下的键。
Mechanical keyboards instead use individual spring-loaded switches. A keypress compresses a spring until two metal contacts touch, generating an electrical impulse. This switch-based design provides tactile feedback and a longer lifespan than membrane keyboards.
机械键盘则使用独立的弹簧开关。按下按键时压缩弹簧,使两个金属触点接触,产生电脉冲。这种基于开关的设计提供了触觉反馈,且寿命比薄膜键盘更长。
Key pressed → Contact closed → Circuit completed → Scan code generated → Sent to CPU
按键按下 → 触点闭合 → 电路导通 → 生成扫描码 → 发送至 CPU
3. Pointing Devices: Mouse and Trackpad | 指点设备:鼠标与触摸板
An optical mouse uses a small camera to take thousands of images per second of the surface beneath it. An image sensor detects changes in surface texture, and a digital signal processor (DSP) compares consecutive frames to calculate the direction and distance of movement. The horizontal and vertical displacement values (Δx and Δy) are sent to the computer, which moves the cursor accordingly.
光电鼠标使用小型摄像头每秒拍摄数千张其下方表面的图像。图像传感器检测表面纹理变化,数字信号处理器(DSP)比较连续帧的差异,从而计算出移动方向和距离。水平与垂直位移值(Δx 和 Δy)被发送至计算机,使光标相应移动。
Touchpads use capacitive sensing: the human finger acts as a conductor, changing the local electrostatic field at an intersection of a fine grid of electrodes. The controller determines the touched coordinates by measuring capacitance changes at each electrode intersection.
触摸板采用电容感应原理:人的手指作为导体,会改变精细电极网格交叉点附近的静电场。控制器通过测量每个电极交叉点处电容的变化来确定触摸坐标。
4. Scanners: Flatbed and Handheld | 扫描仪:平板式与手持式
A flatbed scanner operates by directing light from a bright lamp onto the document. The reflected light strikes a charge-coupled device (CCD) sensor array. Each sensor element converts light intensity into an analogue voltage, which is then converted by an analogue-to-digital converter (ADC) into a digital pixel value. The scanner moves the lamp and sensor across the document in small steps, building up a complete digital image line by line.
平板扫描仪的工作原理是:明亮灯管发出光线照射文档,反射光投射到电荷耦合器件(CCD)传感器阵列上。每个传感器单元将光强转换为模拟电压,再通过模数转换器(ADC)转换为数字像素值。扫描仪以微小的步进移动灯管和传感器,逐行构建完整数字图像。
Resolution is measured in dots per inch (dpi). A higher dpi means more samples per inch, producing greater detail but also larger file sizes. Colour scanners use three separate passes (red, green, blue) or a single pass with a colour filter array to capture chromatic information.
分辨率以每英寸点数(dpi)为单位。dpi 越高,每英寸采样的次数越多,图像细节越丰富,但文件体积也越大。彩色扫描仪通过三次独立扫描(红、绿、蓝)或使用带彩色滤光阵列的单次扫描来获取色彩信息。
5. Sensors and Microphones | 传感器与麦克风
Sensors are automatic input devices that measure physical quantities and convert them into digital signals. Common examples include temperature sensors (thermistors), light sensors (LDRs), pressure sensors, and proximity sensors. An embedded computer periodically samples the analogue signal from a sensor using an ADC, enabling real-time monitoring and control.
传感器是自动输入设备,用于测量物理量并将其转换为数字信号。常见例子包括温度传感器(热敏电阻)、光线传感器(光敏电阻)、压力传感器和接近传感器。嵌入式计算机使用 ADC 定期对传感器的模拟信号进行采样,从而实现实时监控与控制。
Microphones convert sound pressure waves into analogue electrical signals. In a dynamic microphone, sound waves vibrate a diaphragm attached to a coil that moves within a magnetic field, inducing a voltage. A condenser microphone instead uses a diaphragm and a backplate forming a capacitor; sound changes the gap between them, altering the capacitance and producing an electrical signal. This signal is sampled and quantised to create digital audio.
麦克风将声压波转换为模拟电信号。动圈麦克风中,声波振动连接音圈的振膜,音圈在磁场中运动产生感应电压。电容麦克风则利用振膜与背板构成电容器——声音改变二者间距,从而改变电容并产生电信号。该信号经过采样和量化后生成数字音频。
6. Touchscreen Technologies | 触摸屏技术
Resistive touchscreens consist of two transparent conductive layers separated by a tiny gap. When the screen is pressed, the outer layer flexes and contacts the inner layer, creating a voltage divider at the touch point. The controller measures the voltage to determine accurate coordinates. Resistive screens are cheap, work with any object (finger, stylus, glove), but lack multi-touch capability.
电阻式触摸屏由两层透明导电层构成,中间隔着微小间隙。当屏幕被按下时,外层发生弯曲并与内层接触,在触摸点形成分压。控制器测量电压以确定精确坐标。电阻屏价格低廉,可任意物体操作(手指、触控笔、手套),但不支持多点触控。
Capacitive touchscreens are made of a glass panel coated with a transparent conductor such as indium tin oxide (ITO). The human body is conductive, so touching the screen creates a capacitive coupling with the conductive layer. The controller detects the change in capacitance at each electrode and calculates the touch position. Capacitive screens support multi-touch gestures such as pinch-to-zoom, but require a conductive stylus or bare finger.
电容式触摸屏由涂有透明导电材料(如氧化铟锡 ITO)的玻璃面板制成。人体具有导电性,触摸屏幕时会与导电层形成电容耦合。控制器检测每个电极处电容的变化并计算触摸位置。电容屏支持多点触控手势(如双指缩放),但需要使用导电触控笔或裸指操作。
7. Classification of Output Devices | 输出设备的分类
Output devices present processed data to the user. They can be grouped into soft-copy output (temporary, on screen) and hard-copy output (permanent, on paper). Another classification distinguishes visual, auditory, and haptic outputs.
输出设备将处理后的数据呈现给用户。它们可分为软拷贝输出(暂时的,显示在屏幕上)和硬拷贝输出(持久的,打印在纸上)。另一种分类方式则区分视觉、听觉和触觉输出。
- Soft-copy: monitors, projectors, speakers.
- Hard-copy: printers, plotters.
- Visual: display screens, LEDs.
- Auditory: speakers, headphones, buzzers.
- 软拷贝:显示器、投影仪、扬声器。
- 硬拷贝:打印机、绘图仪。
- 视觉:显示屏、LED 指示灯。
- 听觉:扬声器、耳机、蜂鸣器。
8. Display Technologies: LCD and OLED | 显示技术:LCD 与 OLED
Liquid crystal display (LCD) panels do not emit light themselves; they rely on a backlight. The backlight passes through a sheet of liquid crystal molecules sandwiched between two polarising filters. When an electric field is applied, the molecules twist, changing the polarisation of light and therefore controlling how much light passes through each sub-pixel (red, green, or blue). An image is formed by combining thousands of these sub-pixels.
液晶显示器(LCD)面板本身不发光,而是依赖背光源。背光穿过夹在两片偏光滤光片之间的液晶分子层。当施加电场时,液晶分子发生扭转,改变光的偏振方向,从而控制每个子像素(红、绿或蓝)的光透过量。数千个子像素组合起来便形成图像。
Organic light-emitting diode (OLED) displays use organic compounds that emit light directly when an electric current passes through them. Each pixel is self-emissive, so no backlight is required. This produces perfect black levels (pixels are fully off), higher contrast ratios, faster response times, and thinner panels than LCD. However, OLEDs may suffer from burn-in over long periods of static display.
有机发光二极管(OLED)显示器使用有机化合物,当电流通过时直接发光。每个像素均为自发光,因此无需背光。相比 LCD,OLED 可实现完美的黑色(像素完全关闭)、更高的对比度、更快的响应速度以及更薄的屏幕。然而,长时间显示静态画面时 OLED 可能会出现“烧屏”现象。
9. Laser Printers | 激光打印机
Laser printing is based on the xerographic process involving six stages: charging, writing, developing, transferring, fusing, and cleaning.
激光打印基于静电复印原理,包括六个阶段:充电、写入、显影、转印、定影和清洁。
- Charging: A corona wire or primary charge roller applies a uniform negative charge to the photosensitive drum.
- Writing: A laser beam is modulated and reflected by a rotating mirror onto the drum, discharging specific areas to form a latent electrostatic image.
- Developing: Positively charged toner particles are attracted to the discharged regions of the drum.
- Transferring: A stronger charge pulls the toner from the drum onto the paper.
- Fusing: Heated rollers melt the toner so it bonds permanently to the paper.
- Cleaning: Excess toner is removed from the drum before the next cycle.
- 充电:电晕线或主充电辊对感光鼓表面均匀施加负电荷。
- 写入:激光束经旋转反射镜调制后照射到感光鼓上,使特定区域放电,形成潜像。
- 显影:带正电的碳粉颗粒被吸附到鼓上已放电的区域。
- 转印:更强的电荷将碳粉从感光鼓转移到纸张上。
- 定影:加热辊使碳粉熔化并永久固定在纸上。
- 清洁:清除感光鼓上残留的碳粉,为下一循环作准备。
Laser printers offer high speed, high resolution, and low cost per page, making them ideal for high-volume text printing.
激光打印机速度快、分辨率高、单页成本低,非常适合大批量文本打印。
10. Inkjet and Dot-Matrix Printers | 喷墨与点阵打印机
Inkjet printers work by ejecting microscopic droplets of liquid ink onto paper. Thermal inkjet printers heat the ink in a tiny chamber, creating a vapour bubble that forces a droplet out of the nozzle. Piezoelectric inkjet printers instead use a piezoelectric crystal that changes shape when a voltage is applied, mechanically pushing ink out. The print head moves horizontally across the page, producing high-quality colour images with resolutions up to 4800 dpi or more.
喷墨打印机通过将微小墨滴喷射到纸张上来工作。热发泡式喷墨打印机在微小的腔室内加热墨水,产生蒸汽泡,将墨滴从喷嘴中挤出。压电式喷墨打印机则利用压电晶体在施加电压时改变形状的特性,以机械方式将墨水推出。打印头在页面上水平移动,可输出分辨率高达 4800 dpi 或更高的高质量彩色图像。
Dot-matrix printers are impact printers that use a print head containing a matrix of pins. The pins strike an ink-soaked ribbon against the paper, forming characters as a pattern of dots. Although noisy and low-resolution, they can print through multi-part carbon-copy forms, which makes them still useful for invoices and receipts.
点阵打印机是一种击打式打印机,其打印头包含一个由针组成的矩阵。打印针击打浸有墨水的色带,使其接触纸张,以点的图案形成字符。尽管噪声大、分辨率低,但它能打印多联复写表格,因此在发票和收据领域仍有一席之地。
11. Projectors and Actuators | 投影仪与执行器
Digital light processing (DLP) projectors use an array of microscopic mirrors, one for each pixel. Each mirror can tilt toward the light source (ON) or away from it (OFF), reflecting light through a colour wheel onto the screen. The rapid toggling of mirrors creates the perception of full-colour images.
数字光处理(DLP)投影仪使用一个微型镜面阵列,每个像素对应一面微镜。每面镜子可朝光源方向倾斜(开启)或偏离光源(关闭),将光经色轮反射到屏幕上。镜面的快速切换使人眼感知到全彩图像。
Android system in a robot — a robotic arm — receives digital commands and convert them into physical motion. An electric motor or servo actuator converts electrical energy into rotational force. The controller sends pulse-width modulated (PWM) signals to set the motor’s position and speed. Actuators are essential for closed-loop control systems, where the computer adjusts output based on sensor feedback.
例如,机器人手臂中的执行器接收数字命令并将其转换为物理运动。电动机或伺服执行器将电能转换为旋转力。控制器发送脉宽调制(PWM)信号来设定电机的位置和速度。执行器在闭环控制系统中至关重要——计算机根据传感器反馈实时调整输出。
12. Selecting the Right I/O Device | 选择合适的 I/O 设备
When choosing an input device, consider the nature of the data (text, image, audio, physical quantity), required speed and accuracy, user skill level, and cost. For output, key criteria include resolution, speed, colour accuracy, media type, noise level, and running costs.
选择输入设备时,应考虑数据性质(文本、图像、音频、物理量)、所需速度与精度、用户技能水平以及成本。对于输出设备,关键标准包括分辨率、速度、色彩准确性、介质类型、噪声水平和运行成本。
| Device | Input/Output | Best for |
| Keyboard | Input | Text entry |
| Flatbed scanner | Input | Document digitisation |
| OLED monitor | Output | High-contrast visual display |
| Laser printer | Output | High-volume text printing |
| 设备 | 输入/输出 | 最适用于 |
| 键盘 | 输入 | 文本录入 |
| 平板扫描仪 | 输入 | 文档数字化 |
| OLED 显示器 | 输出 | 高对比度视觉显示 |
| 激光打印机 | 输出 | 大批量文本打印 |
Understanding the underlying working principles of I/O devices helps you not only answer exam questions with confidence, but also make better engineering choices in real-world system design.
理解输入输出设备的底层工作原理,不仅能让你自信应对考试题目,还能在实际系统设计时做出更明智的工程决策。
Published by TutorHao | Computer Science Revision Series | aleveler.com
更多咨询请联系16621398022(同微信)
屏轩国际教育cambridge primary/secondary checkpoint, cat4, ukiset,ukcat,igcse,alevel,PAT,STEP,MAT, ibdp,ap,ssat,sat,sat2课程辅导,国外大学本科硕士研究生博士课程论文辅导