数据传输(data transmission)意味着把数据从一个地方移到另一个——例如从你的计算机到一个网站,或从一部手机到一台打印机。
数据常常沿一根电缆行进。下面显示两种常见的。


在它被发送之前,数据被分解成叫数据包(packets)的小的、相等大小的片。每个数据包分别行进,而它们在另一端被重新组合。
用数据包有好处:
- 若一个数据包丢失或损坏,只有那个数据包被再次发送,而不是整个文件;
- 数据包能走不同的路由,所以一个繁忙或损坏的路由能被避免;
- 许多用户能同时共享同一个连接。
IGCSE 计算机科学 · 第 2 主题
数据传输(data transmission)意味着把数据从一个地方移到另一个——例如从你的计算机到一个网站,或从一部手机到一台打印机。
数据常常沿一根电缆行进。下面显示两种常见的。


在它被发送之前,数据被分解成叫数据包(packets)的小的、相等大小的片。每个数据包分别行进,而它们在另一端被重新组合。
用数据包有好处:
| 英文 | 中文 | 拼音 |
|---|---|---|
| data transmission | 数据传输 | shù jù chuán shū |
| packets | 数据包 | shù jù bāo |
| Candidates should be able to: | Notes and guidance |
|---|---|
| 1 (a) Understand that data is broken down into packets to be transmitted | |
| (b) Describe the structure of a packet | • A packet of data contains a: – packet header – payload – trailer • The packet header includes the: – destination address – packet number – originator’s address |
| (c) Describe the process of packet switching | • Data is broken down into packets • Each packet could take a different route • A router controls the route a packet takes • Packets may arrive out of order • Once the last packet has arrived, packets are reordered |
| 2 (a) Describe how data is transmitted from one device to another using different methods of data transmission | • Including: – serial – parallel – simplex – half-duplex – full-duplex |
| (b) Explain the suitability of each method of data transmission, for a given scenario | • Including the advantages and disadvantages of each method |
| 3 Understand the universal serial bus (USB) interface and explain how it is used to transmit data | • Including the benefits and drawbacks of the interface |
来源:剑桥国际大纲
每个数据包有三部分。

| 部分 | 它容纳什么 |
|---|---|
| 包头(packet header) | 控制信息(见下面) |
| 有效载荷(payload) | 被携带的实际数据 |
| 尾部(trailer) | 显示数据包在哪里结束,加上一个错误检查 |
包头容纳:
| 英文 | 中文 | 拼音 |
|---|---|---|
| packet header | 包头 | bāo tóu |
| payload | 有效载荷 | yǒu xiào zài hè |
| trailer | 尾部 | wěi bù |
| address | 地址 | dì zhǐ |
数据包交换(packet switching)是数据包在一个网络上被发送的方式。

Step through packet switching. Splitting a file into addressed packets is why one lost packet only needs resending, and why many users can share the same line.
| 英文 | 中文 | 拼音 |
|---|---|---|
| packet switching | 数据包交换 | shù jù bāo jiāo huàn |
| routers | 路由器 | lù yóu qì |
| 串行(serial) | 并行(parallel) | |
|---|---|---|
| 如何 | 一次一位,沿一根导线 | 一次几位,沿几根导线 |
| 距离 | 长距离上好 | 只在短距离上好 |
| 成本 | 更便宜(更少的导线) | 更昂贵(更多的导线) |
| 错误 | 位保持顺序 | 位在长导线上能稍微不同的时间到达 |
串行沿一根单一的导线一个接一个地发送位。并行沿几根导线同时发送几位,所以它在短距离上更快。

这些描述数据能行进的方向。

| 方法 | 方向 |
|---|---|
| 单工(simplex) | 只一个方向(例如计算机 → 打印机) |
| 半双工(half-duplex) | 两个方向,但一次只一个(例如对讲机) |
| 全双工(full-duplex) | 同时两个方向(例如电话通话) |
选择取决于距离、需要的速度、成本,以及数据是否必须同时两个方向行进。
| 英文 | 中文 | 拼音 |
|---|---|---|
| serial | 串行 | chuàn xíng |
| parallel | 并行 | bìng xíng |
| simplex | 单工 | dān gōng |
| half-duplex | 半双工 | bàn shuāng gōng |
| full-duplex | 全双工 | quán shuāng gōng |
通用串行总线(universal serial bus,USB)是一个把设备连接到一台计算机的常见接口(interface,一个连接点)。
好处:
缺点:

| 英文 | 中文 | 拼音 |
|---|---|---|
| universal serial bus | 通用串行总线 | tōng yòng chuàn xíng zǒng xiàn |
| interface | 接口 | jiē kǒu |
| Candidates should be able to: | Notes and guidance |
|---|---|
| 1 Understand the need to check for errors after data transmission and how these errors can occur | • Errors can occur during data transmission due to interference, e.g. data loss, data gain and data change |
| 2 Describe the processes involved in each of the following error detection methods for detecting errors in data after transmission: parity check (odd and even), checksum and echo check | • Including parity byte and parity block check |
| 3 Describe how a check digit is used to detect errors in data entry and identify examples of when a check digit is used, including international standard book numbers (ISBN) and bar codes | |
| 4 Describe how an automatic repeat query (ARQ) can be used to establish that data is received without error | • Including the use of: – positive/negative acknowledgements – timeout |
来源:剑桥国际大纲
当数据行进时,干扰(interference)能改变它。三件事能出错:
所以接收方检查数据是否正确地到达。
| 英文 | 中文 | 拼音 |
|---|---|---|
| interference | 干扰 | gān rǎo |
一个奇偶校验(parity check)给每个字节加一个额外的位,奇偶校验位(parity bit)。有两种类型:

例子(偶校验):数据 1011001 有四个 1,它已经是偶,所以奇偶校验位是 0:
parity bit + data
0 1011001
要找到一个错误:接收方数 1。若约定了偶校验但一个字节到达时带奇数目的 1,一个错误在传输期间发生了。
一个奇偶校验不能找到每个错误。若两位翻转,计数可能仍看起来正确。
例题。 一个单一的奇偶校验位告诉你一个错误发生了,但不告诉在哪里。一个奇偶校验块(parity block)能找到确切的位。几个字节一起被发送,每个带一个行奇偶校验位,而底部一个额外的奇偶校验字节(parity byte)为每一列容纳一个奇偶校验位。下面用了偶校验,而一位在传输期间被翻转。找到它。
b1 b2 b3 b4 b5 | parity
byte 1 1 0 1 1 0 | 1
byte 2 0 1 1 0 1 | 1
byte 3 1 1 1 1 0 | 1 <- row: odd number of 1s
byte 4 0 0 1 1 0 | 0
------------------------------
parity 0 0 1 1 1 | 1
^ column b3: odd number of 1s
行 byte 3 打破偶校验,而列 b3 打破偶校验。翻转的位是它们交叉的地方:byte 3, bit b3。把它从 1 改回 0 修复数据。一个单一的奇偶校验位只说一个错误发生了;一个奇偶校验块确切地说在哪里,所以接收方甚至能修复它。
一个校验和(checksum)是发送前从所有数据算出的一个值。接收方从它收到的数据再次算出校验和。若两个值不匹配,一个错误发生了,而数据被重新发送。
在一个回送校验(echo check)中,接收方把数据发送回发送方。发送方把它与原始比较。若它们不同,一个错误发生了。(这需要数据被发送两次,所以它慢。)
自动重传请求(Automatic Repeat reQuest,ARQ)用叫确认(acknowledgements)的消息。
一个校验码(check digit)是放在一个数末端的一个额外数字,从其他数字算出。它被用来在一个数被键入时找到错误。
当数被输入时,校验码被再次计算并比较。它能捕捉:
校验码被用于条形码(barcodes)和 ISBN(书号)。
Classify concrete examples by the computing idea they demonstrate.
| 英文 | 中文 | 拼音 |
|---|---|---|
| parity check | 奇偶校验 | jī ǒu jiào yàn |
| parity bit | 奇偶校验位 | jī ǒu jiào yàn wèi |
| parity block | 奇偶校验块 | jī ǒu jiào yàn kuài |
| parity byte | 奇偶校验字节 | jī ǒu jiào yàn zì jié |
| checksum | 校验和 | jiào yàn hé |
| echo check | 回送校验 | huí sòng jiào yàn |
| automatic repeat request | 自动重传请求 | zì dòng zhòng chuán qǐng qiú |
| acknowledgements | 确认 | què rèn |
| timeout | 超时 | chāo shí |
| check digit | 校验码 | jiào yàn mǎ |
| transposition error | 换位错误 | huàn wèi cuò wù |
| barcodes | 条形码 | tiáo xíng mǎ |
| Candidates should be able to: | Notes and guidance |
|---|---|
| 1 Understand the need for and purpose of encryption when transmitting data | |
| 2 Understand how data is encrypted using symmetric and asymmetric encryption | • Asymmetric encryption includes the use of public and private keys |
来源:剑桥国际大纲
加密(encryption)打乱数据,使它在被错误的人拦截(intercepted,捕获)时不能被理解。可读的数据叫明文(plaintext);加密后它变成密文(ciphertext)。
加密不阻止数据被拦截。它只阻止数据被理解。
对称加密(symmetric encryption)用一个单一的密钥(key)来加密和解密数据两者。发送方和接收方必须共享这个同样的秘密密钥。风险是密钥本身可能在被共享时被偷。
非对称加密(asymmetric encryption)用两个不同的密钥:
用公钥加密的数据只能用匹配的私钥解密,所以密钥从不必被共享。这比共享一个秘密密钥更安全。

Shift each letter to encrypt a message — the simplest idea of a cipher and its key.
| 英文 | 中文 | 拼音 |
|---|---|---|
| encryption | 加密 | jiā mì |
| intercepted | 拦截 | lán jié |
| plaintext | 明文 | míng wén |
| ciphertext | 密文 | mì wén |
| symmetric encryption | 对称加密 | duì chèn jiā mì |
| key | 密钥 | mì yào |
| asymmetric encryption | 非对称加密 | fēi duì chèn jiā mì |
| public key | 公钥 | gōng yào |
| private key | 私钥 | sī yào |
逐步学习,并即时检测练习。